AxUsageContext Generated TypeScript API reference. typescript api api/reference build/apidocs/TypeAlias.AxUsageContext.md type AxUsageContext

AxUsageContext

TypeScript
type AxUsageContext = object;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L212

Request-scoped attribution attached to normalized AI usage events.

Keep identity and request metadata here instead of in process-global state so concurrent multi-tenant calls cannot leak attribution across requests.

Properties

attributes?

TypeScript
optional attributes: Record<string, string | number | boolean>;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L219


feature?

TypeScript
optional feature: string;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L218


parentRunId?

TypeScript
optional parentRunId: string;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L217


requestId?

TypeScript
optional requestId: string;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L215


runId?

TypeScript
optional runId: string;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L216


tenantId?

TypeScript
optional tenantId: string;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L213


userId?

TypeScript
optional userId: string;

Defined in: https://github.com/ax-llm/ax/blob/686f8ba96cf652e044cf922b67c16c8f09754a70/src/ax/ai/types.ts#L214

Docs