Skip to content
PACKAGES

createKeyedRateLimitOutcome()

Create one externally authoritative outcome without handwritten canonical encoding.

The host assigns the outcome id after a valid authority decision. This helper owns no durable receipt, transaction, clock, evaluator, or admission.

import { createKeyedRateLimitOutcome } from "@graphrefly/ts/rate-limit";
function createKeyedRateLimitOutcome(
requestValue: unknown,
opts: CreateKeyedRateLimitOutcomeOptions,
): KeyedRateLimitOutcome
ParameterTypeDescription
requestValueunknownThe complete strict request decided by the host authority.
optsCreateKeyedRateLimitOutcomeOptionsThe authoritative result, outcome id, quota material, and provenance.

The immutable strict outcome for adapter delivery.

import { createKeyedRateLimitOutcome } from "@graphrefly/ts/rate-limit";

packages/ts/src/rate-limit/keyed-rate-limit.ts