curl -X GET "https://www.okasie.be/api/external/v1/locations?withCounts=true" \
-H "Authorization: Bearer YOUR_API_SECRET"
const response = await fetch(
"https://www.okasie.be/api/external/v1/locations?withCounts=true",
{
headers: {
Authorization: `Bearer ${process.env.PARTNER_SECRET}`,
},
}
);
const data = await response.json();
data.data.forEach(location => {
console.log(`${location.displayName}: ${location.stats?.activeListings} listings`);
});
{
"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"
}
}
}
Locations
List Locations
Retrieve dealer locations within your access scope
GET
/
api
/
external
/
v1
/
locations
curl -X GET "https://www.okasie.be/api/external/v1/locations?withCounts=true" \
-H "Authorization: Bearer YOUR_API_SECRET"
const response = await fetch(
"https://www.okasie.be/api/external/v1/locations?withCounts=true",
{
headers: {
Authorization: `Bearer ${process.env.PARTNER_SECRET}`,
},
}
);
const data = await response.json();
data.data.forEach(location => {
console.log(`${location.displayName}: ${location.stats?.activeListings} listings`);
});
{
"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
string
Filter to locations under this parent profile UUID. Alias:
parent_idboolean
default:"true"
Include child locations in the result set
boolean
default:"true"
Include listing counts per location
string
Search by name, city, province, or location code
Response
Location Response Field Names
| Field | Description |
|---|---|
id | Location profile UUID |
parentId | Parent location UUID |
isRoot | Whether this location is in the partner root scope |
locationCode | Unique location code |
companyName | Company name |
fullName | Full profile name |
displayName | Display name |
email | Contact email |
phone | Contact phone |
address | Street address |
postalCode | Postal code |
city | City |
province | Province |
logoUrl | Logo URL |
metadata | Location metadata |
parent.id | Parent profile UUID |
parent.locationCode | Parent location code |
parent.companyName | Parent company name |
parent.fullName | Parent full name |
parent.displayName | Parent display name |
stats.activeListings | Active listing count |
stats.totalListings | Total listing count |
stats.avgActivePrevMonth | Average active listings previous month, when available |
updatedAt | ISO 8601 last update timestamp |
meta.total | Number of returned locations |
meta.profileIds | Effective profile IDs in response scope |
meta.rootProfileIds | Partner root profile IDs, when available |
meta.filters.parentId | Applied parent filter |
meta.filters.search | Applied search filter |
meta.partner | Partner metadata |
array
Array of location objects
Show Location properties
Show Location properties
string
Location profile UUID
string
Parent location UUID (null for root)
string
Unique location code
string
Legal company name
string
Full profile name
string
Display name
string
Contact email
string
Contact phone
string
Street address
string
Postal code
string
City
string
Province
string
Logo URL
object
Location metadata
object
Parent profile summary
boolean
True if this is a root/parent location
object
Listing statistics (when withCounts=true)
string
ISO 8601 last update timestamp
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"
const response = await fetch(
"https://www.okasie.be/api/external/v1/locations?withCounts=true",
{
headers: {
Authorization: `Bearer ${process.env.PARTNER_SECRET}`,
},
}
);
const data = await response.json();
data.data.forEach(location => {
console.log(`${location.displayName}: ${location.stats?.activeListings} listings`);
});
{
"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
| Status | Code | Description |
|---|---|---|
| 401 | UNAUTHORIZED | Invalid or missing API key |
| 500 | SERVER_ERROR | Failed to load locations |
⌘I