GET
/api/public/v1/location-hours

Get location hours

Read all 7 days of location hours for a location.

Required scope

The access token must carry this scope. A token missing it gets 403 Forbidden. Grant them to an API client under Dev Tools → API, to an assistant or CLI sign-in when you approve or edit it under Dev Tools, and to a teammate under Employee → Permissions.

location:hours:read

Query Parameters

NameTypeRequiredDescription
locationIdstringRequiredLocation to query.
GETExample request
curl
curl -X GET "https://www.pxb.app/api/public/v1/location-hours" \
  -H "Authorization: Bearer your_access_token"
200Example response
json
{
  "message": "Location hours retrieved successfully!",
  "content": {
    "hours": [
      {
        "dayOfWeek": 0,
        "openTime": null,
        "closeTime": null,
        "isClosed": true,
        "is24Hours": false
      },
      {
        "dayOfWeek": 1,
        "openTime": "09:00",
        "closeTime": "17:00",
        "isClosed": false,
        "is24Hours": false
      }
    ]
  }
}

In the console

The same thing done by hand, for anyone comparing the API against the screen they already use.

Company menu → Locations → Business hours
/dashboard
  1. Open the company menu → Locations.
  2. Open the ⋯ menu beside a location → Business hours.