Skip to main content
POST
/
v2
/
ratelimit.listOverrides
Typescript (SDK)
import { Unkey } from "@unkey/api";

const unkey = new Unkey({
  rootKey: process.env["UNKEY_ROOT_KEY"] ?? "",
});

async function run() {
  const result = await unkey.ratelimit.listOverrides({
    namespace: "<value>",
    limit: 20,
  });

  console.log(result);
}

run();
{
  "meta": {
    "requestId": "req_123"
  },
  "data": [
    {
      "overrideId": "<string>",
      "duration": 1001,
      "identifier": "<string>",
      "limit": 1
    }
  ],
  "pagination": {
    "cursor": "eyJrZXkiOiJrZXlfMTIzNCIsInRzIjoxNjk5Mzc4ODAwfQ==",
    "hasMore": true
  }
}

Authorizations

Authorization
string
header
required

Unkey uses API keys (root keys) for authentication. These keys authorize access to management operations in the API. To authenticate, include your root key in the Authorization header of each request:

Authorization: Bearer unkey_123

Root keys have specific permissions attached to them, controlling what operations they can perform. Key permissions follow a hierarchical structure with patterns like resource.resource_id.action (e.g., apis.*.create_key, apis.*.read_api). Security best practices:

  • Keep root keys secure and never expose them in client-side code
  • Use different root keys for different environments
  • Rotate keys periodically, especially after team member departures
  • Create keys with minimal necessary permissions following least privilege principle
  • Monitor key usage with audit logs.

Body

application/json
namespace
string
required

The id or name of the rate limit namespace to list overrides for.

Required string length: 1 - 255
cursor
string

Pagination cursor from a previous response. Include this when fetching subsequent pages of results. Each response containing more results than the requested limit will include a cursor value in the pagination object that can be used here.

limit
integer
default:10

Maximum number of override entries to return in a single response. Use this to control response size and loading performance.

  • Lower values (10-20): Better for UI displays and faster response times
  • Higher values (50-100): Better for data exports or bulk operations
  • Default (10): Suitable for most dashboard views

Results exceeding this limit will be paginated, with a cursor provided for fetching subsequent pages.

Required range: 1 <= x <= 100

Response

Overrides retrieved successfully. Includes pagination metadata if more results are available.

meta
object
required

Metadata object included in every API response. This provides context about the request and is essential for debugging, audit trails, and support inquiries. The requestId is particularly important when troubleshooting issues with the Unkey support team.

data
object[]
required
pagination
object

Pagination metadata for list endpoints. Provides information necessary to traverse through large result sets efficiently using cursor-based pagination.

I