@vercel/sdk
Version:
<p align="center"> <a href="https://vercel.com"> <img src="https://assets.vercel.com/image/upload/v1588805858/repositories/vercel/logo.png" height="96"> <h3 align="center">Vercel</h3> </a> <p align="center">Develop. Preview. Ship.</p> </p>
1,381 lines • 61.3 kB
JavaScript
/*
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
*/
import * as z from "zod/v3";
import { remap as remap$ } from "../lib/primitives.js";
import { safeParse } from "../lib/schemas.js";
import * as types from "../types/primitives.js";
import { smartUnion } from "../types/smartUnion.js";
export const PayloadEnvironment = {
Preview: "preview",
Production: "production",
};
export const Enabled = {
Default: "default",
DefaultForce: "default-force",
Off: "off",
OffForce: "off-force",
On: "on",
OnForce: "on-force",
};
export const Environment = {
Preview: "preview",
Production: "production",
};
export const UserEventPayload298Role = {
Billing: "BILLING",
Contributor: "CONTRIBUTOR",
Developer: "DEVELOPER",
Member: "MEMBER",
Owner: "OWNER",
Security: "SECURITY",
Viewer: "VIEWER",
ViewerForPlus: "VIEWER_FOR_PLUS",
};
export const UserEventPayload297Previous = {
Elastic: "elastic",
Enhanced: "enhanced",
Standard: "standard",
Turbo: "turbo",
};
export const UserEventPayload297Next = {
Elastic: "elastic",
Enhanced: "enhanced",
Standard: "standard",
Turbo: "turbo",
};
/**
* Which repository visibilities get automatic reviews
*/
export const UserEventPayloadScope = {
All: "all",
Private: "private",
Public: "public",
SelectedRepos: "selected_repos",
};
/**
* Which repository visibilities get automatic reviews
*/
export const UserEventPayload293Scope = {
All: "all",
Private: "private",
Public: "public",
SelectedRepos: "selected_repos",
};
export const UserEventPayload291Type = {
Blob: "blob",
EdgeConfig: "edge-config",
Integration: "integration",
Postgres: "postgres",
Redis: "redis",
};
export const PayloadAccess = {
Private: "private",
Public: "public",
};
export const UserEventPayload289Type = {
Blob: "blob",
EdgeConfig: "edge-config",
Integration: "integration",
Postgres: "postgres",
Redis: "redis",
};
export const Access = {
Private: "private",
Public: "public",
};
export const UserEventPayload288Type = {
Blob: "blob",
EdgeConfig: "edge-config",
Integration: "integration",
Postgres: "postgres",
Redis: "redis",
};
export const UserEventPayload287Type = {
Blob: "blob",
EdgeConfig: "edge-config",
Integration: "integration",
Postgres: "postgres",
Redis: "redis",
};
export const UserEventPayload286Type = {
Blob: "blob",
EdgeConfig: "edge-config",
Integration: "integration",
Postgres: "postgres",
Redis: "redis",
};
export const StoreType = {
Postgres: "postgres",
Redis: "redis",
};
/**
* The budget type
*/
export const UserEventPayload283Type = {
Fixed: "fixed",
};
/**
* The acive pricing plan the team is billed with
*/
export const PayloadPricingPlan = {
Legacy: "legacy",
Platform: "platform",
Plus: "plus",
Unbundled: "unbundled",
};
/**
* The budget type
*/
export const UserEventPayload282Type = {
Fixed: "fixed",
};
/**
* The acive pricing plan the team is billed with
*/
export const PricingPlan = {
Legacy: "legacy",
Platform: "platform",
Plus: "plus",
Unbundled: "unbundled",
};
/**
* The budget type
*/
export const UserEventPayload281Type = {
Fixed: "fixed",
};
/**
* The acive pricing plan the team is billed with
*/
export const UserEventPayloadPricingPlan = {
Legacy: "legacy",
Platform: "platform",
Plus: "plus",
Unbundled: "unbundled",
};
export const FactorsOrigin = {
Apple: "apple",
Bitbucket: "bitbucket",
Chatgpt: "chatgpt",
Email: "email",
Github: "github",
Gitlab: "gitlab",
Google: "google",
Otp: "otp",
Saml: "saml",
};
export const PayloadReasonCode = {
Backoffice: "BACKOFFICE",
PublicApi: "PUBLIC_API",
};
export const TrustedIps = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
Production: "production",
};
export const OldTrustedIps = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
Production: "production",
};
export const SsoProtection2 = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const SsoProtectionDeploymentType = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const Cve55182MigrationAppliedFrom = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const April2026SecurityIncidentMigrationAppliedFrom = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const OldSsoProtection2 = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const OldSsoProtectionDeploymentType = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const OldSsoProtectionCve55182MigrationAppliedFrom = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const OldSsoProtectionApril2026SecurityIncidentMigrationAppliedFrom = {
All: "all",
AllExceptCustomDomains: "all_except_custom_domains",
Preview: "preview",
ProdDeploymentUrlsAndAllPreviews: "prod_deployment_urls_and_all_previews",
};
export const IssuerMode = {
Global: "global",
Team: "team",
};
export const PayloadIssuerMode = {
Global: "global",
Team: "team",
};
export const Consent = {
Granted: "granted",
Refused: "refused",
};
/** @internal */
export const ThreeHundredAndThree$inboundSchema = z.object({
emailDomain: z.nullable(types.string()).optional(),
});
export function threeHundredAndThreeFromJSON(jsonString) {
return safeParse(jsonString, (x) => ThreeHundredAndThree$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ThreeHundredAndThree' from JSON`);
}
/** @internal */
export const PayloadEnvironment$inboundSchema = z.nativeEnum(PayloadEnvironment);
/** @internal */
export const Enabled$inboundSchema = z
.nativeEnum(Enabled);
/** @internal */
export const ThreeHundredAndTwo$inboundSchema = z.object({
environment: PayloadEnvironment$inboundSchema,
enabled: Enabled$inboundSchema,
});
export function threeHundredAndTwoFromJSON(jsonString) {
return safeParse(jsonString, (x) => ThreeHundredAndTwo$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ThreeHundredAndTwo' from JSON`);
}
/** @internal */
export const Environment$inboundSchema = z
.nativeEnum(Environment);
/** @internal */
export const ThreeHundredAndOne$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
enabled: types.nullable(types.boolean()),
environment: Environment$inboundSchema,
});
export function threeHundredAndOneFromJSON(jsonString) {
return safeParse(jsonString, (x) => ThreeHundredAndOne$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ThreeHundredAndOne' from JSON`);
}
/** @internal */
export const ThreeHundred$inboundSchema = z.object({
enabled: types.boolean(),
domain: types.optional(types.string()),
});
export function threeHundredFromJSON(jsonString) {
return safeParse(jsonString, (x) => ThreeHundred$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ThreeHundred' from JSON`);
}
/** @internal */
export const UserEventPayload299Previous$inboundSchema = z.object({});
export function userEventPayload299PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload299Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload299Previous' from JSON`);
}
/** @internal */
export const UserEventPayload299Next$inboundSchema = z.object({});
export function userEventPayload299NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload299Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload299Next' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetyNine$inboundSchema = z.object({
previous: types.nullable(z.lazy(() => UserEventPayload299Previous$inboundSchema)),
next: types.nullable(z.lazy(() => UserEventPayload299Next$inboundSchema)),
});
export function twoHundredAndNinetyNineFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyNine$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyNine' from JSON`);
}
/** @internal */
export const Reasons$inboundSchema = z.object({
slug: types.string(),
description: types.string(),
});
export function reasonsFromJSON(jsonString) {
return safeParse(jsonString, (x) => Reasons$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Reasons' from JSON`);
}
/** @internal */
export const UserEventPayload298Role$inboundSchema = z.nativeEnum(UserEventPayload298Role);
/** @internal */
export const PayloadRemovedUsers$inboundSchema = z.object({
role: UserEventPayload298Role$inboundSchema,
confirmed: types.boolean(),
confirmedAt: types.optional(types.number()),
});
export function payloadRemovedUsersFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadRemovedUsers$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadRemovedUsers' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetyEight$inboundSchema = z.object({
slug: types.string(),
teamId: types.string(),
by: types.string(),
byUid: types.optional(types.string()),
reasons: types.optional(z.array(z.lazy(() => Reasons$inboundSchema))),
removedUsers: types.optional(z.record(z.lazy(() => PayloadRemovedUsers$inboundSchema))),
removedMemberCount: types.optional(types.number()),
timestamp: types.optional(types.number()),
});
export function twoHundredAndNinetyEightFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyEight$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyEight' from JSON`);
}
/** @internal */
export const UserEventPayload297Previous$inboundSchema = z.nativeEnum(UserEventPayload297Previous);
/** @internal */
export const UserEventPayload297Next$inboundSchema = z.nativeEnum(UserEventPayload297Next);
/** @internal */
export const TwoHundredAndNinetySeven$inboundSchema = z.object({
previous: types.optional(UserEventPayload297Previous$inboundSchema),
next: types.optional(UserEventPayload297Next$inboundSchema),
});
export function twoHundredAndNinetySevenFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetySeven$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetySeven' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetySix$inboundSchema = z.object({
eventId: types.string(),
sessionId: types.string(),
sessionKind: types.string(),
surface: types.string(),
occurredAt: types.number(),
planId: types.string(),
requestedScopes: z.array(types.string()),
elevatedScopes: z.array(types.string()),
mergedScopes: z.array(types.string()),
githubScopes: z.array(types.string()),
requestedScopeCount: types.number(),
elevatedScopeCount: types.number(),
mergedScopeCount: types.number(),
githubScopeCount: types.number(),
});
export function twoHundredAndNinetySixFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetySix$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetySix' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetyFive$inboundSchema = z.object({
eventId: types.string(),
sessionId: types.string(),
sessionKind: types.string(),
surface: types.string(),
occurredAt: types.number(),
});
export function twoHundredAndNinetyFiveFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyFive$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyFive' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetyFour$inboundSchema = z.object({
trialCreditsIssuedAt: types.number(),
expiresAt: types.string(),
amount: types.string(),
currency: types.string(),
});
export function twoHundredAndNinetyFourFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyFour$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyFour' from JSON`);
}
/** @internal */
export const UserEventPayloadScope$inboundSchema = z.nativeEnum(UserEventPayloadScope);
/** @internal */
export const UserEventPayload293Previous$inboundSchema = z.object({
enabled: types.boolean(),
scope: UserEventPayloadScope$inboundSchema,
includeDrafts: types.boolean(),
selectedRepos: z.nullable(z.array(types.string())).optional(),
});
export function userEventPayload293PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload293Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload293Previous' from JSON`);
}
/** @internal */
export const UserEventPayload293Scope$inboundSchema = z.nativeEnum(UserEventPayload293Scope);
/** @internal */
export const UserEventPayload293Next$inboundSchema = z.object({
enabled: types.boolean(),
scope: UserEventPayload293Scope$inboundSchema,
includeDrafts: types.boolean(),
selectedRepos: z.nullable(z.array(types.string())).optional(),
});
export function userEventPayload293NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload293Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload293Next' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetyThree$inboundSchema = z.object({
previous: types.optional(z.lazy(() => UserEventPayload293Previous$inboundSchema)),
next: z.lazy(() => UserEventPayload293Next$inboundSchema),
});
export function twoHundredAndNinetyThreeFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyThree$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyThree' from JSON`);
}
/** @internal */
export const TwoHundredAndNinetyTwo$inboundSchema = z.object({
slug: types.string(),
});
export function twoHundredAndNinetyTwoFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyTwo$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyTwo' from JSON`);
}
/** @internal */
export const UserEventPayload291Type$inboundSchema = z.nativeEnum(UserEventPayload291Type);
/** @internal */
export const PayloadAccess$inboundSchema = z.nativeEnum(PayloadAccess);
/** @internal */
export const TwoHundredAndNinetyOne$inboundSchema = z.object({
id: types.string(),
name: types.optional(types.string()),
computeUnitsMax: types.optional(types.number()),
computeUnitsMin: types.optional(types.number()),
suspendTimeoutSeconds: types.optional(types.number()),
type: UserEventPayload291Type$inboundSchema,
access: types.optional(PayloadAccess$inboundSchema),
locked: types.boolean(),
});
export function twoHundredAndNinetyOneFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinetyOne$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinetyOne' from JSON`);
}
/** @internal */
export const UserEventPayload290Store$inboundSchema = z.object({
name: types.string(),
id: types.string(),
});
export function userEventPayload290StoreFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload290Store$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload290Store' from JSON`);
}
/** @internal */
export const TwoHundredAndNinety$inboundSchema = z.object({
store: z.lazy(() => UserEventPayload290Store$inboundSchema),
ownerId: types.optional(types.string()),
});
export function twoHundredAndNinetyFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndNinety$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndNinety' from JSON`);
}
/** @internal */
export const UserEventPayload289Type$inboundSchema = z.nativeEnum(UserEventPayload289Type);
/** @internal */
export const Access$inboundSchema = z
.nativeEnum(Access);
/** @internal */
export const TwoHundredAndEightyNine$inboundSchema = z.object({
id: types.string(),
name: types.optional(types.string()),
computeUnitsMax: types.optional(types.number()),
computeUnitsMin: types.optional(types.number()),
suspendTimeoutSeconds: types.optional(types.number()),
type: UserEventPayload289Type$inboundSchema,
access: types.optional(Access$inboundSchema),
});
export function twoHundredAndEightyNineFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyNine$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyNine' from JSON`);
}
/** @internal */
export const UserEventPayload288Type$inboundSchema = z.nativeEnum(UserEventPayload288Type);
/** @internal */
export const UserEventPayloadStore$inboundSchema = z.object({
id: types.string(),
name: types.optional(types.string()),
type: UserEventPayload288Type$inboundSchema,
});
export function userEventPayloadStoreFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayloadStore$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayloadStore' from JSON`);
}
/** @internal */
export const TwoHundredAndEightyEight$inboundSchema = z.object({
transferRequestCode: types.string(),
store: z.lazy(() => UserEventPayloadStore$inboundSchema),
originTeamId: types.string(),
originTeamName: types.string(),
});
export function twoHundredAndEightyEightFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyEight$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyEight' from JSON`);
}
/** @internal */
export const UserEventPayload287Type$inboundSchema = z.nativeEnum(UserEventPayload287Type);
/** @internal */
export const PayloadStore$inboundSchema = z.object({
id: types.string(),
name: types.optional(types.string()),
type: UserEventPayload287Type$inboundSchema,
});
export function payloadStoreFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadStore$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadStore' from JSON`);
}
/** @internal */
export const TwoHundredAndEightySeven$inboundSchema = z.object({
transferRequestCode: types.string(),
store: z.lazy(() => PayloadStore$inboundSchema),
destinationTeamId: types.string(),
destinationTeamName: types.string(),
});
export function twoHundredAndEightySevenFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightySeven$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightySeven' from JSON`);
}
/** @internal */
export const UserEventPayload286Type$inboundSchema = z.nativeEnum(UserEventPayload286Type);
/** @internal */
export const Store$inboundSchema = z
.object({
id: types.string(),
name: types.optional(types.string()),
type: UserEventPayload286Type$inboundSchema,
});
export function storeFromJSON(jsonString) {
return safeParse(jsonString, (x) => Store$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Store' from JSON`);
}
/** @internal */
export const TwoHundredAndEightySix$inboundSchema = z.object({
transferRequestCode: types.string(),
store: z.lazy(() => Store$inboundSchema),
});
export function twoHundredAndEightySixFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightySix$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightySix' from JSON`);
}
/** @internal */
export const StoreType$inboundSchema = z
.nativeEnum(StoreType);
/** @internal */
export const TwoHundredAndEightyFive$inboundSchema = z.object({
storeType: StoreType$inboundSchema,
});
export function twoHundredAndEightyFiveFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyFive$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyFive' from JSON`);
}
/** @internal */
export const TwoHundredAndEightyFour$inboundSchema = z.object({
webhookUrl: types.optional(types.string()),
});
export function twoHundredAndEightyFourFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyFour$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyFour' from JSON`);
}
/** @internal */
export const UserEventPayload283Type$inboundSchema = z.nativeEnum(UserEventPayload283Type);
/** @internal */
export const PayloadPricingPlan$inboundSchema = z.nativeEnum(PayloadPricingPlan);
/** @internal */
export const UserEventPayload283Budget$inboundSchema = z.object({
type: UserEventPayload283Type$inboundSchema,
fixedBudget: types.number(),
previousSpend: z.array(types.number()),
notifiedAt: z.array(types.number()),
webhookId: types.optional(types.string()),
webhookNotified: types.optional(types.boolean()),
createdAt: types.number(),
updatedAt: types.optional(types.number()),
isActive: types.boolean(),
pauseProjects: types.optional(types.boolean()),
pricingPlan: types.optional(PayloadPricingPlan$inboundSchema),
teamId: types.string(),
id: types.string(),
});
export function userEventPayload283BudgetFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload283Budget$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload283Budget' from JSON`);
}
/** @internal */
export const TwoHundredAndEightyThree$inboundSchema = z.object({
budget: z.lazy(() => UserEventPayload283Budget$inboundSchema),
webhookUrl: types.optional(types.string()),
});
export function twoHundredAndEightyThreeFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyThree$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyThree' from JSON`);
}
/** @internal */
export const UserEventPayload282Type$inboundSchema = z.nativeEnum(UserEventPayload282Type);
/** @internal */
export const PricingPlan$inboundSchema = z
.nativeEnum(PricingPlan);
/** @internal */
export const UserEventPayload282Budget$inboundSchema = z.object({
type: UserEventPayload282Type$inboundSchema,
fixedBudget: types.number(),
previousSpend: z.array(types.number()),
notifiedAt: z.array(types.number()),
webhookId: types.optional(types.string()),
webhookNotified: types.optional(types.boolean()),
createdAt: types.number(),
updatedAt: types.optional(types.number()),
isActive: types.boolean(),
pauseProjects: types.optional(types.boolean()),
pricingPlan: types.optional(PricingPlan$inboundSchema),
teamId: types.string(),
id: types.string(),
});
export function userEventPayload282BudgetFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload282Budget$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload282Budget' from JSON`);
}
/** @internal */
export const TwoHundredAndEightyTwo$inboundSchema = z.object({
budget: z.lazy(() => UserEventPayload282Budget$inboundSchema),
});
export function twoHundredAndEightyTwoFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyTwo$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyTwo' from JSON`);
}
/** @internal */
export const UserEventPayload281Type$inboundSchema = z.nativeEnum(UserEventPayload281Type);
/** @internal */
export const UserEventPayloadPricingPlan$inboundSchema = z.nativeEnum(UserEventPayloadPricingPlan);
/** @internal */
export const BudgetItem$inboundSchema = z.object({
type: UserEventPayload281Type$inboundSchema,
fixedBudget: types.number(),
previousSpend: z.array(types.number()),
notifiedAt: z.array(types.number()),
webhookId: types.optional(types.string()),
webhookNotified: types.optional(types.boolean()),
createdAt: types.number(),
updatedAt: types.optional(types.number()),
isActive: types.boolean(),
pauseProjects: types.optional(types.boolean()),
pricingPlan: types.optional(UserEventPayloadPricingPlan$inboundSchema),
teamId: types.string(),
id: types.string(),
});
export function budgetItemFromJSON(jsonString) {
return safeParse(jsonString, (x) => BudgetItem$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'BudgetItem' from JSON`);
}
/** @internal */
export const UserEventPayloadBudget$inboundSchema = z.object({
budgetItem: z.lazy(() => BudgetItem$inboundSchema),
});
export function userEventPayloadBudgetFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayloadBudget$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayloadBudget' from JSON`);
}
/** @internal */
export const TwoHundredAndEightyOne$inboundSchema = z.object({
budget: z.lazy(() => UserEventPayloadBudget$inboundSchema),
});
export function twoHundredAndEightyOneFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEightyOne$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEightyOne' from JSON`);
}
/** @internal */
export const UserEventPayload280Previous$inboundSchema = z.object({
sampleRatePercent: types.nullable(types.number()),
spendLimitInDollars: types.nullable(types.number()),
});
export function userEventPayload280PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload280Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload280Previous' from JSON`);
}
/** @internal */
export const TwoHundredAndEighty$inboundSchema = z.object({
projectId: types.optional(types.string()),
projectName: types.optional(types.string()),
analyticsId: types.optional(types.string()),
sampleRatePercent: types.nullable(types.number()),
spendLimitInDollars: types.nullable(types.number()),
previous: z.lazy(() => UserEventPayload280Previous$inboundSchema),
});
export function twoHundredAndEightyFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndEighty$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndEighty' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyNine$inboundSchema = z.object({
email: types.string(),
gitlabLogin: types.string(),
gitlabEmail: types.string(),
gitlabName: types.string(),
zeitAccount: types.string(),
zeitAccountType: types.string(),
});
export function twoHundredAndSeventyNineFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyNine$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyNine' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyEight$inboundSchema = z.object({
email: types.string(),
githubLogin: types.string(),
zeitAccount: types.string(),
zeitAccountType: types.string(),
});
export function twoHundredAndSeventyEightFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyEight$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyEight' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventySeven$inboundSchema = z.object({
email: types.string(),
bitbucketLogin: types.string(),
bitbucketEmail: types.string(),
bitbucketName: types.string(),
zeitAccount: types.string(),
zeitAccountType: types.string(),
});
export function twoHundredAndSeventySevenFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventySeven$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventySeven' from JSON`);
}
/** @internal */
export const UserEventPayload276Names$inboundSchema = z.object({
en: types.string(),
});
export function userEventPayload276NamesFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload276Names$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload276Names' from JSON`);
}
/** @internal */
export const PayloadCity$inboundSchema = z.object({
names: z.lazy(() => UserEventPayload276Names$inboundSchema),
});
export function payloadCityFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadCity$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadCity' from JSON`);
}
/** @internal */
export const UserEventPayload276GeolocationNames$inboundSchema = z.object({
en: types.string(),
});
export function userEventPayload276GeolocationNamesFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload276GeolocationNames$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload276GeolocationNames' from JSON`);
}
/** @internal */
export const PayloadCountry$inboundSchema = z.object({
names: z.lazy(() => UserEventPayload276GeolocationNames$inboundSchema),
});
export function payloadCountryFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadCountry$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadCountry' from JSON`);
}
/** @internal */
export const UserEventPayload276GeolocationMostSpecificSubdivisionNames$inboundSchema = z.object({
en: types.string(),
});
export function userEventPayload276GeolocationMostSpecificSubdivisionNamesFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload276GeolocationMostSpecificSubdivisionNames$inboundSchema
.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload276GeolocationMostSpecificSubdivisionNames' from JSON`);
}
/** @internal */
export const PayloadMostSpecificSubdivision$inboundSchema = z.object({
names: z.lazy(() => UserEventPayload276GeolocationMostSpecificSubdivisionNames$inboundSchema),
});
export function payloadMostSpecificSubdivisionFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadMostSpecificSubdivision$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadMostSpecificSubdivision' from JSON`);
}
/** @internal */
export const PayloadGeolocation$inboundSchema = z.object({
city: types.optional(z.lazy(() => PayloadCity$inboundSchema)),
country: z.lazy(() => PayloadCountry$inboundSchema),
most_specific_subdivision: types.optional(z.lazy(() => PayloadMostSpecificSubdivision$inboundSchema)),
regionName: types.optional(types.string()),
}).transform((v) => {
return remap$(v, {
"most_specific_subdivision": "mostSpecificSubdivision",
});
});
export function payloadGeolocationFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadGeolocation$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadGeolocation' from JSON`);
}
/** @internal */
export const FactorsOrigin$inboundSchema = z.nativeEnum(FactorsOrigin);
/** @internal */
export const UserEventFactors1$inboundSchema = z.object({
origin: FactorsOrigin$inboundSchema,
username: types.optional(types.string()),
teamId: types.optional(types.string()),
legacy: types.optional(types.boolean()),
ssoType: types.optional(types.string()),
});
export function userEventFactors1FromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventFactors1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventFactors1' from JSON`);
}
/** @internal */
export const PayloadFactors$inboundSchema = z.lazy(() => UserEventFactors1$inboundSchema);
export function payloadFactorsFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadFactors$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadFactors' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventySix$inboundSchema = z.object({
userAgent: types.optional(types.string()),
geolocation: z.nullable(z.lazy(() => PayloadGeolocation$inboundSchema))
.optional(),
env: types.optional(types.string()),
os: types.optional(types.string()),
username: types.optional(types.string()),
ssoType: types.optional(types.string()),
factors: types.optional(z.array(z.lazy(() => UserEventFactors1$inboundSchema))),
viaOTP: types.optional(types.boolean()),
viaGithub: types.optional(types.boolean()),
viaGitlab: types.optional(types.boolean()),
viaBitbucket: types.optional(types.boolean()),
viaGoogle: types.optional(types.boolean()),
viaApple: types.optional(types.boolean()),
viaSamlSso: types.optional(types.boolean()),
viaPasskey: types.optional(types.boolean()),
});
export function twoHundredAndSeventySixFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventySix$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventySix' from JSON`);
}
/** @internal */
export const ScalingRules$inboundSchema = z.object({
min: types.number(),
max: types.number(),
});
export function scalingRulesFromJSON(jsonString) {
return safeParse(jsonString, (x) => ScalingRules$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ScalingRules' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyFive$inboundSchema = z.object({
scalingRules: z.record(z.lazy(() => ScalingRules$inboundSchema)),
min: types.number(),
max: types.number(),
url: types.string(),
});
export function twoHundredAndSeventyFiveFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyFive$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyFive' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyFour$inboundSchema = z.object({
bio: types.string(),
});
export function twoHundredAndSeventyFourFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyFour$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyFour' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyThree$inboundSchema = z.object({
enabled: types.boolean(),
updatedAt: types.number(),
firstEnabledAt: types.optional(types.number()),
projectId: types.optional(types.string()),
projectName: types.optional(types.string()),
});
export function twoHundredAndSeventyThreeFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyThree$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyThree' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyTwo$inboundSchema = z.object({
oldName: types.string(),
newName: types.string(),
uid: types.optional(types.string()),
});
export function twoHundredAndSeventyTwoFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyTwo$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyTwo' from JSON`);
}
/** @internal */
export const Name2$inboundSchema = z
.object({
name: types.string(),
});
export function name2FromJSON(jsonString) {
return safeParse(jsonString, (x) => Name2$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'Name2' from JSON`);
}
/** @internal */
export const PayloadName$inboundSchema = smartUnion([z.lazy(() => Name2$inboundSchema), types.string()]);
export function payloadNameFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadName$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadName' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventyOne$inboundSchema = z.object({
uid: types.string(),
name: smartUnion([z.lazy(() => Name2$inboundSchema), types.string()]),
});
export function twoHundredAndSeventyOneFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventyOne$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventyOne' from JSON`);
}
/** @internal */
export const TwoHundredAndSeventy$inboundSchema = z.object({
email: types.string(),
});
export function twoHundredAndSeventyFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSeventy$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSeventy' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtyNine$inboundSchema = z.object({
email: types.string(),
verified: types.boolean(),
});
export function twoHundredAndSixtyNineFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyNine$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyNine' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtyEight$inboundSchema = z.object({
instances: types.number(),
url: types.string(),
});
export function twoHundredAndSixtyEightFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyEight$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyEight' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtySeven$inboundSchema = z.object({
alias: types.string(),
sandboxName: types.string(),
sandboxId: types.optional(types.string()),
projectId: types.optional(types.string()),
});
export function twoHundredAndSixtySevenFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtySeven$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtySeven' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtySix$inboundSchema = z.object({
gitProvider: types.string(),
gitProviderGroupDescriptor: types.string(),
gitScope: types.string(),
});
export function twoHundredAndSixtySixFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtySix$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtySix' from JSON`);
}
/** @internal */
export const ProjectWebAnalytics$inboundSchema = z.object({
id: types.string(),
disabledAt: types.optional(types.number()),
canceledAt: types.optional(types.number()),
enabledAt: types.optional(types.number()),
hasData: types.optional(types.literal(true)),
});
export function projectWebAnalyticsFromJSON(jsonString) {
return safeParse(jsonString, (x) => ProjectWebAnalytics$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ProjectWebAnalytics' from JSON`);
}
/** @internal */
export const PrevProjectWebAnalytics$inboundSchema = z.object({
id: types.string(),
disabledAt: types.optional(types.number()),
canceledAt: types.optional(types.number()),
enabledAt: types.optional(types.number()),
hasData: types.optional(types.literal(true)),
});
export function prevProjectWebAnalyticsFromJSON(jsonString) {
return safeParse(jsonString, (x) => PrevProjectWebAnalytics$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PrevProjectWebAnalytics' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtyFive$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
projectWebAnalytics: types.optional(z.lazy(() => ProjectWebAnalytics$inboundSchema)),
prevProjectWebAnalytics: z.nullable(z.lazy(() => PrevProjectWebAnalytics$inboundSchema)).optional(),
});
export function twoHundredAndSixtyFiveFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyFive$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyFive' from JSON`);
}
/** @internal */
export const PayloadReasonCode$inboundSchema = z.nativeEnum(PayloadReasonCode);
/** @internal */
export const TwoHundredAndSixtyFour$inboundSchema = z.object({
projectId: types.string(),
reasonCode: types.optional(PayloadReasonCode$inboundSchema),
});
export function twoHundredAndSixtyFourFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyFour$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyFour' from JSON`);
}
/** @internal */
export const AddedProjects$inboundSchema = z.object({
id: types.string(),
name: types.string(),
});
export function addedProjectsFromJSON(jsonString) {
return safeParse(jsonString, (x) => AddedProjects$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'AddedProjects' from JSON`);
}
/** @internal */
export const RemovedProjects$inboundSchema = z.object({
id: types.string(),
name: types.string(),
});
export function removedProjectsFromJSON(jsonString) {
return safeParse(jsonString, (x) => RemovedProjects$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'RemovedProjects' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtyThree$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
addedProjects: z.array(z.lazy(() => AddedProjects$inboundSchema)),
removedProjects: z.array(z.lazy(() => RemovedProjects$inboundSchema)),
addedProviders: z.array(types.string()),
removedProviders: z.array(types.string()),
});
export function twoHundredAndSixtyThreeFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyThree$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyThree' from JSON`);
}
/** @internal */
export const TrustedIps$inboundSchema = z
.nativeEnum(TrustedIps);
/** @internal */
export const OldTrustedIps$inboundSchema = z.nativeEnum(OldTrustedIps);
/** @internal */
export const TwoHundredAndSixtyTwo$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
trustedIps: z.nullable(TrustedIps$inboundSchema).optional(),
oldTrustedIps: z.nullable(OldTrustedIps$inboundSchema).optional(),
addedAddresses: z.nullable(z.array(types.string())).optional(),
removedAddresses: z.nullable(z.array(types.string())).optional(),
});
export function twoHundredAndSixtyTwoFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyTwo$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyTwo' from JSON`);
}
/** @internal */
export const StaticIps$inboundSchema = z.object({
builds: types.optional(types.boolean()),
enabled: types.boolean(),
regions: types.optional(z.array(types.string())),
});
export function staticIpsFromJSON(jsonString) {
return safeParse(jsonString, (x) => StaticIps$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'StaticIps' from JSON`);
}
/** @internal */
export const UserEventPayload261Project$inboundSchema = z.object({
id: types.optional(types.string()),
staticIps: z.lazy(() => StaticIps$inboundSchema),
});
export function userEventPayload261ProjectFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload261Project$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload261Project' from JSON`);
}
/** @internal */
export const UserEventPayload261Next$inboundSchema = z.object({
project: z.lazy(() => UserEventPayload261Project$inboundSchema),
});
export function userEventPayload261NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload261Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload261Next' from JSON`);
}
/** @internal */
export const PayloadStaticIps$inboundSchema = z.object({
builds: types.optional(types.boolean()),
enabled: types.boolean(),
regions: types.optional(z.array(types.string())),
});
export function payloadStaticIpsFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadStaticIps$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadStaticIps' from JSON`);
}
/** @internal */
export const UserEventPayload261PreviousProject$inboundSchema = z.object({
id: types.optional(types.string()),
staticIps: z.lazy(() => PayloadStaticIps$inboundSchema),
});
export function userEventPayload261PreviousProjectFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload261PreviousProject$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload261PreviousProject' from JSON`);
}
/** @internal */
export const UserEventPayload261Previous$inboundSchema = z.object({
project: z.lazy(() => UserEventPayload261PreviousProject$inboundSchema),
});
export function userEventPayload261PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload261Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload261Previous' from JSON`);
}
/** @internal */
export const TwoHundredAndSixtyOne$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
next: z.lazy(() => UserEventPayload261Next$inboundSchema),
previous: z.lazy(() => UserEventPayload261Previous$inboundSchema),
});
export function twoHundredAndSixtyOneFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixtyOne$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixtyOne' from JSON`);
}
/** @internal */
export const SsoProtection2$inboundSchema = z.nativeEnum(SsoProtection2);
/** @internal */
export const SsoProtectionDeploymentType$inboundSchema = z.nativeEnum(SsoProtectionDeploymentType);
/** @internal */
export const Cve55182MigrationAppliedFrom$inboundSchema = z.nativeEnum(Cve55182MigrationAppliedFrom);
/** @internal */
export const April2026SecurityIncidentMigrationAppliedFrom$inboundSchema = z
.nativeEnum(April2026SecurityIncidentMigrationAppliedFrom);
/** @internal */
export const SsoProtection1$inboundSchema = z.object({
deploymentType: SsoProtectionDeploymentType$inboundSchema,
cve55182MigrationAppliedFrom: z.nullable(Cve55182MigrationAppliedFrom$inboundSchema).optional(),
april2026SecurityIncidentMigrationAppliedFrom: z.nullable(April2026SecurityIncidentMigrationAppliedFrom$inboundSchema).optional(),
});
export function ssoProtection1FromJSON(jsonString) {
return safeParse(jsonString, (x) => SsoProtection1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'SsoProtection1' from JSON`);
}
/** @internal */
export const PayloadSsoProtection$inboundSchema = smartUnion([
z.lazy(() => SsoProtection1$inboundSchema),
SsoProtection2$inboundSchema,
]);
export function payloadSsoProtectionFromJSON(jsonString) {
return safeParse(jsonString, (x) => PayloadSsoProtection$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'PayloadSsoProtection' from JSON`);
}
/** @internal */
export const OldSsoProtection2$inboundSchema = z.nativeEnum(OldSsoProtection2);
/** @internal */
export const OldSsoProtectionDeploymentType$inboundSchema = z.nativeEnum(OldSsoProtectionDeploymentType);
/** @internal */
export const OldSsoProtectionCve55182MigrationAppliedFrom$inboundSchema = z
.nativeEnum(OldSsoProtectionCve55182MigrationAppliedFrom);
/** @internal */
export const OldSsoProtectionApril2026SecurityIncidentMigrationAppliedFrom$inboundSchema = z.nativeEnum(OldSsoProtectionApril2026SecurityIncidentMigrationAppliedFrom);
/** @internal */
export const OldSsoProtection1$inboundSchema = z.object({
deploymentType: OldSsoProtectionDeploymentType$inboundSchema,
cve55182MigrationAppliedFrom: z.nullable(OldSsoProtectionCve55182MigrationAppliedFrom$inboundSchema).optional(),
april2026SecurityIncidentMigrationAppliedFrom: z.nullable(OldSsoProtectionApril2026SecurityIncidentMigrationAppliedFrom$inboundSchema).optional(),
});
export function oldSsoProtection1FromJSON(jsonString) {
return safeParse(jsonString, (x) => OldSsoProtection1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OldSsoProtection1' from JSON`);
}
/** @internal */
export const OldSsoProtection$inboundSchema = smartUnion([
z.lazy(() => OldSsoProtection1$inboundSchema),
OldSsoProtection2$inboundSchema,
]);
export function oldSsoProtectionFromJSON(jsonString) {
return safeParse(jsonString, (x) => OldSsoProtection$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OldSsoProtection' from JSON`);
}
/** @internal */
export const TwoHundredAndSixty$inboundSchema = z.object({
projectId: types.optional(types.string()),
projectName: types.optional(types.string()),
ssoProtection: types.nullable(smartUnion([
z.lazy(() => SsoProtection1$inboundSchema),
SsoProtection2$inboundSchema,
])),
oldSsoProtection: types.nullable(smartUnion([
z.lazy(() => OldSsoProtection1$inboundSchema),
OldSsoProtection2$inboundSchema,
])),
});
export function twoHundredAndSixtyFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndSixty$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndSixty' from JSON`);
}
/** @internal */
export const UserEventPayload259Next$inboundSchema = z.object({
skewProtectionAllowedDomains: z.array(types.string()),
});
export function userEventPayload259NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload259Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload259Next' from JSON`);
}
/** @internal */
export const UserEventPayload259Previous$inboundSchema = z.object({
skewProtectionAllowedDomains: types.optional(z.array(types.string())),
});
export function userEventPayload259PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload259Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload259Previous' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyNine$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
next: z.lazy(() => UserEventPayload259Next$inboundSchema),
previous: z.lazy(() => UserEventPayload259Previous$inboundSchema),
});
export function twoHundredAndFiftyNineFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyNine$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyNine' from JSON`);
}
/** @internal */
export const UserEventPayload258Next$inboundSchema = z.object({
skewProtectionMaxAge: types.number(),
});
export function userEventPayload258NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload258Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload258Next' from JSON`);
}
/** @internal */
export const UserEventPayload258Previous$inboundSchema = z.object({
skewProtectionMaxAge: types.optional(types.number()),
});
export function userEventPayload258PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload258Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload258Previous' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyEight$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
next: z.lazy(() => UserEventPayload258Next$inboundSchema),
previous: z.lazy(() => UserEventPayload258Previous$inboundSchema),
});
export function twoHundredAndFiftyEightFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyEight$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyEight' from JSON`);
}
/** @internal */
export const UserEventPayload257Next$inboundSchema = z.object({
skewProtectionBoundaryAt: types.number(),
});
export function userEventPayload257NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload257Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload257Next' from JSON`);
}
/** @internal */
export const UserEventPayload257Previous$inboundSchema = z.object({
skewProtectionBoundaryAt: types.optional(types.number()),
});
export function userEventPayload257PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload257Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload257Previous' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftySeven$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
next: z.lazy(() => UserEventPayload257Next$inboundSchema),
previous: z.lazy(() => UserEventPayload257Previous$inboundSchema),
});
export function twoHundredAndFiftySevenFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftySeven$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftySeven' from JSON`);
}
/** @internal */
export const UserEventPayload256Previous$inboundSchema = z.object({
expiration: types.optional(types.string()),
expirationProduction: types.optional(types.string()),
expirationCanceled: types.optional(types.string()),
expirationErrored: types.optional(types.string()),
});
export function userEventPayload256PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload256Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload256Previous' from JSON`);
}
/** @internal */
export const UserEventPayload256Next$inboundSchema = z.object({
expiration: types.optional(types.string()),
expirationProduction: types.optional(types.string()),
expirationCanceled: types.optional(types.string()),
expirationErrored: types.optional(types.string()),
});
export function userEventPayload256NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload256Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload256Next' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftySix$inboundSchema = z.object({
projectId: types.optional(types.string()),
projectName: types.optional(types.string()),
previous: z.lazy(() => UserEventPayload256Previous$inboundSchema),
next: z.lazy(() => UserEventPayload256Next$inboundSchema),
});
export function twoHundredAndFiftySixFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftySix$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftySix' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyFive$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
publicSource: types.boolean(),
});
export function twoHundredAndFiftyFiveFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyFive$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyFive' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyFour$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
inheritDeploymentProtection: types.boolean(),
});
export function twoHundredAndFiftyFourFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyFour$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyFour' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyThree$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
protectedSourcemaps: types.boolean(),
});
export function twoHundredAndFiftyThreeFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyThree$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyThree' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyTwo$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
gitForkProtection: types.boolean(),
});
export function twoHundredAndFiftyTwoFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyTwo$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyTwo' from JSON`);
}
/** @internal */
export const TwoHundredAndFiftyOne$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
customerSupportCodeVisibility: types.boolean(),
});
export function twoHundredAndFiftyOneFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFiftyOne$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFiftyOne' from JSON`);
}
/** @internal */
export const IssuerMode$inboundSchema = z
.nativeEnum(IssuerMode);
/** @internal */
export const UserEventPayload250Previous$inboundSchema = z.object({
issuerMode: types.optional(IssuerMode$inboundSchema),
});
export function userEventPayload250PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload250Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload250Previous' from JSON`);
}
/** @internal */
export const PayloadIssuerMode$inboundSchema = z.nativeEnum(PayloadIssuerMode);
/** @internal */
export const UserEventPayload250Next$inboundSchema = z.object({
issuerMode: PayloadIssuerMode$inboundSchema,
});
export function userEventPayload250NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload250Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload250Next' from JSON`);
}
/** @internal */
export const TwoHundredAndFifty$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
previous: z.lazy(() => UserEventPayload250Previous$inboundSchema),
next: z.lazy(() => UserEventPayload250Next$inboundSchema),
});
export function twoHundredAndFiftyFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFifty$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFifty' from JSON`);
}
/** @internal */
export const UserEventPayload249Previous$inboundSchema = z.object({});
export function userEventPayload249PreviousFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload249Previous$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload249Previous' from JSON`);
}
/** @internal */
export const UserEventPayload249Next$inboundSchema = z.object({});
export function userEventPayload249NextFromJSON(jsonString) {
return safeParse(jsonString, (x) => UserEventPayload249Next$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UserEventPayload249Next' from JSON`);
}
/** @internal */
export const TwoHundredAndFortyNine$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
previous: types.nullable(z.lazy(() => UserEventPayload249Previous$inboundSchema)),
next: types.nullable(z.lazy(() => UserEventPayload249Next$inboundSchema)),
});
export function twoHundredAndFortyNineFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFortyNine$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFortyNine' from JSON`);
}
/** @internal */
export const TwoHundredAndFortyEight$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
targetDeploymentId: types.optional(types.string()),
action: types.optional(types.string()),
});
export function twoHundredAndFortyEightFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFortyEight$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFortyEight' from JSON`);
}
/** @internal */
export const TwoHundredAndFortySeven$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
targetDeploymentId: types.optional(types.string()),
newTargetPercentage: types.optional(types.number()),
});
export function twoHundredAndFortySevenFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFortySeven$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFortySeven' from JSON`);
}
/** @internal */
export const TwoHundredAndFortySix$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
targetDeploymentId: types.optional(types.string()),
});
export function twoHundredAndFortySixFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFortySix$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFortySix' from JSON`);
}
/** @internal */
export const RollbackDescription$inboundSchema = z.object({
userId: types.string(),
username: types.string(),
description: types.string(),
createdAt: types.number(),
});
export function rollbackDescriptionFromJSON(jsonString) {
return safeParse(jsonString, (x) => RollbackDescription$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'RollbackDescription' from JSON`);
}
/** @internal */
export const TwoHundredAndFortyFive$inboundSchema = z.object({
projectId: types.string(),
projectName: types.string(),
projectAccountId: types.string(),
deploymentId: types.string(),
rollbackDescription: types.optional(z.lazy(() => RollbackDescription$inboundSchema)),
});
export function twoHundredAndFortyFiveFromJSON(jsonString) {
return safeParse(jsonString, (x) => TwoHundredAndFortyFive$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'TwoHundredAndFortyFive' from JSON`);
}
/** @internal */
export const Consent$inboundSchema = z
.nativeEnum(Consent);
//# sourceMappingURL=consent.js.map