Docs
API Reference

API Reference

REST endpoints for the core Servicebay resources

The Servicebay API exposes an organisation's core resources through predictable REST endpoints. Pick a resource below to see its endpoints, code examples, and any quirks worth knowing about.

Resources

Base URL

All requests go to:

https://developer.servicebay.io/api/v1

Authentication

Every request must carry an X-API-Key header containing a key created in the developer portal. Each key is bound to one organisation and cannot read or write data outside it.

curl -X GET \
  'https://developer.servicebay.io/api/v1/organisations/{orgId}/customers' \
  -H 'X-API-Key: sk_live_your_api_key'

Requests can also carry an OAuth access token (Authorization: Bearer …) instead of an API key — same endpoints, same envelope, with per-scope permissions.

See Authentication for the full key lifecycle and Two-Factor Authentication for the portal sign-in flow.

Response envelope

Every response uses the same JSON envelope, so client code only needs one parsing path.

Success

{
  "success": true,
  "data": { /* resource payload */ }
}

Error

{
  "success": false,
  "error": "Description of what went wrong"
}

See Error Handling for the full status code reference.

Rate limits

100 requests per minute per API key. Every response includes X-RateLimit-Limit, X-RateLimit-Remaining, and X-RateLimit-Reset headers so you can pace yourself. See Rate Limiting for retry patterns.

Interactive reference

Each resource page below embeds request/response schemas and code samples (cURL, JavaScript, Python) generated from the OpenAPI spec. For the raw contract, download the OpenAPI 3.1 spec.

Try it live

The API Playground in the developer portal sends real requests against your organisation with your API key — useful for exploring responses before you write integration code. See Developer Portal for how key caching and the organisation selector work.