Skip to main content
GET
https://api.bunship.com
/
api
/
v1
/
organizations
/
{orgId}
/
api-keys
List API Keys
curl --request GET \
  --url https://api.bunship.com/api/v1/organizations/{orgId}/api-keys \
  --header 'Authorization: Bearer <token>'
{
  "success": true,
  "data": [
    {
      "id": "key_abc123",
      "name": "Production API",
      "prefix": "bsk_live_abc1",
      "scopes": ["members:read", "webhooks:read"],
      "rateLimit": 1000,
      "lastUsedAt": "2024-01-21T09:00:00Z",
      "expiresAt": null,
      "isActive": true,
      "createdAt": "2024-01-15T10:00:00Z"
    },
    {
      "id": "key_def456",
      "name": "CI/CD Pipeline",
      "prefix": "bsk_live_def4",
      "scopes": [],
      "rateLimit": null,
      "lastUsedAt": "2024-01-20T03:00:00Z",
      "expiresAt": "2024-06-15T00:00:00Z",
      "isActive": true,
      "createdAt": "2024-01-10T08:00:00Z"
    }
  ]
}
Returns all API keys for the organization. The full key value is never returned — only the key prefix is shown for identification purposes.

Auth

Requires a valid Bearer token. User must be a member of the organization.

Path Parameters

orgId
string
required
Organization identifier.

Response

success
boolean
Always true on success.
data
array
Array of API key objects.
{
  "success": true,
  "data": [
    {
      "id": "key_abc123",
      "name": "Production API",
      "prefix": "bsk_live_abc1",
      "scopes": ["members:read", "webhooks:read"],
      "rateLimit": 1000,
      "lastUsedAt": "2024-01-21T09:00:00Z",
      "expiresAt": null,
      "isActive": true,
      "createdAt": "2024-01-15T10:00:00Z"
    },
    {
      "id": "key_def456",
      "name": "CI/CD Pipeline",
      "prefix": "bsk_live_def4",
      "scopes": [],
      "rateLimit": null,
      "lastUsedAt": "2024-01-20T03:00:00Z",
      "expiresAt": "2024-06-15T00:00:00Z",
      "isActive": true,
      "createdAt": "2024-01-10T08:00:00Z"
    }
  ]
}

Example

curl https://api.bunship.com/api/v1/organizations/org_cld2abc123def456/api-keys \
  -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIs..."