Files
hatchet/api-contracts/openapi/components/schemas/rate_limits.yaml
abelanger5 a1a10b4073 feat: dynamic rate limits (#904)
* wip: step run expressions on rate limits

* feat: dynamic rate limits

* chore: v0.47.0

* chore: address changes from PR review

* fix: improved error handling

* address pr review

* better error messages for step run cels, remove debug logs

* fix: hash

---------

Co-authored-by: gabriel ruttner <gabriel.ruttner@gmail.com>
2024-09-26 22:00:34 +00:00

52 lines
1.1 KiB
YAML

RateLimit:
properties:
key:
type: string
description: The key for the rate limit.
tenantId:
type: string
description: The ID of the tenant associated with this rate limit.
limitValue:
type: integer
description: The maximum number of requests allowed within the window.
value:
type: integer
description: The current number of requests made within the window.
window:
type: string
description: The window of time in which the limitValue is enforced.
lastRefill:
type: string
format: date-time
example: 2022-12-13T15:06:48.888358-05:00
description: The last time the rate limit was refilled.
required:
- key
- tenantId
- limitValue
- value
- window
- lastRefill
RateLimitList:
properties:
pagination:
$ref: "./metadata.yaml#/PaginationResponse"
rows:
items:
$ref: "#/RateLimit"
type: array
RateLimitOrderByField:
type: string
enum:
- key
- value
- limitValue
RateLimitOrderByDirection:
type: string
enum:
- asc
- desc