/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */

import * as z from "zod/v3";
import { safeParse } from "../lib/schemas.js";
import { ClosedEnum } from "../types/enums.js";
import { Result as SafeParseResult } from "../types/fp.js";
import * as types from "../types/primitives.js";
import { SDKValidationError } from "./sdkvalidationerror.js";

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndTen = {
  name: string;
  price?: number | undefined;
  currency?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndNine = {
  renew?: boolean | undefined;
  domain: string;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndEight = {
  name: string;
  destinationId: string;
  destinationName: string;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndSeven = {
  name: string;
  destinationId: string | null;
  destinationName: string | null;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndSix = {
  name: string;
  fromId: string | null;
  fromName: string | null;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndFive = {
  domain: string;
  zone: boolean;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndFour = {
  domain: string;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndThree = {
  domain: string;
  customNameservers: Array<string> | null;
  prevCustomNameservers: Array<string> | null;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndTwo = {
  previousServiceType: string;
  serviceType: string;
  id: string;
  name: string;
  nameservers: Array<string>;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundredAndOne = {
  domainId: string;
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type OneHundred = {
  name: string;
  userId: string;
  teamId: string;
  ownerName: string;
};

export type UserEventPayload99OldTeam = {
  name: string;
};

export type UserEventPayload99NewTeam = {
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type NinetyNine = {
  name: string;
  oldTeam?: UserEventPayload99OldTeam | undefined;
  newTeam?: UserEventPayload99NewTeam | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type NinetyEight = {
  name: string;
  cdnEnabled: boolean;
};

/**
 * The payload of the event, if requested.
 */
export type NinetySeven = {
  name: string;
  price: number;
  currency?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type NinetySix = {
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type NinetyFive = {
  id: string;
  value: string;
  name: string;
  domain: string;
  type: string;
};

export const UserEventPayload94Action = {
  Add: "add",
  Delete: "delete",
  Update: "update",
} as const;
export type UserEventPayload94Action = ClosedEnum<
  typeof UserEventPayload94Action
>;

export const Initiator = {
  System: "system",
  User: "user",
} as const;
export type Initiator = ClosedEnum<typeof Initiator>;

/**
 * The payload of the event, if requested.
 */
export type NinetyFour = {
  action: UserEventPayload94Action;
  initiator: Initiator;
  id: string;
  domain: string;
  name: string;
  type: string;
  value: string;
  mxPriority?: number | undefined;
  previousValue?: string | undefined;
  source?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type NinetyThree = {
  id: string;
  value: string;
  name: string;
  domain: string;
  type: string;
  mxPriority?: number | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type NinetyTwo = {
  integrationId: string;
  configurationId: string;
  integrationSlug: string;
  integrationName: string;
  ownerId: string;
  projectIds?: Array<string> | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type NinetyOne = {
  deploymentId: string;
  deploymentUrl: string | null;
  deploymentName: string | null;
  projectId: string;
  projectName: string;
};

/**
 * Which rule blocked the deploy.
 */
export const RuleName = {
  DeploymentSources: "deploymentSources",
  GitSources: "gitSources",
} as const;
/**
 * Which rule blocked the deploy.
 */
export type RuleName = ClosedEnum<typeof RuleName>;

/**
 * Team-level or project-level rule.
 */
export const RuleProvenance = {
  Default: "default",
  Project: "project",
  Team: "team",
} as const;
/**
 * Team-level or project-level rule.
 */
export type RuleProvenance = ClosedEnum<typeof RuleProvenance>;

/**
 * The payload of the event, if requested.
 */
export type Ninety = {
  projectId?: string | undefined;
  projectName: string;
  /**
   * The blocked deployment's id (e.g. `dpl_…`). When present, the message links it to the deployment details (inspector) page. Optional so events emitted before this field was added still render.
   */
  deploymentId?: string | undefined;
  /**
   * Classified deploy source, e.g. 'cli', 'git', 'integration'.
   */
  source: string;
  /**
   * Which rule blocked the deploy.
   */
  ruleName: RuleName;
  /**
   * Team-level or project-level rule.
   */
  ruleProvenance: RuleProvenance;
};

export type UserEventPayload89Deployment = {
  id: string;
  name: string;
  meta: { [k: string]: string };
  url: string;
};

/**
 * The payload of the event, if requested.
 */
export type EightyNine = {
  deployment: UserEventPayload89Deployment;
  deploymentId: string;
  url: string;
};

/**
 * The payload of the event, if requested.
 */
export type EightyEight = {
  sha: string;
  gitUserPlatform: string;
  projectId?: string | undefined;
  projectName: string;
  gitCommitterName: string;
  source: string;
};

export type UserEventPayloadOldTeam = {
  name: string;
};

export type UserEventPayloadNewTeam = {
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type EightySeven = {
  url: string;
  oldTeam?: UserEventPayloadOldTeam | undefined;
  newTeam?: UserEventPayloadNewTeam | undefined;
};

export type UserEventJobPayload868DeployHook = {
  createdAt: number;
  id: string;
  name: string;
  ref: string;
};

/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export const UserEventJobPayload86GitHashtagVercel = {
  NumberVERCELBUILDPRIO1: "#VERCEL_BUILD_PRIO_1",
  NumberVERCELBUILDPRIO10: "#VERCEL_BUILD_PRIO_10",
  NumberVERCELBUILDPRIO2: "#VERCEL_BUILD_PRIO_2",
  NumberVERCELBUILDPRIO3: "#VERCEL_BUILD_PRIO_3",
  NumberVERCELBUILDPRIO4: "#VERCEL_BUILD_PRIO_4",
  NumberVERCELBUILDPRIO5: "#VERCEL_BUILD_PRIO_5",
  NumberVERCELBUILDPRIO6: "#VERCEL_BUILD_PRIO_6",
  NumberVERCELBUILDPRIO7: "#VERCEL_BUILD_PRIO_7",
  NumberVERCELBUILDPRIO8: "#VERCEL_BUILD_PRIO_8",
  NumberVERCELBUILDPRIO9: "#VERCEL_BUILD_PRIO_9",
  NumberVERCELSDDJAFTERGETREPOFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_CANCEL",
  NumberVERCELSDDJAFTERGETREPOFORCEERROR:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_ERROR",
  NumberVERCELSDDJAFTERVERIFYFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_CANCEL",
  NumberVERCELSDDJAFTERVERIFYFORCEERROR:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_ERROR",
  NumberVERCELSDDJBEFOREBUILDJOBQUEUEDERROR:
    "#VERCEL_SDDJ_BEFORE_BUILD_JOB_QUEUED_ERROR",
  NumberVERCELSDDJFORCEGITFORKERROR: "#VERCEL_SDDJ_FORCE_GIT_FORK_ERROR",
  NumberVERCELSKIP: "#VERCEL_SKIP",
  NumberVERCELV0MESSAGE: "#VERCEL_V0_MESSAGE",
} as const;
/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export type UserEventJobPayload86GitHashtagVercel = ClosedEnum<
  typeof UserEventJobPayload86GitHashtagVercel
>;

/**
 * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
 */
export type UserEventJobPayload868GitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export const UserEventJobPayload86CommitVerification = {
  Unknown: "unknown",
  Unverified: "unverified",
  Verified: "verified",
} as const;
/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export type UserEventJobPayload86CommitVerification = ClosedEnum<
  typeof UserEventJobPayload86CommitVerification
>;

export const UserEventJobPayload868Action = {
  AutoApprovedMember: "auto-approved-member",
  AutoApprovedPendingInvite: "auto-approved-pending-invite",
} as const;
export type UserEventJobPayload868Action = ClosedEnum<
  typeof UserEventJobPayload868Action
>;

/**
 * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
 */
export type UserEventJobPayload86NsnbSideEffect = {
  action: UserEventJobPayload868Action;
  gitUserLogin: string;
};

/**
 * Vercel
 */
export type UserEventJobPayload868HeadInfo = {
  org: string;
  ref: string;
  repo: string;
  sha: string;
};

export const UserEventJobPayload868Provider = {
  Vercel: "vercel",
} as const;
export type UserEventJobPayload868Provider = ClosedEnum<
  typeof UserEventJobPayload868Provider
>;

export type Job8 = {
  type: "vercel-push";
  ref: string;
  repo: string;
  sha: string;
  repoPushedAt?: number | null | undefined;
  deployHook?: UserEventJobPayload868DeployHook | undefined;
  url?: string | undefined;
  target?: string | null | undefined;
  deploymentId?: string | undefined;
  linkedProjectId?: string | undefined;
  projectId?: string | undefined;
  authorized?: boolean | undefined;
  authorizedBy?: string | undefined;
  /**
   * Since December 2022 All project ids associated to this job. Think monorepo. This job will be for one of these project.
   */
  jobProjectIds?: Array<string> | undefined;
  /**
   * Since December 2022 Pairs of projects and owner ids to build for this build request.
   */
  jobPairs?: Array<Array<string>> | undefined;
  /**
   * Since June 2024 Pairs of projects and owner ids to immediately finish (without building) because we want to create them in a skipped state.
   */
  skippedJobPairs?: Array<Array<string>> | undefined;
  /**
   * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
   */
  gitHashtagVercel?: Array<UserEventJobPayload86GitHashtagVercel> | undefined;
  /**
   * Since April 2023 Cached count of how many projects are connected to the repo. Saves a few Cosmos queries down the road in the main flow.
   */
  connectedProjectCount?: number | undefined;
  /**
   * Since April 2023 If set then it is a cached result of asking the remote for the PR ID the commit that triggered this Job. Or zero if it was not a PR. This prevents a few git round trips by the git updater.
   */
  prIdOrZero?: number | undefined;
  /**
   * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
   */
  gitComments?: UserEventJobPayload868GitComments | undefined;
  /**
   * Since 28 Feb 2024 If set to true, identifies that the git job was created for a manual git deployment
   */
  isManualGitDeploy?: boolean | undefined;
  /**
   * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
   */
  commitVerification?: UserEventJobPayload86CommitVerification | undefined;
  /**
   * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
   */
  nsnbSideEffect?: UserEventJobPayload86NsnbSideEffect | undefined;
  /**
   * Vercel
   */
  headInfo: UserEventJobPayload868HeadInfo;
  org: string;
  provider: UserEventJobPayload868Provider;
  customEnvId?: string | null | undefined;
  prId?: number | null | undefined;
};

export type UserEventJobPayloadProject = {
  defaultBranch?: string | null | undefined;
  id: string;
  name?: string | null | undefined;
  namespace?: string | null | undefined;
  path?: string | null | undefined;
  url?: string | null | undefined;
};

/**
 * GitLab
 */
export type UserEventJobPayload867HeadInfo = {
  project: UserEventJobPayloadProject;
  ref: string;
  sha: string;
};

export type UserEventJobProject = {
  defaultBranch?: string | null | undefined;
  id: string;
  name?: string | null | undefined;
  namespace?: string | null | undefined;
  path?: string | null | undefined;
  url?: string | null | undefined;
};

export type UserEventJobPayload867GitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

export const UserEventJobPayload867Provider = {
  Gitlab: "gitlab",
} as const;
export type UserEventJobPayload867Provider = ClosedEnum<
  typeof UserEventJobPayload867Provider
>;

export type Job7 = {
  createdAt?: number | undefined;
  eventful?: boolean | undefined;
  /**
   * GitLab
   */
  headInfo: UserEventJobPayload867HeadInfo;
  linkedProjectId?: string | undefined;
  prId: number;
  project: UserEventJobProject;
  projectId?: string | undefined;
  customEnvId?: string | null | undefined;
  ref: string;
  sha: string;
  type: "gitlab-now-comment";
  gitComments?: UserEventJobPayload867GitComments | undefined;
  provider: UserEventJobPayload867Provider;
};

/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export const UserEventJobPayloadGitHashtagVercel = {
  NumberVERCELBUILDPRIO1: "#VERCEL_BUILD_PRIO_1",
  NumberVERCELBUILDPRIO10: "#VERCEL_BUILD_PRIO_10",
  NumberVERCELBUILDPRIO2: "#VERCEL_BUILD_PRIO_2",
  NumberVERCELBUILDPRIO3: "#VERCEL_BUILD_PRIO_3",
  NumberVERCELBUILDPRIO4: "#VERCEL_BUILD_PRIO_4",
  NumberVERCELBUILDPRIO5: "#VERCEL_BUILD_PRIO_5",
  NumberVERCELBUILDPRIO6: "#VERCEL_BUILD_PRIO_6",
  NumberVERCELBUILDPRIO7: "#VERCEL_BUILD_PRIO_7",
  NumberVERCELBUILDPRIO8: "#VERCEL_BUILD_PRIO_8",
  NumberVERCELBUILDPRIO9: "#VERCEL_BUILD_PRIO_9",
  NumberVERCELSDDJAFTERGETREPOFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_CANCEL",
  NumberVERCELSDDJAFTERGETREPOFORCEERROR:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_ERROR",
  NumberVERCELSDDJAFTERVERIFYFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_CANCEL",
  NumberVERCELSDDJAFTERVERIFYFORCEERROR:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_ERROR",
  NumberVERCELSDDJBEFOREBUILDJOBQUEUEDERROR:
    "#VERCEL_SDDJ_BEFORE_BUILD_JOB_QUEUED_ERROR",
  NumberVERCELSDDJFORCEGITFORKERROR: "#VERCEL_SDDJ_FORCE_GIT_FORK_ERROR",
  NumberVERCELSKIP: "#VERCEL_SKIP",
  NumberVERCELV0MESSAGE: "#VERCEL_V0_MESSAGE",
} as const;
/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export type UserEventJobPayloadGitHashtagVercel = ClosedEnum<
  typeof UserEventJobPayloadGitHashtagVercel
>;

/**
 * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
 */
export type UserEventJobPayload866GitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export const UserEventJobPayloadCommitVerification = {
  Unknown: "unknown",
  Unverified: "unverified",
  Verified: "verified",
} as const;
/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export type UserEventJobPayloadCommitVerification = ClosedEnum<
  typeof UserEventJobPayloadCommitVerification
>;

export const UserEventJobPayload86Action = {
  AutoApprovedMember: "auto-approved-member",
  AutoApprovedPendingInvite: "auto-approved-pending-invite",
} as const;
export type UserEventJobPayload86Action = ClosedEnum<
  typeof UserEventJobPayload86Action
>;

/**
 * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
 */
export type UserEventJobPayloadNsnbSideEffect = {
  action: UserEventJobPayload86Action;
  gitUserLogin: string;
};

export type Commit = {
  id: string;
  authorAvatar?: string | null | undefined;
  authorEmail?: string | null | undefined;
  authorId?: number | null | undefined;
  authorLogin?: string | null | undefined;
  authorName?: string | null | undefined;
};

export type UserEventJobPayload86DeployHook = {
  createdAt: number;
  id: string;
  name: string;
  ref: string;
};

export type UserEventJobPayload86Project = {
  defaultBranch?: string | null | undefined;
  id: string;
  name?: string | null | undefined;
  namespace?: string | null | undefined;
  path?: string | null | undefined;
  url?: string | null | undefined;
};

/**
 * GitLab
 */
export type UserEventJobPayload866HeadInfo = {
  project: UserEventJobPayload86Project;
  ref: string;
  sha: string;
};

export type JobProject = {
  defaultBranch?: string | null | undefined;
  id: string;
  name?: string | null | undefined;
  namespace?: string | null | undefined;
  path?: string | null | undefined;
  url?: string | null | undefined;
};

export const UserEventJobPayload866Provider = {
  Gitlab: "gitlab",
} as const;
export type UserEventJobPayload866Provider = ClosedEnum<
  typeof UserEventJobPayload866Provider
>;

export type Job6 = {
  type: "gitlab-push";
  authorized?: boolean | undefined;
  authorizedBy?: string | undefined;
  /**
   * Since December 2022 All project ids associated to this job. Think monorepo. This job will be for one of these project.
   */
  jobProjectIds?: Array<string> | undefined;
  /**
   * Since December 2022 Pairs of projects and owner ids to build for this build request.
   */
  jobPairs?: Array<Array<string>> | undefined;
  /**
   * Since June 2024 Pairs of projects and owner ids to immediately finish (without building) because we want to create them in a skipped state.
   */
  skippedJobPairs?: Array<Array<string>> | undefined;
  /**
   * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
   */
  gitHashtagVercel?: Array<UserEventJobPayloadGitHashtagVercel> | undefined;
  /**
   * Since April 2023 Cached count of how many projects are connected to the repo. Saves a few Cosmos queries down the road in the main flow.
   */
  connectedProjectCount?: number | undefined;
  /**
   * Since April 2023 If set then it is a cached result of asking the remote for the PR ID the commit that triggered this Job. Or zero if it was not a PR. This prevents a few git round trips by the git updater.
   */
  prIdOrZero?: number | undefined;
  /**
   * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
   */
  gitComments?: UserEventJobPayload866GitComments | undefined;
  /**
   * Since 28 Feb 2024 If set to true, identifies that the git job was created for a manual git deployment
   */
  isManualGitDeploy?: boolean | undefined;
  /**
   * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
   */
  commitVerification?: UserEventJobPayloadCommitVerification | undefined;
  /**
   * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
   */
  nsnbSideEffect?: UserEventJobPayloadNsnbSideEffect | undefined;
  commit?: Commit | undefined;
  createdAt?: number | undefined;
  deployHook?: UserEventJobPayload86DeployHook | undefined;
  deploymentId?: string | undefined;
  eventful?: boolean | undefined;
  forceNew?: boolean | undefined;
  /**
   * GitLab
   */
  headInfo: UserEventJobPayload866HeadInfo;
  linkedProjectId?: string | undefined;
  prId?: number | undefined;
  project: JobProject;
  projectId?: string | undefined;
  customEnvId?: string | null | undefined;
  ref: string;
  repoPushedAt?: number | null | undefined;
  sha: string;
  silent?: boolean | undefined;
  target?: string | null | undefined;
  url?: string | undefined;
  withCache?: boolean | undefined;
  provider: UserEventJobPayload866Provider;
};

/**
 * Information about the head commit/branch for a GitHub repository
 */
export type UserEventJobPayload86HeadInfo = {
  org: string;
  ref: string;
  repo: string;
  repoId: number;
  sha: string;
};

export type UserEventJobPayload86GitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

export const UserEventJobPayload865Provider = {
  Github: "github",
  GithubCustomHost: "github-custom-host",
  GithubLimited: "github-limited",
} as const;
export type UserEventJobPayload865Provider = ClosedEnum<
  typeof UserEventJobPayload865Provider
>;

export type Job5 = {
  createdAt?: number | undefined;
  eventful?: boolean | undefined;
  /**
   * Information about the head commit/branch for a GitHub repository
   */
  headInfo: UserEventJobPayload86HeadInfo;
  beforeSha?: string | undefined;
  installationId: number;
  isPrivate: boolean;
  linkedProjectId?: string | undefined;
  org: string;
  prId: number;
  projectId?: any | null | undefined;
  customEnvId?: any | null | undefined;
  repo: string;
  repoId: number;
  type: "now-comment";
  gitComments?: UserEventJobPayload86GitComments | undefined;
  provider: UserEventJobPayload865Provider;
  customHost?: string | undefined;
};

export type CommitInfo = {
  total: number;
  earliestSha?: string | undefined;
};

/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export const UserEventJobGitHashtagVercel = {
  NumberVERCELBUILDPRIO1: "#VERCEL_BUILD_PRIO_1",
  NumberVERCELBUILDPRIO10: "#VERCEL_BUILD_PRIO_10",
  NumberVERCELBUILDPRIO2: "#VERCEL_BUILD_PRIO_2",
  NumberVERCELBUILDPRIO3: "#VERCEL_BUILD_PRIO_3",
  NumberVERCELBUILDPRIO4: "#VERCEL_BUILD_PRIO_4",
  NumberVERCELBUILDPRIO5: "#VERCEL_BUILD_PRIO_5",
  NumberVERCELBUILDPRIO6: "#VERCEL_BUILD_PRIO_6",
  NumberVERCELBUILDPRIO7: "#VERCEL_BUILD_PRIO_7",
  NumberVERCELBUILDPRIO8: "#VERCEL_BUILD_PRIO_8",
  NumberVERCELBUILDPRIO9: "#VERCEL_BUILD_PRIO_9",
  NumberVERCELSDDJAFTERGETREPOFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_CANCEL",
  NumberVERCELSDDJAFTERGETREPOFORCEERROR:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_ERROR",
  NumberVERCELSDDJAFTERVERIFYFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_CANCEL",
  NumberVERCELSDDJAFTERVERIFYFORCEERROR:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_ERROR",
  NumberVERCELSDDJBEFOREBUILDJOBQUEUEDERROR:
    "#VERCEL_SDDJ_BEFORE_BUILD_JOB_QUEUED_ERROR",
  NumberVERCELSDDJFORCEGITFORKERROR: "#VERCEL_SDDJ_FORCE_GIT_FORK_ERROR",
  NumberVERCELSKIP: "#VERCEL_SKIP",
  NumberVERCELV0MESSAGE: "#VERCEL_V0_MESSAGE",
} as const;
/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export type UserEventJobGitHashtagVercel = ClosedEnum<
  typeof UserEventJobGitHashtagVercel
>;

/**
 * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
 */
export type UserEventJobPayloadGitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export const UserEventJobCommitVerification = {
  Unknown: "unknown",
  Unverified: "unverified",
  Verified: "verified",
} as const;
/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export type UserEventJobCommitVerification = ClosedEnum<
  typeof UserEventJobCommitVerification
>;

export const UserEventJobPayloadAction = {
  AutoApprovedMember: "auto-approved-member",
  AutoApprovedPendingInvite: "auto-approved-pending-invite",
} as const;
export type UserEventJobPayloadAction = ClosedEnum<
  typeof UserEventJobPayloadAction
>;

/**
 * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
 */
export type UserEventJobNsnbSideEffect = {
  action: UserEventJobPayloadAction;
  gitUserLogin: string;
};

export type UserEventJobPayloadDeployHook = {
  createdAt: number;
  id: string;
  name: string;
  ref: string;
};

/**
 * Information about the head commit/branch for a GitHub repository
 */
export type UserEventJobPayloadHeadInfo = {
  org: string;
  ref: string;
  repo: string;
  repoId: number;
  sha: string;
};

export const UserEventJobPayload86Provider = {
  Github: "github",
  GithubCustomHost: "github-custom-host",
  GithubLimited: "github-limited",
} as const;
export type UserEventJobPayload86Provider = ClosedEnum<
  typeof UserEventJobPayload86Provider
>;

export type Job4 = {
  repoPushedAt: number | null;
  commitInfo?: CommitInfo | undefined;
  forced?: boolean | undefined;
  type: "push";
  authorized?: boolean | undefined;
  authorizedBy?: string | undefined;
  /**
   * Since December 2022 All project ids associated to this job. Think monorepo. This job will be for one of these project.
   */
  jobProjectIds?: Array<string> | undefined;
  /**
   * Since December 2022 Pairs of projects and owner ids to build for this build request.
   */
  jobPairs?: Array<Array<string>> | undefined;
  /**
   * Since June 2024 Pairs of projects and owner ids to immediately finish (without building) because we want to create them in a skipped state.
   */
  skippedJobPairs?: Array<Array<string>> | undefined;
  /**
   * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
   */
  gitHashtagVercel?: Array<UserEventJobGitHashtagVercel> | undefined;
  /**
   * Since April 2023 Cached count of how many projects are connected to the repo. Saves a few Cosmos queries down the road in the main flow.
   */
  connectedProjectCount?: number | undefined;
  /**
   * Since April 2023 If set then it is a cached result of asking the remote for the PR ID the commit that triggered this Job. Or zero if it was not a PR. This prevents a few git round trips by the git updater.
   */
  prIdOrZero?: number | undefined;
  /**
   * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
   */
  gitComments?: UserEventJobPayloadGitComments | undefined;
  /**
   * Since 28 Feb 2024 If set to true, identifies that the git job was created for a manual git deployment
   */
  isManualGitDeploy?: boolean | undefined;
  /**
   * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
   */
  commitVerification?: UserEventJobCommitVerification | undefined;
  /**
   * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
   */
  nsnbSideEffect?: UserEventJobNsnbSideEffect | undefined;
  /**
   * Remote account id of the committer details (github id etc, not vercel). Note that the committer name/email are user input verbatim and not verified. Github does appear to resolve the given email to the username so we can trust that. If the username matches that of the sender, which is verified info, then we can use the account id and account type. See api-incoming, where we determine and set this property Note that even with that, the account may still have been spoofed.
   */
  committerGitUserId?: number | undefined;
  /**
   * Remote account type of the committer details (github type etc, not vercel). Note that the committer name/email are user input verbatim and not verified. Github does appear to resolve the given email to the username so we can trust that. If the username matches that of the sender, which is verified info, then we can use the account id and account type. See api-incoming, where we determine and set this property Note that even with that, the account may still have been spoofed.
   */
  committerGitUserType?: string | undefined;
  createdAt?: number | undefined;
  forceNew?: boolean | undefined;
  deploymentId?: string | undefined;
  deployHook?: UserEventJobPayloadDeployHook | undefined;
  beforeSha?: string | undefined;
  defaultBranch?: string | undefined;
  eventful?: boolean | undefined;
  githubDeploymentId?: string | undefined;
  /**
   * Information about the head commit/branch for a GitHub repository
   */
  headInfo: UserEventJobPayloadHeadInfo;
  installationId: number;
  isPrivate: boolean;
  linkedProjectId?: string | undefined;
  org: string;
  prId: number | null;
  projectId?: string | undefined;
  customEnvId?: string | null | undefined;
  repo: string;
  repoId: number;
  target?: string | null | undefined;
  url?: string | undefined;
  withCache?: boolean | undefined;
  provider: UserEventJobPayload86Provider;
  customHost?: string | undefined;
};

/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export const JobGitHashtagVercel = {
  NumberVERCELBUILDPRIO1: "#VERCEL_BUILD_PRIO_1",
  NumberVERCELBUILDPRIO10: "#VERCEL_BUILD_PRIO_10",
  NumberVERCELBUILDPRIO2: "#VERCEL_BUILD_PRIO_2",
  NumberVERCELBUILDPRIO3: "#VERCEL_BUILD_PRIO_3",
  NumberVERCELBUILDPRIO4: "#VERCEL_BUILD_PRIO_4",
  NumberVERCELBUILDPRIO5: "#VERCEL_BUILD_PRIO_5",
  NumberVERCELBUILDPRIO6: "#VERCEL_BUILD_PRIO_6",
  NumberVERCELBUILDPRIO7: "#VERCEL_BUILD_PRIO_7",
  NumberVERCELBUILDPRIO8: "#VERCEL_BUILD_PRIO_8",
  NumberVERCELBUILDPRIO9: "#VERCEL_BUILD_PRIO_9",
  NumberVERCELSDDJAFTERGETREPOFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_CANCEL",
  NumberVERCELSDDJAFTERGETREPOFORCEERROR:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_ERROR",
  NumberVERCELSDDJAFTERVERIFYFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_CANCEL",
  NumberVERCELSDDJAFTERVERIFYFORCEERROR:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_ERROR",
  NumberVERCELSDDJBEFOREBUILDJOBQUEUEDERROR:
    "#VERCEL_SDDJ_BEFORE_BUILD_JOB_QUEUED_ERROR",
  NumberVERCELSDDJFORCEGITFORKERROR: "#VERCEL_SDDJ_FORCE_GIT_FORK_ERROR",
  NumberVERCELSKIP: "#VERCEL_SKIP",
  NumberVERCELV0MESSAGE: "#VERCEL_V0_MESSAGE",
} as const;
/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export type JobGitHashtagVercel = ClosedEnum<typeof JobGitHashtagVercel>;

/**
 * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
 */
export type UserEventJobGitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export const JobCommitVerification = {
  Unknown: "unknown",
  Unverified: "unverified",
  Verified: "verified",
} as const;
/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export type JobCommitVerification = ClosedEnum<typeof JobCommitVerification>;

export const UserEventJobAction = {
  AutoApprovedMember: "auto-approved-member",
  AutoApprovedPendingInvite: "auto-approved-pending-invite",
} as const;
export type UserEventJobAction = ClosedEnum<typeof UserEventJobAction>;

/**
 * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
 */
export type JobNsnbSideEffect = {
  action: UserEventJobAction;
  gitUserLogin: string;
};

export type UserEventJobDeployHook = {
  createdAt: number;
  id: string;
  name: string;
  ref: string;
};

/**
 * Information about the head commit/branch for a GitHub repository
 */
export type UserEventJobHeadInfo = {
  org: string;
  ref: string;
  repo: string;
  repoId: number;
  sha: string;
};

export const UserEventJobPayloadProvider = {
  Github: "github",
  GithubCustomHost: "github-custom-host",
  GithubLimited: "github-limited",
} as const;
export type UserEventJobPayloadProvider = ClosedEnum<
  typeof UserEventJobPayloadProvider
>;

export type Job3 = {
  prId: number;
  type: "pr";
  authorized?: boolean | undefined;
  authorizedBy?: string | undefined;
  /**
   * Since December 2022 All project ids associated to this job. Think monorepo. This job will be for one of these project.
   */
  jobProjectIds?: Array<string> | undefined;
  /**
   * Since December 2022 Pairs of projects and owner ids to build for this build request.
   */
  jobPairs?: Array<Array<string>> | undefined;
  /**
   * Since June 2024 Pairs of projects and owner ids to immediately finish (without building) because we want to create them in a skipped state.
   */
  skippedJobPairs?: Array<Array<string>> | undefined;
  /**
   * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
   */
  gitHashtagVercel?: Array<JobGitHashtagVercel> | undefined;
  /**
   * Since April 2023 Cached count of how many projects are connected to the repo. Saves a few Cosmos queries down the road in the main flow.
   */
  connectedProjectCount?: number | undefined;
  /**
   * Since April 2023 If set then it is a cached result of asking the remote for the PR ID the commit that triggered this Job. Or zero if it was not a PR. This prevents a few git round trips by the git updater.
   */
  prIdOrZero?: number | undefined;
  /**
   * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
   */
  gitComments?: UserEventJobGitComments | undefined;
  /**
   * Since 28 Feb 2024 If set to true, identifies that the git job was created for a manual git deployment
   */
  isManualGitDeploy?: boolean | undefined;
  /**
   * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
   */
  commitVerification?: JobCommitVerification | undefined;
  /**
   * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
   */
  nsnbSideEffect?: JobNsnbSideEffect | undefined;
  /**
   * Remote account id of the committer details (github id etc, not vercel). Note that the committer name/email are user input verbatim and not verified. Github does appear to resolve the given email to the username so we can trust that. If the username matches that of the sender, which is verified info, then we can use the account id and account type. See api-incoming, where we determine and set this property Note that even with that, the account may still have been spoofed.
   */
  committerGitUserId?: number | undefined;
  /**
   * Remote account type of the committer details (github type etc, not vercel). Note that the committer name/email are user input verbatim and not verified. Github does appear to resolve the given email to the username so we can trust that. If the username matches that of the sender, which is verified info, then we can use the account id and account type. See api-incoming, where we determine and set this property Note that even with that, the account may still have been spoofed.
   */
  committerGitUserType?: string | undefined;
  createdAt?: number | undefined;
  forceNew?: boolean | undefined;
  deploymentId?: string | undefined;
  deployHook?: UserEventJobDeployHook | undefined;
  beforeSha?: string | undefined;
  defaultBranch?: string | undefined;
  eventful?: boolean | undefined;
  githubDeploymentId?: string | undefined;
  /**
   * Information about the head commit/branch for a GitHub repository
   */
  headInfo: UserEventJobHeadInfo;
  installationId: number;
  isPrivate: boolean;
  linkedProjectId?: string | undefined;
  org: string;
  projectId?: string | undefined;
  customEnvId?: string | null | undefined;
  repo: string;
  repoId: number;
  target?: string | null | undefined;
  url?: string | undefined;
  withCache?: boolean | undefined;
  provider: UserEventJobPayloadProvider;
  customHost?: string | undefined;
};

export type JobHeadInfo = {
  owner: string;
  ref: string;
  repoUuid: string;
  sha: string;
  slug: string;
};

export type JobGitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

export const UserEventJobProvider = {
  Bitbucket: "bitbucket",
} as const;
export type UserEventJobProvider = ClosedEnum<typeof UserEventJobProvider>;

/**
 * Represents the payload for a Bitbucket comment job This interface defines the structure of data needed when creating a job to handle comments on Bitbucket pull requests or commits.
 */
export type Job2 = {
  createdAt?: number | undefined;
  eventful?: boolean | undefined;
  headInfo: JobHeadInfo;
  linkedProjectId?: string | undefined;
  name: string;
  owner: string;
  prId: number;
  projectId?: string | undefined;
  customEnvId?: string | null | undefined;
  ref: string;
  repoUuid: string;
  sha: string;
  slug: string;
  type: "bitbucket-now-comment";
  workspaceUuid: string;
  gitComments?: JobGitComments | undefined;
  provider: UserEventJobProvider;
};

/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export const GitHashtagVercel = {
  NumberVERCELBUILDPRIO1: "#VERCEL_BUILD_PRIO_1",
  NumberVERCELBUILDPRIO10: "#VERCEL_BUILD_PRIO_10",
  NumberVERCELBUILDPRIO2: "#VERCEL_BUILD_PRIO_2",
  NumberVERCELBUILDPRIO3: "#VERCEL_BUILD_PRIO_3",
  NumberVERCELBUILDPRIO4: "#VERCEL_BUILD_PRIO_4",
  NumberVERCELBUILDPRIO5: "#VERCEL_BUILD_PRIO_5",
  NumberVERCELBUILDPRIO6: "#VERCEL_BUILD_PRIO_6",
  NumberVERCELBUILDPRIO7: "#VERCEL_BUILD_PRIO_7",
  NumberVERCELBUILDPRIO8: "#VERCEL_BUILD_PRIO_8",
  NumberVERCELBUILDPRIO9: "#VERCEL_BUILD_PRIO_9",
  NumberVERCELSDDJAFTERGETREPOFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_CANCEL",
  NumberVERCELSDDJAFTERGETREPOFORCEERROR:
    "#VERCEL_SDDJ_AFTER_GET_REPO_FORCE_ERROR",
  NumberVERCELSDDJAFTERVERIFYFORCECANCEL:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_CANCEL",
  NumberVERCELSDDJAFTERVERIFYFORCEERROR:
    "#VERCEL_SDDJ_AFTER_VERIFY_FORCE_ERROR",
  NumberVERCELSDDJBEFOREBUILDJOBQUEUEDERROR:
    "#VERCEL_SDDJ_BEFORE_BUILD_JOB_QUEUED_ERROR",
  NumberVERCELSDDJFORCEGITFORKERROR: "#VERCEL_SDDJ_FORCE_GIT_FORK_ERROR",
  NumberVERCELSKIP: "#VERCEL_SKIP",
  NumberVERCELV0MESSAGE: "#VERCEL_V0_MESSAGE",
} as const;
/**
 * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
 */
export type GitHashtagVercel = ClosedEnum<typeof GitHashtagVercel>;

/**
 * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
 */
export type GitComments = {
  onPullRequest: boolean;
  onCommit: boolean;
};

/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export const CommitVerification = {
  Unknown: "unknown",
  Unverified: "unverified",
  Verified: "verified",
} as const;
/**
 * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
 */
export type CommitVerification = ClosedEnum<typeof CommitVerification>;

export const JobAction = {
  AutoApprovedMember: "auto-approved-member",
  AutoApprovedPendingInvite: "auto-approved-pending-invite",
} as const;
export type JobAction = ClosedEnum<typeof JobAction>;

/**
 * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
 */
export type NsnbSideEffect = {
  action: JobAction;
  gitUserLogin: string;
};

export type JobDeployHook = {
  createdAt: number;
  id: string;
  name: string;
  ref: string;
};

export type HeadInfo = {
  owner: string;
  ref: string;
  repoUuid: string;
  sha: string;
  slug: string;
};

export const JobProvider = {
  Bitbucket: "bitbucket",
} as const;
export type JobProvider = ClosedEnum<typeof JobProvider>;

export type Job1 = {
  type: "bitbucket-push";
  authorized?: boolean | undefined;
  authorizedBy?: string | undefined;
  /**
   * Since December 2022 All project ids associated to this job. Think monorepo. This job will be for one of these project.
   */
  jobProjectIds?: Array<string> | undefined;
  /**
   * Since December 2022 Pairs of projects and owner ids to build for this build request.
   */
  jobPairs?: Array<Array<string>> | undefined;
  /**
   * Since June 2024 Pairs of projects and owner ids to immediately finish (without building) because we want to create them in a skipped state.
   */
  skippedJobPairs?: Array<Array<string>> | undefined;
  /**
   * Since February 2022 All the hashtag-vercel tags found in the commit message triggering the deploy. For example, #VERCEL_DO_SOMETHING
   */
  gitHashtagVercel?: Array<GitHashtagVercel> | undefined;
  /**
   * Since April 2023 Cached count of how many projects are connected to the repo. Saves a few Cosmos queries down the road in the main flow.
   */
  connectedProjectCount?: number | undefined;
  /**
   * Since April 2023 If set then it is a cached result of asking the remote for the PR ID the commit that triggered this Job. Or zero if it was not a PR. This prevents a few git round trips by the git updater.
   */
  prIdOrZero?: number | undefined;
  /**
   * Since June 2023 Determines if comments should be posted to the git host. Replaces `github.silent` in the vercel.json.
   */
  gitComments?: GitComments | undefined;
  /**
   * Since 28 Feb 2024 If set to true, identifies that the git job was created for a manual git deployment
   */
  isManualGitDeploy?: boolean | undefined;
  /**
   * Since 6 Nov 2025 The verification status of the commit. - 'verified' if the commit is verified - 'unverified' if the commit is not verified - 'unknown' if the commit verification status is unknown or not supported
   */
  commitVerification?: CommitVerification | undefined;
  /**
   * Since March 2026 Records a successful NSNB auto-add result so later GitHub PR comments can deterministically explain why this SHA was allowed to deploy.
   */
  nsnbSideEffect?: NsnbSideEffect | undefined;
  createdAt?: number | undefined;
  deploymentId?: string | undefined;
  deployHook?: JobDeployHook | undefined;
  eventful?: boolean | undefined;
  forceNew?: boolean | undefined;
  headInfo: HeadInfo;
  linkedProjectId?: string | undefined;
  name: string;
  owner: string;
  prId?: number | undefined;
  projectId?: string | undefined;
  customEnvId?: string | null | undefined;
  ref: string;
  repoPushedAt?: number | null | undefined;
  repoUuid: string;
  sha: string;
  silent?: boolean | undefined;
  slug: string;
  target?: string | null | undefined;
  url?: string | undefined;
  withCache?: boolean | undefined;
  workspaceUuid: string;
  provider: JobProvider;
};

export type PayloadJob = Job1 | Job2 | Job3 | Job4 | Job5 | Job6 | Job7 | Job8;

/**
 * The payload of the event, if requested.
 */
export type EightySix = {
  job: Job1 | Job2 | Job3 | Job4 | Job5 | Job6 | Job7 | Job8;
};

/**
 * A narrowed subset of the deployment's `readyStateReasonInternal` — only values in the public allowlist are permitted here. Callers should run their raw reason through `toAllowListedReadyStateReasonInternal` from `@api/events` before assigning. This keeps abuse / moderation / admin reasons out of the public activity log.
 */
export const UserEventPayloadAllowListedReadyStateReasonInternal = {
  EarlyIgnoreStep: "EARLY_IGNORE_STEP",
  IgnoreStep: "IGNORE_STEP",
  NamespacePruned: "NAMESPACE_PRUNED",
  UnaffectedProject: "UNAFFECTED_PROJECT",
  UnverifiedCommit: "UNVERIFIED_COMMIT",
} as const;
/**
 * A narrowed subset of the deployment's `readyStateReasonInternal` — only values in the public allowlist are permitted here. Callers should run their raw reason through `toAllowListedReadyStateReasonInternal` from `@api/events` before assigning. This keeps abuse / moderation / admin reasons out of the public activity log.
 */
export type UserEventPayloadAllowListedReadyStateReasonInternal = ClosedEnum<
  typeof UserEventPayloadAllowListedReadyStateReasonInternal
>;

export type UserEventPayloadDeployment = {
  id: string;
  name: string;
  url: string;
  meta: { [k: string]: string };
  readyState?: string | undefined;
  /**
   * A narrowed subset of the deployment's `readyStateReasonInternal` — only values in the public allowlist are permitted here. Callers should run their raw reason through `toAllowListedReadyStateReasonInternal` from `@api/events` before assigning. This keeps abuse / moderation / admin reasons out of the public activity log.
   */
  allowListedReadyStateReasonInternal?:
    | UserEventPayloadAllowListedReadyStateReasonInternal
    | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type EightyFive = {
  name?: string | undefined;
  alias?: Array<string> | undefined;
  target?: string | null | undefined;
  deployment?: UserEventPayloadDeployment | null | undefined;
  url: string;
  forced?: boolean | undefined;
  deploymentId?: string | undefined;
  plan?: string | undefined;
  project?: string | undefined;
  projectId?: string | undefined;
  regions?: Array<string> | undefined;
  type?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type EightyFour = {
  projectId: string;
  projectName: string;
  checkId: string;
  checkName: string;
};

export type UserEventPayload83Project = {
  name: string;
};

export type DeployHook = {
  createdAt: number;
  id: string;
  name: string;
  ref: string;
};

export type Job = {
  deployHook: DeployHook;
  state: string;
};

/**
 * The payload of the event, if requested.
 */
export type EightyThree = {
  project: UserEventPayload83Project;
  job: Job;
};

/**
 * The payload of the event, if requested.
 */
export type EightyTwo = {
  projectId: string;
  projectName: string;
  hookName: string;
  ref: string;
};

/**
 * The payload of the event, if requested.
 */
export type EightyOne = {
  suffix: string;
};

/**
 * The payload of the event, if requested.
 */
export type Eighty = {
  status: string;
  suffix: string;
};

/**
 * The payload of the event, if requested.
 */
export type SeventyNine = {
  reason?: string | undefined;
  suffix: string;
};

export const SubjectType = {
  App: "app",
  User: "user",
} as const;
export type SubjectType = ClosedEnum<typeof SubjectType>;

/**
 * The payload of the event, if requested.
 */
export type SeventyEight = {
  clientId?: string | undefined;
  clientUid?: string | undefined;
  clientName?: string | undefined;
  projectId?: string | undefined;
  installationId?: string | undefined;
  subjectType?: SubjectType | undefined;
  fields?: Array<string> | undefined;
  triggerDestinationCount?: number | undefined;
  tokensDeleted?: number | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SeventySeven = {
  bitbucketLogin: string;
  bitbucketAccountId: string;
};

/**
 * The payload of the event, if requested.
 */
export type SeventySix = {
  bitbucketEmail: string;
  bitbucketLogin: string;
  bitbucketName?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SeventyFive = {
  gitlabLogin: string;
  gitlabUserId: number;
};

/**
 * The payload of the event, if requested.
 */
export type SeventyFour = {
  gitlabLogin: string;
  gitlabEmail: string;
  gitlabName?: string | undefined;
  zeitAccount?: string | undefined;
  zeitAccountType?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SeventyThree = {
  githubLogin: string;
  host: string;
};

/**
 * The payload of the event, if requested.
 */
export type SeventyTwo = {
  githubLogin: string;
};

/**
 * The payload of the event, if requested.
 */
export type SeventyOne = {
  githubLogin: string;
  host?: string | undefined;
};

export type UserEventPayload70Team = {
  id: string;
  name: string;
};

export type UserEventPayload70Configuration = {
  id: string;
  name?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type Seventy = {
  team: UserEventPayload70Team;
  configuration: UserEventPayload70Configuration;
  newName: string;
};

export type UserEventPayloadTeam = {
  id: string;
  name: string;
};

export type UserEventPayload69Configuration = {
  id: string;
  name?: string | undefined;
};

export type UserEventPayload69Project = {
  id: string;
  name?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyNine = {
  team: UserEventPayloadTeam;
  configuration: UserEventPayload69Configuration;
  project: UserEventPayload69Project;
};

export type PayloadTeam = {
  id: string;
  name: string;
};

export type UserEventPayloadConfiguration = {
  id: string;
  name?: string | undefined;
};

export type UserEventPayload68Project = {
  id: string;
  name?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyEight = {
  team: PayloadTeam;
  configuration: UserEventPayloadConfiguration;
  project: UserEventPayload68Project;
  buildsEnabled?: boolean | undefined;
  passive?: boolean | undefined;
};

export type UserEventPayload67Team = {
  id: string;
  name: string;
};

export type PayloadConfiguration = {
  id: string;
  name?: string | undefined;
};

export type UserEventPayload67Project = {
  id: string;
  name?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SixtySeven = {
  team: UserEventPayload67Team;
  configuration: PayloadConfiguration;
  project: UserEventPayload67Project;
  buildsEnabled?: boolean | undefined;
};

export type Configuration = {
  id: string;
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type SixtySix = {
  configuration: Configuration;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyFive = {
  cn?: string | undefined;
  cns?: Array<string> | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyFour = {
  id: string;
  cn?: string | undefined;
  cns?: Array<string> | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyThree = {
  src: string;
  dst: string;
};

export type PayloadOldTeam = {
  name: string;
};

export type PayloadNewTeam = {
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyTwo = {
  id: string;
  oldTeam?: PayloadOldTeam | undefined;
  newTeam?: PayloadNewTeam | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type SixtyOne = {
  cn?: string | undefined;
  cns?: Array<string> | undefined;
  id?: string | undefined;
};

/**
 * The payload of the event, if requested.
 */
export type Sixty = {
  id: string;
  cns: Array<string>;
  custom: boolean;
};

/**
 * The payload of the event, if requested.
 */
export type FiftyNine = {
  cn?: string | undefined;
  cns?: Array<string> | undefined;
  custom: boolean;
  id?: string | undefined;
};

export type UserEventPayloadProject = {
  id: string;
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type FiftyEight = {
  project: UserEventPayloadProject;
  versionId: string;
};

export type PayloadProject = {
  id: string;
  name: string;
};

/**
 * The payload of the event, if requested.
 */
export type FiftySeven = {
  project: PayloadProject;
  bulkRedirectsLimit: number;
  prevBulkRedirectsLimit: number;
};

/**
 * The payload of the event, if requested.
 */
export type FiftySix = {
  subscriptionId?: string | undefined;
  productAliases: Array<string>;
};

/** @internal */
export const OneHundredAndTen$inboundSchema: z.ZodType<
  OneHundredAndTen,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  price: types.optional(types.number()),
  currency: types.optional(types.string()),
});

export function oneHundredAndTenFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndTen, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndTen$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndTen' from JSON`,
  );
}

/** @internal */
export const OneHundredAndNine$inboundSchema: z.ZodType<
  OneHundredAndNine,
  z.ZodTypeDef,
  unknown
> = z.object({
  renew: types.optional(types.boolean()),
  domain: types.string(),
});

export function oneHundredAndNineFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndNine, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndNine$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndNine' from JSON`,
  );
}

/** @internal */
export const OneHundredAndEight$inboundSchema: z.ZodType<
  OneHundredAndEight,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  destinationId: types.string(),
  destinationName: types.string(),
});

export function oneHundredAndEightFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndEight, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndEight$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndEight' from JSON`,
  );
}

/** @internal */
export const OneHundredAndSeven$inboundSchema: z.ZodType<
  OneHundredAndSeven,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  destinationId: types.nullable(types.string()),
  destinationName: types.nullable(types.string()),
});

export function oneHundredAndSevenFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndSeven, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndSeven$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndSeven' from JSON`,
  );
}

/** @internal */
export const OneHundredAndSix$inboundSchema: z.ZodType<
  OneHundredAndSix,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  fromId: types.nullable(types.string()),
  fromName: types.nullable(types.string()),
});

export function oneHundredAndSixFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndSix, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndSix$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndSix' from JSON`,
  );
}

/** @internal */
export const OneHundredAndFive$inboundSchema: z.ZodType<
  OneHundredAndFive,
  z.ZodTypeDef,
  unknown
> = z.object({
  domain: types.string(),
  zone: types.boolean(),
});

export function oneHundredAndFiveFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndFive, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndFive$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndFive' from JSON`,
  );
}

/** @internal */
export const OneHundredAndFour$inboundSchema: z.ZodType<
  OneHundredAndFour,
  z.ZodTypeDef,
  unknown
> = z.object({
  domain: types.string(),
});

export function oneHundredAndFourFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndFour, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndFour$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndFour' from JSON`,
  );
}

/** @internal */
export const OneHundredAndThree$inboundSchema: z.ZodType<
  OneHundredAndThree,
  z.ZodTypeDef,
  unknown
> = z.object({
  domain: types.string(),
  customNameservers: types.nullable(z.array(types.string())),
  prevCustomNameservers: types.nullable(z.array(types.string())),
});

export function oneHundredAndThreeFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndThree, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndThree$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndThree' from JSON`,
  );
}

/** @internal */
export const OneHundredAndTwo$inboundSchema: z.ZodType<
  OneHundredAndTwo,
  z.ZodTypeDef,
  unknown
> = z.object({
  previousServiceType: types.string(),
  serviceType: types.string(),
  id: types.string(),
  name: types.string(),
  nameservers: z.array(types.string()),
});

export function oneHundredAndTwoFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndTwo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndTwo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndTwo' from JSON`,
  );
}

/** @internal */
export const OneHundredAndOne$inboundSchema: z.ZodType<
  OneHundredAndOne,
  z.ZodTypeDef,
  unknown
> = z.object({
  domainId: types.string(),
  name: types.string(),
});

export function oneHundredAndOneFromJSON(
  jsonString: string,
): SafeParseResult<OneHundredAndOne, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundredAndOne$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundredAndOne' from JSON`,
  );
}

/** @internal */
export const OneHundred$inboundSchema: z.ZodType<
  OneHundred,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  userId: types.string(),
  teamId: types.string(),
  ownerName: types.string(),
});

export function oneHundredFromJSON(
  jsonString: string,
): SafeParseResult<OneHundred, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => OneHundred$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'OneHundred' from JSON`,
  );
}

/** @internal */
export const UserEventPayload99OldTeam$inboundSchema: z.ZodType<
  UserEventPayload99OldTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function userEventPayload99OldTeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload99OldTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload99OldTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload99OldTeam' from JSON`,
  );
}

/** @internal */
export const UserEventPayload99NewTeam$inboundSchema: z.ZodType<
  UserEventPayload99NewTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function userEventPayload99NewTeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload99NewTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload99NewTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload99NewTeam' from JSON`,
  );
}

/** @internal */
export const NinetyNine$inboundSchema: z.ZodType<
  NinetyNine,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  oldTeam: types.optional(
    z.lazy(() => UserEventPayload99OldTeam$inboundSchema),
  ),
  newTeam: types.optional(
    z.lazy(() => UserEventPayload99NewTeam$inboundSchema),
  ),
});

export function ninetyNineFromJSON(
  jsonString: string,
): SafeParseResult<NinetyNine, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyNine$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyNine' from JSON`,
  );
}

/** @internal */
export const NinetyEight$inboundSchema: z.ZodType<
  NinetyEight,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  cdnEnabled: types.boolean(),
});

export function ninetyEightFromJSON(
  jsonString: string,
): SafeParseResult<NinetyEight, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyEight$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyEight' from JSON`,
  );
}

/** @internal */
export const NinetySeven$inboundSchema: z.ZodType<
  NinetySeven,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
  price: types.number(),
  currency: types.optional(types.string()),
});

export function ninetySevenFromJSON(
  jsonString: string,
): SafeParseResult<NinetySeven, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetySeven$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetySeven' from JSON`,
  );
}

/** @internal */
export const NinetySix$inboundSchema: z.ZodType<
  NinetySix,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function ninetySixFromJSON(
  jsonString: string,
): SafeParseResult<NinetySix, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetySix$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetySix' from JSON`,
  );
}

/** @internal */
export const NinetyFive$inboundSchema: z.ZodType<
  NinetyFive,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  value: types.string(),
  name: types.string(),
  domain: types.string(),
  type: types.string(),
});

export function ninetyFiveFromJSON(
  jsonString: string,
): SafeParseResult<NinetyFive, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyFive$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyFive' from JSON`,
  );
}

/** @internal */
export const UserEventPayload94Action$inboundSchema: z.ZodNativeEnum<
  typeof UserEventPayload94Action
> = z.nativeEnum(UserEventPayload94Action);

/** @internal */
export const Initiator$inboundSchema: z.ZodNativeEnum<typeof Initiator> = z
  .nativeEnum(Initiator);

/** @internal */
export const NinetyFour$inboundSchema: z.ZodType<
  NinetyFour,
  z.ZodTypeDef,
  unknown
> = z.object({
  action: UserEventPayload94Action$inboundSchema,
  initiator: Initiator$inboundSchema,
  id: types.string(),
  domain: types.string(),
  name: types.string(),
  type: types.string(),
  value: types.string(),
  mxPriority: types.optional(types.number()),
  previousValue: types.optional(types.string()),
  source: types.optional(types.string()),
});

export function ninetyFourFromJSON(
  jsonString: string,
): SafeParseResult<NinetyFour, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyFour$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyFour' from JSON`,
  );
}

/** @internal */
export const NinetyThree$inboundSchema: z.ZodType<
  NinetyThree,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  value: types.string(),
  name: types.string(),
  domain: types.string(),
  type: types.string(),
  mxPriority: types.optional(types.number()),
});

export function ninetyThreeFromJSON(
  jsonString: string,
): SafeParseResult<NinetyThree, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyThree$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyThree' from JSON`,
  );
}

/** @internal */
export const NinetyTwo$inboundSchema: z.ZodType<
  NinetyTwo,
  z.ZodTypeDef,
  unknown
> = z.object({
  integrationId: types.string(),
  configurationId: types.string(),
  integrationSlug: types.string(),
  integrationName: types.string(),
  ownerId: types.string(),
  projectIds: types.optional(z.array(types.string())),
});

export function ninetyTwoFromJSON(
  jsonString: string,
): SafeParseResult<NinetyTwo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyTwo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyTwo' from JSON`,
  );
}

/** @internal */
export const NinetyOne$inboundSchema: z.ZodType<
  NinetyOne,
  z.ZodTypeDef,
  unknown
> = z.object({
  deploymentId: types.string(),
  deploymentUrl: types.nullable(types.string()),
  deploymentName: types.nullable(types.string()),
  projectId: types.string(),
  projectName: types.string(),
});

export function ninetyOneFromJSON(
  jsonString: string,
): SafeParseResult<NinetyOne, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NinetyOne$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NinetyOne' from JSON`,
  );
}

/** @internal */
export const RuleName$inboundSchema: z.ZodNativeEnum<typeof RuleName> = z
  .nativeEnum(RuleName);

/** @internal */
export const RuleProvenance$inboundSchema: z.ZodNativeEnum<
  typeof RuleProvenance
> = z.nativeEnum(RuleProvenance);

/** @internal */
export const Ninety$inboundSchema: z.ZodType<Ninety, z.ZodTypeDef, unknown> = z
  .object({
    projectId: types.optional(types.string()),
    projectName: types.string(),
    deploymentId: types.optional(types.string()),
    source: types.string(),
    ruleName: RuleName$inboundSchema,
    ruleProvenance: RuleProvenance$inboundSchema,
  });

export function ninetyFromJSON(
  jsonString: string,
): SafeParseResult<Ninety, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Ninety$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Ninety' from JSON`,
  );
}

/** @internal */
export const UserEventPayload89Deployment$inboundSchema: z.ZodType<
  UserEventPayload89Deployment,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
  meta: z.record(types.string()),
  url: types.string(),
});

export function userEventPayload89DeploymentFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload89Deployment, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload89Deployment$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload89Deployment' from JSON`,
  );
}

/** @internal */
export const EightyNine$inboundSchema: z.ZodType<
  EightyNine,
  z.ZodTypeDef,
  unknown
> = z.object({
  deployment: z.lazy(() => UserEventPayload89Deployment$inboundSchema),
  deploymentId: types.string(),
  url: types.string(),
});

export function eightyNineFromJSON(
  jsonString: string,
): SafeParseResult<EightyNine, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyNine$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyNine' from JSON`,
  );
}

/** @internal */
export const EightyEight$inboundSchema: z.ZodType<
  EightyEight,
  z.ZodTypeDef,
  unknown
> = z.object({
  sha: types.string(),
  gitUserPlatform: types.string(),
  projectId: types.optional(types.string()),
  projectName: types.string(),
  gitCommitterName: types.string(),
  source: types.string(),
});

export function eightyEightFromJSON(
  jsonString: string,
): SafeParseResult<EightyEight, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyEight$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyEight' from JSON`,
  );
}

/** @internal */
export const UserEventPayloadOldTeam$inboundSchema: z.ZodType<
  UserEventPayloadOldTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function userEventPayloadOldTeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayloadOldTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayloadOldTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayloadOldTeam' from JSON`,
  );
}

/** @internal */
export const UserEventPayloadNewTeam$inboundSchema: z.ZodType<
  UserEventPayloadNewTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function userEventPayloadNewTeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayloadNewTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayloadNewTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayloadNewTeam' from JSON`,
  );
}

/** @internal */
export const EightySeven$inboundSchema: z.ZodType<
  EightySeven,
  z.ZodTypeDef,
  unknown
> = z.object({
  url: types.string(),
  oldTeam: types.optional(z.lazy(() => UserEventPayloadOldTeam$inboundSchema)),
  newTeam: types.optional(z.lazy(() => UserEventPayloadNewTeam$inboundSchema)),
});

export function eightySevenFromJSON(
  jsonString: string,
): SafeParseResult<EightySeven, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightySeven$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightySeven' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload868DeployHook$inboundSchema: z.ZodType<
  UserEventJobPayload868DeployHook,
  z.ZodTypeDef,
  unknown
> = z.object({
  createdAt: types.number(),
  id: types.string(),
  name: types.string(),
  ref: types.string(),
});

export function userEventJobPayload868DeployHookFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload868DeployHook, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload868DeployHook$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload868DeployHook' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86GitHashtagVercel$inboundSchema:
  z.ZodNativeEnum<typeof UserEventJobPayload86GitHashtagVercel> = z.nativeEnum(
    UserEventJobPayload86GitHashtagVercel,
  );

/** @internal */
export const UserEventJobPayload868GitComments$inboundSchema: z.ZodType<
  UserEventJobPayload868GitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function userEventJobPayload868GitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload868GitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload868GitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload868GitComments' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86CommitVerification$inboundSchema:
  z.ZodNativeEnum<typeof UserEventJobPayload86CommitVerification> = z
    .nativeEnum(UserEventJobPayload86CommitVerification);

/** @internal */
export const UserEventJobPayload868Action$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload868Action
> = z.nativeEnum(UserEventJobPayload868Action);

/** @internal */
export const UserEventJobPayload86NsnbSideEffect$inboundSchema: z.ZodType<
  UserEventJobPayload86NsnbSideEffect,
  z.ZodTypeDef,
  unknown
> = z.object({
  action: UserEventJobPayload868Action$inboundSchema,
  gitUserLogin: types.string(),
});

export function userEventJobPayload86NsnbSideEffectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload86NsnbSideEffect, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) =>
      UserEventJobPayload86NsnbSideEffect$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload86NsnbSideEffect' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload868HeadInfo$inboundSchema: z.ZodType<
  UserEventJobPayload868HeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  org: types.string(),
  ref: types.string(),
  repo: types.string(),
  sha: types.string(),
});

export function userEventJobPayload868HeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload868HeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload868HeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload868HeadInfo' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload868Provider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload868Provider
> = z.nativeEnum(UserEventJobPayload868Provider);

/** @internal */
export const Job8$inboundSchema: z.ZodType<Job8, z.ZodTypeDef, unknown> = z
  .object({
    type: types.literal("vercel-push"),
    ref: types.string(),
    repo: types.string(),
    sha: types.string(),
    repoPushedAt: z.nullable(types.number()).optional(),
    deployHook: types.optional(
      z.lazy(() => UserEventJobPayload868DeployHook$inboundSchema),
    ),
    url: types.optional(types.string()),
    target: z.nullable(types.string()).optional(),
    deploymentId: types.optional(types.string()),
    linkedProjectId: types.optional(types.string()),
    projectId: types.optional(types.string()),
    authorized: types.optional(types.boolean()),
    authorizedBy: types.optional(types.string()),
    jobProjectIds: types.optional(z.array(types.string())),
    jobPairs: types.optional(z.array(z.array(types.string()))),
    skippedJobPairs: types.optional(z.array(z.array(types.string()))),
    gitHashtagVercel: types.optional(
      z.array(UserEventJobPayload86GitHashtagVercel$inboundSchema),
    ),
    connectedProjectCount: types.optional(types.number()),
    prIdOrZero: types.optional(types.number()),
    gitComments: types.optional(
      z.lazy(() => UserEventJobPayload868GitComments$inboundSchema),
    ),
    isManualGitDeploy: types.optional(types.boolean()),
    commitVerification: types.optional(
      UserEventJobPayload86CommitVerification$inboundSchema,
    ),
    nsnbSideEffect: types.optional(
      z.lazy(() => UserEventJobPayload86NsnbSideEffect$inboundSchema),
    ),
    headInfo: z.lazy(() => UserEventJobPayload868HeadInfo$inboundSchema),
    org: types.string(),
    provider: UserEventJobPayload868Provider$inboundSchema,
    customEnvId: z.nullable(types.string()).optional(),
    prId: z.nullable(types.number()).optional(),
  });

export function job8FromJSON(
  jsonString: string,
): SafeParseResult<Job8, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job8$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job8' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayloadProject$inboundSchema: z.ZodType<
  UserEventJobPayloadProject,
  z.ZodTypeDef,
  unknown
> = z.object({
  defaultBranch: z.nullable(types.string()).optional(),
  id: types.string(),
  name: z.nullable(types.string()).optional(),
  namespace: z.nullable(types.string()).optional(),
  path: z.nullable(types.string()).optional(),
  url: z.nullable(types.string()).optional(),
});

export function userEventJobPayloadProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayloadProject, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayloadProject$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayloadProject' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload867HeadInfo$inboundSchema: z.ZodType<
  UserEventJobPayload867HeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  project: z.lazy(() => UserEventJobPayloadProject$inboundSchema),
  ref: types.string(),
  sha: types.string(),
});

export function userEventJobPayload867HeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload867HeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload867HeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload867HeadInfo' from JSON`,
  );
}

/** @internal */
export const UserEventJobProject$inboundSchema: z.ZodType<
  UserEventJobProject,
  z.ZodTypeDef,
  unknown
> = z.object({
  defaultBranch: z.nullable(types.string()).optional(),
  id: types.string(),
  name: z.nullable(types.string()).optional(),
  namespace: z.nullable(types.string()).optional(),
  path: z.nullable(types.string()).optional(),
  url: z.nullable(types.string()).optional(),
});

export function userEventJobProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobProject, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobProject$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobProject' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload867GitComments$inboundSchema: z.ZodType<
  UserEventJobPayload867GitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function userEventJobPayload867GitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload867GitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload867GitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload867GitComments' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload867Provider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload867Provider
> = z.nativeEnum(UserEventJobPayload867Provider);

/** @internal */
export const Job7$inboundSchema: z.ZodType<Job7, z.ZodTypeDef, unknown> = z
  .object({
    createdAt: types.optional(types.number()),
    eventful: types.optional(types.boolean()),
    headInfo: z.lazy(() => UserEventJobPayload867HeadInfo$inboundSchema),
    linkedProjectId: types.optional(types.string()),
    prId: types.number(),
    project: z.lazy(() => UserEventJobProject$inboundSchema),
    projectId: types.optional(types.string()),
    customEnvId: z.nullable(types.string()).optional(),
    ref: types.string(),
    sha: types.string(),
    type: types.literal("gitlab-now-comment"),
    gitComments: types.optional(
      z.lazy(() => UserEventJobPayload867GitComments$inboundSchema),
    ),
    provider: UserEventJobPayload867Provider$inboundSchema,
  });

export function job7FromJSON(
  jsonString: string,
): SafeParseResult<Job7, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job7$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job7' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayloadGitHashtagVercel$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayloadGitHashtagVercel
> = z.nativeEnum(UserEventJobPayloadGitHashtagVercel);

/** @internal */
export const UserEventJobPayload866GitComments$inboundSchema: z.ZodType<
  UserEventJobPayload866GitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function userEventJobPayload866GitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload866GitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload866GitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload866GitComments' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayloadCommitVerification$inboundSchema:
  z.ZodNativeEnum<typeof UserEventJobPayloadCommitVerification> = z.nativeEnum(
    UserEventJobPayloadCommitVerification,
  );

/** @internal */
export const UserEventJobPayload86Action$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload86Action
> = z.nativeEnum(UserEventJobPayload86Action);

/** @internal */
export const UserEventJobPayloadNsnbSideEffect$inboundSchema: z.ZodType<
  UserEventJobPayloadNsnbSideEffect,
  z.ZodTypeDef,
  unknown
> = z.object({
  action: UserEventJobPayload86Action$inboundSchema,
  gitUserLogin: types.string(),
});

export function userEventJobPayloadNsnbSideEffectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayloadNsnbSideEffect, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayloadNsnbSideEffect$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayloadNsnbSideEffect' from JSON`,
  );
}

/** @internal */
export const Commit$inboundSchema: z.ZodType<Commit, z.ZodTypeDef, unknown> = z
  .object({
    id: types.string(),
    authorAvatar: z.nullable(types.string()).optional(),
    authorEmail: z.nullable(types.string()).optional(),
    authorId: z.nullable(types.number()).optional(),
    authorLogin: z.nullable(types.string()).optional(),
    authorName: z.nullable(types.string()).optional(),
  });

export function commitFromJSON(
  jsonString: string,
): SafeParseResult<Commit, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Commit$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Commit' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86DeployHook$inboundSchema: z.ZodType<
  UserEventJobPayload86DeployHook,
  z.ZodTypeDef,
  unknown
> = z.object({
  createdAt: types.number(),
  id: types.string(),
  name: types.string(),
  ref: types.string(),
});

export function userEventJobPayload86DeployHookFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload86DeployHook, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload86DeployHook$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload86DeployHook' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86Project$inboundSchema: z.ZodType<
  UserEventJobPayload86Project,
  z.ZodTypeDef,
  unknown
> = z.object({
  defaultBranch: z.nullable(types.string()).optional(),
  id: types.string(),
  name: z.nullable(types.string()).optional(),
  namespace: z.nullable(types.string()).optional(),
  path: z.nullable(types.string()).optional(),
  url: z.nullable(types.string()).optional(),
});

export function userEventJobPayload86ProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload86Project, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload86Project$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload86Project' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload866HeadInfo$inboundSchema: z.ZodType<
  UserEventJobPayload866HeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  project: z.lazy(() => UserEventJobPayload86Project$inboundSchema),
  ref: types.string(),
  sha: types.string(),
});

export function userEventJobPayload866HeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload866HeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload866HeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload866HeadInfo' from JSON`,
  );
}

/** @internal */
export const JobProject$inboundSchema: z.ZodType<
  JobProject,
  z.ZodTypeDef,
  unknown
> = z.object({
  defaultBranch: z.nullable(types.string()).optional(),
  id: types.string(),
  name: z.nullable(types.string()).optional(),
  namespace: z.nullable(types.string()).optional(),
  path: z.nullable(types.string()).optional(),
  url: z.nullable(types.string()).optional(),
});

export function jobProjectFromJSON(
  jsonString: string,
): SafeParseResult<JobProject, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => JobProject$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'JobProject' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload866Provider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload866Provider
> = z.nativeEnum(UserEventJobPayload866Provider);

/** @internal */
export const Job6$inboundSchema: z.ZodType<Job6, z.ZodTypeDef, unknown> = z
  .object({
    type: types.literal("gitlab-push"),
    authorized: types.optional(types.boolean()),
    authorizedBy: types.optional(types.string()),
    jobProjectIds: types.optional(z.array(types.string())),
    jobPairs: types.optional(z.array(z.array(types.string()))),
    skippedJobPairs: types.optional(z.array(z.array(types.string()))),
    gitHashtagVercel: types.optional(
      z.array(UserEventJobPayloadGitHashtagVercel$inboundSchema),
    ),
    connectedProjectCount: types.optional(types.number()),
    prIdOrZero: types.optional(types.number()),
    gitComments: types.optional(
      z.lazy(() => UserEventJobPayload866GitComments$inboundSchema),
    ),
    isManualGitDeploy: types.optional(types.boolean()),
    commitVerification: types.optional(
      UserEventJobPayloadCommitVerification$inboundSchema,
    ),
    nsnbSideEffect: types.optional(
      z.lazy(() => UserEventJobPayloadNsnbSideEffect$inboundSchema),
    ),
    commit: types.optional(z.lazy(() => Commit$inboundSchema)),
    createdAt: types.optional(types.number()),
    deployHook: types.optional(
      z.lazy(() => UserEventJobPayload86DeployHook$inboundSchema),
    ),
    deploymentId: types.optional(types.string()),
    eventful: types.optional(types.boolean()),
    forceNew: types.optional(types.boolean()),
    headInfo: z.lazy(() => UserEventJobPayload866HeadInfo$inboundSchema),
    linkedProjectId: types.optional(types.string()),
    prId: types.optional(types.number()),
    project: z.lazy(() => JobProject$inboundSchema),
    projectId: types.optional(types.string()),
    customEnvId: z.nullable(types.string()).optional(),
    ref: types.string(),
    repoPushedAt: z.nullable(types.number()).optional(),
    sha: types.string(),
    silent: types.optional(types.boolean()),
    target: z.nullable(types.string()).optional(),
    url: types.optional(types.string()),
    withCache: types.optional(types.boolean()),
    provider: UserEventJobPayload866Provider$inboundSchema,
  });

export function job6FromJSON(
  jsonString: string,
): SafeParseResult<Job6, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job6$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job6' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86HeadInfo$inboundSchema: z.ZodType<
  UserEventJobPayload86HeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  org: types.string(),
  ref: types.string(),
  repo: types.string(),
  repoId: types.number(),
  sha: types.string(),
});

export function userEventJobPayload86HeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload86HeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload86HeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload86HeadInfo' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86GitComments$inboundSchema: z.ZodType<
  UserEventJobPayload86GitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function userEventJobPayload86GitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayload86GitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayload86GitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayload86GitComments' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload865Provider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload865Provider
> = z.nativeEnum(UserEventJobPayload865Provider);

/** @internal */
export const Job5$inboundSchema: z.ZodType<Job5, z.ZodTypeDef, unknown> = z
  .object({
    createdAt: types.optional(types.number()),
    eventful: types.optional(types.boolean()),
    headInfo: z.lazy(() => UserEventJobPayload86HeadInfo$inboundSchema),
    beforeSha: types.optional(types.string()),
    installationId: types.number(),
    isPrivate: types.boolean(),
    linkedProjectId: types.optional(types.string()),
    org: types.string(),
    prId: types.number(),
    projectId: z.nullable(z.any()).optional(),
    customEnvId: z.nullable(z.any()).optional(),
    repo: types.string(),
    repoId: types.number(),
    type: types.literal("now-comment"),
    gitComments: types.optional(
      z.lazy(() => UserEventJobPayload86GitComments$inboundSchema),
    ),
    provider: UserEventJobPayload865Provider$inboundSchema,
    customHost: types.optional(types.string()),
  });

export function job5FromJSON(
  jsonString: string,
): SafeParseResult<Job5, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job5$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job5' from JSON`,
  );
}

/** @internal */
export const CommitInfo$inboundSchema: z.ZodType<
  CommitInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  total: types.number(),
  earliestSha: types.optional(types.string()),
});

export function commitInfoFromJSON(
  jsonString: string,
): SafeParseResult<CommitInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => CommitInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'CommitInfo' from JSON`,
  );
}

/** @internal */
export const UserEventJobGitHashtagVercel$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobGitHashtagVercel
> = z.nativeEnum(UserEventJobGitHashtagVercel);

/** @internal */
export const UserEventJobPayloadGitComments$inboundSchema: z.ZodType<
  UserEventJobPayloadGitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function userEventJobPayloadGitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayloadGitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayloadGitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayloadGitComments' from JSON`,
  );
}

/** @internal */
export const UserEventJobCommitVerification$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobCommitVerification
> = z.nativeEnum(UserEventJobCommitVerification);

/** @internal */
export const UserEventJobPayloadAction$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayloadAction
> = z.nativeEnum(UserEventJobPayloadAction);

/** @internal */
export const UserEventJobNsnbSideEffect$inboundSchema: z.ZodType<
  UserEventJobNsnbSideEffect,
  z.ZodTypeDef,
  unknown
> = z.object({
  action: UserEventJobPayloadAction$inboundSchema,
  gitUserLogin: types.string(),
});

export function userEventJobNsnbSideEffectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobNsnbSideEffect, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobNsnbSideEffect$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobNsnbSideEffect' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayloadDeployHook$inboundSchema: z.ZodType<
  UserEventJobPayloadDeployHook,
  z.ZodTypeDef,
  unknown
> = z.object({
  createdAt: types.number(),
  id: types.string(),
  name: types.string(),
  ref: types.string(),
});

export function userEventJobPayloadDeployHookFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayloadDeployHook, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayloadDeployHook$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayloadDeployHook' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayloadHeadInfo$inboundSchema: z.ZodType<
  UserEventJobPayloadHeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  org: types.string(),
  ref: types.string(),
  repo: types.string(),
  repoId: types.number(),
  sha: types.string(),
});

export function userEventJobPayloadHeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobPayloadHeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobPayloadHeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobPayloadHeadInfo' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayload86Provider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayload86Provider
> = z.nativeEnum(UserEventJobPayload86Provider);

/** @internal */
export const Job4$inboundSchema: z.ZodType<Job4, z.ZodTypeDef, unknown> = z
  .object({
    repoPushedAt: types.nullable(types.number()),
    commitInfo: types.optional(z.lazy(() => CommitInfo$inboundSchema)),
    forced: types.optional(types.boolean()),
    type: types.literal("push"),
    authorized: types.optional(types.boolean()),
    authorizedBy: types.optional(types.string()),
    jobProjectIds: types.optional(z.array(types.string())),
    jobPairs: types.optional(z.array(z.array(types.string()))),
    skippedJobPairs: types.optional(z.array(z.array(types.string()))),
    gitHashtagVercel: types.optional(
      z.array(UserEventJobGitHashtagVercel$inboundSchema),
    ),
    connectedProjectCount: types.optional(types.number()),
    prIdOrZero: types.optional(types.number()),
    gitComments: types.optional(
      z.lazy(() => UserEventJobPayloadGitComments$inboundSchema),
    ),
    isManualGitDeploy: types.optional(types.boolean()),
    commitVerification: types.optional(
      UserEventJobCommitVerification$inboundSchema,
    ),
    nsnbSideEffect: types.optional(
      z.lazy(() => UserEventJobNsnbSideEffect$inboundSchema),
    ),
    committerGitUserId: types.optional(types.number()),
    committerGitUserType: types.optional(types.string()),
    createdAt: types.optional(types.number()),
    forceNew: types.optional(types.boolean()),
    deploymentId: types.optional(types.string()),
    deployHook: types.optional(
      z.lazy(() => UserEventJobPayloadDeployHook$inboundSchema),
    ),
    beforeSha: types.optional(types.string()),
    defaultBranch: types.optional(types.string()),
    eventful: types.optional(types.boolean()),
    githubDeploymentId: types.optional(types.string()),
    headInfo: z.lazy(() => UserEventJobPayloadHeadInfo$inboundSchema),
    installationId: types.number(),
    isPrivate: types.boolean(),
    linkedProjectId: types.optional(types.string()),
    org: types.string(),
    prId: types.nullable(types.number()),
    projectId: types.optional(types.string()),
    customEnvId: z.nullable(types.string()).optional(),
    repo: types.string(),
    repoId: types.number(),
    target: z.nullable(types.string()).optional(),
    url: types.optional(types.string()),
    withCache: types.optional(types.boolean()),
    provider: UserEventJobPayload86Provider$inboundSchema,
    customHost: types.optional(types.string()),
  });

export function job4FromJSON(
  jsonString: string,
): SafeParseResult<Job4, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job4$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job4' from JSON`,
  );
}

/** @internal */
export const JobGitHashtagVercel$inboundSchema: z.ZodNativeEnum<
  typeof JobGitHashtagVercel
> = z.nativeEnum(JobGitHashtagVercel);

/** @internal */
export const UserEventJobGitComments$inboundSchema: z.ZodType<
  UserEventJobGitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function userEventJobGitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobGitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobGitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobGitComments' from JSON`,
  );
}

/** @internal */
export const JobCommitVerification$inboundSchema: z.ZodNativeEnum<
  typeof JobCommitVerification
> = z.nativeEnum(JobCommitVerification);

/** @internal */
export const UserEventJobAction$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobAction
> = z.nativeEnum(UserEventJobAction);

/** @internal */
export const JobNsnbSideEffect$inboundSchema: z.ZodType<
  JobNsnbSideEffect,
  z.ZodTypeDef,
  unknown
> = z.object({
  action: UserEventJobAction$inboundSchema,
  gitUserLogin: types.string(),
});

export function jobNsnbSideEffectFromJSON(
  jsonString: string,
): SafeParseResult<JobNsnbSideEffect, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => JobNsnbSideEffect$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'JobNsnbSideEffect' from JSON`,
  );
}

/** @internal */
export const UserEventJobDeployHook$inboundSchema: z.ZodType<
  UserEventJobDeployHook,
  z.ZodTypeDef,
  unknown
> = z.object({
  createdAt: types.number(),
  id: types.string(),
  name: types.string(),
  ref: types.string(),
});

export function userEventJobDeployHookFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobDeployHook, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobDeployHook$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobDeployHook' from JSON`,
  );
}

/** @internal */
export const UserEventJobHeadInfo$inboundSchema: z.ZodType<
  UserEventJobHeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  org: types.string(),
  ref: types.string(),
  repo: types.string(),
  repoId: types.number(),
  sha: types.string(),
});

export function userEventJobHeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<UserEventJobHeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventJobHeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventJobHeadInfo' from JSON`,
  );
}

/** @internal */
export const UserEventJobPayloadProvider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobPayloadProvider
> = z.nativeEnum(UserEventJobPayloadProvider);

/** @internal */
export const Job3$inboundSchema: z.ZodType<Job3, z.ZodTypeDef, unknown> = z
  .object({
    prId: types.number(),
    type: types.literal("pr"),
    authorized: types.optional(types.boolean()),
    authorizedBy: types.optional(types.string()),
    jobProjectIds: types.optional(z.array(types.string())),
    jobPairs: types.optional(z.array(z.array(types.string()))),
    skippedJobPairs: types.optional(z.array(z.array(types.string()))),
    gitHashtagVercel: types.optional(
      z.array(JobGitHashtagVercel$inboundSchema),
    ),
    connectedProjectCount: types.optional(types.number()),
    prIdOrZero: types.optional(types.number()),
    gitComments: types.optional(
      z.lazy(() => UserEventJobGitComments$inboundSchema),
    ),
    isManualGitDeploy: types.optional(types.boolean()),
    commitVerification: types.optional(JobCommitVerification$inboundSchema),
    nsnbSideEffect: types.optional(
      z.lazy(() => JobNsnbSideEffect$inboundSchema),
    ),
    committerGitUserId: types.optional(types.number()),
    committerGitUserType: types.optional(types.string()),
    createdAt: types.optional(types.number()),
    forceNew: types.optional(types.boolean()),
    deploymentId: types.optional(types.string()),
    deployHook: types.optional(
      z.lazy(() => UserEventJobDeployHook$inboundSchema),
    ),
    beforeSha: types.optional(types.string()),
    defaultBranch: types.optional(types.string()),
    eventful: types.optional(types.boolean()),
    githubDeploymentId: types.optional(types.string()),
    headInfo: z.lazy(() => UserEventJobHeadInfo$inboundSchema),
    installationId: types.number(),
    isPrivate: types.boolean(),
    linkedProjectId: types.optional(types.string()),
    org: types.string(),
    projectId: types.optional(types.string()),
    customEnvId: z.nullable(types.string()).optional(),
    repo: types.string(),
    repoId: types.number(),
    target: z.nullable(types.string()).optional(),
    url: types.optional(types.string()),
    withCache: types.optional(types.boolean()),
    provider: UserEventJobPayloadProvider$inboundSchema,
    customHost: types.optional(types.string()),
  });

export function job3FromJSON(
  jsonString: string,
): SafeParseResult<Job3, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job3$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job3' from JSON`,
  );
}

/** @internal */
export const JobHeadInfo$inboundSchema: z.ZodType<
  JobHeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  owner: types.string(),
  ref: types.string(),
  repoUuid: types.string(),
  sha: types.string(),
  slug: types.string(),
});

export function jobHeadInfoFromJSON(
  jsonString: string,
): SafeParseResult<JobHeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => JobHeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'JobHeadInfo' from JSON`,
  );
}

/** @internal */
export const JobGitComments$inboundSchema: z.ZodType<
  JobGitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function jobGitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<JobGitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => JobGitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'JobGitComments' from JSON`,
  );
}

/** @internal */
export const UserEventJobProvider$inboundSchema: z.ZodNativeEnum<
  typeof UserEventJobProvider
> = z.nativeEnum(UserEventJobProvider);

/** @internal */
export const Job2$inboundSchema: z.ZodType<Job2, z.ZodTypeDef, unknown> = z
  .object({
    createdAt: types.optional(types.number()),
    eventful: types.optional(types.boolean()),
    headInfo: z.lazy(() => JobHeadInfo$inboundSchema),
    linkedProjectId: types.optional(types.string()),
    name: types.string(),
    owner: types.string(),
    prId: types.number(),
    projectId: types.optional(types.string()),
    customEnvId: z.nullable(types.string()).optional(),
    ref: types.string(),
    repoUuid: types.string(),
    sha: types.string(),
    slug: types.string(),
    type: types.literal("bitbucket-now-comment"),
    workspaceUuid: types.string(),
    gitComments: types.optional(z.lazy(() => JobGitComments$inboundSchema)),
    provider: UserEventJobProvider$inboundSchema,
  });

export function job2FromJSON(
  jsonString: string,
): SafeParseResult<Job2, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job2$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job2' from JSON`,
  );
}

/** @internal */
export const GitHashtagVercel$inboundSchema: z.ZodNativeEnum<
  typeof GitHashtagVercel
> = z.nativeEnum(GitHashtagVercel);

/** @internal */
export const GitComments$inboundSchema: z.ZodType<
  GitComments,
  z.ZodTypeDef,
  unknown
> = z.object({
  onPullRequest: types.boolean(),
  onCommit: types.boolean(),
});

export function gitCommentsFromJSON(
  jsonString: string,
): SafeParseResult<GitComments, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => GitComments$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'GitComments' from JSON`,
  );
}

/** @internal */
export const CommitVerification$inboundSchema: z.ZodNativeEnum<
  typeof CommitVerification
> = z.nativeEnum(CommitVerification);

/** @internal */
export const JobAction$inboundSchema: z.ZodNativeEnum<typeof JobAction> = z
  .nativeEnum(JobAction);

/** @internal */
export const NsnbSideEffect$inboundSchema: z.ZodType<
  NsnbSideEffect,
  z.ZodTypeDef,
  unknown
> = z.object({
  action: JobAction$inboundSchema,
  gitUserLogin: types.string(),
});

export function nsnbSideEffectFromJSON(
  jsonString: string,
): SafeParseResult<NsnbSideEffect, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => NsnbSideEffect$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'NsnbSideEffect' from JSON`,
  );
}

/** @internal */
export const JobDeployHook$inboundSchema: z.ZodType<
  JobDeployHook,
  z.ZodTypeDef,
  unknown
> = z.object({
  createdAt: types.number(),
  id: types.string(),
  name: types.string(),
  ref: types.string(),
});

export function jobDeployHookFromJSON(
  jsonString: string,
): SafeParseResult<JobDeployHook, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => JobDeployHook$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'JobDeployHook' from JSON`,
  );
}

/** @internal */
export const HeadInfo$inboundSchema: z.ZodType<
  HeadInfo,
  z.ZodTypeDef,
  unknown
> = z.object({
  owner: types.string(),
  ref: types.string(),
  repoUuid: types.string(),
  sha: types.string(),
  slug: types.string(),
});

export function headInfoFromJSON(
  jsonString: string,
): SafeParseResult<HeadInfo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => HeadInfo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'HeadInfo' from JSON`,
  );
}

/** @internal */
export const JobProvider$inboundSchema: z.ZodNativeEnum<typeof JobProvider> = z
  .nativeEnum(JobProvider);

/** @internal */
export const Job1$inboundSchema: z.ZodType<Job1, z.ZodTypeDef, unknown> = z
  .object({
    type: types.literal("bitbucket-push"),
    authorized: types.optional(types.boolean()),
    authorizedBy: types.optional(types.string()),
    jobProjectIds: types.optional(z.array(types.string())),
    jobPairs: types.optional(z.array(z.array(types.string()))),
    skippedJobPairs: types.optional(z.array(z.array(types.string()))),
    gitHashtagVercel: types.optional(z.array(GitHashtagVercel$inboundSchema)),
    connectedProjectCount: types.optional(types.number()),
    prIdOrZero: types.optional(types.number()),
    gitComments: types.optional(z.lazy(() => GitComments$inboundSchema)),
    isManualGitDeploy: types.optional(types.boolean()),
    commitVerification: types.optional(CommitVerification$inboundSchema),
    nsnbSideEffect: types.optional(z.lazy(() => NsnbSideEffect$inboundSchema)),
    createdAt: types.optional(types.number()),
    deploymentId: types.optional(types.string()),
    deployHook: types.optional(z.lazy(() => JobDeployHook$inboundSchema)),
    eventful: types.optional(types.boolean()),
    forceNew: types.optional(types.boolean()),
    headInfo: z.lazy(() => HeadInfo$inboundSchema),
    linkedProjectId: types.optional(types.string()),
    name: types.string(),
    owner: types.string(),
    prId: types.optional(types.number()),
    projectId: types.optional(types.string()),
    customEnvId: z.nullable(types.string()).optional(),
    ref: types.string(),
    repoPushedAt: z.nullable(types.number()).optional(),
    repoUuid: types.string(),
    sha: types.string(),
    silent: types.optional(types.boolean()),
    slug: types.string(),
    target: z.nullable(types.string()).optional(),
    url: types.optional(types.string()),
    withCache: types.optional(types.boolean()),
    workspaceUuid: types.string(),
    provider: JobProvider$inboundSchema,
  });

export function job1FromJSON(
  jsonString: string,
): SafeParseResult<Job1, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job1$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job1' from JSON`,
  );
}

/** @internal */
export const PayloadJob$inboundSchema: z.ZodType<
  PayloadJob,
  z.ZodTypeDef,
  unknown
> = z.union([
  z.lazy(() => Job1$inboundSchema),
  z.lazy(() => Job2$inboundSchema),
  z.lazy(() => Job3$inboundSchema),
  z.lazy(() => Job4$inboundSchema),
  z.lazy(() => Job5$inboundSchema),
  z.lazy(() => Job6$inboundSchema),
  z.lazy(() => Job7$inboundSchema),
  z.lazy(() => Job8$inboundSchema),
]);

export function payloadJobFromJSON(
  jsonString: string,
): SafeParseResult<PayloadJob, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => PayloadJob$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'PayloadJob' from JSON`,
  );
}

/** @internal */
export const EightySix$inboundSchema: z.ZodType<
  EightySix,
  z.ZodTypeDef,
  unknown
> = z.object({
  job: z.union([
    z.lazy(() => Job1$inboundSchema),
    z.lazy(() => Job2$inboundSchema),
    z.lazy(() => Job3$inboundSchema),
    z.lazy(() => Job4$inboundSchema),
    z.lazy(() => Job5$inboundSchema),
    z.lazy(() => Job6$inboundSchema),
    z.lazy(() => Job7$inboundSchema),
    z.lazy(() => Job8$inboundSchema),
  ]),
});

export function eightySixFromJSON(
  jsonString: string,
): SafeParseResult<EightySix, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightySix$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightySix' from JSON`,
  );
}

/** @internal */
export const UserEventPayloadAllowListedReadyStateReasonInternal$inboundSchema:
  z.ZodNativeEnum<typeof UserEventPayloadAllowListedReadyStateReasonInternal> =
    z.nativeEnum(UserEventPayloadAllowListedReadyStateReasonInternal);

/** @internal */
export const UserEventPayloadDeployment$inboundSchema: z.ZodType<
  UserEventPayloadDeployment,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
  url: types.string(),
  meta: z.record(types.string()),
  readyState: types.optional(types.string()),
  allowListedReadyStateReasonInternal: types.optional(
    UserEventPayloadAllowListedReadyStateReasonInternal$inboundSchema,
  ),
});

export function userEventPayloadDeploymentFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayloadDeployment, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayloadDeployment$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayloadDeployment' from JSON`,
  );
}

/** @internal */
export const EightyFive$inboundSchema: z.ZodType<
  EightyFive,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.optional(types.string()),
  alias: types.optional(z.array(types.string())),
  target: z.nullable(types.string()).optional(),
  deployment: z.nullable(z.lazy(() => UserEventPayloadDeployment$inboundSchema))
    .optional(),
  url: types.string(),
  forced: types.optional(types.boolean()),
  deploymentId: types.optional(types.string()),
  plan: types.optional(types.string()),
  project: types.optional(types.string()),
  projectId: types.optional(types.string()),
  regions: types.optional(z.array(types.string())),
  type: types.optional(types.string()),
});

export function eightyFiveFromJSON(
  jsonString: string,
): SafeParseResult<EightyFive, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyFive$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyFive' from JSON`,
  );
}

/** @internal */
export const EightyFour$inboundSchema: z.ZodType<
  EightyFour,
  z.ZodTypeDef,
  unknown
> = z.object({
  projectId: types.string(),
  projectName: types.string(),
  checkId: types.string(),
  checkName: types.string(),
});

export function eightyFourFromJSON(
  jsonString: string,
): SafeParseResult<EightyFour, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyFour$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyFour' from JSON`,
  );
}

/** @internal */
export const UserEventPayload83Project$inboundSchema: z.ZodType<
  UserEventPayload83Project,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function userEventPayload83ProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload83Project, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload83Project$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload83Project' from JSON`,
  );
}

/** @internal */
export const DeployHook$inboundSchema: z.ZodType<
  DeployHook,
  z.ZodTypeDef,
  unknown
> = z.object({
  createdAt: types.number(),
  id: types.string(),
  name: types.string(),
  ref: types.string(),
});

export function deployHookFromJSON(
  jsonString: string,
): SafeParseResult<DeployHook, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => DeployHook$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'DeployHook' from JSON`,
  );
}

/** @internal */
export const Job$inboundSchema: z.ZodType<Job, z.ZodTypeDef, unknown> = z
  .object({
    deployHook: z.lazy(() => DeployHook$inboundSchema),
    state: types.string(),
  });

export function jobFromJSON(
  jsonString: string,
): SafeParseResult<Job, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Job$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Job' from JSON`,
  );
}

/** @internal */
export const EightyThree$inboundSchema: z.ZodType<
  EightyThree,
  z.ZodTypeDef,
  unknown
> = z.object({
  project: z.lazy(() => UserEventPayload83Project$inboundSchema),
  job: z.lazy(() => Job$inboundSchema),
});

export function eightyThreeFromJSON(
  jsonString: string,
): SafeParseResult<EightyThree, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyThree$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyThree' from JSON`,
  );
}

/** @internal */
export const EightyTwo$inboundSchema: z.ZodType<
  EightyTwo,
  z.ZodTypeDef,
  unknown
> = z.object({
  projectId: types.string(),
  projectName: types.string(),
  hookName: types.string(),
  ref: types.string(),
});

export function eightyTwoFromJSON(
  jsonString: string,
): SafeParseResult<EightyTwo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyTwo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyTwo' from JSON`,
  );
}

/** @internal */
export const EightyOne$inboundSchema: z.ZodType<
  EightyOne,
  z.ZodTypeDef,
  unknown
> = z.object({
  suffix: types.string(),
});

export function eightyOneFromJSON(
  jsonString: string,
): SafeParseResult<EightyOne, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => EightyOne$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'EightyOne' from JSON`,
  );
}

/** @internal */
export const Eighty$inboundSchema: z.ZodType<Eighty, z.ZodTypeDef, unknown> = z
  .object({
    status: types.string(),
    suffix: types.string(),
  });

export function eightyFromJSON(
  jsonString: string,
): SafeParseResult<Eighty, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Eighty$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Eighty' from JSON`,
  );
}

/** @internal */
export const SeventyNine$inboundSchema: z.ZodType<
  SeventyNine,
  z.ZodTypeDef,
  unknown
> = z.object({
  reason: types.optional(types.string()),
  suffix: types.string(),
});

export function seventyNineFromJSON(
  jsonString: string,
): SafeParseResult<SeventyNine, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyNine$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyNine' from JSON`,
  );
}

/** @internal */
export const SubjectType$inboundSchema: z.ZodNativeEnum<typeof SubjectType> = z
  .nativeEnum(SubjectType);

/** @internal */
export const SeventyEight$inboundSchema: z.ZodType<
  SeventyEight,
  z.ZodTypeDef,
  unknown
> = z.object({
  clientId: types.optional(types.string()),
  clientUid: types.optional(types.string()),
  clientName: types.optional(types.string()),
  projectId: types.optional(types.string()),
  installationId: types.optional(types.string()),
  subjectType: types.optional(SubjectType$inboundSchema),
  fields: types.optional(z.array(types.string())),
  triggerDestinationCount: types.optional(types.number()),
  tokensDeleted: types.optional(types.number()),
});

export function seventyEightFromJSON(
  jsonString: string,
): SafeParseResult<SeventyEight, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyEight$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyEight' from JSON`,
  );
}

/** @internal */
export const SeventySeven$inboundSchema: z.ZodType<
  SeventySeven,
  z.ZodTypeDef,
  unknown
> = z.object({
  bitbucketLogin: types.string(),
  bitbucketAccountId: types.string(),
});

export function seventySevenFromJSON(
  jsonString: string,
): SafeParseResult<SeventySeven, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventySeven$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventySeven' from JSON`,
  );
}

/** @internal */
export const SeventySix$inboundSchema: z.ZodType<
  SeventySix,
  z.ZodTypeDef,
  unknown
> = z.object({
  bitbucketEmail: types.string(),
  bitbucketLogin: types.string(),
  bitbucketName: types.optional(types.string()),
});

export function seventySixFromJSON(
  jsonString: string,
): SafeParseResult<SeventySix, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventySix$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventySix' from JSON`,
  );
}

/** @internal */
export const SeventyFive$inboundSchema: z.ZodType<
  SeventyFive,
  z.ZodTypeDef,
  unknown
> = z.object({
  gitlabLogin: types.string(),
  gitlabUserId: types.number(),
});

export function seventyFiveFromJSON(
  jsonString: string,
): SafeParseResult<SeventyFive, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyFive$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyFive' from JSON`,
  );
}

/** @internal */
export const SeventyFour$inboundSchema: z.ZodType<
  SeventyFour,
  z.ZodTypeDef,
  unknown
> = z.object({
  gitlabLogin: types.string(),
  gitlabEmail: types.string(),
  gitlabName: types.optional(types.string()),
  zeitAccount: types.optional(types.string()),
  zeitAccountType: types.optional(types.string()),
});

export function seventyFourFromJSON(
  jsonString: string,
): SafeParseResult<SeventyFour, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyFour$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyFour' from JSON`,
  );
}

/** @internal */
export const SeventyThree$inboundSchema: z.ZodType<
  SeventyThree,
  z.ZodTypeDef,
  unknown
> = z.object({
  githubLogin: types.string(),
  host: types.string(),
});

export function seventyThreeFromJSON(
  jsonString: string,
): SafeParseResult<SeventyThree, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyThree$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyThree' from JSON`,
  );
}

/** @internal */
export const SeventyTwo$inboundSchema: z.ZodType<
  SeventyTwo,
  z.ZodTypeDef,
  unknown
> = z.object({
  githubLogin: types.string(),
});

export function seventyTwoFromJSON(
  jsonString: string,
): SafeParseResult<SeventyTwo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyTwo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyTwo' from JSON`,
  );
}

/** @internal */
export const SeventyOne$inboundSchema: z.ZodType<
  SeventyOne,
  z.ZodTypeDef,
  unknown
> = z.object({
  githubLogin: types.string(),
  host: types.optional(types.string()),
});

export function seventyOneFromJSON(
  jsonString: string,
): SafeParseResult<SeventyOne, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SeventyOne$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SeventyOne' from JSON`,
  );
}

/** @internal */
export const UserEventPayload70Team$inboundSchema: z.ZodType<
  UserEventPayload70Team,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function userEventPayload70TeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload70Team, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload70Team$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload70Team' from JSON`,
  );
}

/** @internal */
export const UserEventPayload70Configuration$inboundSchema: z.ZodType<
  UserEventPayload70Configuration,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function userEventPayload70ConfigurationFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload70Configuration, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload70Configuration$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload70Configuration' from JSON`,
  );
}

/** @internal */
export const Seventy$inboundSchema: z.ZodType<Seventy, z.ZodTypeDef, unknown> =
  z.object({
    team: z.lazy(() => UserEventPayload70Team$inboundSchema),
    configuration: z.lazy(() => UserEventPayload70Configuration$inboundSchema),
    newName: types.string(),
  });

export function seventyFromJSON(
  jsonString: string,
): SafeParseResult<Seventy, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Seventy$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Seventy' from JSON`,
  );
}

/** @internal */
export const UserEventPayloadTeam$inboundSchema: z.ZodType<
  UserEventPayloadTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function userEventPayloadTeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayloadTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayloadTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayloadTeam' from JSON`,
  );
}

/** @internal */
export const UserEventPayload69Configuration$inboundSchema: z.ZodType<
  UserEventPayload69Configuration,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function userEventPayload69ConfigurationFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload69Configuration, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload69Configuration$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload69Configuration' from JSON`,
  );
}

/** @internal */
export const UserEventPayload69Project$inboundSchema: z.ZodType<
  UserEventPayload69Project,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function userEventPayload69ProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload69Project, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload69Project$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload69Project' from JSON`,
  );
}

/** @internal */
export const SixtyNine$inboundSchema: z.ZodType<
  SixtyNine,
  z.ZodTypeDef,
  unknown
> = z.object({
  team: z.lazy(() => UserEventPayloadTeam$inboundSchema),
  configuration: z.lazy(() => UserEventPayload69Configuration$inboundSchema),
  project: z.lazy(() => UserEventPayload69Project$inboundSchema),
});

export function sixtyNineFromJSON(
  jsonString: string,
): SafeParseResult<SixtyNine, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyNine$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyNine' from JSON`,
  );
}

/** @internal */
export const PayloadTeam$inboundSchema: z.ZodType<
  PayloadTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function payloadTeamFromJSON(
  jsonString: string,
): SafeParseResult<PayloadTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => PayloadTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'PayloadTeam' from JSON`,
  );
}

/** @internal */
export const UserEventPayloadConfiguration$inboundSchema: z.ZodType<
  UserEventPayloadConfiguration,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function userEventPayloadConfigurationFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayloadConfiguration, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayloadConfiguration$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayloadConfiguration' from JSON`,
  );
}

/** @internal */
export const UserEventPayload68Project$inboundSchema: z.ZodType<
  UserEventPayload68Project,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function userEventPayload68ProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload68Project, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload68Project$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload68Project' from JSON`,
  );
}

/** @internal */
export const SixtyEight$inboundSchema: z.ZodType<
  SixtyEight,
  z.ZodTypeDef,
  unknown
> = z.object({
  team: z.lazy(() => PayloadTeam$inboundSchema),
  configuration: z.lazy(() => UserEventPayloadConfiguration$inboundSchema),
  project: z.lazy(() => UserEventPayload68Project$inboundSchema),
  buildsEnabled: types.optional(types.boolean()),
  passive: types.optional(types.boolean()),
});

export function sixtyEightFromJSON(
  jsonString: string,
): SafeParseResult<SixtyEight, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyEight$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyEight' from JSON`,
  );
}

/** @internal */
export const UserEventPayload67Team$inboundSchema: z.ZodType<
  UserEventPayload67Team,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function userEventPayload67TeamFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload67Team, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload67Team$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload67Team' from JSON`,
  );
}

/** @internal */
export const PayloadConfiguration$inboundSchema: z.ZodType<
  PayloadConfiguration,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function payloadConfigurationFromJSON(
  jsonString: string,
): SafeParseResult<PayloadConfiguration, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => PayloadConfiguration$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'PayloadConfiguration' from JSON`,
  );
}

/** @internal */
export const UserEventPayload67Project$inboundSchema: z.ZodType<
  UserEventPayload67Project,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.optional(types.string()),
});

export function userEventPayload67ProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayload67Project, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayload67Project$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayload67Project' from JSON`,
  );
}

/** @internal */
export const SixtySeven$inboundSchema: z.ZodType<
  SixtySeven,
  z.ZodTypeDef,
  unknown
> = z.object({
  team: z.lazy(() => UserEventPayload67Team$inboundSchema),
  configuration: z.lazy(() => PayloadConfiguration$inboundSchema),
  project: z.lazy(() => UserEventPayload67Project$inboundSchema),
  buildsEnabled: types.optional(types.boolean()),
});

export function sixtySevenFromJSON(
  jsonString: string,
): SafeParseResult<SixtySeven, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtySeven$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtySeven' from JSON`,
  );
}

/** @internal */
export const Configuration$inboundSchema: z.ZodType<
  Configuration,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function configurationFromJSON(
  jsonString: string,
): SafeParseResult<Configuration, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Configuration$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Configuration' from JSON`,
  );
}

/** @internal */
export const SixtySix$inboundSchema: z.ZodType<
  SixtySix,
  z.ZodTypeDef,
  unknown
> = z.object({
  configuration: z.lazy(() => Configuration$inboundSchema),
});

export function sixtySixFromJSON(
  jsonString: string,
): SafeParseResult<SixtySix, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtySix$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtySix' from JSON`,
  );
}

/** @internal */
export const SixtyFive$inboundSchema: z.ZodType<
  SixtyFive,
  z.ZodTypeDef,
  unknown
> = z.object({
  cn: types.optional(types.string()),
  cns: types.optional(z.array(types.string())),
});

export function sixtyFiveFromJSON(
  jsonString: string,
): SafeParseResult<SixtyFive, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyFive$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyFive' from JSON`,
  );
}

/** @internal */
export const SixtyFour$inboundSchema: z.ZodType<
  SixtyFour,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  cn: types.optional(types.string()),
  cns: types.optional(z.array(types.string())),
});

export function sixtyFourFromJSON(
  jsonString: string,
): SafeParseResult<SixtyFour, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyFour$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyFour' from JSON`,
  );
}

/** @internal */
export const SixtyThree$inboundSchema: z.ZodType<
  SixtyThree,
  z.ZodTypeDef,
  unknown
> = z.object({
  src: types.string(),
  dst: types.string(),
});

export function sixtyThreeFromJSON(
  jsonString: string,
): SafeParseResult<SixtyThree, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyThree$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyThree' from JSON`,
  );
}

/** @internal */
export const PayloadOldTeam$inboundSchema: z.ZodType<
  PayloadOldTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function payloadOldTeamFromJSON(
  jsonString: string,
): SafeParseResult<PayloadOldTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => PayloadOldTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'PayloadOldTeam' from JSON`,
  );
}

/** @internal */
export const PayloadNewTeam$inboundSchema: z.ZodType<
  PayloadNewTeam,
  z.ZodTypeDef,
  unknown
> = z.object({
  name: types.string(),
});

export function payloadNewTeamFromJSON(
  jsonString: string,
): SafeParseResult<PayloadNewTeam, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => PayloadNewTeam$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'PayloadNewTeam' from JSON`,
  );
}

/** @internal */
export const SixtyTwo$inboundSchema: z.ZodType<
  SixtyTwo,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  oldTeam: types.optional(z.lazy(() => PayloadOldTeam$inboundSchema)),
  newTeam: types.optional(z.lazy(() => PayloadNewTeam$inboundSchema)),
});

export function sixtyTwoFromJSON(
  jsonString: string,
): SafeParseResult<SixtyTwo, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyTwo$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyTwo' from JSON`,
  );
}

/** @internal */
export const SixtyOne$inboundSchema: z.ZodType<
  SixtyOne,
  z.ZodTypeDef,
  unknown
> = z.object({
  cn: types.optional(types.string()),
  cns: types.optional(z.array(types.string())),
  id: types.optional(types.string()),
});

export function sixtyOneFromJSON(
  jsonString: string,
): SafeParseResult<SixtyOne, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => SixtyOne$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'SixtyOne' from JSON`,
  );
}

/** @internal */
export const Sixty$inboundSchema: z.ZodType<Sixty, z.ZodTypeDef, unknown> = z
  .object({
    id: types.string(),
    cns: z.array(types.string()),
    custom: types.boolean(),
  });

export function sixtyFromJSON(
  jsonString: string,
): SafeParseResult<Sixty, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => Sixty$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'Sixty' from JSON`,
  );
}

/** @internal */
export const FiftyNine$inboundSchema: z.ZodType<
  FiftyNine,
  z.ZodTypeDef,
  unknown
> = z.object({
  cn: types.optional(types.string()),
  cns: types.optional(z.array(types.string())),
  custom: types.boolean(),
  id: types.optional(types.string()),
});

export function fiftyNineFromJSON(
  jsonString: string,
): SafeParseResult<FiftyNine, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => FiftyNine$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'FiftyNine' from JSON`,
  );
}

/** @internal */
export const UserEventPayloadProject$inboundSchema: z.ZodType<
  UserEventPayloadProject,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function userEventPayloadProjectFromJSON(
  jsonString: string,
): SafeParseResult<UserEventPayloadProject, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => UserEventPayloadProject$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'UserEventPayloadProject' from JSON`,
  );
}

/** @internal */
export const FiftyEight$inboundSchema: z.ZodType<
  FiftyEight,
  z.ZodTypeDef,
  unknown
> = z.object({
  project: z.lazy(() => UserEventPayloadProject$inboundSchema),
  versionId: types.string(),
});

export function fiftyEightFromJSON(
  jsonString: string,
): SafeParseResult<FiftyEight, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => FiftyEight$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'FiftyEight' from JSON`,
  );
}

/** @internal */
export const PayloadProject$inboundSchema: z.ZodType<
  PayloadProject,
  z.ZodTypeDef,
  unknown
> = z.object({
  id: types.string(),
  name: types.string(),
});

export function payloadProjectFromJSON(
  jsonString: string,
): SafeParseResult<PayloadProject, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => PayloadProject$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'PayloadProject' from JSON`,
  );
}

/** @internal */
export const FiftySeven$inboundSchema: z.ZodType<
  FiftySeven,
  z.ZodTypeDef,
  unknown
> = z.object({
  project: z.lazy(() => PayloadProject$inboundSchema),
  bulkRedirectsLimit: types.number(),
  prevBulkRedirectsLimit: types.number(),
});

export function fiftySevenFromJSON(
  jsonString: string,
): SafeParseResult<FiftySeven, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => FiftySeven$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'FiftySeven' from JSON`,
  );
}

/** @internal */
export const FiftySix$inboundSchema: z.ZodType<
  FiftySix,
  z.ZodTypeDef,
  unknown
> = z.object({
  subscriptionId: types.optional(types.string()),
  productAliases: z.array(types.string()),
});

export function fiftySixFromJSON(
  jsonString: string,
): SafeParseResult<FiftySix, SDKValidationError> {
  return safeParse(
    jsonString,
    (x) => FiftySix$inboundSchema.parse(JSON.parse(x)),
    `Failed to parse 'FiftySix' from JSON`,
  );
}
