NSN API Documentation (v1.0)

The API is available at https://api.nsn.org.uk/v1/

Documentation homepage https://docs.api.nsn.org.uk/


CURL example

The example below shows you how to authenticate against the API using CURL, and hit the /areas endpoint.

If you have an API key, enter it here to populate the examples:

/v1/areas

 'https://api.nsn.org.uk/v1/areas',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'GET',
  CURLOPT_HTTPHEADER => array(
    'x-api-key: {your api key}'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

Documentation homepage https://docs.api.nsn.org.uk/