export type ApiBlob = {
  sha: string;
};

export type ApiBranch = {
  commit: {
    sha: string;
  };
  name: string;
  protected: boolean;
};

export type ApiBranchDetail = {
  commit: ApiCommit;
  name: string;
  protected: boolean;
};

export type ApiBranchProtection = {
  allow_creation: boolean;
  allow_deletions: boolean;
  allow_force_pushes: boolean;
  allow_master_creation: boolean;
  allow_master_deletions: boolean;
  allow_master_force_pushes: boolean;
  allow_master_pushes: boolean;
  allow_pushes: boolean;
  id: string;
  required_approved_review_count: number;
  required_approved_review_ratio: number;
  required_commit_signatures: boolean;
  required_linear_history: boolean;
  required_master_approve: boolean;
  required_must_auto_merge: boolean;
  required_must_push_via_pull_request: boolean;
  required_pull_request_reviews: boolean;
  required_status_checks: boolean;
  rule: string;
};

export type ApiCommit = {
  author: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  commit: ApiCommitObject;
  committer: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  parents: ApiCommitParent[];
  sha: string;
};

export type ApiCommitAsset = {
  author: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  content_type: string;
  created_at: string;
  id: string;
  name: string;
  path: string;
  size_in_byte: number;
  updated_at: string;
};

export type ApiCommitDiffFilePatch = {
  additions: number;
  deletions: number;
  name: string;
  patch: string;
  path: string;
  status: string;
};

export type ApiCommitObject = {
  author: ApiSignature;
  comment_count: number;
  committer: ApiSignature;
  message: string;
  tree: ApiCommitObjectTree;
  verification: ApiCommitObjectVerification;
};

export type ApiCommitObjectTree = {
  sha: string;
};

export type ApiCommitObjectVerification = {
  payload: string;
  resone: string;
  signature: string;
  verified: boolean;
};

export type ApiCommitParent = {
  sha: string;
};

export type ApiCommitStatus = {
  context: string;
  created_at: string;
  description: string;
  state: string;
  target_url: string;
  updated_at: string;
};

export type ApiCompareResponse = {
  base_commit: ApiCommit;
  commits: ApiCommit[];
  files: ApiCommitDiffFilePatch[];
  head_commit: ApiCommit;
  merge_base_commit: ApiCommit;
  total_commits: number;
};

export type ApiContent = {
  content: string;
  encoding: string;
  entries: ApiTreeEntry[];
  name: string;
  path: string;
  sha: string;
  size: number;
  type: string;
};

export type ApiIssue = {
  assignees: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo[];
  author: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo;
  comment_count: number;
  created_at: string;
  labels: ApiLabel[];
  number: string;
  priority: string;
  state: string;
  state_reason: string;
  title: string;
  updated_at: string;
};

export type ApiIssueComment = {
  author: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo;
  body: string;
  created_at: string;
  id: string;
  updated_at: string;
};

export type ApiIssueDetail = {
  assignees: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo[];
  author: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo;
  body: string;
  comment_count: number;
  created_at: string;
  labels: ApiLabel[];
  number: string;
  priority: string;
  state: string;
  state_reason: string;
  title: string;
  updated_at: string;
};

export type ApiLabel = {
  color: string;
  description: string;
  id: string;
  name: string;
};

export type ApiMergePullRequest = {
  commit_message: string;
  commit_title: string;

  /**The merge method to use. Can be one of: `merge`, `squash`, `rebase`*/
  merge_style: string;
};

export type ApiMergePullResponse = {
  merged: boolean;
  message: string;
  sha: string;
};

export type ApiPatchIssueCommentForm = {
  body: string;
};

export type ApiPatchIssueForm = {
  body: string;

  /**Priority of this issue. Can be one of: `p0`, `p1`, `p2`, `p3`, `""`.*/
  priority: string;

  /**State of this issue. Either `open` or `closed`.*/
  state: string;

  /**StateReason can be one of: `completed`, `not_planned`, `reopened`*/
  state_reason: string;
  title: string;
};

export type ApiPatchLabelForm = {
  /**The hexadecimal color code for the label, without the leading `#`.*/
  color: string;
  description: string;
  new_name: string;
};

export type ApiPatchPullRequest = {
  body: string;

  /**State of this Pull Request. Either `open` or `closed`.*/
  state: string;
  title: string;
};

export type ApiPipelineSettings = {
  auto_trigger: boolean;
  forked_repo_auto_trigger: boolean;
};

export type ApiPostBlobForm = {
  content: string;

  /**当前编码只支持 `"utf-8"` and `"base64"` 。默认: `utf-8`*/
  encoding: string;
};

export type ApiPostIssueCommentForm = {
  body: string;
};

export type ApiPostIssueForm = {
  assignees: string[];
  body: string;
  labels: string[];

  /**Priority of this issue. Can be one of: `p0`, `p1`, `p2`, `p3`, `""`.*/
  priority: string;
  title: string;
};

export type ApiPostIssueLabelsForm = {
  labels: string[];
};

export type ApiPostLabelForm = {
  /**The hexadecimal color code for the label, without the leading `#`.*/
  color: string;
  description: string;
  name: string;
};

export type ApiPostPullLabelsForm = {
  labels: string[];
};

export type ApiPostTagFrom = {
  message: string;
  name: string;
  target: string;
};

export type ApiPull = {
  base: ApiPullRef;
  body: string;
  head: ApiPullRef;
  merged_by: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  number: string;
  state: string;
  title: string;
};

export type ApiPullCommentCreationForm = {
  body: string;
};

export type ApiPullCreationForm = {
  base: string;
  body: string;
  head: string;
  head_repo: string;
  title: string;
};

export type ApiPullRef = {
  ref: string;
  repo: ApiRepo;
  sha: string;
};

export type ApiPullRefInfo = {
  ref: string;
  repo: ApiRepoInfo;
  sha: string;
};

export type ApiPullRequest = {
  assignees: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo[];
  author: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  base: ApiPullRef;
  blocked_on: string;
  comment_count: number;
  created_at: string;
  head: ApiPullRef;
  mergeable_state: string;
  merged_by: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  number: string;
  repo: ApiRepo;
  review_count: number;
  state: string;
  title: string;
  updated_at: string;
};

export type ApiPullRequestComment = {
  author: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  body: string;
  created_at: string;
  updated_at: string;
};

export type ApiPullRequestInfo = {
  assignees: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo[];
  author: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo;
  base: ApiPullRefInfo;
  blocked_on: string;
  created_at: string;
  head: ApiPullRefInfo;
  mergeable_state: string;
  merged_by: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo;
  number: string;
  repo: ApiRepoInfo;
  reviewers: GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo[];
  state: string;
  title: string;
  updated_at: string;
};

export type ApiPullRequestSettings = {
  allow_merge_commit_merge: boolean;
  allow_rebase_merge: boolean;
  allow_squash_merge: boolean;
  master_auto_as_reviewer: boolean;
  merge_commit_message_style: string;
  squash_commit_message_style: string;
};

export type ApiPullReviewCommentCreationForm = {
  body: string;
  end_line: number;
  end_side: string;
  path: string;
  start_line: number;
  start_side: string;

  /**can be one of: line, file*/
  subject_type: string;
};

export type ApiPullReviewCreationForm = {
  body: string;
  comments: ApiPullReviewCommentCreationForm[];
  event: string;
};

export type ApiPushLimitSettings = {
  allow_single_push_number: number;
  check_single_push_number: boolean;
  only_master_can_push_tag: boolean;
};

export type ApiPutIssueLabelsForm = {
  labels: string[];
};

export type ApiPutPullLabelsForm = {
  labels: string[];
};

export type ApiRelease = {
  assets: ApiReleaseAsset[];
  author: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
  body: string;
  created_at: string;
  draft: boolean;
  id: string;
  is_latest: boolean;
  name: string;
  prerelease: boolean;
  published_at: string;
  tag_commitish: string;
  tag_name: string;
  updated_at: string;
};

export type ApiReleaseAsset = {
  content_type: string;
  created_at: string;
  id: string;
  name: string;
  path: string;
  size: number;
  updated_at: string;
  uploader: GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo;
};

export type ApiRepo = {
  id: string;
  name: string;
  path: string;
  web_url: string;
};

export type ApiRepoInfo = {
  id: string;
  name: string;
  path: string;
  web_url: string;
};

export type ApiSignature = {
  date: string;
  email: string;
  name: string;
};

export type ApiTag = {
  commit: ApiCommit;
  name: string;
  target: string;
  target_type: string;
};

export type ApiTreeEntry = {
  name: string;
  path: string;
  sha: string;
  type: string;
};

export type ChartDependency = {
  /**Alias usable alias to be used for the chart*/
  alias: string;

  /**A yaml path that resolves to a boolean, used for enabling/disabling charts (e.g. subchart1.enabled )*/
  condition: string;

  /**Enabled bool determines if chart should be loaded*/
  enabled: boolean;

  /**ImportValues holds the mapping of source values to parent key to be imported. Each item can be a
string or pair of child/parent sublist items.*/
  "import-values": any[];

  /**Name is the name of the dependency.

This must mach the name in the dependency's Chart.yaml.*/
  name: string;

  /**The URL to the repository.

Appending `index.yaml` to this string should result in a URL that can be
used to fetch the repository index.*/
  repository: string;

  /**Tags can be used to group charts for enabling/disabling together*/
  tags: string[];

  /**Version is the version (range) of this chart.

A lock file will always produce a single version, while a dependency
may contain a semantic version range.*/
  version: string;
};

export type ChartMaintainer = {
  /**Email is an optional email address to contact the named maintainer*/
  email: string;

  /**Name is a user name or organization name*/
  name: string;

  /**URL is an optional URL to an address for the named maintainer*/
  url: string;
};

export type ChartMetadata = {
  /**Annotations are additional mappings uninterpreted by Helm,
made available for inspection by other applications.*/
  annotations: any;

  /**The API Version of this chart. Required.*/
  apiVersion: string;

  /**The version of the application enclosed inside of this chart.*/
  appVersion: string;

  /**The condition to check to enable chart*/
  condition: string;

  /**Dependencies are a list of dependencies for a chart.*/
  dependencies: ChartDependency[];

  /**Whether or not this chart is deprecated*/
  deprecated: boolean;

  /**A one-sentence description of the chart*/
  description: string;

  /**The URL to a relevant project page, git repo, or contact person*/
  home: string;

  /**The URL to an icon file.*/
  icon: string;

  /**A list of string keywords*/
  keywords: string[];

  /**KubeVersion is a SemVer constraint specifying the version of Kubernetes required.*/
  kubeVersion: string;

  /**A list of name and URL/email address combinations for the maintainer(s)*/
  maintainers: ChartMaintainer[];

  /**The name of the chart. Required.*/
  name: string;

  /**Source is the URL to the source code of this chart*/
  sources: string[];

  /**The tags to check to enable chart*/
  tags: string;

  /**Specifies the chart type: application or library*/
  type: string;

  /**A SemVer 2 conformant version string of the chart. Required.*/
  version: string;
};

export type ConstantAccessRole = 0 | 10 | 20 | 30 | 40 | 50;

export type ConstantActivityType =
  | "mine"
  | "fork"
  | "follow"
  | "star"
  | "join_group"
  | "create_repo"
  | "user_create_release"
  | "repo_create_release"
  | "user_deploy_success"
  | "repo_deploy_success";

export type ConstantBudgetSts = 1 | 2 | 3 | 4;

export type ConstantChargeResType =
  | "charge_type_git"
  | "charge_type_object"
  | "charge_type_ci"
  | "charge_type_dev";

export type ConstantRepoDisplayModule = 1 | 2 | 4;

export type ConstantRepoStatus = 0 | 1 | 2;

export type ConstantSearchResourceType = 0 | 1 | 2 | 3 | 4 | 5;

export type ConstantSlugType = 0 | 1 | 2 | 3 | 4;

export type ConstantUserEditable = 1 | 2 | 4 | 8 | 16;

export type ConstantUserType = 0 | 1 | 2 | 3;

export type ConstantVisibility = 0 | 10 | 20;

export type ConvertNullTime = {
  time: string;

  /**Valid is true if Time is not NULL*/
  valid: boolean;
};

export type DieWebErr = {
  errcode: number;
  errmsg: string;
  errparam: any;
};

export type DieWebError = {
  errcode: number;
  errmsg: string;
  errparam: any;
};

export type DtoAccessTokenItem = {
  created_at: string;
  description: string;
  expired_at: string;
  last_activity_at: string;
  resource_type: ConstantSlugType;
  scope: string;
  slug: string;
  title: string;
  token_fragment: string;

  /**id 的 string 格式，用于兼容前端 int64 支持*/
  token_id: string;
};

export type DtoAccessTokenPayload = {
  description: string;
  expired_at: ConvertNullTime;
  scope: string;
  slug: string;
  token: string;
};

export type DtoActivityCalendar = any;

export type DtoActivityCalendarDate = {
  commit_count: number;
  issues_count: number;
  pr_count: number;
  score: number;

  /**有效cr数，代码评审通过且对应的pr被合入*/
  valid_cr_count: number;

  /**有效pr数，已被合入，且pr具有至少一个已通过的代码评审*/
  valid_pr_count: number;
};

export type DtoActivityCreateRepoDetail = {
  create_at: string;

  /**公仓转私仓或仓库被删除后为 null*/
  detail: any;

  /**activity 发生时仓库的 path，这时的 path 是可以公开的*/
  exposed_repo_path: string;

  /**仓库是否封禁*/
  freeze: boolean;

  /**仓库是否不可访问（公仓转私仓或仓库被删除后不可访问）*/
  repo_unaccessible: boolean;

  /**仓库可见性*/
  visibility_level: any;
};

export type DtoActivityDate = {
  code_review_count: number;
  code_reviews: DtoActivityRepoDetail[];
  commit_count: number;
  commits: DtoActivityRepoDetail[];
  group_count: number;
  groups: DtoActivityJoinGroupDetail[];
  issues: DtoActivityRepoDetail[];
  issues_count: number;
  private_score: number;
  pull_request_count: number;
  pull_requests: DtoActivityRepoDetail[];
  repo_count: number;
  repos: DtoActivityCreateRepoDetail[];
};

export type DtoActivityJoinGroupDetail = {
  create_at: string;

  /**组织详情，组织被删后为 null*/
  detail: any;

  /**组织别名，组织被删除后才有值*/
  remark: string;
};

export type DtoActivityMineData = {
  activity_type: ConstantActivityType;
  created_at: ConvertNullTime;
  repo: DtoActivityRepos;
  user: DtoActivityUsers;
};

export type DtoActivityRelease = {
  commit_hash: string;
  tag: string;
  title: string;
};

export type DtoActivityRepoDetail = {
  /**公仓转私仓或仓库被删除后为 null*/
  detail: any;

  /**activity 发生时仓库的 path，这时的 path 是可以公开的*/
  exposed_repo_path: string;

  /**仓库是否封禁*/
  freeze: boolean;

  /**仓库是否不可访问（公仓转私仓或仓库被删除后不可访问）*/
  repo_unaccessible: boolean;
  time: number;

  /**仓库可见性*/
  visibility_level: any;
};

export type DtoActivityRepos = {
  created_at: string;
  description: string;
  display_module: ConstantRepoDisplayModule;
  fork_count: number;
  forked_from: string;
  freeze: boolean;
  id: number;
  is_star: boolean;

  /**仓库程序语言，预留*/
  language: string;

  /**最新代码更新时间*/
  last_updated_at: any;
  license: string;
  mark_count: number;
  name: string;
  path: string;
  site: string;
  star_count: number;
  status: any;
  topics: string;
  updated_at: string;
  visibility_level: ConstantVisibility;
};

export type DtoActivitySlugDetail = {
  /**完整仓库路径*/
  path: string;
};

export type DtoActivityTotal = {
  activity_type: ConstantActivityType;
  unread: boolean;
  users: string[];
};

export type DtoActivityUsers = {
  address: string;

  /**用户赞赏码状态，0-无赞赏码，1-有*/
  appreciate_status: number;
  avatar: string;
  bio: string;
  company: string;
  created_at: string;
  email: string;
  follow_count: number;
  follow_repo_count: number;
  follower_count: number;
  freeze: boolean;
  gender: number;
  group_count: number;
  id: string;
  is_follow: boolean;
  location: string;
  mission_count: number;
  nickname: string;
  registry_count: number;
  repo_count: number;
  reward_amount: number;
  reward_count: number;
  site: string;
  stars_count: number;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
  wechat_mp: string;
  wechat_mp_qrcode: string;
};

export type DtoActivityWorkflowData = {
  activity_type: ConstantActivityType;
  created_at: ConvertNullTime;
  group: DtoOrganizationUnion;
  release: DtoActivityRelease;
  repo: DtoActivityRepos;
  user: DtoActivityUsers;
};

export type DtoAnnouncement = {
  announcement_msg: string;
  created_at: string;
  expired_at: string;
  id: string;
  pinned: number;
  title: string;
  updated_at: string;
};

export type DtoArtifactStatus = {
  status: string;
};

export type DtoAssetRecords = {
  id: string;

  /**来源地址，例如 release 附件的来源地址是对应的 release 页面。issue和pr文件没有。*/
  origin_path: string;
  path: string;
  referer: string;
  size_in_byte: number;
};

export type DtoAssetSize = {
  used_in_byte: string;
};

export type DtoAssets = {
  content_type: string;
  name: string;
  path: string;
  size: number;
};

export type DtoBindResources = {
  app_id: string;
  created_at: string;
  metadata: string;
  openid: string;
  updated_at: string;
};

export type DtoBindUsers = {
  app_id: string;
  created_at: string;
  metadata: string;
  openid: string;
  updated_at: string;
};

export type DtoBoolResponse = {
  message: string;
  result: boolean;
};

export type DtoBoolResponseWithDataMapConstantSlugTypeInt64 = {
  data: MapConstantSlugTypeInt64;
  message: string;
  result: boolean;
};

export type DtoBudget = {
  /**单位：核时*/
  charge_type_ci: number;
  charge_type_ci_policy: number;

  /**ci价格，单位：分*/
  charge_type_ci_price: number;
  charge_type_dev: number;
  charge_type_dev_policy: number;

  /**开发价格，单位：分*/
  charge_type_dev_price: number;

  /**单位：Gib*/
  charge_type_git: number;

  /**折扣，没折扣是100*/
  charge_type_git_policy: number;

  /**git存储价格，单位：分*/
  charge_type_git_price: number;
  charge_type_object: number;
  charge_type_object_policy: number;

  /**对象存储价格，单位：分*/
  charge_type_object_price: number;

  /**预算单名称*/
  name: string;

  /**预算单状态，1-正常，2-隔离，3-销毁*/
  status: any;

  /**云账号id*/
  uin: string;
};

export type DtoBudgetPrice = {
  /**ci价格，单位：分*/
  charge_type_ci_price: number;

  /**开发价格，单位：分*/
  charge_type_dev_price: number;

  /**git存储价格，单位：分*/
  charge_type_git_price: number;

  /**对象存储价格，单位：分*/
  charge_type_object_price: number;
};

export type DtoBuildLogsResult = {
  /**构建数据列表*/
  data: DtoLogInfo[];

  /**当前仓库是否已经有构建记录，1 表示有构建记录，0 表示没有构建记录*/
  init: boolean;

  /**当前时间戳*/
  timestamp: number;

  /**总数*/
  total: number;
};

export type DtoBuildResult = {
  /**构建链接*/
  buildLogUrl: string;

  /**message*/
  message: string;

  /**构建号*/
  sn: string;
};

export type DtoBuildStatusResult = {
  /**流水线的状态*/
  pipelinesStatus: any;

  /**构建状态*/
  status: string;
};

export type DtoCnbRegistry = {
  artifact_policy: "all" | "snapshot" | "release";
  created_at: string;
  description: string;
  freeze: boolean;
  id: string;
  kind: string;
  last_push_time: string;
  last_push_user: DtoUsers;
  name: string;
  overwrite_policy: "forbid" | "allow";
  pkg_count: number;
  updated_at: string;
  used_size: number;
  visibility_level: ConstantVisibility;
};

export type DtoChartPackageDetail = {
  address: string;
  desc: string;
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  slug: string;
  tag_total: number;
  tags: DtoChartTag[];
};

export type DtoChartTag = {
  address: string;
  digest: string;
  is_deprecated: boolean;
  last_pusher: DtoLastPusher;
  metadata: ChartMetadata;
  name: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
};

export type DtoChartTagDetail = {
  address: string;
  is_deprecated: boolean;
  last_pusher: DtoLastPusher;
  metadata: ChartMetadata;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  slug: string;
  tag: string;
};

export type DtoCheckFollowingResponse = {
  is_following: boolean;
};

export type DtoCheckStarResponse = {
  is_star: boolean;
};

export type DtoCleanPolicy = "pull_time" | "push_time";

export type DtoCleanPolicyStatus = "enabled" | "disabled";

export type DtoContainerAnnotation = {
  revision: string;
  version: string;
};

export type DtoContainerImage = {
  arch: string;
  digest: string;
  layers: DtoContainerImageLayer[];
  os: string;
  size: number;
};

export type DtoContainerImageLayer = {
  instruction: string;
  size: number;
};

export type DtoContainerPackageDetail = {
  address: string;
  desc: string;
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  slug: string;
  tag_total: number;
  tags: DtoContainerTag[];
};

export type DtoContainerTag = {
  address: string;
  annotations: DtoContainerAnnotation;
  images: DtoContainerImage[];
  last_pusher: DtoLastPusher;
  name: string;
  pull_count: number;
  recent_pull_count: number;
};

export type DtoContainerTagDetail = {
  address: string;
  annotations: DtoContainerAnnotation;
  image: DtoContainerImage;
  last_pusher: DtoLastPusher;
  options: DtoContainerImage[];
  package: string;
  pull_count: number;
  recent_pull_count: number;
  slug: string;
  tag: string;
};

export type DtoCopyReq = {
  description: string;
  group: string;
  name: string;
  visibility: "public" | "private";
};

export type DtoCountResponse = {
  group: number;
  repo: number;
  user: number;
};

export type DtoCreateGroupReq = {
  /**BindDomain 根组织绑定的域名*/
  bind_domain: string;
  description: string;
  path: string;
  remark: string;
};

export type DtoCreateInvitationRequest = {
  is_outside_collaborator: boolean;
  member_number: number;
  member_role: ConstantAccessRole;
  validity_hour: number;
};

export type DtoCreateInvitationResponse = {
  link_token: string;
  resource_name: string;
  resource_type: ConstantSlugType;
  username: string;
};

export type DtoCreateMissionReq = {
  description: string;
  name: string;
  repos: string[];
  visibility: "public" | "private";
};

export type DtoCreateRegistryReq = {
  artifact_policy: "all" | "snapshot" | "release";
  description: string;
  kind: string;
  name: string;
  overwrite_policy: "forbid" | "allow";
  visibility: "public" | "private";
};

export type DtoCreateRepoReq = {
  description: string;
  license: string;
  name: string;
  visibility: "public" | "private" | "secret";
};

export type DtoCreator = {
  freeze: boolean;
  name: string;
  nick: string;
};

export type DtoDependency = {
  artifact: string;
  name: string;
};

export type DtoFile = {
  name: string;
  size: number;
};

export type DtoForkReq = {
  branch: string;
  description: string;
  group: string;
  name: string;
};

export type DtoForks = {
  created_at: string;
  fork_count: number;
  freeze: boolean;
  nickname: string;
  path: string;
  user_freeze: boolean;
  username: string;
};

export type DtoGetActivityMineDetailRsp = {
  activity_mine_datas: DtoActivityMineData[];
  next_offset: string;
};

export type DtoGetActivityWorkflowDetailRsp = {
  activity_workflow_datas: DtoActivityWorkflowData[];
  next_offset: string;
};

export type DtoGetMineCreateDetailRsp = {
  issue_datas: DtoIssueData[];
  mine_type: string;
  pull_request_datas: DtoPullRequestData[];
};

export type DtoGetTodoDetailRsp = {
  issue_datas: DtoIssueData[];
  pull_request_datas: DtoPullRequestData[];
  todo_type: string;
};

export type DtoGroupSettingReq = {
  /**组织限制指定邮箱认证才能加入*/
  email_verification: string;

  /**组织保护开关，0 - 关闭，1 - 打开*/
  group_protection: number;

  /**是否对外隐藏组织成员，0 - 否, 1 - 是*/
  hide_members: number;

  /**是否对外隐藏子组织，0 - 否, 1 - 是*/
  hide_sub_groups: number;

  /**是否对外显示私有仓库水印，0 - 否, 1 - 是*/
  show_private_repo_watermark: number;

  /**SettingValue 组织设置值，多个选项，用逗号拼接。可选值来自 SettingNamesArray 的值，e.g. disable_organization_readme,cloud_native_dev_only*/
  values: string;
};

export type DtoHarborRepository = {
  /**The description of the repository*/
  description: string;

  /**The repository labels*/
  labels: string[];

  /**The push time of the artifact inside the repository
Format: date-time*/
  push_time: string;

  /**The ID of the pusher who push the artifact.*/
  pusher_id: number;

  /**The count that the artifact inside the repository recent pulled*/
  recent_pull_count: number;
};

export type DtoInheritMembersUser = {
  access_level: ConstantAccessRole;
  avatar: string;
  created_at: string;
  email: string;
  email_verification: string;
  freeze: boolean;
  id: string;
  inviter: DtoUsers;
  join_time: string;
  nickname: string;
  self_member: boolean;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
};

export type DtoInteractionType = "radio" | "checkbox" | "time_selector";

export type DtoInvitationWithEmail = {
  count: number;
  creator: string;
  email: string;
  email_match: boolean;
  expire: number;
  is_outside_collaborator: boolean;
  resource: DtoResources;
  role: ConstantAccessRole;
  status: string;
};

export type DtoIssueData = {
  associated_pull_request_counts: number;
  comment_counts: number;
  created_time: string;
  creator: DtoCreator;
  label: DtoLabel[];
  number: number;
  pinned: boolean;
  priority: string;
  slug: string;
  slug_freeze: boolean;
  state: string;
  title: string;
  todo_id: string;
  updated_time: string;
};

export type DtoLabel = {
  color: string;
  description: string;
  name: string;
};

export type DtoLastPusher = {
  is_frozen: boolean;
  name: string;
  nickname: string;
  push_at: string;
};

export type DtoListInheritMembers = {
  inherit_path: string;
  total: number;
  users: DtoInheritMembersUser[];
};

export type DtoLogInfo = {
  /**构建日志 url*/
  buildLogUrl: string;

  /**提交日志 title*/
  commitTitle: string;

  /**构建开始时间*/
  createTime: string;

  /**构建耗时，单位：ms*/
  duration: number;

  /**事件名*/
  event: string;

  /**事件 url*/
  eventUrl: string;

  /**构建用户是否被冻结*/
  freeze: boolean;

  /**组织名*/
  groupName: string;

  /**流水线标签*/
  labels: string;

  /**构建用户昵称*/
  nickName: string;

  /**失败的子流水线个数*/
  pipelineFailCount: number;

  /**成功的子流水线个数*/
  pipelineSuccessCount: number;

  /**子流水线个数*/
  pipelineTotalCount: number;

  /**commitid*/
  sha: string;

  /**仓库路径*/
  slug: string;

  /**构建号*/
  sn: string;

  /**源分支名*/
  sourceRef: string;

  /**源仓库路径*/
  sourceSlug: string;

  /**构建状态*/
  status: string;

  /**目标分支名*/
  targetRef: string;

  /**构建 title*/
  title: string;

  /**用户名*/
  userName: string;
};

export type DtoManifest = {
  metadata: DtoManifestMetadata;

  /**Type manifest/manifest_list*/
  type: string;
};

export type DtoManifestMetadata = {
  /**Annotations contains arbitrary metadata for the image manifest.*/
  annotations: any;

  /**ArtifactType specifies the IANA media type of artifact when the manifest is used for an artifact.*/
  artifactType: string;

  /**Config references a configuration object for a container, by digest.
The referenced configuration object is a JSON blob that the runtime uses to set up the container.*/
  config: any;

  /**Layers is an indexed list of layers referenced by the manifest.*/
  layers: V1Descriptor[];

  /**Manifests references platform specific manifests.*/
  manifests: V1Descriptor[];

  /**MediaType specifies the type of this document data structure e.g. `application/vnd.oci.image.manifest.v1+json`*/
  mediaType: string;

  /**SchemaVersion is the image manifest schema that this image follows*/
  schemaVersion: number;

  /**Subject is an optional link from the image manifest to another manifest forming an association between the image manifest and the other manifest.*/
  subject: any;
};

export type DtoMavenPackageDetail = {
  address: string;
  desc: string;
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  slug: string;
  tag_total: number;
  tags: DtoMavenTag[];
};

export type DtoMavenTag = {
  desc: string;
  digest: string;
  last_pusher: DtoLastPusher;
  name: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  status: string;
};

export type DtoMavenTagDetail = {
  address: string;
  desc: string;
  files: DtoFile[];
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  slug: string;
  status: string;
  tag: string;
  tags: DtoMavenTag[];
};

export type DtoMemberAccessLevel = {
  access_level: ConstantAccessRole;
  path: string;
};

export type DtoMemberAccessLevelInSlugUnion = {
  access_level: ConstantAccessRole;
  inherit: boolean;
  read_privilege: boolean;
  write_privilege: boolean;
};

export type DtoMineCreateTotal = {
  issue_count: number;
  pull_request_count: number;
  total: number;
};

export type DtoMissionPatch = {
  description: string;
  ref_repos: string[];
};

export type DtoMissionWithPath = {
  created_at: string;
  description: string;
  freeze: boolean;
  id: number;
  name: string;
  path: string;
  updated_at: string;
  visibility_level: ConstantVisibility;
};

export type DtoMissionWithRepos = {
  created_at: string;
  description: string;
  freeze: boolean;
  id: number;
  name: string;
  repos: DtoRepos4User[];
  stared: boolean;
  updated_at: string;
  visibility_level: ConstantVisibility;
};

export type DtoMissions4User = {
  access: any;
  created_at: string;
  description: string;
  freeze: boolean;
  id: number;
  name: string;
  path: string;
  star_time: string;
  stared: boolean;
  updated_at: string;
  visibility_level: ConstantVisibility;
};

export type DtoNpmPackageDetail = {
  address: string;
  desc: string;
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  slug: string;
  tag_total: number;
  tags: DtoNpmTag[];
};

export type DtoNpmTag = {
  desc: string;
  digest: string;
  last_pusher: DtoLastPusher;
  name: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  status: string;
};

export type DtoNpmTagDetail = {
  address: string;
  dependencies: DtoDependency[];
  desc: string;
  files: DtoFile[];
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  slug: string;
  status: string;
  tag: string;
  tags: DtoNpmTag[];
};

export type DtoOhpmPackageDetail = {
  address: string;
  desc: string;
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  slug: string;
  tag_total: number;
  tags: DtoOhpmTag[];
};

export type DtoOhpmTag = {
  desc: string;
  digest: string;
  last_pusher: DtoLastPusher;
  name: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  status: string;
};

export type DtoOhpmTagDetail = {
  address: string;
  dependencies: DtoDependency[];
  desc: string;
  files: DtoFile[];
  last_pusher: DtoLastPusher;
  package: string;
  pull_count: number;
  recent_pull_count: number;
  size: number;
  slug: string;
  status: string;
  tag: string;
  tags: DtoOhpmTag[];
};

export type DtoOrganizationAccess = {
  /**AccessRole 用户在当前资源的最大权限*/
  access_role: any;
  all_member_count: number;

  /**下面所有层级子组织*/
  all_sub_group_count: number;

  /**下面所有层级子任务*/
  all_sub_mission_count: number;
  all_sub_registry_count: number;

  /**下面所有层级子仓库*/
  all_sub_repo_count: number;
  created_at: string;
  description: string;
  domain: string;
  email: string;
  follow_count: number;
  freeze: boolean;
  has_sub_group: boolean;
  id: number;
  member_count: number;
  name: string;
  path: string;
  remark: string;
  site: string;

  /**下一级子组织数量*/
  sub_group_count: number;
  sub_mission_count: number;
  sub_registry_count: number;

  /**下一级子仓库*/
  sub_repo_count: number;
  updated_at: string;
  wechat_mp: string;
};

export type DtoOrganizationSettingWithParent = {
  /**上级group设置了hide_members为1，则下级都不能显示*/
  can_show_members: boolean;

  /**上级group设置了hide_sub_groups为1，则下级都不能显示*/
  can_show_sub_groups: boolean;
  can_show_watermark: boolean;
  email_verification: string;
  group_protection: number;

  /**是否对外隐藏组织成员，0 - 否, 1 - 是*/
  hide_members: number;

  /**是否对外隐藏子组织，0 - 否, 1 - 是*/
  hide_sub_groups: number;
  root_email_verification: string;
  root_group_protection: boolean;
  root_values: OrganizationSettingValue;
  show_private_repo_watermark: number;
  values: OrganizationSettingValue;
};

export type DtoOrganizationUnion = {
  all_member_count: number;

  /**下面所有层级子组织*/
  all_sub_group_count: number;

  /**下面所有层级子任务*/
  all_sub_mission_count: number;
  all_sub_registry_count: number;

  /**下面所有层级子仓库*/
  all_sub_repo_count: number;
  created_at: string;
  description: string;
  domain: string;
  email: string;
  follow_count: number;
  freeze: boolean;
  has_sub_group: boolean;
  id: number;
  member_count: number;
  name: string;
  path: string;
  remark: string;
  site: string;

  /**下一级子组织数量*/
  sub_group_count: number;
  sub_mission_count: number;
  sub_registry_count: number;

  /**下一级子仓库*/
  sub_repo_count: number;
  updated_at: string;
  wechat_mp: string;
};

export type DtoOutsideCollaboratorInRepo = {
  access_level: ConstantAccessRole;
  avatar: string;
  created_at: string;
  email: string;
  freeze: boolean;
  id: string;
  join_time: string;
  nickname: string;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
};

export type DtoOverwritePolicy = "forbid" | "allow";

export type DtoPack = {
  expire_at: string;
  name: string;
  res_type: ConstantChargeResType;

  /**单位: GiB/核时*/
  size: number;
  type: DtoPackType;
};

export type DtoPackType = -1 | 0 | 1 | 10 | 20 | 255;

export type DtoPackage = {
  count: number;
  description: string;
  labels: string[];
  last_artifact_name: string;
  last_pusher: DtoLastPusher;
  name: string;
  package: string;
  package_type: DtoPackageType;
  pull_count: number;
  recent_pull_count: number;
};

export type DtoPackageDetail = {
  docker: DtoContainerPackageDetail;
  helm: DtoChartPackageDetail;
  maven: DtoMavenPackageDetail;
  npm: DtoNpmPackageDetail;
  ohpm: DtoOhpmPackageDetail;
};

export type DtoPackageType =
  | "all"
  | "docker"
  | "helm"
  | "npm"
  | "maven"
  | "ohpm";

export type DtoPipelineStatus = {
  /**流水线耗时*/
  duration: number;

  /**流水线各 stage 的状态*/
  stages: DtoStage[];

  /**流水线状态*/
  status: string;
};

export type DtoPullRequestData = {
  associated_issue_counts: number;
  build_status: string;
  comment_counts: number;
  label: DtoLabel[];
  mergeable_state: string;
  number: number;
  pinned: boolean;
  slug: string;
  slug_freeze: boolean;
  src_ref: string;
  state: string;
  target_ref: string;
  title: string;
  todo_id: string;
};

export type DtoQuota = {
  /**The hard limits of the quota,example: { "hard": { "storage": -1}}*/
  hard: any;
};

export type DtoQuotaRsp = {
  /**The hard limits of the quota,example: { "hard": { "storage": -1}}*/
  hard: any;

  /**The repository name of the quota*/
  repository_name: string;

  /**The cnb default quota value*/
  storage_per_project: string;

  /**The used limits of the quota,example: { "used": { "storage": 0}}*/
  used: any;
};

export type DtoRegistry4User = {
  access: any;
  artifact_policy: "all" | "snapshot" | "release";
  created_at: string;
  description: string;
  freeze: boolean;
  id: string;
  kind: string;
  last_push_time: string;
  last_push_user: DtoUsers;
  name: string;
  overwrite_policy: "forbid" | "allow";
  path: string;
  pkg_count: number;
  star_time: string;
  stared: boolean;
  updated_at: string;
  used_size: number;
  visibility_level: ConstantVisibility;
};

export type DtoRegistryCleanDetail = {
  artifact_num: number;
  clean_policy: DtoCleanPolicy;
  status: DtoCleanPolicyStatus;
};

export type DtoRegistryPatch = {
  description: string;
};

export type DtoRegistryPolicy = {
  clean_policy_detail: DtoRegistryCleanDetail;
  overwrite_policy: DtoOverwritePolicy;
  version_policy: DtoVersionPolicy;
};

export type DtoRepoCoreHour = {
  ci_used_core_Sec: string;
  ci_used_core_hour: string;
  code_used_core_Sec: string;
  code_used_core_hour: string;
};

export type DtoRepoLanguage = {
  language: string;
  ratio: string;
};

export type DtoRepoPatch = {
  description: string;
  license: string;
  site: string;
  topics: string[];
};

export type DtoRepoStarUsers = {
  my_follow_count: number;
  total: number;
  users: DtoStarUser[];
};

export type DtoRepoVolume = {
  is_deleted: boolean;
  resource_id: string;
  resource_type: ConstantSlugType;
  slug: string;
  volume: string;
};

export type DtoRepos4User = {
  access: any;
  created_at: string;
  description: string;
  display_module: ConstantRepoDisplayModule;
  fork_count: number;

  /**预留*/
  forked_from_repo: any;
  freeze: boolean;
  id: number;

  /**仓库程序语言，预留*/
  language: string;

  /**仓库语言*/
  languages: DtoRepoLanguage[];

  /**最新代码更新人姓名*/
  last_update_nickname: string;

  /**最新代码更新人账户名*/
  last_update_username: string;

  /**最新代码更新时间*/
  last_updated_at: any;
  license: string;
  mark_count: number;
  name: string;

  /**开启的issue数*/
  open_issue_count: number;

  /**开启的pull request数*/
  open_pull_request_count: number;

  /**完整仓库路径*/
  path: string;
  site: string;
  star_count: number;
  star_time: string;
  stared: boolean;
  status: any;
  tags: {
    name: string;
  }[];
  topics: string;
  updated_at: string;
  visibility_level: ConstantVisibility;
  web_url: string;
};

export type DtoRepos4UserBase = {
  created_at: string;
  description: string;
  display_module: ConstantRepoDisplayModule;
  fork_count: number;

  /**预留*/
  forked_from_repo: any;
  freeze: boolean;
  id: number;

  /**仓库程序语言，预留*/
  language: string;

  /**仓库语言*/
  languages: DtoRepoLanguage[];

  /**最新代码更新人姓名*/
  last_update_nickname: string;

  /**最新代码更新人账户名*/
  last_update_username: string;

  /**最新代码更新时间*/
  last_updated_at: any;
  license: string;
  mark_count: number;
  name: string;

  /**开启的issue数*/
  open_issue_count: number;

  /**开启的pull request数*/
  open_pull_request_count: number;

  /**完整仓库路径*/
  path: string;
  site: string;
  star_count: number;
  status: any;
  tags: {
    name: string;
  }[];
  topics: string;
  updated_at: string;
  visibility_level: ConstantVisibility;
  web_url: string;
};

export type DtoResourceBindInfo = {
  code: string;
  expire_at: string;
  name: string;
  nick: string;
  slug: string;
  url: string;
};

export type DtoResourceGroup = {
  created_at: string;
  description: string;
  domain: string;
  email: string;
  freeze: boolean;
  id: number;
  name: string;
  path: string;
  remark: string;
  site: string;
  updated_at: string;
  wechat_mp: string;
};

export type DtoResourceMission = {
  created_at: string;
  description: string;
  freeze: boolean;
  id: number;
  name: string;
  path: string;
  updated_at: string;
  visibility_level: ConstantVisibility;
};

export type DtoResourceRegistry = {
  artifact_policy: "all" | "snapshot" | "release";
  created_at: string;
  description: string;
  freeze: boolean;
  id: string;
  kind: string;
  last_push_time: string;
  last_push_user: DtoUsers;
  name: string;
  overwrite_policy: "forbid" | "allow";
  path: string;
  pkg_count: number;
  updated_at: string;
  used_size: number;
  visibility_level: ConstantVisibility;
};

export type DtoResourceRepo = {
  created_at: string;
  freeze: boolean;
  id: number;
  name: string;
  path: string;
  status: any;
  updated_at: string;
  visibility_level: ConstantVisibility;
};

export type DtoResources = {
  group: DtoResourceGroup;
  mission: DtoResourceMission;
  registry: DtoResourceRegistry;
  repo: DtoResourceRepo;
  type: ConstantSlugType;
};

export type DtoSearchResponseAny = {
  resource_type: ConstantSearchResourceType;
  results: any;
};

export type DtoSlugMemberCount = {
  /**继承成员总数*/
  inherited_member_count: number;

  /**直接成员总数*/
  member_count: number;

  /**外部协作者总数*/
  outside_collaborator_count: number;
};

export type DtoSlugs = {
  created_at: string;
  freeze: boolean;
  path: string;
  resource_id: number;
  resource_type: ConstantSlugType;
  root_freeze: boolean;
  root_id: number;
  updated_at: string;
};

export type DtoSpecialAmount = {
  compute_build_corehour: number;
  compute_build_desc: string;
  compute_build_expire: string;
  compute_develop_corehour: number;
  compute_develop_desc: string;
  compute_develop_expire: string;
  storage_git_desc: string;
  storage_git_expire: string;
  storage_git_gib: number;
  storage_object_desc: string;
  storage_object_expire: string;
  storage_object_gib: number;
};

export type DtoStage = {
  /**stage 耗时*/
  duration: number;

  /**stage 状态*/
  status: string;
};

export type DtoStarUser = {
  avatar: string;
  created_at: string;
  email: string;
  freeze: boolean;
  id: string;
  is_follow: boolean;
  nickname: string;
  stared_at: string;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
};

export type DtoStartBuildReq = {
  /**触发分支，默认为主分支*/
  branch: string;

  /**指定配置文件内容，yaml 格式*/
  config: string;

  /**环境变量，对象格式*/
  env: any;

  /**事件名，必须是 api_trigger 或以 api_trigger_ 开头，默认为 `api_trigger`*/
  event: string;

  /**是否跳过 git status 的上报*/
  ignoreGitStatus: string;

  /**commit id ，优先级比 tag 高，默认为分支最新提交记录*/
  sha: string;

  /**是否等待构建正式触发，为false时会立刻返回 sn 和 buildLogUrl*/
  sync: string;

  /**触发 tag，优先级比 branch 高*/
  tag: string;
};

export type DtoStatus = {
  /**预算单状态，0-没有预算单，1-正常，2-欠费被隔离，3-被销毁*/
  budget_status: any;

  /**超限的资源，将该数字转成二进制，0001表示git存储超限，0010表示对象存储超限，0100表示ci超限，1000表示云原生开发超限*/
  overruns: number;
};

export type DtoSystemAcceleration = {
  priority: number;
  url: string;
  user_name: string;
};

export type DtoTag = {
  docker: DtoContainerTag[];
  helm: DtoChartTag[];
  maven: DtoMavenTag[];
  npm: DtoNpmTag[];
  ohpm: DtoOhpmTag[];
  package: string;
};

export type DtoTagDetail = {
  docker: DtoContainerTagDetail;
  helm: DtoChartTagDetail;
  maven: DtoMavenTagDetail;
  npm: DtoNpmTagDetail;
  ohpm: DtoOhpmTagDetail;
};

export type DtoTimeVolume = {
  time_rfc3339: string;
  volume: string;
};

export type DtoTodoTotal = {
  issue_complete_count: number;
  issue_pending_count: number;
  pull_request_complete_count: number;
  pull_request_pending_count: number;
  total: number;
};

export type DtoTransferSlugReq = {
  source: string;
  target: string;
};

export type DtoUpdateGroupAvatarReq = {
  /**新头像 url*/
  url: string;
};

export type DtoUpdateGroupReq = {
  description: string;
  domain: string;
  email: string;
  remark: string;
  site: string;
  wechat_mp: string;
};

export type DtoUpdateMembersRequest = {
  access_level: string;
  is_outside_collaborator: boolean;
};

export type DtoUploadAssetsResponse = {
  assets: DtoAssets;
  form: any;

  /**后续调用 confirm 接口用的*/
  token: string;
  upload_url: string;
};

export type DtoUploadRequestParams = {
  name: string;
  size: number;
};

export type DtoUserBindInfo = {
  code: string;
  expire_at: string;
  name: string;
  nick: string;
  url: string;
  user: string;
};

export type DtoUserEmailPayload = {
  email: string;
};

export type DtoUserEmailType = "git" | "contact";

export type DtoUserEmailWithCodePayload = {
  code: string;
  email: string;
};

export type DtoUserEmailWithTypePayload = {
  email: string;
  type: DtoUserEmailType;
};

export type DtoUserEmails = {
  /**ContactEmail 用户通知邮箱*/
  contact_email: string;

  /**Email 用户git提交邮箱，是 emails 里面的某一个*/
  email: string;

  /**Emails 邮箱列表*/
  emails: string[];

  /**系统默认邮箱*/
  system_email: string;

  /**系统默认邮箱是否可以通知*/
  system_email_contact: boolean;
};

export type DtoUserFollowResult = {
  freeze: boolean;

  /**查询人是否follow了此用户*/
  is_following: boolean;
  nickname: string;
  username: string;
};

export type DtoUsers = {
  avatar: string;
  created_at: string;
  email: string;
  freeze: boolean;
  id: string;
  nickname: string;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
};

export type DtoUsersIdentity = {
  phone: string;
};

export type DtoUsersLangPayload = {
  language: string;
};

export type DtoUsersResult = {
  address: string;

  /**用户赞赏码状态，0-无赞赏码，1-有*/
  appreciate_status: number;
  avatar: string;
  bio: string;
  company: string;
  created_at: string;
  email: string;
  follow_count: number;
  follow_repo_count: number;
  follower_count: number;
  freeze: boolean;
  gender: number;
  group_count: number;
  id: string;

  /**查询人是否follow了此用户*/
  is_following: boolean;
  location: string;
  mission_count: number;
  nickname: string;
  registry_count: number;
  repo_count: number;
  reward_amount: number;
  reward_count: number;
  site: string;
  stars_count: number;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
  wechat_mp: string;
  wechat_mp_qrcode: string;
};

export type DtoUsersResultForSelf = {
  address: string;

  /**用户赞赏码状态，0-无赞赏码，1-有*/
  appreciate_status: number;
  avatar: string;
  bio: string;
  company: string;
  created_at: string;
  editable: ConstantUserEditable;
  email: string;
  follow_count: number;
  follow_repo_count: number;
  follower_count: number;
  freeze: boolean;
  gender: number;
  group_count: number;
  id: string;
  language: string;
  last_login_at: string;
  last_login_ip: string;
  location: string;
  mission_count: number;
  next_updated_name_at: string;
  nickname: string;
  registry_count: number;
  repo_count: number;
  reward_amount: number;
  reward_count: number;
  site: string;
  stars_count: number;
  type: ConstantUserType;
  updated_name_at: string;
  updated_nick_at: string;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
  wechat_mp: string;
  wechat_mp_qrcode: string;
};

export type DtoUsersWithAccessLevelInSlug = {
  access_level: ConstantAccessRole;
  avatar: string;
  created_at: string;
  email: string;
  email_verification: string;
  freeze: boolean;
  id: string;
  inviter: DtoUsers;
  join_time: string;
  nickname: string;
  type: ConstantUserType;
  username: string;

  /**认证类型*/
  verified: number;

  /**认证过期时间*/
  verified_expire_in: string;
};

export type DtoVersionPolicy = "all" | "snapshot" | "release";

export type DtoVolumeUsed = any;

export type DtoWorkspaceDeleteReq = {
  /**创建环境的流水线 id*/
  pipelineId: string;
};

export type DtoWorkspaceDeleteResult = {
  /**返回码，0 表示成功，1 表示失败*/
  code: number;

  /**描述*/
  message: string;
};

export type DtoWorkspaceDetailResult = {
  /**Cursor 客户端 remote-ssh 访问 schema 地址*/
  cursor: string;

  /**VSCode 客户端 remote-ssh 访问 schema 地址*/
  vscode: string;

  /**WebIDE 访问 url*/
  webide: string;
};

export type DtoWorkspaceInfo = {
  /**分支名，例如：main*/
  branch: string;

  /**备份的 commit 数*/
  commit_count: number;

  /**开发环境创建时间，例如：2024-12-02T03:20:22.000Z*/
  create_time: string;

  /**开发环境持续时间，单位：ms（非实时更新）*/
  duration: number;

  /**备份的文件数*/
  file_count: number;

  /**备份的文件列表，仅前五个备份文件相对路径*/
  file_list: string;

  /**环境销毁时远程最新的 commit short hash*/
  latest_sha: string;

  /**创建环境的子流水线 id*/
  pipeline_id: string;

  /**备份的 stash 数*/
  remote_stash_count: number;

  /**仓库地址*/
  repo_url: string;

  /**恢复备份代码的流水线 id，如果有值表示备份代码已被恢复（重建环境时会恢复备份代码）*/
  restore_id: string;

  /**仓库路径，例如：groupname/reponame*/
  slug: string;

  /**创建开发环境的流水线 sn*/
  sn: string;

  /**开发环境是否支持 ssh 链接*/
  ssh: boolean;

  /**工作区状态，running: 开发环境已启动，closed：开发环境已关闭*/
  status: string;

  /**开发环境默认工作区路径*/
  workspace: string;
};

export type DtoWorkspaceListResult = {
  /**开发环境状态，running: 开发环境已启动，closed：开发环境已关闭*/
  hasMore: boolean;

  /**查询开始时间，格式：YYYY-MM-DD HH:mm:ssZZ，例如：2024-12-01 00:00:00+0800*/
  list: DtoWorkspaceInfo[];

  /**查询结束时间，格式：YYYY-MM-DD HH:mm:ssZZ，例如：2024-12-01 00:00:00+0800*/
  pageInfo: any;

  /**分支名，例如：main*/
  total: number;
};

export type DtoWorkspacePageInfo = {
  page: number;
  pageSize: number;
};

export type DtoWxJsSdkSign = {
  appid: string;
  noncestr: string;

  /**签名结果*/
  sign: string;
  timestamp: number;
};

export type DtoStorage = {
  /**example: { "hard": { "storage": -1}},移除 omitempty ，Storage = 0，会生成 {"hard":{"storage":0}}*/
  storage: number;
};

export type GitWoaComCnbMonorepoGitInternalAppGitServiceBffApiUserInfo = {
  freeze: boolean;
  nickname: string;
  username: string;
};

export type GitWoaComCnbMonorepoGitInternalAppGitServiceBffWebUserInfo = {
  freeze: boolean;
  nickname: string;
  username: string;
};

export type GitWoaComCnbMonorepoGitInternalAppVcsServiceBffApiUserInfo = {
  nickname: string;
  username: string;
};

export type GitWoaComCnbMonorepoGitInternalDtoWebUserInfo = {
  freeze: boolean;
  nickname: string;
  username: string;
};

export type GitWoaComCnbMonorepoMissionMissionResourceDtoWebUserInfo = {
  nickname: string;
  username: string;
};

export type HandlerCreateIssueCommentForm = {
  body: string;
};

export type HandlerCreateIssueForm = {
  assignees: string[];
  body: string;
  labels: string[];

  /**p0, p1, p2, p3, ""。 single choice。*/
  priority: string;
  title: string;
};

export type HandlerCreateLabelForm = {
  color: string;
  description: string;
  name: string;
};

export type HandlerGitIgnoreTemplate = {
  name: string;
  source: string;
};

export type HandlerIssueNumber = {
  number: string;
};

export type HandlerLabelId = {
  id: string;
};

export type HandlerLicense = {
  body: string;
  conditions: string[];
  description: string;
  key: string;
  limitations: string[];
  name: string;
  permissions: string[];
  spdx_id: string;
};

export type HandlerLicenseListItem = {
  key: string;
  name: string;
  spdx_id: string;
};

export type HandlerLogoutRes = {
  url: string;
};

export type HandlerMissionFilter = {
  /**属性名*/
  field: string;

  /**筛选符*/
  operator: string;

  /**属性值*/
  value: string[];
};

export type HandlerMissionFilterFrom = {
  selectors: HandlerMissionFilter[];
};

export type HandlerUpdateIssueForm = {
  body: string;
  end_date: string;

  /**p0, p1, p2, p3, ""。 single choice。*/
  priority: string;
  start_date: string;

  /**open or closed*/
  state: string;

  /**completed, not_planned, reopened*/
  state_reason: string;
  title: string;
};

export type HandlerUpdateItemField = {
  id: string;
  value: string[];
};

export type HandlerUpdateItemFieldInBatchForm = {
  field: string;
  type: string;
  updated_item_fields: HandlerUpdateItemField[];
};

export type HandlerUpdateLabelForm = {
  color: string;
  description: string;
  new_name: string;
};

export type HttpUpdateUserInfoPayload = {
  address: string;
  bio: string;
  company: string;
  location: string;
  name: string;
  nickname: string;
  site: string;
  wechat_mp: string;
  wechat_mp_qrcode: string;
};

export type IdentityMpPhoneReq = {
  code: string;
};

export type IdentityState = {
  nickName: string;
  ok: boolean;
};

export type IdentityTicket = {
  state: string;
};

export type LabelOption = {
  color: string;
  description: string;
  id: string;
  name: string;
};

export type MapConstantSlugTypeInt64 = any;

export type OpenapiCommitAssetUploadUrl = {
  expires_in_sec: number;
  upload_url: string;
  verify_url: string;
};

export type OpenapiCreateBranchForm = {
  name: string;
  start_point: string;
};

export type OpenapiHeadRef = {
  name: string;
  protected: boolean;
};

export type OpenapiPatchReleaseForm = {
  body: string;
  draft: boolean;
  make_latest: string;
  name: string;
  prerelease: boolean;
};

export type OpenapiPostCommitAssetUploadUrlForm = {
  asset_name: string;
};

export type OpenapiPostReleaseAssetUploadUrlForm = {
  asset_name: string;
  overwrite: boolean;
};

export type OpenapiPostReleaseForm = {
  body: string;
  draft: boolean;
  make_latest: string;
  name: string;
  prerelease: boolean;
  tag_name: string;
  target_commitish: string;
};

export type OpenapiPutCommitAnnotation = {
  key: string;
  value: string;
};

export type OpenapiPutCommitAnnotationsForm = {
  annotations: OpenapiPutCommitAnnotation[];
};

export type OpenapiPutTagAnnotation = {
  key: string;
  value: string;
};

export type OpenapiPutTagAnnotationsForm = {
  annotations: OpenapiPutTagAnnotation[];
};

export type OpenapiReleaseAssetUploadUrl = {
  expires_in_sec: number;
  upload_url: string;
  verify_url: string;
};

export type OrganizationSettingValue = 1 | 2 | 4 | 8 | 16;

export type OrganizationsDomainsVerificationResponse = {
  domains: string[];
  domains_by: string[];
  message: string;
  result: boolean;
  txt_match: boolean;
  txt_value: string;
  valid: boolean;
};

export type ScopeAccessTokenConfig = {
  config: ScopeGroupItem[];
  scene: ScopeScene[];
};

export type ScopeGroupItem = {
  codes: ScopeRawItem[];
  group: string;
};

export type ScopeRawItem = {
  code: string;
  text: string;
  values: string[];
};

export type ScopeScene = {
  description: string;
  id: string;
  title: string;
  values: string[];
};

export type V1Descriptor = {
  /**Annotations contains arbitrary metadata relating to the targeted content.*/
  annotations: any;

  /**ArtifactType is the IANA media type of this artifact.*/
  artifactType: string;

  /**Data is an embedding of the targeted content. This is encoded as a base64
string when marshalled to JSON (automatically, by encoding/json). If
present, Data can be used directly to avoid fetching the targeted content.*/
  data: number[];

  /**Digest is the digest of the targeted content.*/
  digest: string;

  /**MediaType is the media type of the object this schema refers to.*/
  mediaType: string;

  /**Platform describes the platform which the image in the manifest runs on.

This should only be used when referring to a manifest.*/
  platform: any;

  /**Size specifies the size in bytes of the blob.*/
  size: number;

  /**URLs specifies a list of URLs from which this object MAY be downloaded*/
  urls: string[];
};

export type V1Platform = {
  /**Architecture field specifies the CPU architecture, for example
`amd64` or `ppc64le`.*/
  architecture: string;

  /**OS specifies the operating system, for example `linux` or `windows`.*/
  os: string;

  /**OSFeatures is an optional field specifying an array of strings,
each listing a required OS feature (for example on Windows `win32k`).*/
  "os.features": string[];

  /**OSVersion is an optional field specifying the operating system
version, for example on Windows `10.0.14393.1066`.*/
  "os.version": string;

  /**Variant is an optional field specifying a variant of the CPU, for
example `v7` to specify ARMv7 when architecture is `arm`.*/
  variant: string;
};

export type WebAddGpgKeyForm = {
  /**A GPG public key in ASCII-armored format.*/
  armoredPublicKey: string;

  /**A descriptive name for the new key.*/
  name: string;
};

export type WebAuthor = {
  email: string;
  user_name: string;
};

export type WebBranch = {
  commit: WebCommit;
  is_protected: boolean;
  name: string;
};

export type WebBranchListItem = {
  ahead: number;
  associated_pull_request: WebBranchPullRequest;
  behind: number;
  commit: WebCommit;
  dev_meta: number[];
  is_head: boolean;
  is_protected: boolean;
  name: string;
};

export type WebBranchProtection = {
  allow_creation: boolean;
  allow_deletions: boolean;
  allow_force_pushes: boolean;
  allow_master_creation: boolean;
  allow_master_deletions: boolean;
  allow_master_force_pushes: boolean;
  allow_master_pushes: boolean;
  allow_pushes: boolean;
  id: string;
  match_count: number;
  required_approved_review_count: number;
  required_approved_review_ratio: number;
  required_commit_signatures: boolean;
  required_linear_history: boolean;
  required_master_approve: boolean;
  required_must_auto_merge: boolean;
  required_must_push_via_pull_request: boolean;
  required_pull_request_reviews: boolean;
  required_status_checks: boolean;
  rule: string;
};

export type WebBranchPullRequest = {
  is_merged: boolean;
  mergeable_state: string;
  number: string;
  state: string;
};

export type WebCodeSensitiveDetail = {
  /**问题内容*/
  content: string;

  /**问题创建时间*/
  created_at: string;

  /**问题描述*/
  description: string;

  /**问题域*/
  domain: string;

  /**包含问题的文件路径*/
  file_path: string;

  /**默认分支信息*/
  head_ref: any;

  /**问题 id,此id用来更新问题状态*/
  info_id: string;

  /**问题类型*/
  issue_type: string;
  keen_attr: WebKeenAttr;

  /**问题行号*/
  line_no: number[];

  /**问题发生版本*/
  occur_version: string;

  /**问题责任人(平台信息)*/
  owner: any;

  /**问题责任人原生git信息*/
  raw_author: any;

  /**仓库 id*/
  repo_id: string;

  /**问题所在版本*/
  revision: string;

  /**问题等级*/
  risk_level: string;

  /**问题状态 开启/忽略*/
  state: string;

  /**问题子类型*/
  sub_class: string;

  /**扫描工具*/
  tool: string;
};

export type WebCodeSensitiveDetailResp = {
  /**问题详情*/
  detail: any;

  /**忽略问题详情*/
  ignore_detail: any;

  /**详情类型 开启中/已忽略*/
  type: string;
};

export type WebCodeSensitiveIgnoreDetail = {
  /**问题内容*/
  content: string;

  /**问题创建时间*/
  created_at: string;

  /**问题描述*/
  description: string;

  /**问题域*/
  domain: string;

  /**包含问题的文件路径*/
  file_path: string;

  /**默认分支信息*/
  head_ref: any;

  /**忽略人*/
  ignore_operator: any;

  /**忽略原因*/
  ignore_reason: string;

  /**问题 id,此id用来更新问题状态*/
  info_id: string;

  /**问题类型*/
  issue_type: string;
  keen_attr: WebKeenAttr;

  /**问题行号*/
  line_no: number[];

  /**问题发生版本*/
  occur_version: string;

  /**问题责任人(平台信息)*/
  owner: any;

  /**问题责任人原生git信息*/
  raw_author: any;

  /**仓库 id*/
  repo_id: string;

  /**问题所在版本*/
  revision: string;

  /**问题等级*/
  risk_level: string;

  /**问题状态 开启/忽略*/
  state: string;

  /**问题子类型*/
  sub_class: string;

  /**扫描工具*/
  tool: string;
};

export type WebCodeSensitiveInfo = {
  /**问题创建时间*/
  created_at: string;

  /**包含问题的文件路径*/
  file_path: string;

  /**问题id*/
  id: string;

  /**问题类型*/
  issue_type: string;

  /**问题发生版本*/
  occur_version: string;

  /**问题责任人(平台信息)*/
  owner: any;

  /**问题责任人原生git信息*/
  raw_author: any;

  /**仓库id*/
  repo_id: string;

  /**问题所在版本*/
  revision: string;

  /**问题等级*/
  risk_level: string;

  /**问题状态 开启/忽略*/
  state: string;

  /**扫描工具*/
  tool: string;
};

export type WebCommit = {
  author: GitWoaComCnbMonorepoGitInternalAppGitServiceBffWebUserInfo;
  commit: WebCommitObject;
  commit_statuses: WebCommitStatuses;
  committer: GitWoaComCnbMonorepoGitInternalAppGitServiceBffWebUserInfo;
  files: WebCommitFiles;
  parents: WebCommitParent[];
  sha: string;
};

export type WebCommitAnnotation = {
  key: string;
  meta: any;
  value: string;
};

export type WebCommitAnnotationInBatch = {
  annotations: WebCommitAnnotation[];
  commit_hash: string;
};

export type WebCommitAsset = {
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  content_type: string;
  created_at: string;
  id: string;
  name: string;
  path: string;
  size_in_byte: number;
  updated_at: string;
};

export type WebCommitFiles = {
  base_commit: string;
  diff: WebDiff;
  head_commit: string;
  straight: boolean;
};

export type WebCommitObject = {
  author: WebSignature;
  comment_count: number;
  committer: WebSignature;
  message: string;
  tree: WebCommitObjectTree;
  verification: WebCommitObjectVerification;
};

export type WebCommitObjectTree = {
  sha: string;
};

export type WebCommitObjectVerification = {
  payload: string;
  reason: string;
  signature: string;
  verified: boolean;
};

export type WebCommitParent = {
  sha: string;
};

export type WebCommitStatus = {
  context: string;
  created_at: string;
  description: string;
  state: string;
  target_url: string;
  updated_at: string;
};

export type WebCommitStatuses = {
  sha: string;
  state: string;
  statuses: WebCommitStatus[];
};

export type WebComparedCommits = {
  base_commit: string;
  commit_count: number;
  commits: WebCommit[];
  head_commit: string;
  merge_base_commit: string;
  straight: boolean;
};

export type WebComparedFiles = {
  base_commit: string;
  diff: WebDiff;
  head_commit: string;
  merge_base_commit: string;
  straight: boolean;
};

export type WebComparedOverview = {
  base_commit: string;
  commit_count: number;
  file_count: number;
  head_commit: string;
  merge_base_commit: string;
  straight: boolean;
};

export type WebComparedRawDiff = {
  base_commit: string;
  diff: string;
  head_commit: string;
  merge_base_commit: string;
  straight: boolean;
};

export type WebContributorTrend = {
  /**贡献者信息*/
  author: any;

  /**贡献者的总提交数*/
  commit_count: number;

  /**贡献者以周为单位的提交趋势数据*/
  weeks: WebWeek[];
};

export type WebCustomerField = {
  name: string;
  type: string;
  value: string;
};

export type WebDiff = {
  base_commit: string;
  file_exceeded: boolean;
  file_limit: number;
  files: WebDiffFile[];
  head_commit: string;
  stat: WebDiffStat;
};

export type WebDiffEntry = {
  change_type: string;
  deletions: number;
  file_index: number;
  insertions: number;
  is_bin: boolean;
  old_path: string;
  path: string;
};

export type WebDiffFile = {
  change_type: string;
  deletions: number;
  file_index: number;
  insertions: number;
  is_bin: boolean;
  old_path: string;
  path: string;
  sections: WebDiffSection[];
};

export type WebDiffLine = {
  content: string;
  left_line_number: number;
  prefix: string;
  right_line_number: number;
  type: string;
};

export type WebDiffSection = {
  lines: WebDiffLine[];
};

export type WebDiffStat = {
  deletions: number;
  entry_exceeded: boolean;
  entry_limit: number;
  insertions: number;
  paths: WebDiffEntry[];
};

export type WebEntry = {
  entries: WebSubEntry[];
  name: string;
  path: string;
  type: string;
};

export type WebExpandBlob = {
  lines: string[];
};

export type WebFieldInfo = {
  priority: WebFieldInfoPriority;
  status: WebFieldInfoStatus;
};

export type WebFieldInfoPriority = {
  color_options: WebFieldInfoPriorityColorOption[];
  html_type: string;
  label: string;
  name: string;
};

export type WebFieldInfoPriorityColorOption = {
  color: string;
  label: string;
  value: string;
};

export type WebFieldInfoStatus = {
  html_type: string;
  label: string;
  name: string;
  options: any;
};

export type WebFieldInfos = {
  bug: WebFieldInfo;
  stories: WebFieldInfo;
  task: WebFieldInfo;
};

export type WebFileContent = {
  branch_count: number;
  cnb_settings: WebPreloadFile;
  content: string;
  encoding: string;
  file_size_exceeded: boolean;
  file_size_limit: number;
  file_stat: WebFileStat;
  initialized: boolean;
  is_lfs: boolean;

  /**如果当前访问的是分支，那么表示是否是保护分支*/
  is_protected: boolean;
  last_commit: WebCommit;
  lfs_oid: string;
  name: string;
  path: string;
  repository: WebRepository;
  size: number;
  tag_count: number;
  type: string;
};

export type WebFileStat = {
  mime_type: WebMimeType;
};

export type WebForkSyncStatus = {
  ahead: number;
  behind: number;
  upstream_ref: string;
  upstream_slug: string;
};

export type WebGpgEmail = {
  /**邮箱*/
  email: string;

  /**是否已验证*/
  verified: boolean;
};

export type WebGpgPublicKey = {
  created_at: string;
  emails: WebGpgEmail[];

  /**过期时间*/
  expired_at: string;

  /**公钥指纹*/
  fingerprint: string;
  id: string;

  /**密钥创建时间*/
  key_creation_time: string;

  /**公钥 ID*/
  key_id: string;

  /**标题*/
  name: string;
  public_key: string;

  /**子密钥指纹，当为 primary key 时与 primary_fingerprint 相同*/
  subkeys: WebGpgSubkey[];
  user_id: string;
};

export type WebGpgSubkey = {
  /**子密钥系统创建时间（添加到系统时间）*/
  created_at: string;

  /**子密钥过期时间*/
  expired_at: string;

  /**子密钥指纹*/
  fingerprint: string;
  id: string;

  /**子密钥创建时间*/
  key_creation_time: string;

  /**子密钥 KeyID*/
  key_id: string;

  /**主密钥 KeyID*/
  primary_key_id: string;
};

export type WebGetCommitAnnotationsInBatchForm = {
  commit_hashes: string[];
  keys: string[];
};

export type WebGitHead = {
  branch: string;
};

export type WebGitSize = {
  lfs_limit_in_kib: string;
  lfs_used_in_kib: string;
  limit_in_kib: string;
  logical_lfs_used_in_kib: string;
  physical_lfs_used_in_kib: string;
  used_in_kib: string;
};

export type WebHeadRef = {
  /**分支hash*/
  hash: string;

  /**分支名称*/
  ref: string;
};

export type WebIssue = {
  assignees: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo[];
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  comment_count: number;
  created_at: string;
  labels: LabelOption[];
  last_acted_at: string;
  number: string;
  priority: string;
  state: string;
  state_reason: string;
  title: string;
  updated_at: string;
};

export type WebIssueActivity = {
  actor: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  actor_access_role: string;
  actor_meta: number[];
  created_at: string;
  payload: any;
  type: string;
};

export type WebIssueAssignee = {
  user: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
};

export type WebIssueComment = {
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  author_meta: number[];
  body: string;
  comment_id: string;
  created_at: string;
  updated_at: string;
};

export type WebIssueDetail = {
  assignees: WebIssueAssignee[];
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  body: string;
  comment_count: number;
  created_at: string;
  labels: LabelOption[];
  last_acted_at: string;
  number: string;
  participants: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo[];
  priority: string;
  state: string;
  state_reason: string;
  title: string;
  updated_at: string;
};

export type WebIssueResource = {
  assignees: GitWoaComCnbMonorepoMissionMissionResourceDtoWebUserInfo[];
  author: GitWoaComCnbMonorepoMissionMissionResourceDtoWebUserInfo;
  comment_count: number;
  created_at: string;
  customer_fields: WebCustomerField[];
  ended_at: string;
  id: string;
  labels: WebLabelOption[];
  number: string;
  priority: string;
  repo_slug: string;
  started_at: string;
  state: string;
  state_reason: string;
  title: string;
  updated_at: string;
};

export type WebIssueSummary = {
  closed_issue_number: number;
  closed_pull_request_number: number;
  open_issue_number: number;
  open_pull_request_number: number;
};

export type WebIssueTemplate = {
  content: string;
  encoding: string;
  name: string;
  path: string;
};

export type WebIssueTemplates = {
  templates: WebIssueTemplate[];
};

export type WebKeenAttr = {
  /**秘钥对象是否加密*/
  encrypted: boolean;

  /**URL 协议*/
  scheme: string;

  /**文件类型标签*/
  tag: string;
};

export type WebLfsFile = {
  sha: string;
  size: string;
};

export type WebLabelOption = {
  color: string;
  created_at: string;
  description: string;
  id: string;
  name: string;
  repo_id: number;
  slug: string;
  updated_at: string;
};

export type WebLabelWithCount = {
  color: string;
  created_at: string;
  description: string;
  id: string;
  issue_count: number;
  name: string;
  pull_request_count: number;
  updated_at: string;
};

export type WebLastPushBranch = {
  date_time: string;
  is_head: boolean;
  pull_number: number;
  ref: string;
};

export type WebMimeType = {
  content_type: string;
  externsion: string;
  is_audio: boolean;
  is_browsable_binary_type: boolean;
  is_image: boolean;
  is_pdf: boolean;
  is_representable_as_text: boolean;
  is_svg_image: boolean;
  is_text: boolean;
  is_video: boolean;
};

export type WebMergeState = {
  conflicts: string[];
  state: string;
};

export type WebMeta = {
  gen_branch: string;
  gen_hash: string;
  updated_at: string;
};

export type WebMissionField = {
  interaction_type: DtoInteractionType;
  name: string;
  value: any[];
};

export type WebMissionResources = {
  issues: WebIssueResource[];
  pull_requests: WebPullRequestResource[];
};

export type WebOverviewBranches = {
  active_branches: WebBranchListItem[];
  default_branch: WebBranchListItem;
  has_more_active_branch: boolean;
  has_more_stale_branch: boolean;
  has_more_yours_branch: boolean;
  initialized: boolean;
  stale_branches: WebBranchListItem[];
  yours_branches: WebBranchListItem[];
};

export type WebPermission = {
  allow_push_git_tag: boolean;
};

export type WebPipelineSettings = {
  auto_trigger: boolean;
  forked_repo_auto_trigger: boolean;
};

export type WebPostCommitAssetForm = {
  content_type: string;
  name: string;
  path: string;
  size_in_byte: number;
  token: string;
};

export type WebPreloadFile = {
  content: string;
  encoding: string;
  file_stat: WebFileStat;
  name: string;
};

export type WebPullRawDiff = {
  base_commit: string;
  diff: string;
  head_commit: string;
  merge_base_commit: string;
};

export type WebPullRequest = {
  assignees: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo[];
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  base_repo_ref: string;
  blocked_on: string;
  comment_count: number;
  commit_count: number;
  commit_statuses: WebCommitStatuses;
  created_at: string;
  file_count: number;
  head_repo_ref: string;
  head_repo_slug: string;
  is_merged: boolean;
  is_ready_for_merge: boolean;
  labels: LabelOption[];
  last_acted_at: string;
  merge_style: string;
  mergeable_state: string;
  number: string;
  review_comment_count: number;
  review_count: number;
  reviewers: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo[];
  state: string;
  status_check_commit_sha: string;
  title: string;
  updated_at: string;
};

export type WebPullRequestActivity = {
  actor: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  actor_access_role: string;
  actor_meta: number[];
  created_at: string;
  payload: any;
  type: string;
};

export type WebPullRequestAssignee = {
  user: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
};

export type WebPullRequestBranchProtection = {
  allow_deletions: boolean;
  allow_force_pushes: boolean;
  allow_master_deletions: boolean;
  allow_master_force_pushes: boolean;
  dismiss_stale_review: boolean;
  required_approved_review_count: number;
  required_approved_review_ratio: number;
  required_commit_signatures: boolean;
  required_conversation_resolution: boolean;
  required_linear_history: boolean;
  required_master_approve: boolean;
  required_must_auto_merge: boolean;
  required_must_push_via_pull_request: boolean;
  required_pull_request_reviews: boolean;
  required_status_checks: boolean;
  rule: string;
};

export type WebPullRequestDetail = {
  allow_merge_styles: string[];
  assignees: WebPullRequestAssignee[];
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  base: WebPullRequestRepository;
  base_repo_ref: string;
  blocked_on: string;
  body: string;
  can_do_merge: boolean;
  comment_count: number;
  commit_count: number;
  commit_statuses: WebCommitStatuses;
  conflict_file_count: number;
  conflict_files: string[];
  created_at: string;
  file_count: number;
  head: WebPullRequestRepository;
  head_repo_ref: string;
  head_repo_slug: string;
  is_merged: boolean;
  is_ready_for_merge: boolean;
  labels: LabelOption[];
  last_acted_at: string;
  merge_style: string;
  mergeable_state: string;
  number: string;
  participants: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo[];
  review_comment_count: number;
  review_count: number;
  reviewers: WebPullRequestReviewer[];
  reviews: WebPullRequestReviews;
  settings: WebPullRequestSetting;
  state: string;
  status_check_commit_sha: string;
  title: string;
  updated_at: string;
};

export type WebPullRequestFileComments = {
  comments: WebPullRequestReviewComment[];
  path: string;
  total_comment: number;
};

export type WebPullRequestFiles = {
  base_commit: string;
  diff: WebDiff;
  file_comments: WebPullRequestFileComments[];
  head_commit: string;
  merge_base_commit: string;
};

export type WebPullRequestRepository = {
  ref: string;
  slug: string;
  usage: WebRepositoryUsage;
};

export type WebPullRequestResource = {
  assignees: GitWoaComCnbMonorepoMissionMissionResourceDtoWebUserInfo[];
  author: GitWoaComCnbMonorepoMissionMissionResourceDtoWebUserInfo;
  base_repo_ref: string;
  blocked_on: string;
  comment_count: number;
  commit_count: number;
  created_at: string;
  customer_fields: WebCustomerField[];
  file_count: number;
  head_repo_ref: string;
  id: string;
  is_merged: boolean;
  is_ready_for_merge: boolean;
  labels: WebLabelOption[];
  last_acted_at: string;
  merge_style: string;
  mergeable_state: string;
  number: string;
  repo_slug: string;
  reviewers: WebPullRequestResourceReviewer[];
  state: string;
  status_check_commit_sha: string;
  title: string;
  updated_at: string;
};

export type WebPullRequestResourceReviewer = {
  nickname: string;
  review_state: string;
  username: string;
};

export type WebPullRequestReviewComment = {
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  author_meta: number[];
  body: string;
  comment_id: string;
  commit_hash: string;
  created_at: string;
  diff_hunk: WebDiffLine[];
  end_line: number;
  end_side: string;
  path: string;
  replies: WebPullRequestReviewCommentReply[];
  reply_to_comment_id: string;
  review_id: string;
  start_line: number;
  start_side: string;
  subject_type: string;
  updated_at: string;
};

export type WebPullRequestReviewCommentReply = {
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  body: string;
  comment_id: string;
  created_at: string;
  updated_at: string;
};

export type WebPullRequestReviewer = {
  review_state: string;
  user: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
};

export type WebPullRequestReviews = {
  approved_ratio: number;
  master_reviewers: WebPullRequestReviewer[];
  reviewers: WebPullRequestReviewer[];
  state: string;
};

export type WebPullRequestSetting = {
  allow_merge_styles: string[];
  base_branch_protection: WebPullRequestBranchProtection;
  merge_commit_message_style: string;
  squash_commit_message_style: string;
};

export type WebPullRequestSettings = {
  allow_merge_commit_merge: boolean;
  allow_rebase_merge: boolean;
  allow_squash_merge: boolean;
  master_auto_as_reviewer: boolean;
  merge_commit_message_style: string;
  squash_commit_message_style: string;
};

export type WebPullRequestState = {
  commit_statuses: WebCommitStatuses;
  merge_style: string;
  mergeable_state: string;
  number: string;
  reviews: WebPullRequestReviews;
  settings: WebPullRequestSetting;
  state: string;
  status_check_commit_sha: string;
};

export type WebPullViewedFile = {
  head_commit_sha: string;
  is_viewed: boolean;
  path: string;
};

export type WebPushLimitSettings = {
  allow_single_push_number: number;
  check_single_push_number: boolean;
  only_master_can_push_tag: boolean;
};

export type WebRawAuthor = {
  author_email: string;
  author_name: string;
};

export type WebRecommendBranchNameResponse = {
  name: string;
};

export type WebRecommendReviewer = {
  user: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
};

export type WebRef = {
  is_head: boolean;
  is_protected: boolean;
  ref: string;
  target_date: string;
  target_hash: string;
  target_type: string;
};

export type WebRefWithPath = {
  initialized: boolean;
  path: string;
  ref: string;
  ref_simple_name: string;
  ref_type: string;
};

export type WebReferTapd = {
  created: string;
  due: string;
  id: string;
  name: string;
  owner: string;
  priority: string;
  status: string;
  type: string;
  view_link: string;
  workspace_id: string;
};

export type WebRelease = {
  assets: WebReleaseAsset[];
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  body: string;
  created_at: string;
  id: string;
  is_draft: boolean;
  is_latest: boolean;
  is_prerelease: boolean;
  last_updated_by: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  published_at: string;
  tag_ref: string;
  target_commit_hash: string;
  title: string;
  updated_at: string;
};

export type WebReleaseAsset = {
  author: GitWoaComCnbMonorepoGitInternalDtoWebUserInfo;
  content_type: string;
  created_at: string;
  id: string;
  name: string;
  path: string;
  size_in_byte: number;
  updated_at: string;
};

export type WebReleaseList = {
  release_count: number;
  releases: WebRelease[];
  tag_count: number;
};

export type WebReleaseTag = {
  release: WebRelease;
  tag: WebTag;
};

export type WebRepoContribSimply = {
  meta: WebMeta;
  top_100_contrib: WebUserContributorSimply[];
  total: number;
};

export type WebRepoContribTrend = {
  meta: WebMeta;
  repo_data: WebWeek[];
  user_total: number;
  users_data: WebContributorTrend[];
  week_total: number;

  /**是否统计增删的行数, 默认总提交超过 10000 的仓库不统计*/
  with_line_counts: boolean;
};

export type WebRepoLanguage = {
  name: string;
  ratio: string;
};

export type WebRepoLicense = {
  file_name: string;
  license: string;
};

export type WebRepository = {
  head_ref: string;
  http_clone_url: string;
  slug: string;
  ssh_clone_url: string;
  usage: WebRepositoryUsage;
};

export type WebRepositoryUsage = {
  git_size_in_kib: string;
  lfs_size_in_kib: string;
};

export type WebResource = {
  type: string;
};

export type WebSignature = {
  date: string;
  email: string;
  name: string;
};

export type WebSubEntry = {
  name: string;
  path: string;
  sha: string;
  type: string;
};

export type WebSubmodule = {
  link_url: string;
};

export type WebTag = {
  commit: WebCommit;
  has_release: boolean;
  message: string;
  tag: string;
  tag_object: WebTagObject;
  tagger: GitWoaComCnbMonorepoGitInternalAppGitServiceBffWebUserInfo;
};

export type WebTagAnnotation = {
  key: string;
  meta: any;
  value: string;
};

export type WebTagList = {
  release_count: number;
  tag_count: number;
  tags: WebTag[];
};

export type WebTagObject = {
  message: string;
  tag: string;
  tagger: WebSignature;
};

export type WebTreeContent = {
  branch_count: number;
  cnb_settings: WebPreloadFile;
  commit_count: number;
  commit_count_exceeded: boolean;
  entries: WebTreeEntry[];
  file_list_exceeded: boolean;
  file_list_limit: number;
  has_web_trigger: boolean;
  initialized: boolean;

  /**如果当前访问的是分支，那么表示是否是保护分支*/
  is_protected: boolean;
  last_commit: WebCommit;
  name: string;
  path: string;
  read_me: WebPreloadFile;
  repository: WebRepository;
  tag_count: number;
  type: string;
};

export type WebTreeEntry = {
  is_lfs: boolean;
  name: string;
  path: string;
  sha: string;
  submodule: WebSubmodule;
  type: string;
};

export type WebTreeInfo = {
  entries: WebTreeInfoEntry[];
  path: string;
};

export type WebTreeInfoEntry = {
  last_commit: WebCommit;
  name: string;
  path: string;
};

export type WebUpdateGitQuotaForm = {
  quota_in_kib: number;
};

export type WebUpdateLfsQuotaForm = {
  quota_in_kib: number;
};

export type WebUpdatePullViewedFileForm = {
  path: string;
};

export type WebUserContributorSimply = {
  commit_count: number;
  email: string;
  user_name: string;
};

export type WebWeek = {
  /**每周增加的行数*/
  a: number;

  /**每周的提交数量*/
  c: number;

  /**每周删除的行数*/
  d: number;

  /**周的时间戳*/
  w: number;
};

export type WebapiCommitAssetId = {
  asset_id: string;
};

export type WebapiCreateBranchForm = {
  new_branch_name: string;
  start_point: string;
};

export type WebapiCreateIssueCommentForm = {
  body: string;
};

export type WebapiCreatePullRequestCommentForm = {
  body: string;
};

export type WebapiCreatePullRequestForm = {
  assignees: string[];
  base_branch: string;
  body: string;
  head_branch: string;
  head_repo_slug: string;
  labels: string[];
  reviewers: string[];
  title: string;
};

export type WebapiCreateTagForm = {
  message: string;
  name: string;
  target: string;
};

export type WebapiHeadRef = {
  ref: string;
};

export type WebapiInitRepositoryForm = {
  gitignore_template: string;
  is_auto_readme: boolean;
  license_template: string;
};

export type WebapiMergePullRequestForm = {
  commit_message: string;
  merge_style: string;
};

export type WebapiPatchIssueAssigneesForm = {
  assignees: string[];
};

export type WebapiPatchPullRequestAssigneesForm = {
  assignees: string[];
};

export type WebapiPatchPullRequestReviewCommentForm = {
  body: string;
};

export type WebapiPatchPullRequestReviewForm = {
  body: string;
};

export type WebapiPatchPullRequestReviewersForm = {
  reviewers: string[];
};

export type WebapiPatchReleaseForm = {
  body: string;
  is_draft: boolean;
  is_prerelease: boolean;
  make_latest: string;
  title: string;
};

export type WebapiPostCommitFile = {
  content: string;
  encoding: string;
  is_deleted: boolean;
  is_executable: boolean;
  path: string;
};

export type WebapiPostCommitForm = {
  base_branch: string;
  files: WebapiPostCommitFile[];
  message: string;
  new_branch: string;
  parent_commit_sha: string;
};

export type WebapiPostPendingPullRequestReviewEventForm = {
  body: string;
  event: string;
};

export type WebapiPostPullRequestReviewCommentForm = {
  body: string;
  end_line: number;
  end_side: string;
  path: string;
  start_line: number;
  start_side: string;

  /**can be one of: line, file*/
  subject_type: string;
};

export type WebapiPostPullRequestReviewForm = {
  body: string;
  comment: WebapiPostPullRequestReviewCommentForm;

  /**comment, approve, request_changes or ""*/
  event: string;
};

export type WebapiPostPullRequestReviewReplyForm = {
  body: string;
  reply_to_comment_id: string;
};

export type WebapiPostReleaseAssetForm = {
  content_type: string;
  name: string;
  path: string;
  size_in_byte: number;
  token: string;
};

export type WebapiPostReleaseForm = {
  body: string;
  is_draft: boolean;
  is_prerelease: boolean;
  make_latest: string;
  tag_name: string;
  target_commitish: string;
  title: string;
};

export type WebapiPullRequestNumber = {
  number: string;
};

export type WebapiPullRequestReviewId = {
  comment_ids: string[];
  review_id: string;
};

export type WebapiPutCommitAnnotation = {
  key: string;
  value: string;
};

export type WebapiPutCommitAnnotationsForm = {
  annotations: WebapiPutCommitAnnotation[];
};

export type WebapiPutIssueLabelsForm = {
  labels: string[];
};

export type WebapiPutPullRequestLabelsForm = {
  labels: string[];
};

export type WebapiPutTagAnnotation = {
  key: string;
  value: string;
};

export type WebapiPutTagAnnotationsForm = {
  annotations: WebapiPutTagAnnotation[];
};

export type WebapiReleaseAssetId = {
  asset_id: string;
};

export type WebapiUpdateCodeSensitiveIgnoreForm = {
  ignore: boolean;
  ignore_reason: string;
};

export type WebapiUpdatePullRequestForm = {
  body: string;
  state: string;
  title: string;
};

export type WechatAuthorizedUser = {
  /**默认的过期天数*/
  defaultMaxDay: number;
  freeze: boolean;
  headImgUrl: string;

  /**用户登陆过期天数可选项*/
  maxDaysOptions: number[];
  nickName: string;
};

export type WechatLoginState = {
  avatar: string;
  confirmed: boolean;
  isExpired: boolean;
  nickName: string;
};

export type WechatLoginTicket = {
  state: string;
};
