Skip to content

Latest commit

 

History

History
41 lines (32 loc) · 1.11 KB

File metadata and controls

41 lines (32 loc) · 1.11 KB

Vendure Plugin Dutch Postalcodes

Vendure version

Find Dutch addresses by postalcode and housenumber using https://postcode.tech's api. You need to register to obtain an API key, but registering is free of charge.

Getting started

  1. Register at https://postcode.tech/ to get an API key
  2. Add the following code to your plugins in vendure-config.ts
plugins: [
  DutchPostalCodePlugin.init('your-postcode.tech-apikey'),
  ...
]
  1. Start your Vendure server
  2. You can now lookup address details based on a postalcode and housenumber via the shop-api
query {
  dutchAddressLookup(input: { postalCode: "8932BR", houseNumber: "48" }) {
    lat
    lon
    postalCode
    houseNumber
    street
    city
    municipality
    province
  }
}

The api has permission Public set, which requires you to be authorized as guest or logged in customer. If you have an activeOrder, you're usually authorized.