Sets a new or overwrites an existing override.
import { V2RatelimitSetOverrideRequestBody } from "@unkey/api/models/components";
let value: V2RatelimitSetOverrideRequestBody = {
duration: 302499,
identifier: "<value>",
limit: 793890,
};
Field | Type | Required | Description |
---|---|---|---|
namespaceId |
string | ➖ | The id of the namespace. Either namespaceId or namespaceName must be provided |
namespaceName |
string | ➖ | The name of the namespace. Either namespaceId or namespaceName must be provided |
duration |
number | ✔️ | The duration in milliseconds for the rate limit window. |
identifier |
string | ✔️ | Identifier of your user, this can be their userId, an email, an ip or anything else. Wildcards ( * ) can be used to match multiple identifiers, More info can be found at https://www.unkey.com/docs/ratelimiting/overrides#wildcard-rules |
limit |
number | ✔️ | The maximum number of requests allowed. |