- Overview
- Key Access Levels
- Basic Authentication Overview
- HMAC Authentication Overview
- SDKs
- Calven Data Models
- HMAC Authentication
- Presence
- Occupancy
- Time off
- Access Credentials
- Warehouse - Basic Auth
- Warehouse - HMAC Auth
Generate a token with an API key and client secret
POST
/v1/auth/token
auth
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.Example:
Authorization: Bearer ********************
Body Params application/json
client_id
string
required
client_secret
string
required
Example
{
"client_id": "string",
"client_secret": "string"
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://api.calven.com/v1/auth/token' \
--header 'Content-Type: application/json' \
--data-raw '{
"client_id": "string",
"client_secret": "string"
}'
Responses
🟢200Success
application/json
Body
access_token
string
required
expires_in
number
required
Example:
3600
token_type
string
required
Example
{
"access_token": "string",
"expires_in": 3600,
"token_type": "string"
}
🟠401Payload when auth header is missing or invalid