Skip to main content
GET /v1/account/api_keys API Key

List API keys

List the account’s API keys. Each account has one secret key and one publishable key.

  • Secret keys: Masked in responses (only first/last characters shown)
  • Publishable keys: Full key value always included (browser-safe)

Parameters

Name Location Type Description
X-API-Key * header string API key for authentication

* Required parameter

Response

200 API keys retrieved

Content-Type: application/json

success boolean
data array[object]

Array items:

An API key for programmatic access. Each account has one secret key and one publishable key: - **Secret keys**: For server-to-server API calls. Masked in responses. - **Publishable keys**: For browser-based requests. Always shown in full.

id * string

Unique key identifier (hashid)

Example: apikey_abc123

type * string

Key type

Allowed values: "secret_key", "publishable_key"

Example: secret_key

name * string

Display name for the key

Example: Secret Key

status * string

Key lifecycle status

Allowed values: "pending", "active", "revoked", "expired"

Example: active

usable * boolean

Whether the key can be used (active and not expired)

Example: true

allowed_sources * array[string]

Allowed IPs/CIDRs (secret keys) or origins (publishable keys)

Example: ["192.168.1.0/24"]

Array items:

key string nullable

Full key value. Always shown for publishable keys; only on regeneration for secret keys.

Example: aho_pub_abc123...

masked_key string nullable

Masked key (secret keys only)

Example: aho_sec_abc...xyz

last_used_at string (date-time) nullable

When the key was last used

Example: 2025-03-15T10:30:00Z

expires_at string (date-time) nullable

When the key expires

created_at * string (date-time)

When the key was created

Example: 2025-01-01T00:00:00Z

updated_at * string (date-time)

When the key was last updated

Example: 2025-03-15T10:30:00Z

Code Examples

import os
from aho_sdk import AhoSdk

client = AhoSdk.account(api_key=os.environ["AHO_API_KEY"])

result = client.api_keys.list

Try It

Log in to test this endpoint directly from the documentation.

Log in