We use cookies

We use cookies to ensure you get the best experience on our website. For more information on how we use cookies, please see our cookie policy.

By clicking "Accept", you agree to our use of cookies.
Learn more.

RatelimitsClient

The rate limits client is a wrapper for Hatchet’s gRPC API that makes it easier to work with rate limits in Hatchet.

Methods

list()

Lists all rate limits for the current tenant.

Parameters

ParameterTypeDescription
opts| { limit?: number; offset?: number; orderByDirection?: RateLimitOrderByDirection; orderByField?: RateLimitOrderByField; search?: string; } | undefinedThe options for the list operation.

Returns

Promise<RateLimitList>

A promise that resolves to the list of rate limits.

upsert()

Upserts a rate limit for the current tenant.

Parameters

ParameterTypeDescription
optsCreateRateLimitOptsThe options for the upsert operation.

Returns

Promise<string>

A promise that resolves to the key of the upserted rate limit.