Addressfinder

The best way to find exact addresses in New Zealand

  • Skip to Main Navigation
  • Skip to Footer Sitemap
  • Skip to Top
  • Pricing
  • Features
    • Autocomplete
      Search addresses and locations as you type
    • Bulk Cleansing
      Verify a database of addresses
    • Geocode Addresses
      Collect addresses and GPS coordinates together
    • Bounding Box
      Collect all addresses within a defined area
    • MORE FEATURES
  • About us
  • Case studies
  • FAQ
  • Contact
  • Blog
  • JavaScript widget docs
  • API developer docs
  • Pricing
  • Features
    • Autocomplete
      Search addresses and locations as you type
    • Bulk Cleansing
      Verify a database of addresses
    • Geocode Addresses
      Collect addresses and GPS coordinates together
    • Bounding Box
      Collect all addresses within a defined area
    • MORE FEATURES
  • More
    • Company & product
      • About Us
      • Case Studies
      • FAQ
      • Partners
      • Blog
      Contact Us
    • Integrations
      • Magento
      • WooCommerce
      • BigCommerce
      • Salesforce
      • Shopify Plus
      See all integrations
    • JavaScript widget docs
      • Integration Guide
      • Widget Code Generator
      • Widget Reference
      • Code Examples
      See all JavaScript docs
    • API developer docs
      • Address Autocomplete
      • Address Metadata
      • Address Verification
      • API Errors
      See all API docs
  • Login
Frequently asked questions

Can I write my own autocomplete service?

We suggest that developers use our Javascript widget to provide autocomplete capability to their users.

If you decide to write your own autocomplete service, then you will need to follow these guidelines.

Make a GET request

Addressfinder is expecting that an HTTP GET request is made. Although an HTTP POST request is supported, it will add extra complexity for your developers. The user experience will be degraded with a POST request as a CORS pre-flight request will be required.

Use a simple request

Requests to the Addressfinder API from a browser are classified as “Cross Origin” as they are made to a different domain than the main web page. These requests are subject to the CORS mechanisms which are built into all modern browsers.

Simple requests are HTTP GET requests that meet certain criteria such as allowing headers and content types. You can read more about the criteria here:

https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS#Simple_requests

Make a secure requests (HTTPS)

You should always make requests to our secure endpoint using HTTPS. Support of unencrypted HTTP requests is only retained for backwards compatibility purposes, and will eventually be disabled.

In addition, use of HTTPS endpoint will allow the browser to make HTTP version 2 requests. These are substantially faster, and will give a better user experience.

Request origin

For authentication, the requests must be sent from a domain which has been approved on your Addressfinder account. The Referer header, which is automatically included by the browser, is used for this purpose.

Secret parameter

You should not include the API secret token in any of your API calls. The secret is intended for server-to-server API calls only. By including the secret in a browser-based API call, this value would be visible to 3rd parties. This could result in your account being abused by malicious parties.

The Addressfinder API performs a safety check to ensure that the secret value has not been included. It will return a 1008 error if the secret has been included. See https://addressfinder.nz/api/nz/address/autocomplete/#errors

Domain parameter

The domain parameter is not intended for use in the web browser. If you include it, the API will return an error result.

Address Autocomplete and Metadata APIs

The Address Autocomplete API must be used in conjunction with the Address Metadata API.

We expect that several calls to the Autocomplete API would be made as the user types in a portion of their address. The results of the Autocomplete API should be displayed to the user, normally in a popup style panel.

When the user identifies the desired address, they would select that address. At that point, you should make a call to the Address Metadata API. This would return all of the individual metadata for that address.

General Request Parameters

Include other request parameters in your request string as necessary. These will determine the types of addresses and data returned in the response. https://addressfinder.nz/api/nz/address/autocomplete/#build

https://addressfinder.nz/faq/can-i-write-my-own-autocomplete-service/
Addressfinder logo
Addressfinder provides speedy, accurate and dependable address autocompletion at a fair price. Easily integrate our address finder software with your site to start enjoying our address verification, address autocomplete and other address services today.

Sitemap

  • Home
  • About
  • Contact
  • Blog
  • FAQ
  • Pricing
  • Case Studies
  • Status Page
  • Privacy Policy
  • Terms & Conditions
  • Features
  • Address Metadata
  • Bulk Cleansing
  • Geocode Addresses
  • Reverse Address Lookup
  • Points of Interest
  • Street, Suburb & City Search
  • Bounding Box Search
  • Postcode Finder
  • Address Verification
  • Integrations
  • WooCommerce
  • BigCommerce
  • Shopify Plus
  • Magento
  • Salesforce
  • Spiffy Stores
  • iOS
  • Ruby
  • HubSpot
  • Drupal
  • Microsoft Dynamics 365
  • Vue
  • Gravity Forms
  • React
  • API Documentation
  • Address Autocomplete
  • Address Metadata
  • Address Verification
  • API Errors
  • Another 6 APIs
  • AU APIs specs
  • International APIs
  • Widget Documentation
  • Integration Guide
  • International Integration Guide
  • Code Generator
  • Code Examples
  • Javascript Reference
Addressfinder is also available in Australia
Terms and Conditions | Privacy
Copyright © 2022 Addressfinder, New Zealand