GET /api/v1/api-keys

Authentication

Bearer Token API Key (cookie: better-auth.session_token)

Responses

200 API key list
application/json
keys object[] REQUIRED
Array of:
id string REQUIRED
key_prefix string REQUIRED
name string REQUIRED
type string REQUIRED
Enum: live, publishable
project_id string | null REQUIRED
allowed_domains string | null REQUIRED
JSON-encoded domain allowlist for publishable keys.
last_used_at string | null REQUIRED
created_at string REQUIRED
curl -X GET 'https://littledemo.com/api/v1/api-keys' \  -H 'Authorization: Bearer YOUR_API_TOKEN'
const response = await fetch('https://littledemo.com/api/v1/api-keys', {  method: 'GET',  headers: {      "Authorization": "Bearer YOUR_API_TOKEN"  }});const data = await response.json();console.log(data);
import requestsheaders = {    'Authorization': 'Bearer YOUR_API_TOKEN'}response = requests.get('https://littledemo.com/api/v1/api-keys', headers=headers)print(response.json())
200 Response
{  "keys": [    {      "id": "<string>",      "key_prefix": "<string>",      "name": "<string>",      "type": "live",      "project_id": "<string>",      "allowed_domains": "[\"example.com\",\"docs.example.com\"]",      "last_used_at": "<string>",      "created_at": "<string>"    }  ]}
Ask a question... ⌘I