User API Keys
Create a new user API key
Authorization
session session_id<token>
Browser session cookie. Obtained via /api/auth/login.
In: cookie
Request Body
application/json
name*string
organization_id*string
Format
uuidtags*array<string>
user_id*string
Format
uuidexpires_at?string|null
Format
date-timeis_enabled?boolean
network_ids?array<string>
Network IDs this key has access to (hydrated from junction table)
permissions?string
Value in
"Owner" | "Admin" | "Member" | "Viewer"Response Body
application/json
application/json
application/json
application/json
curl -X POST "https://loading/api/v1/auth/keys" \ -H "Content-Type: application/json" \ -d '{ "name": "string", "organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6", "tags": [ "497f6eca-6276-4993-bfeb-53cbbbba6f08" ], "user_id": "a169451c-8525-4352-b8ca-070dd449a1a5" }'{
"meta": {
"api_version": 1,
"server_version": "0.13.5"
},
"success": true,
"data": {
"api_key": {
"created_at": "2019-08-24T14:15:22Z",
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"key": "string",
"last_used": "2019-08-24T14:15:22Z",
"name": "string",
"organization_id": "7c60d51f-b44e-4682-87d6-449835ea4de6",
"tags": [
"497f6eca-6276-4993-bfeb-53cbbbba6f08"
],
"updated_at": "2019-08-24T14:15:22Z",
"user_id": "a169451c-8525-4352-b8ca-070dd449a1a5",
"expires_at": "2019-08-24T14:15:22Z",
"is_enabled": true,
"network_ids": [
"497f6eca-6276-4993-bfeb-53cbbbba6f08"
],
"permissions": "Owner"
},
"key": "string"
},
"error": "string"
}{
"success": true,
"error": "string"
}{
"success": true,
"error": "string"
}{
"success": true,
"error": "string"
}