Api keys
Creates a new API key. The full key value is only returned once in the response — store it securely.
Authorization
bearerAuth AuthorizationBearer <token>
API key with fh_ prefix. Pass as Authorization: Bearer fh_...
In: header
Request Body
application/json
name*string
A label for the key
permission?string
Default
"readwrite"Value in
"readwrite" | "readonly"fullAccess?boolean
Access to all profiles
Default
trueprofileIds?array<>
Specific profile IDs (when fullAccess is false)
expiresAt?string
Optional expiry date
Format
date-timeResponse Body
application/json
application/json
curl -X POST "https://app.feedhorizon.dev/api/v1/api-keys" \ -H "Content-Type: application/json" \ -d '{ "name": "string" }'{
"data": {
"id": "string",
"keyPrefix": "fh_abc12345",
"name": "string",
"permission": "readwrite",
"fullAccess": true,
"profileIds": [
"string"
],
"lastUsedAt": "2019-08-24T14:15:22Z",
"expiresAt": "2019-08-24T14:15:22Z",
"createdAt": "2019-08-24T14:15:22Z",
"key": "fh_aee6d4242ae1d2ff857b4a900904f9e5beac1f2168a6c83da9f63053fda8caf8"
}
}{
"error": {
"code": "VALIDATION_ERROR",
"message": "string",
"details": [
{
"field": "string",
"message": "string"
}
]
}
}