SuprSync
Developer Portal
Sign In

Locations

GET /external/v1/locations

Returns all branches/locations for your company.

Query Parameters

None.

Response

[
  {
    "id": "branch-uuid-1",
    "name": "Downtown Office",
    "city": "Lagos",
    "state": "Lagos",
    "latitude": 6.5244,
    "longitude": 3.3792,
    "hexcode": "#00AD57",
    "symbol": "DO",
    "locationDetectionEnabled": true
  },
  {
    "id": "branch-uuid-2",
    "name": "Airport Terminal",
    "city": "Ikeja",
    "state": "Lagos",
    "latitude": 6.5774,
    "longitude": 3.3211,
    "hexcode": "#FF6B35",
    "symbol": "AT",
    "locationDetectionEnabled": false
  }
]

Response Fields

FieldTypeDescription
idstringUnique branch ID
namestringBranch display name
citystring | nullCity name
statestring | nullState/region name
latitudenumber | nullGeographic latitude
longitudenumber | nullGeographic longitude
hexcodestringColor code for UI display
symbolstringShort abbreviation (typically 2 characters)
locationDetectionEnabledbooleanWhether GPS-based clock-in is enabled

Example

curl -X GET "https://api.suprsync.com/external/v1/locations" \
  -H "x-api-key: api_your_client_id" \
  -H "x-api-secret: sec_your_client_secret"

Create Location

POST /external/v1/locations

Creates a new branch/location for your company.

Request Body

FieldTypeRequiredDescription
namestringYesLocation name
addressstringNoStreet address
countryIdstringNoCountry ID
stateIdstringNoState/region ID
cityIdstringNoCity ID
zipCodestringNoPostal code
hexcodestringNoColor hex code
symbolstringNoShort abbreviation
latitudenumberNoGeographic latitude
longitudenumberNoGeographic longitude
curl -X POST "https://api.suprsync.com/external/v1/locations" \
  -H "x-api-key: api_your_client_id" \
  -H "x-api-secret: sec_your_client_secret" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Uptown Office", "hexcode": "#FF6B35", "symbol": "UO" }'

Response (201 Created)

{
  "id": "branch-uuid-new",
  "name": "Uptown Office",
  "address": "",
  "latitude": null,
  "longitude": null,
  "hexcode": "#FF6B35",
  "symbol": "UO"
}

Update Location

PATCH /external/v1/locations/:id

Updates an existing location. Send only the fields you want to change.

curl -X PATCH "https://api.suprsync.com/external/v1/locations/branch-uuid-1" \
  -H "x-api-key: api_your_client_id" \
  -H "x-api-secret: sec_your_client_secret" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Uptown Office - Renamed" }'

Response (200 OK)

{
  "id": "branch-uuid-1",
  "name": "Uptown Office - Renamed"
}

Notes

  • Results are ordered alphabetically by name.
  • Sensitive fields (address, zip code) are not included in the GET response.
  • Plan limits on locations are bypassed for external API clients.