Assemble Developer Portal

Address book (3.0)

Download OpenAPI specification:Download

This documentation describes how to retrieve, store and update address book entries.

The address book is used to associate known addresses with resources throughout Assemble.

Address book

Address book listing

Retrieve a paginated response of address book entries.

The response will include organisation addresses and addresses that are specific to the user.

Authorizations:
JWT
query Parameters
q
string
Example: q=London

Search by address name

type
string
Enum: "point" "area"
Example: type=point

Filter by the address type

status
string
Default: "all"
Enum: "all" "active" "inactive"
Example: status=active

Filter by address status

global
boolean

Only show organisation addresses

o
string
Default: "d"
Enum: "a" "d"
Example: o=a

Order the results

s
string
Default: "id"
Enum: "id" "name"
Example: s=name

Sort the results

include
string
Value: "polygon"

Available includes for an address (comma separated list)

Responses

Response Schema: application/json
Array of objects (GeoLocation)
object

Response samples

Content type
application/json
{
  • "data": [
    • {
      • "id": 54654,
      • "name": "11 Downing St",
      • "status": "active",
      • "company_name": "string",
      • "street": "11 Downing St",
      • "street_second": "string",
      • "street_third": "string",
      • "city": "London",
      • "county": "Westminster",
      • "postcode": "SW1A 2AB",
      • "country": "United Kingdom",
      • "address": "11 Downing St, Westminster, London SW1A 2AB",
      • "lat": 51.503274,
      • "long": -0.127822
      }
    ],
  • "meta": {
    • "pagination": {
      • "total": "string",
      • "count": "string",
      • "per_page": "string",
      • "current_page": "string",
      • "total_pages": "string",
      • "links": {
        • "next": "string",
        • "previous": "string"
        }
      }
    }
}

Create a new address

Create a new address book entry

Authorizations:
JWT
Request Body schema: application/json
id
integer

The unique ID for this GeoLocation record

name
string

Geo location friendly name

status
string
Enum: "active" "inactive"

Geo location status

company_name
string
street
string

Address line 1

street_second
string

Address line 2

street_third
string

Address line 3

city
string

Address city

county
string

Address county

postcode
string

Address postcode

country
string

Address country

address
string

Full address details

lat
number

Latitude

long
number

Longitude

polygon
string

Feature GeoJSON of an polygon as a string

Responses

Response Schema: application/json
object (GeoLocation)

Request samples

Content type
application/json
Example
{
  • "name": "11 Downing St",
  • "status": "active",
  • "company_name": "string",
  • "street": "11 Downing St",
  • "city": "London",
  • "county": "Westminster",
  • "postcode": "SW1A 2AB",
  • "country": "United Kingdom",
  • "lat": 51.503274,
  • "long": -0.127822
}

Response samples

Content type
application/json
{
  • "data": {
    • "id": 54654,
    • "name": "11 Downing St",
    • "status": "active",
    • "company_name": "string",
    • "street": "11 Downing St",
    • "street_second": "string",
    • "street_third": "string",
    • "city": "London",
    • "county": "Westminster",
    • "postcode": "SW1A 2AB",
    • "country": "United Kingdom",
    • "address": "11 Downing St, Westminster, London SW1A 2AB",
    • "lat": 51.503274,
    • "long": -0.127822
    }
}

Show an address

Show a specific adddress book entry

Authorizations:
JWT
path Parameters
id
required
string
query Parameters
include
string
Value: "polygon"

Available includes for an address (comma separated list)

Responses

Response Schema: application/json
object (GeoLocation)

Response samples

Content type
application/json
{
  • "data": {
    • "id": 54654,
    • "name": "11 Downing St",
    • "status": "active",
    • "company_name": "string",
    • "street": "11 Downing St",
    • "street_second": "string",
    • "street_third": "string",
    • "city": "London",
    • "county": "Westminster",
    • "postcode": "SW1A 2AB",
    • "country": "United Kingdom",
    • "address": "11 Downing St, Westminster, London SW1A 2AB",
    • "lat": 51.503274,
    • "long": -0.127822
    }
}

Update an address

Update an existing address.

Depending on the address type, some information may not be editable.

Authorizations:
JWT
path Parameters
id
required
string
Request Body schema: application/json
status
string
Enum: "active" "inactive"

Geo location status

company_name
string
street
string

Address line 1

street_second
string

Address line 2

street_third
string

Address line 3

city
string

Address city

county
string

Address county

postcode
string

Address postcode

country
string

Address country

lat
number

Latitude

long
number

Longitude

polygon
string

Feature GeoJSON of an polygon as a string

Responses

Response Schema: application/json
object (GeoLocation)

Request samples

Content type
application/json
{
  • "status": "active",
  • "company_name": "string",
  • "street": "11 Downing St",
  • "street_second": "string",
  • "street_third": "string",
  • "city": "London",
  • "county": "Westminster",
  • "postcode": "SW1A 2AB",
  • "country": "United Kingdom",
  • "lat": 51.503274,
  • "long": -0.127822,
  • "polygon": "string"
}

Response samples

Content type
application/json
{
  • "data": {
    • "id": 54654,
    • "name": "11 Downing St",
    • "status": "active",
    • "company_name": "string",
    • "street": "11 Downing St",
    • "street_second": "string",
    • "street_third": "string",
    • "city": "London",
    • "county": "Westminster",
    • "postcode": "SW1A 2AB",
    • "country": "United Kingdom",
    • "address": "11 Downing St, Westminster, London SW1A 2AB",
    • "lat": 51.503274,
    • "long": -0.127822
    }
}

Delete an address

Delete an existing address.

Please note that addresses are not deleted but marked as inactive and may still appear in listings where inactive addresses are used.

Authorizations:
JWT
path Parameters
id
required
string

Responses

Response samples

Content type
application/json
{
  • "message": "400 Bad request",
  • "status_code": "400"
}