Skip to main content
GET
/
api
/
external
/
v1
/
locations
curl -X GET "https://www.okasie.be/api/external/v1/locations?withCounts=true" \
  -H "Authorization: Bearer YOUR_API_SECRET"
{
  "data": [
    {
      "id": "8f8f8f8f-8f8f-408f-a8f8-8f8f8f8f8f8f",
      "parentId": null,
      "locationCode": "DEX-HQ",
      "companyName": "DEX Belgium NV",
      "fullName": "DEX Belgium",
      "displayName": "DEX Belgium",
      "email": "info@dex.be",
      "phone": "+32 3 123 45 67",
      "address": "Hoofdstraat 1",
      "postalCode": "2000",
      "city": "Antwerpen",
      "province": "Antwerpen",
      "logoUrl": "https://cdn.okasie.be/logos/dex.png",
      "metadata": {},
      "parent": null,
      "isRoot": true,
      "stats": {
        "activeListings": 250,
        "totalListings": 312,
        "avgActivePrevMonth": 238.5
      },
      "updatedAt": "2024-10-05T09:12:01Z"
    }
  ],
  "meta": {
    "total": 5,
    "profileIds": ["8f8f8f8f-8f8f-408f-a8f8-8f8f8f8f8f8f"],
    "rootProfileIds": ["8f8f8f8f-8f8f-408f-a8f8-8f8f8f8f8f8f"],
    "filters": {
      "parentId": null,
      "search": null
    },
    "partner": {
      "id": "partner-id",
      "name": "Partner Name"
    }
  }
}

List Locations

Retrieve dealer locations within your partner access scope. Supports hierarchical queries and optional listing counts.

Query Parameters

parentId
string
Filter to locations under this parent profile UUID. Alias: parent_id
includeChildren
boolean
default:"true"
Include child locations in the result set
withCounts
boolean
default:"true"
Include listing counts per location
Search by name, city, province, or location code

Response

Location Response Field Names

FieldDescription
idLocation profile UUID
parentIdParent location UUID
isRootWhether this location is in the partner root scope
locationCodeUnique location code
companyNameCompany name
fullNameFull profile name
displayNameDisplay name
emailContact email
phoneContact phone
addressStreet address
postalCodePostal code
cityCity
provinceProvince
logoUrlLogo URL
metadataLocation metadata
parent.idParent profile UUID
parent.locationCodeParent location code
parent.companyNameParent company name
parent.fullNameParent full name
parent.displayNameParent display name
stats.activeListingsActive listing count
stats.totalListingsTotal listing count
stats.avgActivePrevMonthAverage active listings previous month, when available
updatedAtISO 8601 last update timestamp
meta.totalNumber of returned locations
meta.profileIdsEffective profile IDs in response scope
meta.rootProfileIdsPartner root profile IDs, when available
meta.filters.parentIdApplied parent filter
meta.filters.searchApplied search filter
meta.partnerPartner metadata
data
array
Array of location objects
meta
object
Request metadata including partner info
curl -X GET "https://www.okasie.be/api/external/v1/locations?withCounts=true" \
  -H "Authorization: Bearer YOUR_API_SECRET"
{
  "data": [
    {
      "id": "8f8f8f8f-8f8f-408f-a8f8-8f8f8f8f8f8f",
      "parentId": null,
      "locationCode": "DEX-HQ",
      "companyName": "DEX Belgium NV",
      "fullName": "DEX Belgium",
      "displayName": "DEX Belgium",
      "email": "info@dex.be",
      "phone": "+32 3 123 45 67",
      "address": "Hoofdstraat 1",
      "postalCode": "2000",
      "city": "Antwerpen",
      "province": "Antwerpen",
      "logoUrl": "https://cdn.okasie.be/logos/dex.png",
      "metadata": {},
      "parent": null,
      "isRoot": true,
      "stats": {
        "activeListings": 250,
        "totalListings": 312,
        "avgActivePrevMonth": 238.5
      },
      "updatedAt": "2024-10-05T09:12:01Z"
    }
  ],
  "meta": {
    "total": 5,
    "profileIds": ["8f8f8f8f-8f8f-408f-a8f8-8f8f8f8f8f8f"],
    "rootProfileIds": ["8f8f8f8f-8f8f-408f-a8f8-8f8f8f8f8f8f"],
    "filters": {
      "parentId": null,
      "search": null
    },
    "partner": {
      "id": "partner-id",
      "name": "Partner Name"
    }
  }
}

Error Responses

StatusCodeDescription
401UNAUTHORIZEDInvalid or missing API key
500SERVER_ERRORFailed to load locations