import * as z from "zod/v3"; import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; /** * cluster = operator ceiling (org-admin read-only); org = self-budget */ export declare const SetApiKeyBudgetOwner: { readonly Cluster: "cluster"; readonly Org: "org"; }; /** * cluster = operator ceiling (org-admin read-only); org = self-budget */ export type SetApiKeyBudgetOwner = ClosedEnum; export declare const SetApiKeyBudgetPeriod: { readonly Daily: "daily"; readonly Weekly: "weekly"; readonly Monthly: "monthly"; }; export type SetApiKeyBudgetPeriod = ClosedEnum; export declare const SetApiKeyBudgetAction: { readonly Alert: "alert"; readonly Block: "block"; }; export type SetApiKeyBudgetAction = ClosedEnum; export type SetApiKeyBudgetThresholds = { pct: number; action: SetApiKeyBudgetAction; }; export type SetApiKeyBudgetRequestBody = { /** * cluster = operator ceiling (org-admin read-only); org = self-budget */ owner?: SetApiKeyBudgetOwner | undefined; period: SetApiKeyBudgetPeriod; /** * Spend limit in major currency units */ limit: number; thresholds: Array; webhookUrl?: string | null | undefined; webhookSecret?: string | null | undefined; }; export type SetApiKeyBudgetRequest = { apiKeyId: string; requestBody: SetApiKeyBudgetRequestBody; }; export declare const SetApiKeyBudgetScope: { readonly Org: "org"; readonly Apikey: "apikey"; readonly User: "user"; readonly Team: "team"; readonly ExternalUser: "external_user"; readonly UserDefault: "user_default"; readonly TeamDefault: "team_default"; readonly ExternalUserDefault: "external_user_default"; }; export type SetApiKeyBudgetScope = ClosedEnum; export declare const SetApiKeyBudgetBudgetsOwner: { readonly Cluster: "cluster"; readonly Org: "org"; }; export type SetApiKeyBudgetBudgetsOwner = ClosedEnum; export declare const SetApiKeyBudgetBudgetsPeriod: { readonly Daily: "daily"; readonly Weekly: "weekly"; readonly Monthly: "monthly"; }; export type SetApiKeyBudgetBudgetsPeriod = ClosedEnum; export declare const SetApiKeyBudgetBudgetsAction: { readonly Alert: "alert"; readonly Block: "block"; }; export type SetApiKeyBudgetBudgetsAction = ClosedEnum; export type SetApiKeyBudgetBudgetsThresholds = { pct: number; action: SetApiKeyBudgetBudgetsAction; }; export declare const SetApiKeyBudgetStatus: { readonly Ok: "ok"; readonly Blocked: "blocked"; }; export type SetApiKeyBudgetStatus = ClosedEnum; export type SetApiKeyBudgetSpend = { /** * Current period bucket, e.g. 2026-07 / 2026-W28 / 2026-07-07 */ window: string; /** * Live spend this window, major currency units */ costSpent: number; limit: number; pct: number; status: SetApiKeyBudgetStatus; }; /** * OK */ export type SetApiKeyBudgetResponseBody = { id: string; scope: SetApiKeyBudgetScope; scopeId: string; scopeOrgId: string | null; owner: SetApiKeyBudgetBudgetsOwner; period: SetApiKeyBudgetBudgetsPeriod; limit: number; thresholds: Array; alertWebhookUrl: string | null; spend: SetApiKeyBudgetSpend; }; /** @internal */ export declare const SetApiKeyBudgetOwner$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetOwner$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetPeriod$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetPeriod$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetAction$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetAction$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetThresholds$inboundSchema: z.ZodType; /** @internal */ export type SetApiKeyBudgetThresholds$Outbound = { pct: number; action: string; }; /** @internal */ export declare const SetApiKeyBudgetThresholds$outboundSchema: z.ZodType; export declare function setApiKeyBudgetThresholdsToJSON(setApiKeyBudgetThresholds: SetApiKeyBudgetThresholds): string; export declare function setApiKeyBudgetThresholdsFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const SetApiKeyBudgetRequestBody$inboundSchema: z.ZodType; /** @internal */ export type SetApiKeyBudgetRequestBody$Outbound = { owner: string; period: string; limit: number; thresholds: Array; webhook_url?: string | null | undefined; webhook_secret?: string | null | undefined; }; /** @internal */ export declare const SetApiKeyBudgetRequestBody$outboundSchema: z.ZodType; export declare function setApiKeyBudgetRequestBodyToJSON(setApiKeyBudgetRequestBody: SetApiKeyBudgetRequestBody): string; export declare function setApiKeyBudgetRequestBodyFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const SetApiKeyBudgetRequest$inboundSchema: z.ZodType; /** @internal */ export type SetApiKeyBudgetRequest$Outbound = { apiKeyId: string; RequestBody: SetApiKeyBudgetRequestBody$Outbound; }; /** @internal */ export declare const SetApiKeyBudgetRequest$outboundSchema: z.ZodType; export declare function setApiKeyBudgetRequestToJSON(setApiKeyBudgetRequest: SetApiKeyBudgetRequest): string; export declare function setApiKeyBudgetRequestFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const SetApiKeyBudgetScope$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetScope$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsOwner$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsOwner$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsPeriod$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsPeriod$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsAction$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsAction$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetBudgetsThresholds$inboundSchema: z.ZodType; /** @internal */ export type SetApiKeyBudgetBudgetsThresholds$Outbound = { pct: number; action: string; }; /** @internal */ export declare const SetApiKeyBudgetBudgetsThresholds$outboundSchema: z.ZodType; export declare function setApiKeyBudgetBudgetsThresholdsToJSON(setApiKeyBudgetBudgetsThresholds: SetApiKeyBudgetBudgetsThresholds): string; export declare function setApiKeyBudgetBudgetsThresholdsFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const SetApiKeyBudgetStatus$inboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetStatus$outboundSchema: z.ZodNativeEnum; /** @internal */ export declare const SetApiKeyBudgetSpend$inboundSchema: z.ZodType; /** @internal */ export type SetApiKeyBudgetSpend$Outbound = { window: string; cost_spent: number; limit: number; pct: number; status: string; }; /** @internal */ export declare const SetApiKeyBudgetSpend$outboundSchema: z.ZodType; export declare function setApiKeyBudgetSpendToJSON(setApiKeyBudgetSpend: SetApiKeyBudgetSpend): string; export declare function setApiKeyBudgetSpendFromJSON(jsonString: string): SafeParseResult; /** @internal */ export declare const SetApiKeyBudgetResponseBody$inboundSchema: z.ZodType; /** @internal */ export type SetApiKeyBudgetResponseBody$Outbound = { id: string; scope: string; scope_id: string; scope_org_id: string | null; owner: string; period: string; limit: number; thresholds: Array; alert_webhook_url: string | null; spend: SetApiKeyBudgetSpend$Outbound; }; /** @internal */ export declare const SetApiKeyBudgetResponseBody$outboundSchema: z.ZodType; export declare function setApiKeyBudgetResponseBodyToJSON(setApiKeyBudgetResponseBody: SetApiKeyBudgetResponseBody): string; export declare function setApiKeyBudgetResponseBodyFromJSON(jsonString: string): SafeParseResult; //# sourceMappingURL=setapikeybudget.d.ts.map