# Ordstage API

> Connect your own systems to Ordstage with a REST API, signed webhooks and a test workspace.

Source: https://www.ordstage.com/docs/

The Ordstage API lets a business connect its own systems (a clinic system, a hotel PMS, a booking site, a CRM) to
Ordstage. Your system can read and write the same data the Ordstage dashboard and assistant use, and Ordstage tells
your system when something changes through signed webhooks.

<div class="cards">
<a class="card" href="https://www.ordstage.com/docs/quickstart/"><strong>Quickstart</strong><span>Make your first request in five minutes.</span></a>
<a class="card" href="https://www.ordstage.com/docs/reference/"><strong>API reference</strong><span>Every endpoint, with examples and Try it.</span></a>
<a class="card" href="https://www.ordstage.com/docs/webhooks/"><strong>Webhooks</strong><span>Events, payloads and signature checks.</span></a>
<a class="card" href="https://www.ordstage.com/docs/sandbox/"><strong>Sandbox</strong><span>Build against a test workspace with test keys.</span></a>
</div>

## The basics

| | |
|---|---|
| Base URL | `https://api.ordstage.com/v1` |
| Format | JSON in and out (`Content-Type: application/json`), UTF-8 |
| Authentication | A workspace API key in `Authorization: Bearer <key>` or `X-Api-Key: <key>` ([Authentication](https://www.ordstage.com/docs/authentication/)) |
| Live and test | `ord_live_` keys reach your real business; `ord_test_` keys reach its test workspace ([Sandbox](https://www.ordstage.com/docs/sandbox/)) |
| Errors | One envelope for every error, with a stable `code` ([Errors](https://www.ordstage.com/docs/errors/)) |
| Safe retries | `Idempotency-Key` on requests that create something ([Idempotency](https://www.ordstage.com/docs/idempotency/)) |
| Limits | Per key, per minute, reported in `X-RateLimit-*` headers ([Rate limits](https://www.ordstage.com/docs/rate-limits/)) |
| Versioning | `/v1` in the path; only additive changes within a version ([Versioning](https://www.ordstage.com/docs/versioning/)) |
| Times | ISO 8601. Booking times are local to the calendar and carry its offset |

Every answer carries a `Request-Id` header. Quote it when you contact support.

## Who can use the API

The API is part of paid plans (Growth and up). An owner or admin creates keys in **Settings → Developers** in the
Ordstage dashboard. A key can only do what its scopes allow, and only while the business still has the matching
feature: if the bookings module is turned off, keys with booking scopes stop reaching bookings at once, and start
again when it is turned back on.

## What is available

| Area | Endpoints | Scopes |
|---|---|---|
| Bookings | Calendars, availability, bookings from every source, pushing your own bookings and closures | `bookings:read`, `bookings:write` |

More areas (the business profile, team members, webhooks, assistants, conversations, contacts, leads, orders and
products) follow in later releases. They will be listed in the [changelog](https://www.ordstage.com/docs/versioning/#changelog).

## Where to start

1. Follow the [Quickstart](https://www.ordstage.com/docs/quickstart/) with a test key.
2. Read [Authentication](https://www.ordstage.com/docs/authentication/) before you put a key in production.
3. Subscribe to [webhooks](https://www.ordstage.com/docs/webhooks/) instead of polling for changes.
4. Use the [API reference](https://www.ordstage.com/docs/reference/) to try each endpoint against your test workspace.
