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/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L182

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/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L189


feature?

TypeScript
optional feature: string;

Defined in: https://github.com/ax-llm/ax/blob/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L188


parentRunId?

TypeScript
optional parentRunId: string;

Defined in: https://github.com/ax-llm/ax/blob/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L187


requestId?

TypeScript
optional requestId: string;

Defined in: https://github.com/ax-llm/ax/blob/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L185


runId?

TypeScript
optional runId: string;

Defined in: https://github.com/ax-llm/ax/blob/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L186


tenantId?

TypeScript
optional tenantId: string;

Defined in: https://github.com/ax-llm/ax/blob/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L183


userId?

TypeScript
optional userId: string;

Defined in: https://github.com/ax-llm/ax/blob/e690b4823b8309e258594064abe941d4cff6ef89/src/ax/ai/types.ts#L184

Docs