Skip to main content
GET
/
api-keys
/
{keyId}
Get API key
curl --request GET \
  --url https://api.natural.co/api-keys/{keyId} \
  --header 'Authorization: Bearer <token>'
{
  "data": {
    "type": "apiKey",
    "id": "apy_550e8400e29b41d4a716446655440000",
    "attributes": {
      "apiKeyPrefix": "sk_ntl_prod_sxHp_FRoRTnDEmEH",
      "name": "Production Backend",
      "scopes": [
        "payments.read",
        "payments.create"
      ],
      "environment": "prod",
      "status": "ACTIVE",
      "createdAt": "2026-01-04T15:30:00Z",
      "expiresAt": null,
      "lastUsedAt": null,
      "revokedAt": null,
      "createdBy": "usr_550e8400e29b41d4a716446655440000",
      "revokedBy": null
    },
    "relationships": {
      "party": {
        "data": {
          "type": "party",
          "id": "pty_7c9e6679e29b41d4a716446655440001"
        }
      }
    }
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-Agent-ID
string | null

Agent ID (agt_xxx) identifying which agent is making the request.

X-Instance-ID
string | null

Required when X-Agent-ID is present. Session or conversation ID for agent observability.

Maximum string length: 1024

Path Parameters

keyId
string
required

API key ID (key_xxx)

Response

Successful Response

data
ApiKeyResource · object
required