Get All API Keys

GET/v1/api-keys

Retrieve all API keys associated with the authenticated account.

About API Key Management

This endpoint returns a list of all API keys associated with your account. Each API key entry includes metadata such as name, scopes, status, and usage information. This is useful for managing and monitoring your API keys.

Key Information:

  • Key Identification: Each key has a unique key_id and optional name
  • Permissions: View the scopes (permissions) assigned to each key
  • Status Tracking: Monitor which keys are active or inactive
  • Usage Monitoring: See when each key was last used
  • Expiration: Check expiration dates for keys that have them

Request History

Log in to see full request history

TIMESTATUSUSER AGENT
Make a request to see history.

0 Requests This Month

Request Example

shell
curl -X GET https://api.konpro.ai/v1/api-keys \
  -H "x-api-key: <your-api-key>" \
  -H "Content-Type: application/json"

Response

FieldTypeDescription
api_keysarrayArray of API key objects. Each object contains the API key details and metadata.

API Key Object

FieldTypeDescription
key_idstringUnique identifier for the API key (e.g., key-001)
namestringOptional name or label for the API key (e.g., "Production Key")
scopesarrayArray of permission scopes granted to the API key (e.g., ["read", "write"])
last_usedstringISO 8601 timestamp of when the API key was last used. May be null if never used.
created_atstringISO 8601 timestamp of when the API key was created
expires_atstringISO 8601 timestamp of when the API key expires. If null, the key does not expire.
statusstringCurrent status of the API key (e.g., active or inactive)

Sample Successful Response

json
{
  "api_keys": [
    {
      "key_id": "key-001",
      "name": "Production Key",
      "scopes": ["read", "write"],
      "last_used": "2024-01-01T00:00:00Z",
      "created_at": "2024-01-01T00:00:00Z",
      "expires_at": "2024-12-31T23:59:59Z",
      "status": "active"
    }
  ]
}

Notes

  • This endpoint requires authentication using the x-api-key header.
  • This endpoint does not require any query parameters - it returns all API keys associated with your account.
  • Only API keys that belong to your account are returned.
  • The response does not include the actual API key values for security reasons - only metadata about the keys.
  • Use the status field to identify which keys are currently active.
  • The last_used field helps you identify unused keys that may be candidates for deletion.
  • If expires_at is null, the API key does not have an expiration date.
  • For error descriptions, see Error Responses.

Table of Contents