Authentication and API keys
How API keys work, the difference between test and live mode, and how to rotate a key safely.
The Meetlane API uses secret API keys. Send the key in the Authorization header of every request.
curl https://api.example.com/v1/event_types \ -H "Authorization: Bearer $MEETLANE_API_KEY"Test and live mode
Section titled “Test and live mode”| Key prefix | Mode | What it can do |
|---|---|---|
ml_test_ |
Test | Reads and writes test data only. No emails, no calendar events. |
ml_live_ |
Live | Creates real bookings, sends emails and updates calendars. |
Objects created in test mode are invisible in live mode, and the other way round.
Keep keys secret
Section titled “Keep keys secret”Store keys in environment variables or a secrets manager, and only call the API from your server.
Rotate a key
Section titled “Rotate a key”- Go to Settings → Developers → API keys and select Roll key on the key you want to replace.
- Choose how long the old key keeps working: immediately, 1 hour, 24 hours or 7 days.
- Deploy the new key, then let the old one expire.
Restricted keys
Section titled “Restricted keys”Restricted keys only have the permissions you choose, for example read bookings without create bookings. Use them for analytics jobs and third-party tools.