Ruby SDKFeature Clients
Rate Limits Client
Rate Limits client for managing rate limits within Hatchet.
This class provides a high-level interface for creating and updating rate limits using the gRPC Admin client.
hatchet.rate_limits.put(key: "api-calls", limit: 100, duration: :SECOND)It is available on the main client as hatchet.rate_limits.
Methods:
| Name | Description |
|---|---|
put | Put a rate limit for a given key. |
Functions
put
Put a rate limit for a given key.
hatchet.rate_limits.put(key: "api-calls", limit: 100, duration: :SECOND)Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
key | String | The key to set the rate limit for. | required |
limit | Integer | The rate limit to set. | required |
duration | Symbol | The duration of the rate limit (:SECOND, :MINUTE, :HOUR) | :SECOND |
Raises:
| Type | Description |
|---|---|
GRPC::BadStatus | If the gRPC request fails. |
Last updated on August 24, 2026