Create API key
Create a new API key with specified permissions and metadata. The key value is returned only once for security.
AuthorizationBearer <token>
In: header
namestring
Human-readable name for the API key
Length
1 <= lengthdescription?string
Description of the API key purpose
rolestring
Role/permissions for this API key
Value in
"admin" | "account_manager" | "viewer"expires_at?string
When the API key should expire (optional)
Format
date-timeResponse Body
const body = JSON.stringify({ "name": "Production Integration", "role": "account_manager"})fetch("https://app.orbiqhq.com/api/v1/integrations/api-keys", { method: "POST", headers: { "Content-Type": "application/json" }, body}){
"success": true,
"data": {
"token": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string",
"description": "string",
"token": "tc_abcd1234567890abcd1234567890abcd1234567890abcd1234567890abcd1234",
"role": "string",
"expires_at": "2025-12-31T23:59:59Z",
"created_at": "2025-01-01T10:00:00Z"
},
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
}
}{
"success": false,
"status": 400,
"error": "Invalid role specified: invalid_role"
}Empty
Empty
How is this guide?