key management

List Keys

List all keys for a given user / team / organization.

Parameters: expand: Optional[List[str]] - Expand related objects (e.g. 'user' to include user information) status: Optional[str] - Filter by status. Currently supports "deleted" to query deleted keys.

Returns: { "keys": List[str] or List[UserAPIKeyAuth], "total_count": int, "current_page": int, "total_pages": int, }

When expand includes "user", each key object will include a "user" field with the associated user object. Note: When expand=user is specified, full key objects are returned regardless of the return_full_object parameter.

get/key/list

Request

  • Base URL: https://api.sea-lion.ai (the document declares no server; this is the origin it was published from)
  • URL: https://api.sea-lion.ai/key/list
  • Auth: one of:
    • API key in header x-litellm-api-key
    • API key in header x-litellm-api-key
    • API key in header x-litellm-api-key
    • API key in header x-litellm-api-key
    • API key in header x-litellm-api-key
    • API key in header x-litellm-api-key

Query parameters

pageinteger

Page number

sizeinteger

Page size

user_idstring nullable

Filter keys by user ID

team_idstring nullable

Filter keys by team ID

organization_idstring nullable

Filter keys by organization ID

key_hashstring nullable

Filter keys by key hash

key_aliasstring nullable

Filter keys by key alias

return_full_objectboolean

Return full key object

include_team_keysboolean

Include all keys for teams that user is an admin of.

include_created_by_keysboolean

Include keys created by the user

sort_bystring nullable

Column to sort by (e.g. 'user_id', 'created_at', 'spend')

sort_orderstring

Sort order ('asc' or 'desc')

expandstring[] nullable

Expand related objects (e.g. 'user')

statusstring nullable

Filter by status (e.g. 'deleted')

project_idstring nullable

Filter keys by project ID

access_group_idstring nullable

Filter keys by access group ID

Response

Successful Response

total_countinteger nullable
current_pageinteger nullable
total_pagesinteger nullable

Changes

No recorded changes to this operation across all 78 revisions of this API.