export declare const ANTHROPIC_V1_MESSAGES_COUNT_TOKENS_ENDPOINT: "/v1/messages/count_tokens";
export declare const DEFAULT_ANTHROPIC_V1_MESSAGES_COUNT_TOKENS_BASE_URL: "https://api.anthropic.com";
export declare const DEFAULT_ANTHROPIC_VERSION: "2023-06-01";
export type AnthropicV1MessagesCountTokensBoundary = "input" | "contract" | "governance" | "provider" | "timeout" | "response";
export type AnthropicV1MessagesCountTokensErrorCode = "MISSING_REQUEST" | "MISSING_REQUEST_BODY" | "MISSING_AUTH_TOKEN" | "CONTRACT_REJECTED" | "GOVERNANCE_REJECTED" | "TRANSPORT_UNAVAILABLE" | "PROVIDER_AUTH_FAILED" | "PROVIDER_RATE_LIMITED" | "PROVIDER_TIMEOUT" | "PROVIDER_UNAVAILABLE" | "PROVIDER_ERROR" | "RESPONSE_FORMAT_DRIFT";
export type AnthropicV1MessagesCountTokensGate = {
    accepted: boolean;
    reason?: string;
};
export type AnthropicV1MessagesCountTokensRuntimeContext = {
    runtimeId?: string;
    invocationId?: string;
    traceId?: string;
};
export type AnthropicV1MessagesCountTokensBody = Readonly<Record<string, unknown>>;
export type AnthropicV1MessagesCountTokensProviderEnvelope = {
    provider: "anthropic";
    endpoint: typeof ANTHROPIC_V1_MESSAGES_COUNT_TOKENS_ENDPOINT;
    method: "POST";
    url: string;
    headers: Readonly<Record<string, string>>;
    body: AnthropicV1MessagesCountTokensBody;
    timeoutMs: number;
    dryRun: boolean;
    providerCallPlanned: boolean;
    runtime: AnthropicV1MessagesCountTokensRuntimeContext;
};
export type AnthropicV1MessagesCountTokensProviderResult = {
    statusCode: number;
    body: unknown;
    headers?: Readonly<Record<string, string>>;
};
export type AnthropicV1MessagesCountTokensTransport = (envelope: AnthropicV1MessagesCountTokensProviderEnvelope) => Promise<AnthropicV1MessagesCountTokensProviderResult> | AnthropicV1MessagesCountTokensProviderResult;
export type AnthropicV1MessagesCountTokensRequest = {
    baseUrl?: string;
    apiKey?: string;
    anthropicVersion?: string;
    body?: AnthropicV1MessagesCountTokensBody;
    timeoutMs?: number;
    dryRun?: boolean;
    runtime?: AnthropicV1MessagesCountTokensRuntimeContext;
    contract?: AnthropicV1MessagesCountTokensGate;
    governance?: AnthropicV1MessagesCountTokensGate;
    transport?: AnthropicV1MessagesCountTokensTransport;
};
export type AnthropicV1MessagesCountTokensResponseEnvelope = {
    kind: "dry-run" | "provider";
    statusCode?: number;
    body: unknown;
    headers?: Readonly<Record<string, string>>;
};
export type AnthropicV1MessagesCountTokensCapabilitySignal = {
    provider: "anthropic";
    endpoint: typeof ANTHROPIC_V1_MESSAGES_COUNT_TOKENS_ENDPOINT;
    operation: "count-message-tokens";
    rawShape: "token-count" | "dry-run";
};
export type AnthropicV1MessagesCountTokensError = {
    code: AnthropicV1MessagesCountTokensErrorCode;
    message: string;
    boundary: AnthropicV1MessagesCountTokensBoundary;
    statusCode?: number;
};
export type AnthropicV1MessagesCountTokensResult = {
    ok: true;
    envelope: AnthropicV1MessagesCountTokensProviderEnvelope;
    response: AnthropicV1MessagesCountTokensResponseEnvelope;
    capability: AnthropicV1MessagesCountTokensCapabilitySignal;
    events: readonly string[];
} | {
    ok: false;
    error: AnthropicV1MessagesCountTokensError;
    envelope?: AnthropicV1MessagesCountTokensProviderEnvelope;
    events: readonly string[];
};
export declare function invokeAnthropicV1MessagesCountTokens(request?: AnthropicV1MessagesCountTokensRequest): Promise<AnthropicV1MessagesCountTokensResult>;
