Authorization header.
API Key Format
Keys follow a prefixed format inspired by Stripe — the prefix tells you the key type at a glance:| Key Type | Prefix | Purpose |
|---|---|---|
| Live | pms_live_ | Production — creates real guest records, triggers dashboard updates |
| Test | pms_test_ | Sandbox — validates your payloads but writes NO data. Learn more → |
How to Authenticate
Include your API key as a Bearer token in theAuthorization header of every request:
All POST endpoints also require an
Idempotency-Key header. See Testing & Rate Limits for details.How to Get an API Key
API keys are generated by the hotel administrator (not by RecepAI or the PMS provider):Hotel admin opens Settings → PMS Integration
In the RecepAI admin panel, the hotel staff navigates to their PMS Integration settings page.
Hotel admin clicks 'Generate API Key'
The system generates a live key (
pms_live_) and a test key (pms_test_) together as a pair. Both full keys are displayed once — after that, only masked previews are visible.Hotel admin shares the key with you
The hotel sends the API key and their hotel slug to your technical team through a secure channel. Recommended options:
- One-time secret link: onetimesecret.com — the link self-destructs after one view
- Password manager sharing (1Password, Bitwarden, etc.)
- Encrypted email (PGP, S/MIME)
Key Lifecycle
| Action | Who does it | What happens |
|---|---|---|
| Generate | Hotel admin | A live key and test key are created together as a pair. Previous revoked keys are not affected. |
| Use | Your PMS | Every API call authenticates with the live or test key. Usage is tracked (last used, request count). |
| Revoke | Hotel admin | Both keys (live and test) are immediately invalidated. All subsequent requests return 401 KEY_REVOKED. |
| Regenerate | Hotel admin | Both old keys are revoked and a new pair is generated in a single operation. |