UNPKG

@unkey/api

Version:

Developer-friendly & type-safe Typescript SDK specifically catered to leverage *@unkey/api* API.

57 lines (51 loc) 1.82 kB
/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod/v3"; export type V2RatelimitListOverridesRequestBody = { /** * The id or name of the rate limit namespace to list overrides for. */ namespace: 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. */ cursor?: string | undefined; /** * Maximum number of override entries to return in a single response. Use this to control response size and loading performance. * * @remarks * * - 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. */ limit?: number | undefined; }; /** @internal */ export type V2RatelimitListOverridesRequestBody$Outbound = { namespace: string; cursor?: string | undefined; limit: number; }; /** @internal */ export const V2RatelimitListOverridesRequestBody$outboundSchema: z.ZodType< V2RatelimitListOverridesRequestBody$Outbound, z.ZodTypeDef, V2RatelimitListOverridesRequestBody > = z.object({ namespace: z.string(), cursor: z.string().optional(), limit: z.number().int().default(10), }); export function v2RatelimitListOverridesRequestBodyToJSON( v2RatelimitListOverridesRequestBody: V2RatelimitListOverridesRequestBody, ): string { return JSON.stringify( V2RatelimitListOverridesRequestBody$outboundSchema.parse( v2RatelimitListOverridesRequestBody, ), ); }