Pagination
Cursor pagination for list endpoints.
List endpoints return a page of objects plus a cursor. Eridian does not use offset pagination. Cursors are opaque; do not parse them.
Query Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
limit | integer | 20 | Page size. Maximum 100 (500 on /v1/audit/events) |
starting_after | string | - | Object ID to start after (exclusive) |
ending_before | string | - | Object ID to end before (exclusive) |
Do not combine starting_after and ending_before on the same request. HTTP 400 invalid_request if you do.
Response Envelope
{
"object": "list",
"data": [
{ "id": "key_8f3a2b1c", "object": "eridian.api_key" }
],
"has_more": true,
"url": "/v1/keys"
}
Walk forward by passing the last id in data as starting_after.
GET /v1/keys?project_id=prj_legal_001&limit=20&starting_after=key_8f3a2b1c
Authorization: Bearer eridian_sk_...
Response headers:
| Header | Description |
|---|---|
X-Eridian-Request-Id | Request ID |
X-Eridian-Page-Limit | Echo of limit |
X-Eridian-Has-More | true or false |
Endpoints
| Path | Cursor field |
|---|---|
GET /v1/projects | id |
GET /v1/keys | id |
GET /v1/templates | id |
GET /v1/routing/policies | policy_id |
GET /v1/webhooks | id |
GET /v1/rag/documents | id |
GET /v1/audit/events | id |
GET /v1/evals | id |
GET /v1/usage (when granularity=request) | request_id |
SDK Helpers
Python
for key in client.keys.list(project_id="prj_legal_001").auto_paging_iter():
print(key.id)
TypeScript
for await (const key of client.keys.list({ projectId: "prj_legal_001" })) {
console.log(key.id);
}
Stop when has_more is false. Do not sleep between pages unless you are below rate limit remaining of 10.
See Rate Limits and Audit Log.
Production API credentials are issued with an institution workspace. Contact sales if you need access.