Uncategorized

API Access to NBNCo Rollout Data

EDIT  – It’s been brought to my attention this no longer works. Leaving it to gather dust rather than removing it.

NBNCo have an address search tool on their site to lookup service information for an address. The API it uses actually exposes more data than they show on the website. The API is not documented but it’s fairly self explanatory. Just be sure to add the correct referer header.

Unfortunately it probably won’t tell you anything you want to know, such as the availability of FTTP at your home address. Ahem.

Politics aside, I found that supplying only the lat and lng for an address is sufficient for a lookup, though I get some odd results; it’s not clear how and when they’re doing geocoding from the parameters you supply.

In curl-land:

curl -X GET \
'http://www.nbnco.com.au/api/map/search.html?\
lat={decimal latitude}&\
lng={decimal longitude}&\
streetNumber={street number}\&
street={street}\&
postCode={postCode}\&
state={VIC/NSW/TAS/QLD/WA/NT/SA} \
-H 'referer: http://www.nbnco.com.au/connect-home-or-business/check-your-address.html'

If you use Postman (and you should) for API testing, I’ve made a collection that supports this.

You’ll get a JSON response that follows this template:

{
"serviceAvailableAddress": false,
"servingArea": {
"isDisconnectionDatePassed": true,
"techTypeMapLabel": "nbn™ Fibre to the premises (FTTP)",
"techTypeDescription": "An nbn™ Fibre to the premises connection (FTTP) is used in circumstances where an optic fibre line will be run from the nearest available fibre node, to your premises.",
"rfsMessage": "",
"csaId": "CSA300000010862",
"addressStatus": "0",
"serviceType": "fibre",
"id": "fibre:3BRU-A0106",
"serviceStatus": "available",
"disconnectionDate": "02/01/2015",
"description": "XDA",
"serviceCategory": "brownfields",
"techTypeLabel": "Fibre to the premises (FTTP)"
},
"fsams": []
}

16 thoughts on “API Access to NBNCo Rollout Data

  1. Can you please elaborate somehow how can we implement this API into leaflet mapping api and search an address using textual adress?

    Like

    1. There are already plenty of good tutorials out there on using Leaflet and the answer really depends on how you’re building your site. I think the main thing you would have to consider is how to request the address from the user, validate it and geocode it, (i.e. getting the lat/lng value for a street address). I’d start with Google for that: https://developers.google.com/maps/documentation/geocoding/intro
      For something really simple, you might use a text search for an address (e.g. http://labs.easyblog.it/maps/leaflet-search/), and hook this up to the geocoder, NBN search, and display the attributes for the NBN service.

      Like

  2. I’m only getting the below response from postman
    {
    “servingArea”: null,
    “serviceAvailableAddress”: true,
    “rfsDateConfident”: false
    }

    Can you confirm they’ve removed most of the servingArea info?

    Like

  3. I’m late to the party, but I don’t think this works since they modified their site. At least the curl command does not.

    Like

  4. hi hamun2015, you can use the following to get location IDs in the vicinity of a GPS location:

    curl -s -H ‘Referer: https://www2.nbnco.com.au/residential/learn/rollout-map‘ ‘https://places.nbnco.net.au/places/v1/nearby?lat=-31.xxxxxxxxxxxxxxx&lng=115.xxxxxxxxxxxxxx&source=website_rollout_map’

    (replacing -31.xxxx with your latitude and 115.xxx with your longitude)

    and this to get detailed information on a location ID:

    curl -s -H ‘Referer: https://www2.nbnco.com.au/residential/learn/rollout-map‘ ‘https://places.nbnco.net.au/places/v2/details/LOCxxxxxxxxxxxx?source=website_rollout_map’

    Liked by 1 person

Leave a comment