Skip to main content
POST
Verify key

Headers

x-api-key
string

your workspace API key

Body

application/json
api_id
string
required

API ID from your dashboard

Example:

"{api_id}"

key
string
required

The generated API key

Example:

"key_xxxxxxxxxxxxxxxx"

Response

OK

valid
boolean

Whether the key is valid or not. A key could be invalid for a number of reasons, for example if it has expired or has no more verifications left

Example:

true

status
enum<string>

If the key status is false this field will be set to the reason why it is invalid. Possible values are:

  • USAGE_EXCEEDED: the key has exceeded its validation limit
  • EXPIRED: the key has expired,
Available options:
EXPIRED,
USAGE_EXCEEDED
api_id
string

The ID of the API the key belongs to

Example:

"{api_id}"

name
string

The name assigned to the key

Example:

"{api_name}"

prefix
string

The prefix assigned to the key

Example:

"prefix"

length
integer
default:16

The length assigned to the key

Required range: 16 <= x <= 255
meta
object

extra details you passed via the meta attribute

Example:
expires_at
integer<int64>

Unix timestamp of when the key expires, returns null when not set

verification_limit
integer<int64>

maximum verification allowed for this key, returns null when not set