{
  "groups.post": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "CreateOrganization",
    "tags": [
      "Organizations"
    ],
    "summary": "创建新组织",
    "parameters": [
      {
        "description": "group information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.CreateGroupReq"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      }
    },
    "path": "/groups",
    "method": "post"
  },
  "user.get": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-profile:r",
    "operationId": "GetUserInfo",
    "tags": [
      "Users"
    ],
    "summary": "获取指定用户的详情信息",
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.UsersResultForSelf"
        }
      }
    },
    "path": "/user",
    "method": "get"
  },
  "user.post": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-profile:rw",
    "operationId": "UpdateUserInfo",
    "tags": [
      "Users"
    ],
    "summary": "更新指定用户的详情信息, 可更新内容为: 昵称, 个人签名, 微信公众号名称, 微信公众号二维码链接, 个人网站, 个人地址, 公司名称",
    "parameters": [
      {
        "description": "user info",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/http.UpdateUserInfoPayload"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/user",
    "method": "post"
  },
  "user.autocompleteSource.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "AutoCompleteSource",
    "tags": [
      "Users"
    ],
    "summary": "查询当前用户用户拥有指定权限的所有资源列表",
    "parameters": [
      {
        "description": "资源类型, 默认group",
        "enum": [
          "Group",
          "Repo"
        ],
        "in": "query",
        "name": "source_type",
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": "",
        "description": "过滤组织",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "description": "最小仓库权限，默认owner",
        "enum": [
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "access",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      }
    },
    "path": "/user/autocomplete_source",
    "method": "get"
  },
  "user.groups.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "ListTopGroups",
    "tags": [
      "Organizations"
    ],
    "summary": "获取当前用户拥有权限的顶层组织列表",
    "parameters": [
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": "",
        "description": "过滤组织",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.OrganizationAccess"
          },
          "type": "array"
        }
      }
    },
    "path": "/user/groups",
    "method": "get"
  },
  "user.groups.listByGroup": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "ListGroups",
    "tags": [
      "Organizations"
    ],
    "summary": "查询当前用户在指定组织下拥有指定权限的子组织列表",
    "parameters": [
      {
        "default": "hello",
        "description": "Group slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "access level",
        "in": "query",
        "name": "access",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.OrganizationAccess"
          },
          "type": "array"
        }
      }
    },
    "path": "/user/groups/{group}",
    "method": "get"
  },
  "user.repos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetRepos",
    "tags": [
      "Repositories"
    ],
    "summary": "获取当前用户拥有指定权限及其以上权限的仓库",
    "parameters": [
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": "",
        "description": "过滤仓库",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "description": "仓库类型",
        "enum": [
          "private",
          "public",
          "encrypted"
        ],
        "in": "query",
        "name": "filter_type",
        "type": "string"
      },
      {
        "description": "最小仓库权限，默认owner",
        "enum": [
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "description": "排序类型，默认last_updated_at",
        "enum": [
          "created_at",
          "last_updated_at",
          "stars",
          "slug_path",
          "forks"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4User"
          },
          "type": "array"
        }
      }
    },
    "path": "/user/repos",
    "method": "get"
  },
  "user.staredRepos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetUserAllStaredRepos",
    "tags": [
      "Repositories"
    ],
    "summary": "获取当前用户 star 的仓库列表",
    "parameters": [
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": "",
        "description": "过滤仓库",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      },
      {
        "description": "排序类型，默认last_updated_at",
        "enum": [
          "created_at",
          "last_updated_at",
          "stars",
          "forks"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4UserBase"
          },
          "type": "array"
        }
      }
    },
    "path": "/user/stared-repos",
    "method": "get"
  },
  "users.get": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-profile:r",
    "operationId": "GetUserInfoByName",
    "tags": [
      "Users"
    ],
    "summary": "获取指定用户的详情信息",
    "parameters": [
      {
        "default": "someone",
        "description": "User Name",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.UsersResult"
        }
      }
    },
    "path": "/users/{username}",
    "method": "get"
  },
  "users.avatar.get": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-profile:r",
    "operationId": "GetUserAvatar",
    "tags": [
      "Assets"
    ],
    "summary": "获取指定用户的用户头像",
    "parameters": [
      {
        "default": "someone",
        "description": "User Name",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "头像大小，取 s 或者 l",
        "in": "path",
        "name": "size",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {},
    "path": "/users/{username}/avatar/{size}",
    "method": "get"
  },
  "users.followers.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetFollowersByUserID",
    "tags": [
      "Followers"
    ],
    "summary": "获取指定用户的粉丝列表",
    "parameters": [
      {
        "default": "someone",
        "description": "User Name",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.UserFollowResult"
          },
          "type": "array"
        }
      }
    },
    "path": "/users/{username}/followers",
    "method": "get"
  },
  "users.following.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetFollowingByUserID",
    "tags": [
      "Followers"
    ],
    "summary": "获取指定用户的关注人列表",
    "parameters": [
      {
        "default": "someone",
        "description": "User Name",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.UserFollowResult"
          },
          "type": "array"
        }
      }
    },
    "path": "/users/{username}/following",
    "method": "get"
  },
  "users.groups.get": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetGroupsByUserID",
    "tags": [
      "Organizations"
    ],
    "summary": "获取指定用户拥有权限的顶层组织列表",
    "parameters": [
      {
        "default": "someone",
        "description": "UserName",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤组织",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      },
      {
        "description": "排序类型，默认为created_at",
        "enum": [
          "join_time",
          "created_at"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.OrganizationUnion"
        }
      }
    },
    "path": "/users/{username}/groups",
    "method": "get"
  },
  "users.pinnedRepos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetPinnedRepoByID",
    "tags": [
      "Repositories"
    ],
    "summary": "获取指定用户的用户仓库墙",
    "parameters": [
      {
        "default": "someone",
        "description": "User Name",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4User"
          },
          "type": "array"
        }
      }
    },
    "path": "/users/{username}/pinned-repos",
    "method": "get"
  },
  "users.repos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetReposByUserName",
    "tags": [
      "Repositories"
    ],
    "summary": "获取指定用户有指定以上权限并且客人态可见的仓库",
    "parameters": [
      {
        "default": "someone",
        "description": "UserName",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤仓库",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "description": "最小仓库权限，默认owner",
        "enum": [
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      },
      {
        "description": "排序类型，默认last_updated_at",
        "enum": [
          "created_at",
          "last_updated_at",
          "stars",
          "slug_path",
          "forks"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4User"
          },
          "type": "array"
        }
      }
    },
    "path": "/users/{username}/repos",
    "method": "get"
  },
  "users.staredRepos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "GetUserStaredRepos",
    "tags": [
      "Starring"
    ],
    "summary": "获取指定用户的 star 仓库列表",
    "parameters": [
      {
        "default": "someone",
        "description": "UserName",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤仓库",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      },
      {
        "description": "排序类型，默认last_updated_at",
        "enum": [
          "created_at",
          "last_updated_at",
          "stars",
          "forks"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4User"
          },
          "type": "array"
        }
      }
    },
    "path": "/users/{username}/stared-repos",
    "method": "get"
  },
  "workspace.delete.post": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:rw",
    "operationId": "DeleteWorkspace",
    "tags": [
      "Workspace"
    ],
    "summary": "删除我的云原生开发环境",
    "parameters": [
      {
        "description": "参数",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.WorkspaceDeleteReq"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.WorkspaceDeleteResult"
        }
      }
    },
    "path": "/workspace/delete",
    "method": "post"
  },
  "workspace.list.get": {
    "description": "访问令牌调用此接口需包含以下权限 \naccount-engage:r",
    "operationId": "ListWorkspaces",
    "tags": [
      "Workspace"
    ],
    "summary": "获取我的云原生开发环境列表",
    "parameters": [
      {
        "description": "分支名，例如：main",
        "in": "query",
        "name": "branch",
        "type": "string"
      },
      {
        "description": "查询结束时间，格式：YYYY-MM-DD HH:mm:ssZZ，例如：2024-12-01 00:00:00+0800",
        "in": "query",
        "name": "end",
        "type": "string"
      },
      {
        "description": "分页页码，从 1 开始，默认为 1",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "description": "每页条数，默认为 20，最高 100",
        "in": "query",
        "name": "pageSize",
        "type": "integer"
      },
      {
        "description": "仓库路径，例如：groupname/reponame",
        "in": "query",
        "name": "slug",
        "type": "string"
      },
      {
        "description": "查询开始时间，格式：YYYY-MM-DD HH:mm:ssZZ，例如：2024-12-01 00:00:00+0800",
        "in": "query",
        "name": "start",
        "type": "string"
      },
      {
        "description": "开发环境状态，running: 开发环境已启动，closed：开发环境已关闭",
        "in": "query",
        "name": "status",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.WorkspaceListResult"
        }
      }
    },
    "path": "/workspace/list",
    "method": "get"
  },
  "group.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-delete:rw",
    "operationId": "DeleteOrganization",
    "tags": [
      "Organizations"
    ],
    "summary": "删除指定组织",
    "parameters": [
      {
        "description": "group path",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "微信用户需要确认身份，第一次调用不传接口会调用失败并返回一个x-cnb-identity-ticket，第二次调用再传返回的值",
        "in": "header",
        "name": "x-cnb-identity-ticket",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}",
    "method": "delete"
  },
  "group.get": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-resource:r",
    "operationId": "GetGroup",
    "tags": [
      "Organizations"
    ],
    "summary": "获取指定组织信息",
    "parameters": [
      {
        "description": "group path",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "group",
        "schema": {
          "$ref": "#/definitions/dto.OrganizationAccess"
        }
      }
    },
    "path": "/{group}",
    "method": "get"
  },
  "group.put": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "UpdateOrganization",
    "tags": [
      "Organizations"
    ],
    "summary": "更新组织信息, 可更新的内容为: 组织描述, 组织展示名称, 组织网站, 组织联系邮箱",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "group information to update",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateGroupReq"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}",
    "method": "put"
  },
  "group.avatar.put": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "UpdateGroupAvatar",
    "tags": [
      "Organizations"
    ],
    "summary": "更新组织头像 URL 地址",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "group avatar url to update",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateGroupAvatarReq"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}/-/avatar",
    "method": "put"
  },
  "group.inheritMembers.list": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:r",
    "operationId": "ListInheritMembersOfGroup",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取指定组织或仓库内的继承成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤成员",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.ListInheritMembers"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/inherit-members",
    "method": "get"
  },
  "group.logos.put": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "PutLogos",
    "tags": [
      "Assets"
    ],
    "summary": "确认上传的logo",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "group",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "获取 uploadurl 时返回的token",
        "in": "query",
        "name": "token",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}/-/logos",
    "method": "put"
  },
  "group.logos.get": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-resource:r",
    "operationId": "GetLogos",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个获取 logo 的请求，返回内容或者 302 到某个地址",
    "parameters": [
      {
        "default": "test-group",
        "description": "group",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "size",
        "in": "path",
        "name": "size",
        "type": "string"
      }
    ],
    "responses": {
      "302": {
        "description": "Found"
      }
    },
    "path": "/{group}/-/logos/{size}",
    "method": "get"
  },
  "group.members.list": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:r",
    "operationId": "ListMembersOfGroup",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取指定组织或仓库内的所有直接成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤成员",
        "in": "query",
        "name": "search",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.UsersWithAccessLevelInSlug"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/members",
    "method": "get"
  },
  "group.members.accessLevel.get": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:r",
    "operationId": "GetMemberAccessLevelOfGroup",
    "tags": [
      "Contributors"
    ],
    "summary": "获取指定组织或仓库内, 访问成员在当前层级内的权限信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "default": true,
        "description": "是否包含继承的权限",
        "in": "query",
        "name": "include_inherit",
        "type": "boolean"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.MemberAccessLevelInSlugUnion"
        }
      }
    },
    "path": "/{group}/-/members/access-level",
    "method": "get"
  },
  "group.members.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "DeleteMembersOfGroup",
    "tags": [
      "Collaborators"
    ],
    "summary": "删除指定组织或仓库的直接成员, 包含两种场景: 1. 作为直接成员的用户自己退出 2. 由管理者移除指定的直接成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}/-/members/{username}",
    "method": "delete"
  },
  "group.members.post": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "AddMembersOfGroup",
    "tags": [
      "Collaborators"
    ],
    "summary": "添加成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "member information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateMembersRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}/-/members/{username}",
    "method": "post"
  },
  "group.members.put": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "UpdateMembersOfGroup",
    "tags": [
      "Collaborators"
    ],
    "summary": "更新指定组织或仓库内的直接成员权限信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "member information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateMembersRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}/-/members/{username}",
    "method": "put"
  },
  "group.members.accessLevel.list": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:r",
    "operationId": "ListMemberAccessLevelOfGroup",
    "tags": [
      "Contributors"
    ],
    "summary": "获取指定组织或仓库内指定成员的权限信息, 结果按组织层级来展示, 包含上层组织的权限继承信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.MemberAccessLevel"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/members/{username}/access-level",
    "method": "get"
  },
  "group.pinnedRepos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:r",
    "operationId": "GetPinnedRepoByGroup",
    "tags": [
      "Repositories"
    ],
    "summary": "获取指定组织的仓库墙列表",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4UserBase"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/pinned-repos",
    "method": "get"
  },
  "group.pinnedRepos.put": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "SetPinnedRepoByGroup",
    "tags": [
      "Repositories"
    ],
    "summary": "更新指定组织仓库墙",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "repo path",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4UserBase"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/pinned-repos",
    "method": "put"
  },
  "group.repos.list": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-resource:r",
    "operationId": "GetGroupSubRepos",
    "tags": [
      "Repositories"
    ],
    "summary": "查询组织下访问用户有权限查看到仓库",
    "parameters": [
      {
        "description": "组织 slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "页码",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页数量",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "仓库类型",
        "enum": [
          "private",
          "public",
          "encrypted"
        ],
        "in": "query",
        "name": "filter_type",
        "type": "string"
      },
      {
        "description": "排序类型，默认last_updated_at",
        "enum": [
          "created_at",
          "last_updated_at",
          "stars",
          "slug_path"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      },
      {
        "description": "查全部/查询直接属于当前组织的仓库/查询子组织的仓库",
        "enum": [
          "all",
          "sub",
          "grand"
        ],
        "in": "query",
        "name": "descendant",
        "type": "string"
      },
      {
        "description": "搜索关键字",
        "in": "query",
        "name": "search",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Repos4UserBase"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/repos",
    "method": "get"
  },
  "group.repos.post": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-resource:rw",
    "operationId": "CreateRepo",
    "tags": [
      "Repositories"
    ],
    "summary": "创建仓库",
    "parameters": [
      {
        "default": "hello",
        "description": "Group slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "repo information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.CreateRepoReq"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      }
    },
    "path": "/{group}/-/repos",
    "method": "post"
  },
  "group.settings.get": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:r",
    "operationId": "GetGroupSetting",
    "tags": [
      "Organizations"
    ],
    "summary": "获取指定组织的配置详情",
    "parameters": [
      {
        "description": "group path",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.OrganizationSettingWithParent"
        }
      }
    },
    "path": "/{group}/-/settings",
    "method": "get"
  },
  "group.settings.put": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "UpdateGroupSetting",
    "tags": [
      "Organizations"
    ],
    "summary": "更新指定组织的配置, 可更新内容为: 是否对外隐藏组织成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "group information to update",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.GroupSettingReq"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{group}/-/settings",
    "method": "put"
  },
  "group.subGroups.list": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-resource:r",
    "operationId": "ListSubgroups",
    "tags": [
      "Organizations"
    ],
    "summary": "获取指定组织下的子组织列表",
    "parameters": [
      {
        "description": "Slug",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤组织",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "default": 1,
        "description": "page",
        "in": "query",
        "name": "page",
        "required": true,
        "type": "integer"
      },
      {
        "default": 10,
        "description": "page",
        "in": "query",
        "name": "page_size",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.OrganizationUnion"
          },
          "type": "array"
        }
      }
    },
    "path": "/{group}/-/sub-groups",
    "method": "get"
  },
  "group.upload.logos.post": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-manage:rw",
    "operationId": "UploadLogos",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个上传 logo 的请求，返回上传 cos 的 url 和 form 内容",
    "parameters": [
      {
        "default": "test-group",
        "description": "group",
        "in": "path",
        "name": "group",
        "required": true,
        "type": "string"
      },
      {
        "description": "UploadRequestParams",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UploadRequestParams"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.UploadAssetsResponse"
        }
      }
    },
    "path": "/{group}/-/upload/logos",
    "method": "post"
  },
  "mission.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nmission-delete:rw",
    "operationId": "DeleteMission",
    "tags": [
      "Missions"
    ],
    "summary": "删除指定任务集",
    "parameters": [
      {
        "description": "mission path",
        "in": "path",
        "name": "mission",
        "required": true,
        "type": "string"
      },
      {
        "description": "微信用户需要确认身份，第一次调用不传接口会调用失败并返回一个x-cnb-identity-ticket，第二次调用再传返回的值",
        "in": "header",
        "name": "x-cnb-identity-ticket",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{mission}",
    "method": "delete"
  },
  "mission.members.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nmission-manage:rw",
    "operationId": "AddMembersOfMission",
    "tags": [
      "Collaborators"
    ],
    "summary": "添加成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "mission",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "member information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateMembersRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{mission}/-/members/{username}",
    "method": "post"
  },
  "registry.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-delete:rw",
    "operationId": "DeleteRegistry",
    "tags": [
      "Artifactory"
    ],
    "summary": "删除制品仓库",
    "parameters": [
      {
        "description": "registry path",
        "in": "path",
        "name": "registry",
        "required": true,
        "type": "string"
      },
      {
        "description": "微信用户需要确认身份，第一次调用不传接口会调用失败并返回一个x-cnb-identity-ticket，第二次调用再传返回的值",
        "in": "header",
        "name": "x-cnb-identity-ticket",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{registry}",
    "method": "delete"
  },
  "registry.members.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-manage:rw",
    "operationId": "AddMembersOfRegistry",
    "tags": [
      "Collaborators"
    ],
    "summary": "添加成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "registry",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "member information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateMembersRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{registry}/-/members/{username}",
    "method": "post"
  },
  "repo.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-delete:rw",
    "operationId": "DeleteRepo",
    "tags": [
      "Repositories"
    ],
    "summary": "删除指定仓库",
    "parameters": [
      {
        "description": "repo path",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "微信用户需要确认身份，第一次调用不传接口会调用失败并返回一个x-cnb-identity-ticket，第二次调用再传返回的值",
        "in": "header",
        "name": "x-cnb-identity-ticket",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}",
    "method": "delete"
  },
  "repo.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-basic-info:r",
    "operationId": "GetRepo",
    "tags": [
      "Repositories"
    ],
    "summary": "获取指定仓库信息",
    "parameters": [
      {
        "description": "repo path",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "repo",
        "schema": {
          "$ref": "#/definitions/dto.Repos4User"
        }
      }
    },
    "path": "/{repo}",
    "method": "get"
  },
  "repo.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "UpdateRepo",
    "tags": [
      "Repositories"
    ],
    "summary": "更新仓库信息, 可更新的内容为: 仓库简介, 仓库站点, 仓库主题, 开源许可证",
    "parameters": [
      {
        "description": "仓库路径",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "仓库信息",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.RepoPatch"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}",
    "method": "patch"
  },
  "repo.build.logs.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-cnb-trigger:r",
    "operationId": "GetBuildLogs",
    "tags": [
      "Build"
    ],
    "summary": "查询流水线构建列表",
    "parameters": [
      {
        "description": "仓库路径",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "开始时间，格式：YYYY-MM-DD，例如：2024-12-01",
        "in": "query",
        "name": "createTime",
        "type": "string"
      },
      {
        "description": "结束时间，格式：YYYY-MM-DD，例如：2024-12-01",
        "in": "query",
        "name": "endTime",
        "type": "string"
      },
      {
        "description": "事件名，例如：push",
        "in": "query",
        "name": "event",
        "type": "string"
      },
      {
        "description": "页数，从 1 开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "description": "每页数量，最大 100 条，默认 20 条",
        "in": "query",
        "name": "pagesize",
        "type": "integer"
      },
      {
        "description": "commit id，例如：2221d4535ec0c921bcd0858627c5025a871dd2b5",
        "in": "query",
        "name": "sha",
        "type": "string"
      },
      {
        "description": "构建号，例如：cnb-1qa-1i3f5ecau",
        "in": "query",
        "name": "sn",
        "type": "string"
      },
      {
        "description": "源分支名，例如：dev",
        "in": "query",
        "name": "sourceRef",
        "type": "string"
      },
      {
        "description": "构建状态，pending: 构建中、success：成功、error: 失败、cancel: 取消",
        "in": "query",
        "name": "status",
        "type": "string"
      },
      {
        "description": "目标分支名，例如：main",
        "in": "query",
        "name": "targetRef",
        "type": "string"
      },
      {
        "description": "用户 id",
        "in": "query",
        "name": "userId",
        "type": "string"
      },
      {
        "description": "用户名",
        "in": "query",
        "name": "userName",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.BuildLogsResult"
        }
      }
    },
    "path": "/{repo}/-/build/logs",
    "method": "get"
  },
  "repo.build.start.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-cnb-trigger:rw",
    "operationId": "StartBuild",
    "tags": [
      "Build"
    ],
    "summary": "开始一个构建",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "构建参数",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.StartBuildReq"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.BuildResult"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/build/start",
    "method": "post"
  },
  "repo.build.status.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-cnb-trigger:r",
    "operationId": "GetBuildStatus",
    "tags": [
      "Build"
    ],
    "summary": "查询流水线构建状态",
    "parameters": [
      {
        "description": "仓库路径",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "构建号",
        "in": "path",
        "name": "sn",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.BuildStatusResult"
        }
      }
    },
    "path": "/{repo}/-/build/status/{sn}",
    "method": "get"
  },
  "repo.build.stop.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-cnb-trigger:rw",
    "operationId": "StopBuild",
    "tags": [
      "Build"
    ],
    "summary": "停止一个构建",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "构建号",
        "in": "path",
        "name": "sn",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.BuildResult"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/build/stop/{sn}",
    "method": "post"
  },
  "repo.commitAssets.download.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "GetCommitAssets",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个获取 commits 附件的请求，返回内容或者 302 到某个地址",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "Repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "包含commitSha和文件名，例如 3bba1ce6a8c35ee1264c7449f4f0b512bd751eac/test.png",
        "in": "path",
        "name": "fileName",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "302": {
        "description": "Found"
      }
    },
    "path": "/{repo}/-/commit-assets/download/{fileName}",
    "method": "get"
  },
  "repo.contributor.trend.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetRepoContributorTrend",
    "tags": [
      "RepoContributor"
    ],
    "summary": "查询仓库贡献者前 100 名的详细趋势数据",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 14,
        "description": "limit, 0~100",
        "in": "query",
        "name": "limit",
        "type": "integer"
      },
      {
        "default": false,
        "description": "exclude_external_users, true|false",
        "in": "query",
        "name": "exclude_external_users",
        "type": "boolean"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/web.RepoContribTrend"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/contributor/trend",
    "method": "get"
  },
  "repo.files.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "GetFiles",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个获取 files 的请求，返回内容或者 302 到某个地址",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "user_id_key",
        "in": "path",
        "name": "userIdKey",
        "required": true,
        "type": "string"
      },
      {
        "description": "random_uuid",
        "in": "path",
        "name": "randomUUID",
        "required": true,
        "type": "string"
      },
      {
        "description": "file_name",
        "in": "path",
        "name": "fileName",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "302": {
        "description": "Found"
      }
    },
    "path": "/{repo}/-/files/{userIdKey}/{randomUUID}/{fileName}",
    "method": "get"
  },
  "repo.files.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "PutFiles",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个确认 files 的请求，上传的图片要调用此接口才能生效",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "Repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "user_id_key",
        "in": "path",
        "name": "userIdKey",
        "required": true,
        "type": "string"
      },
      {
        "description": "random_uuid",
        "in": "path",
        "name": "randomUUID",
        "required": true,
        "type": "string"
      },
      {
        "description": "file_name",
        "in": "path",
        "name": "fileName",
        "required": true,
        "type": "string"
      },
      {
        "description": "获取 uploadurl 时返回的token",
        "in": "query",
        "name": "token",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/files/{userIdKey}/{randomUUID}/{fileName}",
    "method": "put"
  },
  "repo.forks.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-base-info:r",
    "operationId": "ListForksRepos",
    "tags": [
      "Repositories"
    ],
    "summary": "获取指定仓库的 fork 列表",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "page",
        "in": "query",
        "name": "page",
        "required": true,
        "type": "integer"
      },
      {
        "default": 10,
        "description": "page",
        "in": "query",
        "name": "page_size",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Forks"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/forks",
    "method": "get"
  },
  "repo.forks.post": {
    "description": "访问令牌调用此接口需包含以下权限 \ngroup-resource:rw",
    "operationId": "CreateAFork",
    "tags": [
      "Repositories"
    ],
    "summary": "fork 仓库",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "target",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.ForkReq"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      }
    },
    "path": "/{repo}/-/forks",
    "method": "post"
  },
  "repo.git.archiveCommitChangedFiles.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetArchiveCommitChangedFiles",
    "tags": [
      "Git"
    ],
    "summary": "打包下载 commit 变更文件",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "commit sha",
        "in": "path",
        "name": "sha1",
        "type": "string"
      }
    ],
    "responses": {
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/archive-commit-changed-files/{sha1}",
    "method": "get"
  },
  "repo.git.archiveCompareChangedFiles.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetArchiveCompareChangedFiles",
    "tags": [
      "Git"
    ],
    "summary": "打包下载两次 ref 之间的变更文件",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "base...head",
        "in": "path",
        "name": "base_head",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/archive-compare-changed-files/{base_head}",
    "method": "get"
  },
  "repo.git.blobs.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "CreateBlob",
    "tags": [
      "Git"
    ],
    "summary": "创建一个 blob",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "PostBlobForm",
        "in": "body",
        "name": "post_blob_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostBlobForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.Blob"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/blobs",
    "method": "post"
  },
  "repo.git.branches.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "ListBranches",
    "tags": [
      "Git"
    ],
    "summary": "查询分支列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Branch"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/branches",
    "method": "get"
  },
  "repo.git.branches.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "CreateBranch",
    "tags": [
      "Git"
    ],
    "summary": "创建新分支",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Create BranchDetail Form",
        "in": "body",
        "name": "create_branch_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.CreateBranchForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/branches",
    "method": "post"
  },
  "repo.git.branches.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "DeleteBranch",
    "tags": [
      "Git"
    ],
    "summary": "删除指定分支",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "branch name",
        "in": "path",
        "name": "branch",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/branches/{branch}",
    "method": "delete"
  },
  "repo.git.branches.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetBranch",
    "tags": [
      "Git"
    ],
    "summary": "查询指定分支",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "branch name",
        "in": "path",
        "name": "branch",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.BranchDetail"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/branches/{branch}",
    "method": "get"
  },
  "repo.git.commitAnnotationsInBatch.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetCommitAnnotationsInBatch",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 commit 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Get Commit Annotations In Batch Form",
        "in": "body",
        "name": "get_commit_annotations_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/web.GetCommitAnnotationsInBatchForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/web.CommitAnnotationInBatch"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-annotations-in-batch",
    "method": "post"
  },
  "repo.git.commitAnnotations.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetCommitAnnotations",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 commit 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "commit hash",
        "in": "path",
        "name": "sha",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/web.CommitAnnotation"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-annotations/{sha}",
    "method": "get"
  },
  "repo.git.commitAnnotations.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PutCommitAnnotations",
    "tags": [
      "Git"
    ],
    "summary": "设定指定 commit 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "commit hash",
        "in": "path",
        "name": "sha",
        "required": true,
        "type": "string"
      },
      {
        "description": "Put Commit Annotations Form",
        "in": "body",
        "name": "put_commit_annotations_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.PutCommitAnnotationsForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-annotations/{sha}",
    "method": "put"
  },
  "repo.git.commitAnnotations.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "DeleteCommitAnnotation",
    "tags": [
      "Git"
    ],
    "summary": "删除指定 commit 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "commit hash",
        "in": "path",
        "name": "sha",
        "required": true,
        "type": "string"
      },
      {
        "description": "commit annotation key",
        "in": "path",
        "name": "key",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-annotations/{sha}/{key}",
    "method": "delete"
  },
  "repo.git.commitAssets.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetCommitAssetsBySha",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 commit 的附件",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "sha",
        "in": "path",
        "name": "sha1",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.CommitAsset"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-assets/{sha1}",
    "method": "get"
  },
  "repo.git.commitAssets.assetUploadConfirmation.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PostCommitAssetUploadConfirmation",
    "tags": [
      "Git"
    ],
    "summary": "确认 Commit asset 上传完成",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "sha",
        "in": "path",
        "name": "sha1",
        "required": true,
        "type": "integer"
      },
      {
        "description": "upload token",
        "in": "path",
        "name": "token",
        "required": true,
        "type": "string"
      },
      {
        "description": "release asset path",
        "in": "path",
        "name": "asset_path",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-assets/{sha1}/asset-upload-confirmation/{token}/{asset_path}",
    "method": "post"
  },
  "repo.git.commitAssets.assetUploadUrl.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PostCommitAssetUploadURL",
    "tags": [
      "Git"
    ],
    "summary": "新增一个 Commit asset",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "sha",
        "in": "path",
        "name": "sha1",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Commit Asset Upload URL Form",
        "in": "body",
        "name": "create_commit_asset_upload_url_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.PostCommitAssetUploadURLForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/openapi.CommitAssetUploadURL"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-assets/{sha1}/asset-upload-url",
    "method": "post"
  },
  "repo.git.commitAssets.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "DeleteCommitAsset",
    "tags": [
      "Git"
    ],
    "summary": "删除指定 commit 的附件",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "sha",
        "in": "path",
        "name": "sha1",
        "required": true,
        "type": "string"
      },
      {
        "description": "asset id",
        "in": "path",
        "name": "asset_id",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "204": {
        "description": "No Content"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-assets/{sha1}/{asset_id}",
    "method": "delete"
  },
  "repo.git.commitStatuses.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetCommitStatuses",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 commit 的 check statuses",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "commitish",
        "in": "path",
        "name": "commitish",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.CommitStatus"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commit-statuses/{commitish}",
    "method": "get"
  },
  "repo.git.commits.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "ListCommits",
    "tags": [
      "Git"
    ],
    "summary": "查询 commit 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "sha or branch",
        "in": "query",
        "name": "sha",
        "type": "string"
      },
      {
        "description": "commit author pattern",
        "in": "query",
        "name": "author",
        "type": "string"
      },
      {
        "description": "commit committer pattern",
        "in": "query",
        "name": "committer",
        "type": "string"
      },
      {
        "description": "commit since",
        "in": "query",
        "name": "since",
        "type": "string"
      },
      {
        "description": "commit until",
        "in": "query",
        "name": "until",
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Commit"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commits",
    "method": "get"
  },
  "repo.git.commits.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetCommit",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 commit",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "ref",
        "in": "path",
        "name": "ref",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Commit"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/commits/{ref}",
    "method": "get"
  },
  "repo.git.compare.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetCompareCommits",
    "tags": [
      "Git"
    ],
    "summary": "对比 base...head",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "base...head",
        "in": "path",
        "name": "base_head",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.CompareResponse"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/compare/{base_head}",
    "method": "get"
  },
  "repo.git.contents.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetContent",
    "tags": [
      "Git"
    ],
    "summary": "查询仓库文件列表或文件",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "path",
        "in": "path",
        "name": "file_path",
        "required": true,
        "type": "string"
      },
      {
        "description": "ref",
        "in": "query",
        "name": "ref",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Content"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/contents/{file_path}",
    "method": "get"
  },
  "repo.git.head.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetHead",
    "tags": [
      "Git"
    ],
    "summary": "获取仓库默认分支",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/openapi.HeadRef"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/head",
    "method": "get"
  },
  "repo.git.tagAnnotations.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "DeleteTagAnnotation",
    "tags": [
      "Git"
    ],
    "summary": "删除指定 tag 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag with key",
        "in": "path",
        "name": "tag_with_key",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tag-annotations/{tag_with_key}",
    "method": "delete"
  },
  "repo.git.tagAnnotations.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "GetTagAnnotations",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 tag 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/web.TagAnnotation"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tag-annotations/{tag}",
    "method": "get"
  },
  "repo.git.tagAnnotations.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "PutTagAnnotations",
    "tags": [
      "Git"
    ],
    "summary": "设定指定 tag 的元数据",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      },
      {
        "description": "Put Tag Annotations Form",
        "in": "body",
        "name": "put_tag_annotations_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.PutTagAnnotationsForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tag-annotations/{tag}",
    "method": "put"
  },
  "repo.git.tags.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "ListTags",
    "tags": [
      "Git"
    ],
    "summary": "查询标签列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Tag"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tags",
    "method": "get"
  },
  "repo.git.tags.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "CreateTag",
    "tags": [
      "Git"
    ],
    "summary": "创建一个 tag",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "PostTagFrom",
        "in": "body",
        "name": "post_tag_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostTagFrom"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.Tag"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tags",
    "method": "post"
  },
  "repo.git.tags.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "DeleteTag",
    "tags": [
      "Git"
    ],
    "summary": "删除指定标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag name",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "204": {
        "description": "No Content"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tags/{tag}",
    "method": "delete"
  },
  "repo.git.tags.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "GetTag",
    "tags": [
      "Git"
    ],
    "summary": "查询指定 Tag",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag name",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Tag"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/git/tags/{tag}",
    "method": "get"
  },
  "repo.imgs.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "GetImgs",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个获取 imgs 的请求，返回内容或者 302 到某个地址",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "user_id_key",
        "in": "path",
        "name": "userIdKey",
        "required": true,
        "type": "string"
      },
      {
        "description": "file_name",
        "in": "path",
        "name": "fileName",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "302": {
        "description": "Found"
      }
    },
    "path": "/{repo}/-/imgs/{userIdKey}/{fileName}",
    "method": "get"
  },
  "repo.imgs.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "PutImgs",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个确认 imgs 的请求，上传的图片要调用此接口才能生效",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "Repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "user_id_key",
        "in": "path",
        "name": "userIdKey",
        "required": true,
        "type": "string"
      },
      {
        "description": "file_name",
        "in": "path",
        "name": "fileName",
        "required": true,
        "type": "string"
      },
      {
        "description": "获取 uploadurl 时返回的token",
        "in": "query",
        "name": "token",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/imgs/{userIdKey}/{fileName}",
    "method": "put"
  },
  "repo.inheritMembers.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "ListInheritMembersOfRepo",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取指定组织或仓库内的继承成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤成员",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.ListInheritMembers"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/inherit-members",
    "method": "get"
  },
  "repo.issues.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "ListIssues",
    "tags": [
      "Issues"
    ],
    "summary": "查询仓库的 Issues",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "issue state open or closed",
        "in": "query",
        "name": "state",
        "type": "string"
      },
      {
        "description": "issue search key",
        "in": "query",
        "name": "keyword",
        "type": "string"
      },
      {
        "description": "issue priority example: p0,p1,p2,p3",
        "in": "query",
        "name": "priority",
        "type": "string"
      },
      {
        "description": "issue labels example: git,bug,feature",
        "in": "query",
        "name": "labels",
        "type": "string"
      },
      {
        "description": "issue authors name, example: 张三,李四",
        "in": "query",
        "name": "authors",
        "type": "string"
      },
      {
        "description": "issue assignees name, example: 张三,李四,-; - means assign to nobody",
        "in": "query",
        "name": "assignees",
        "type": "string"
      },
      {
        "description": "issue filter update time begin  example: 2022-01-31",
        "in": "query",
        "name": "updated_time_begin",
        "type": "string"
      },
      {
        "description": "issue filter update time end,  example: 2022-01-31",
        "in": "query",
        "name": "updated_time_end",
        "type": "string"
      },
      {
        "description": "issue order, example: created_at, -updated_at, reference_count。‘-’ prefix means descending order",
        "in": "query",
        "name": "order_by",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Issue"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues",
    "method": "get"
  },
  "repo.issues.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "CreateIssue",
    "tags": [
      "Issues"
    ],
    "summary": "创建一个 Issue",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Post Issue Form",
        "in": "body",
        "name": "post_issue_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostIssueForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.IssueDetail"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues",
    "method": "post"
  },
  "repo.issues.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "GetIssue",
    "tags": [
      "Issues"
    ],
    "summary": "查询指定的 Issues",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "issue number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.IssueDetail"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}",
    "method": "get"
  },
  "repo.issues.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "UpdateIssue",
    "tags": [
      "Issues"
    ],
    "summary": "更新一个 Issue",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "issue number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Patch Issue Form",
        "in": "body",
        "name": "patch_issue_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PatchIssueForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.IssueDetail"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}",
    "method": "patch"
  },
  "repo.issues.comments.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "ListIssueComments",
    "tags": [
      "Issues"
    ],
    "summary": "查询仓库的 Issue 评论列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "issue number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.IssueComment"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/comments",
    "method": "get"
  },
  "repo.issues.comments.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PostIssueComment",
    "tags": [
      "Issues"
    ],
    "summary": "创建一个 Issue Comment",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Issue Comment Form",
        "in": "body",
        "name": "post_issue_comment_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostIssueCommentForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.IssueComment"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/comments",
    "method": "post"
  },
  "repo.issues.comments.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "GetIssueComment",
    "tags": [
      "Issues"
    ],
    "summary": "获取一个 Issue Comment",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "comment_id",
        "in": "path",
        "name": "comment_id",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.IssueComment"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/comments/{comment_id}",
    "method": "get"
  },
  "repo.issues.comments.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PatchIssueComment",
    "tags": [
      "Issues"
    ],
    "summary": "修改一个 Issue Comment",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "comment_id",
        "in": "path",
        "name": "comment_id",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Patch Issue Comment Form",
        "in": "body",
        "name": "patch_issue_comment_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PatchIssueCommentForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.IssueComment"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/comments/{comment_id}",
    "method": "patch"
  },
  "repo.issues.labels.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "DeleteIssueLabels",
    "tags": [
      "Issues"
    ],
    "summary": "清空 Issue 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "204": {
        "description": "No Content"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/labels",
    "method": "delete"
  },
  "repo.issues.labels.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "ListIssueLabels",
    "tags": [
      "Issues"
    ],
    "summary": "查询 Issue 的标签(label) 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Label"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/labels",
    "method": "get"
  },
  "repo.issues.labels.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PostIssueLabels",
    "tags": [
      "Issues"
    ],
    "summary": "新增 Issue 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Issue Labels Form",
        "in": "body",
        "name": "post_issue_labels_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostIssueLabelsForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/labels",
    "method": "post"
  },
  "repo.issues.labels.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PutIssueLabels",
    "tags": [
      "Issues"
    ],
    "summary": "设置 Issue 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Put Issue Labels Form",
        "in": "body",
        "name": "put_issue_labels_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PutIssueLabelsForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/labels",
    "method": "put"
  },
  "repo.issues.labels.deleteByName": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "DeleteIssueLabel",
    "tags": [
      "Issues"
    ],
    "summary": "删除 Issue 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "label name",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/issues/{number}/labels/{name}",
    "method": "delete"
  },
  "repo.labels.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "ListLabels",
    "tags": [
      "RepoLabels"
    ],
    "summary": "查询仓库的标签(label) 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "label search key",
        "in": "query",
        "name": "keyword",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Label"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/labels",
    "method": "get"
  },
  "repo.labels.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PostLabel",
    "tags": [
      "RepoLabels"
    ],
    "summary": "创建一个 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Post Label Form",
        "in": "body",
        "name": "post_label_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostLabelForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/labels",
    "method": "post"
  },
  "repo.labels.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "DeleteLabel",
    "tags": [
      "RepoLabels"
    ],
    "summary": "删除指定的仓库标签 label",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "label name",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "204": {
        "description": "No Content"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/labels/{name}",
    "method": "delete"
  },
  "repo.labels.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PatchLabel",
    "tags": [
      "RepoLabels"
    ],
    "summary": "更新标签信息",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "label name",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      },
      {
        "description": "Patch Label Form",
        "in": "body",
        "name": "patch_label_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PatchLabelForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/labels/{name}",
    "method": "patch"
  },
  "repo.listMembers.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "ListAllMembers",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取指定仓库内的有效成员列表，包含继承成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤成员",
        "in": "query",
        "name": "search",
        "type": "string"
      },
      {
        "default": "",
        "description": "精准匹配用户名,多个用户名用逗号间隔",
        "in": "query",
        "name": "names",
        "type": "string"
      },
      {
        "description": "排序类型，默认created_at",
        "enum": [
          "created_at",
          "stars",
          "follower"
        ],
        "in": "query",
        "name": "order_by",
        "type": "string"
      },
      {
        "default": false,
        "description": "排序顺序",
        "in": "query",
        "name": "desc",
        "type": "boolean"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.UsersWithAccessLevelInSlug"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/list-members",
    "method": "get"
  },
  "repo.members.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "ListMembersOfRepo",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取指定组织或仓库内的所有直接成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master",
          "Owner"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤成员",
        "in": "query",
        "name": "search",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.UsersWithAccessLevelInSlug"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/members",
    "method": "get"
  },
  "repo.members.accessLevel.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "GetMemberAccessLevelOfRepo",
    "tags": [
      "Contributors"
    ],
    "summary": "获取指定组织或仓库内, 访问成员在当前层级内的权限信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": true,
        "description": "是否包含继承的权限",
        "in": "query",
        "name": "include_inherit",
        "type": "boolean"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.MemberAccessLevelInSlugUnion"
        }
      }
    },
    "path": "/{repo}/-/members/access-level",
    "method": "get"
  },
  "repo.members.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "DeleteMembersOfRepo",
    "tags": [
      "Collaborators"
    ],
    "summary": "删除指定组织或仓库的直接成员, 包含两种场景: 1. 作为直接成员的用户自己退出 2. 由管理者移除指定的直接成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/members/{username}",
    "method": "delete"
  },
  "repo.members.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "AddMembersOfRepo",
    "tags": [
      "Collaborators"
    ],
    "summary": "添加成员",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "member information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateMembersRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/members/{username}",
    "method": "post"
  },
  "repo.members.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "UpdateMembersOfRepo",
    "tags": [
      "Collaborators"
    ],
    "summary": "更新指定组织或仓库内的直接成员权限信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "member information",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UpdateMembersRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/members/{username}",
    "method": "put"
  },
  "repo.members.accessLevel.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "ListMemberAccessLevelOfRepo",
    "tags": [
      "Contributors"
    ],
    "summary": "获取指定组织或仓库内指定成员的权限信息, 结果按组织层级来展示, 包含上层组织的权限继承信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.MemberAccessLevel"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/members/{username}/access-level",
    "method": "get"
  },
  "repo.outsideCollaborators.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "ListOutsideCollaborators",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取指定仓库内的外部贡献者",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "第几页，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "筛选角色",
        "enum": [
          "Guest",
          "Reporter",
          "Developer",
          "Master"
        ],
        "in": "query",
        "name": "role",
        "type": "string"
      },
      {
        "default": "",
        "description": "过滤成员",
        "in": "query",
        "name": "search",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.OutsideCollaboratorInRepo"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/outside-collaborators",
    "method": "get"
  },
  "repo.outsideCollaborators.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "DeleteOutsideCollaborators",
    "tags": [
      "Collaborators"
    ],
    "summary": "删除指定仓库的外部贡献者, 包含两种场景: 1. 作为外部贡献者的用户自己退出仓库 2. 由仓库管理者移除指定的外部贡献者",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/outside-collaborators/{username}",
    "method": "delete"
  },
  "repo.outsideCollaborators.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "UpdateOutsideCollaborators",
    "tags": [
      "Collaborators"
    ],
    "summary": "更新指定仓库的外部贡献者权限信息",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "username",
        "in": "path",
        "name": "username",
        "required": true,
        "type": "string"
      },
      {
        "description": "用户权限",
        "enum": [
          "Guest",
          "Reporter",
          "Developer"
        ],
        "in": "query",
        "name": "role",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{repo}/-/outside-collaborators/{username}",
    "method": "put"
  },
  "repo.pullInBatch.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-pr:r",
    "operationId": "ListPullsByNumbers",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 根据numbers查询 Pull 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "pull request numbers",
        "in": "query",
        "name": "n",
        "required": true,
        "type": "array"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.PullRequestInfo"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pull-in-batch",
    "method": "get"
  },
  "repo.pulls.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-pr:r",
    "operationId": "ListPulls",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 查询 Pull 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "default": "open",
        "description": "pull state `open`，`closed`, `all`",
        "in": "query",
        "name": "state",
        "type": "string"
      },
      {
        "description": "pull authors name, example: 张三,李四",
        "in": "query",
        "name": "authors",
        "type": "string"
      },
      {
        "description": "pull reviewers name, example: 张三,李四; - means nobody to review",
        "in": "query",
        "name": "reviewers",
        "type": "string"
      },
      {
        "description": "pull assignees name, example: 张三,李四,-; - means assign to nobody",
        "in": "query",
        "name": "assignees",
        "type": "string"
      },
      {
        "description": "pull base ref,  example: refs/heads/master",
        "in": "query",
        "name": "base_ref",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.PullRequest"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls",
    "method": "get"
  },
  "repo.pulls.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-pr:rw",
    "operationId": "PostPull",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 新增一个 Pull",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Post Pull Request Form",
        "in": "body",
        "name": "post_pull_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PullCreationForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.Pull"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls",
    "method": "post"
  },
  "repo.pulls.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-pr:r",
    "operationId": "GetPull",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 查询指定 Pull",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "pull request number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Pull"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}",
    "method": "get"
  },
  "repo.pulls.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-pr:rw",
    "operationId": "PatchPull",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 更新一个 Pull Request",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Pull Request Number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Update Pull Request Form",
        "in": "body",
        "name": "update_pull_request_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PatchPullRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Pull"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}",
    "method": "patch"
  },
  "repo.pulls.comments.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "ListPullComments",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 查询 Pull Comments 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.PullRequestComment"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/comments",
    "method": "get"
  },
  "repo.pulls.comments.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PostPullComment",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 新增一个 Pull Comment",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Pull Request Comment Form",
        "in": "body",
        "name": "post_pull_comment_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PullCommentCreationForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/comments",
    "method": "post"
  },
  "repo.pulls.labels.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "DeletePullLabels",
    "tags": [
      "Pulls"
    ],
    "summary": "清空 Pull 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "204": {
        "description": "No Content"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/labels",
    "method": "delete"
  },
  "repo.pulls.labels.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:r",
    "operationId": "ListPullLabels",
    "tags": [
      "Pulls"
    ],
    "summary": "查询 Pull 的标签(label) 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Label"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/labels",
    "method": "get"
  },
  "repo.pulls.labels.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PostPullLabels",
    "tags": [
      "Pulls"
    ],
    "summary": "新增 Pull 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Pull Labels Form",
        "in": "body",
        "name": "post_pull_labels_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PostPullLabelsForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/labels",
    "method": "post"
  },
  "repo.pulls.labels.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PutPullLabels",
    "tags": [
      "Pulls"
    ],
    "summary": "设置 Pull 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Put Pull Labels Form",
        "in": "body",
        "name": "put_pull_labels_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PutPullLabelsForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/labels",
    "method": "put"
  },
  "repo.pulls.labels.deleteByName": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "DeletePullLabel",
    "tags": [
      "Pulls"
    ],
    "summary": "删除 Pull 标签",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "label name",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Label"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/labels/{name}",
    "method": "delete"
  },
  "repo.pulls.merge.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-pr:rw",
    "operationId": "MergePull",
    "tags": [
      "Pulls"
    ],
    "summary": "[openapi] 合并一个 Pull Request",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Pull Request Number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Merge Pull Request Form",
        "in": "body",
        "name": "merge_pull_request_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.MergePullRequest"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.MergePullResponse"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/merge",
    "method": "put"
  },
  "repo.pulls.reviews.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-notes:rw",
    "operationId": "PostPullReview",
    "tags": [
      "Pulls"
    ],
    "summary": "新增一次 pull request 评审",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "number",
        "in": "path",
        "name": "number",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Pull Review Form",
        "in": "body",
        "name": "post_pull_review_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PullReviewCreationForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      },
      "403": {
        "description": "Forbidden",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/pulls/{number}/reviews",
    "method": "post"
  },
  "repo.releases.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "ListReleases",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 查询 release 列表",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "pagination page number",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 30,
        "description": "pagination page size",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.Release"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases",
    "method": "get"
  },
  "repo.releases.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PostRelease",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 新增一个 Release",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Post Release Form, attachment is optional",
        "in": "body",
        "name": "create_release_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.PostReleaseForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/api.Release"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases",
    "method": "post"
  },
  "repo.releases.download.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:r",
    "operationId": "GetReleasesAsset",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个获取 release 附件的请求，返回内容或者 302 到某个地址",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "Repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "包含tag名称和文件名，例如 v1.0/test.png",
        "in": "path",
        "name": "fileName",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "302": {
        "description": "Found"
      }
    },
    "path": "/{repo}/-/releases/download/{fileName}",
    "method": "get"
  },
  "repo.releases.tags.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetReleaseByTag",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 通过 tag 查询指定 release",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag name",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Release"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/tags/{tag}",
    "method": "get"
  },
  "repo.releases.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "DeleteRelease",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 删除指定的 release",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}",
    "method": "delete"
  },
  "repo.releases.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetReleaseByID",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 根据 id\t查询指定 release",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.Release"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}",
    "method": "get"
  },
  "repo.releases.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PatchRelease",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 更新 release",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      },
      {
        "description": "patch release form",
        "in": "body",
        "name": "patch_release_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.PatchReleaseForm"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}",
    "method": "patch"
  },
  "repo.releases.assetUploadConfirmation.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PostReleaseAssetUploadConfirmation",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 确认 Release asset 上传完成",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      },
      {
        "description": "upload token",
        "in": "path",
        "name": "token",
        "required": true,
        "type": "string"
      },
      {
        "description": "release asset path",
        "in": "path",
        "name": "asset_path",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}/asset-upload-confirmation/{token}/{asset_path}",
    "method": "post"
  },
  "repo.releases.assetUploadUrl.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "PostReleaseAssetUploadURL",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 新增一个 Release asset",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      },
      {
        "description": "Post Release Asset Upload URL Form",
        "in": "body",
        "name": "create_release_asset_upload_url_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/openapi.PostReleaseAssetUploadURLForm"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created",
        "schema": {
          "$ref": "#/definitions/openapi.ReleaseAssetUploadURL"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}/asset-upload-url",
    "method": "post"
  },
  "repo.releases.assets.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:rw",
    "operationId": "DeleteReleaseAsset",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 删除指定的 release asset",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      },
      {
        "description": "asset id",
        "in": "path",
        "name": "asset_id",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}/assets/{asset_id}",
    "method": "delete"
  },
  "repo.releases.assets.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-code:r",
    "operationId": "GetReleaseAsset",
    "tags": [
      "Releases"
    ],
    "summary": "[openapi] 查询指定的 release asset",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "release id",
        "in": "path",
        "name": "release_id",
        "required": true,
        "type": "integer"
      },
      {
        "description": "asset id",
        "in": "path",
        "name": "asset_id",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.ReleaseAsset"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/releases/{release_id}/assets/{asset_id}",
    "method": "get"
  },
  "repo.settings.branchProtections.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "ListBranchProtections",
    "tags": [
      "GitSettings"
    ],
    "summary": "查询仓库保护分支规则列表(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/api.BranchProtection"
          },
          "type": "array"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/branch-protections",
    "method": "get"
  },
  "repo.settings.branchProtections.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "PostBranchProtection",
    "tags": [
      "GitSettings"
    ],
    "summary": "新增仓库保护分支规则(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Branch Protection Form",
        "in": "body",
        "name": "branch_protection_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.BranchProtection"
        }
      }
    ],
    "responses": {
      "201": {
        "description": "Created"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/branch-protections",
    "method": "post"
  },
  "repo.settings.branchProtections.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "DeleteBranchProtection",
    "tags": [
      "GitSettings"
    ],
    "summary": "删除仓库保护分支规则(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Branch Protection id",
        "in": "path",
        "name": "id",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/branch-protections/{id}",
    "method": "delete"
  },
  "repo.settings.branchProtections.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "GetBranchProtection",
    "tags": [
      "GitSettings"
    ],
    "summary": "查询仓库保护分支规则(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "branch protection id",
        "in": "path",
        "name": "id",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.BranchProtection"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/branch-protections/{id}",
    "method": "get"
  },
  "repo.settings.branchProtections.patch": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "PatchBranchProtection",
    "tags": [
      "GitSettings"
    ],
    "summary": "更新仓库保护分支规则(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Branch Protection id",
        "in": "path",
        "name": "id",
        "required": true,
        "type": "string"
      },
      {
        "description": "Branch Protection Form",
        "in": "body",
        "name": "branch_protection_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.BranchProtection"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/branch-protections/{id}",
    "method": "patch"
  },
  "repo.settings.cloudNativeBuild.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "GetPipelineSettings",
    "tags": [
      "GitSettings"
    ],
    "summary": "查询仓库云原生构建设置(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.PipelineSettings"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/cloud-native-build",
    "method": "get"
  },
  "repo.settings.cloudNativeBuild.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "PutPipelineSettings",
    "tags": [
      "GitSettings"
    ],
    "summary": "更新仓库云原生构建设置(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Cloud Native Build Form",
        "in": "body",
        "name": "pipeline_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/web.PipelineSettings"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/cloud-native-build",
    "method": "put"
  },
  "repo.settings.pullRequest.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "GetPullRequestSettings",
    "tags": [
      "GitSettings"
    ],
    "summary": "查询仓库合并请求设置(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.PullRequestSettings"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/pull-request",
    "method": "get"
  },
  "repo.settings.pullRequest.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "PutPullRequestSettings",
    "tags": [
      "GitSettings"
    ],
    "summary": "设置仓库推送设置(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Pull Request Form",
        "in": "body",
        "name": "pull_request_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PullRequestSettings"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/pull-request",
    "method": "put"
  },
  "repo.settings.pushLimit.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:r",
    "operationId": "GetPushLimitSettings",
    "tags": [
      "GitSettings"
    ],
    "summary": "查询仓库推送设置(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/api.PushLimitSettings"
        }
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/push-limit",
    "method": "get"
  },
  "repo.settings.pushLimit.put": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-manage:rw",
    "operationId": "PutPushLimitSettings",
    "tags": [
      "GitSettings"
    ],
    "summary": "设置仓库推送设置(openapi)",
    "parameters": [
      {
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "Push Limit Form",
        "in": "body",
        "name": "push_limit_form",
        "required": true,
        "schema": {
          "$ref": "#/definitions/api.PushLimitSettings"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "404": {
        "description": "Not Found",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      },
      "500": {
        "description": "Internal Server Error",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{repo}/-/settings/push-limit",
    "method": "put"
  },
  "repo.stars.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-basic-info:r",
    "operationId": "ListStarUsers",
    "tags": [
      "Starring"
    ],
    "summary": "获取指定仓库的star用户列表",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "我关注的",
        "enum": [
          "all",
          "followed"
        ],
        "in": "query",
        "name": "filter_type",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "page",
        "in": "query",
        "name": "page",
        "required": true,
        "type": "integer"
      },
      {
        "default": 10,
        "description": "page",
        "in": "query",
        "name": "page_size",
        "required": true,
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.RepoStarUsers"
        }
      }
    },
    "path": "/{repo}/-/stars",
    "method": "get"
  },
  "repo.topActivityUsers.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-base-info:r",
    "operationId": "TopContributors",
    "tags": [
      "Collaborators"
    ],
    "summary": "获取 top 贡献用户",
    "parameters": [
      {
        "description": "slug",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "default": 5,
        "description": "top几，不要超过10",
        "in": "query",
        "name": "top",
        "type": "integer"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.UsersResult"
          },
          "type": "array"
        }
      }
    },
    "path": "/{repo}/-/top-activity-users",
    "method": "get"
  },
  "repo.upload.files.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "UploadFiles",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个上传 files（issue，pr 及其评论中文档，压缩包等）的请求，返回上传 cos 的 url 和 form 内容",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "UploadRequestParams",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UploadRequestParams"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.UploadAssetsResponse"
        }
      }
    },
    "path": "/{repo}/-/upload/files",
    "method": "post"
  },
  "repo.upload.imgs.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "UploadImgs",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个上传 imgs 的请求，返回上传 cos 的 url 和 form 内容",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "UploadRequestParams",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UploadRequestParams"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.UploadAssetsResponse"
        }
      }
    },
    "path": "/{repo}/-/upload/imgs",
    "method": "post"
  },
  "repo.upload.releases.post": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-contents:rw",
    "operationId": "UploadReleases",
    "tags": [
      "Assets"
    ],
    "summary": "发起一个上传 release 附件的请求，返回上传 cos 的 url 和 form 内容",
    "parameters": [
      {
        "default": "test-group/test-repo",
        "description": "repo",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "tag_name",
        "in": "path",
        "name": "tagName",
        "required": true,
        "type": "string"
      },
      {
        "description": "UploadRequestParams",
        "in": "body",
        "name": "request",
        "required": true,
        "schema": {
          "$ref": "#/definitions/dto.UploadRequestParams"
        }
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.UploadAssetsResponse"
        }
      }
    },
    "path": "/{repo}/-/upload/releases/{tagName}",
    "method": "post"
  },
  "repo.workspace.detail.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nrepo-cnb-detail:r",
    "operationId": "GetWorkspaceDetail",
    "tags": [
      "Workspace"
    ],
    "summary": "根据流水线sn查询云原生开发访问地址",
    "parameters": [
      {
        "description": "仓库路径",
        "in": "path",
        "name": "repo",
        "required": true,
        "type": "string"
      },
      {
        "description": "构建号",
        "in": "path",
        "name": "sn",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.WorkspaceDetailResult"
        }
      }
    },
    "path": "/{repo}/-/workspace/detail/{sn}",
    "method": "get"
  },
  "slug.packages.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "ListPackages",
    "tags": [
      "Artifactory"
    ],
    "summary": "List all packages",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "all",
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "query",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "页码，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页数量",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "排序类型",
        "enum": [
          "pull_count",
          "last_push_at",
          "name_ascend",
          "name_descend"
        ],
        "in": "query",
        "name": "ordering",
        "type": "string"
      },
      {
        "description": "制品名搜索关键词",
        "in": "query",
        "name": "name",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.Package"
          },
          "type": "array"
        }
      },
      "400": {
        "description": "Bad Request",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{slug}/-/packages",
    "method": "get"
  },
  "slug.packages.head": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "HeadPackages",
    "tags": [
      "Artifactory"
    ],
    "summary": "Head all packages",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "all",
          "docker",
          "helm"
        ],
        "in": "query",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "页码，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页数量",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "排序类型",
        "enum": [
          "pull_count",
          "last_push_at",
          "name_ascend",
          "name_descend"
        ],
        "in": "query",
        "name": "ordering",
        "type": "string"
      },
      {
        "description": "制品名搜索关键词",
        "in": "query",
        "name": "name",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      },
      "400": {
        "description": "Bad Request"
      }
    },
    "path": "/{slug}/-/packages",
    "method": "head"
  },
  "slug.packages.type.quota.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "GetQuotaByProjectName",
    "tags": [
      "Artifactory"
    ],
    "summary": "Get quota of specific registry",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.QuotaRsp"
        }
      },
      "400": {
        "description": "Bad Request",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{slug}/-/packages/{type}/-/quota",
    "method": "get"
  },
  "slug.packages.type.quotas.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "GetQuotasByProjectName",
    "tags": [
      "Artifactory"
    ],
    "summary": "Get quotas of packages under one registry",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "页码，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页数量",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "排序类型",
        "enum": [
          "used_ascend",
          "used_descend"
        ],
        "in": "query",
        "name": "ordering",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.QuotaRsp"
          },
          "type": "array"
        }
      },
      "400": {
        "description": "Bad Request",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{slug}/-/packages/{type}/-/quotas",
    "method": "get"
  },
  "slug.packages.type.quotas.download.list": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "DownloadQuotasByProjectName",
    "tags": [
      "Artifactory"
    ],
    "summary": "Download registry quota details",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "页码，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页数量",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "排序类型",
        "enum": [
          "used_ascend",
          "used_descend"
        ],
        "in": "query",
        "name": "ordering",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "items": {
            "$ref": "#/definitions/dto.QuotaRsp"
          },
          "type": "array"
        }
      },
      "400": {
        "description": "Bad Request",
        "schema": {
          "$ref": "#/definitions/die.WebError"
        }
      }
    },
    "path": "/{slug}/-/packages/{type}/-/quotas/download",
    "method": "get"
  },
  "slug.packages.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "GetPackage",
    "tags": [
      "Artifactory"
    ],
    "summary": "Get the specific package",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品名称",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.PackageDetail"
        }
      }
    },
    "path": "/{slug}/-/packages/{type}/{name}",
    "method": "get"
  },
  "slug.packages.name.tag.delete": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package-delete:rw",
    "operationId": "DeletePackageTag",
    "tags": [
      "Artifactory"
    ],
    "summary": "Delete the specific tag under specific package",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品名称",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品标签",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK"
      }
    },
    "path": "/{slug}/-/packages/{type}/{name}/-/tag/{tag}",
    "method": "delete"
  },
  "slug.packages.name.tag.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "GetPackageTagDetail",
    "tags": [
      "Artifactory"
    ],
    "summary": "Get the specific tag under specific package",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品名称",
        "in": "path",
        "name": "name",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品标签",
        "in": "path",
        "name": "tag",
        "required": true,
        "type": "string"
      },
      {
        "description": "摘要，容器制品时必须",
        "in": "query",
        "name": "sha256",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.TagDetail"
        }
      }
    },
    "path": "/{slug}/-/packages/{type}/{name}/-/tag/{tag}",
    "method": "get"
  },
  "slug.packages.pkgname.tags.get": {
    "description": "访问令牌调用此接口需包含以下权限 \nregistry-package:r",
    "operationId": "ListPackageTags",
    "tags": [
      "Artifactory"
    ],
    "summary": "List all tags under specific package",
    "parameters": [
      {
        "description": "仓库 slug",
        "in": "path",
        "name": "slug",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品类型",
        "enum": [
          "docker",
          "helm",
          "maven",
          "npm",
          "ohpm"
        ],
        "in": "path",
        "name": "type",
        "required": true,
        "type": "string"
      },
      {
        "description": "制品名称",
        "in": "path",
        "name": "pkgname",
        "required": true,
        "type": "string"
      },
      {
        "default": 1,
        "description": "页码，从1开始",
        "in": "query",
        "name": "page",
        "type": "integer"
      },
      {
        "default": 10,
        "description": "每页多少条数据",
        "in": "query",
        "name": "page_size",
        "type": "integer"
      },
      {
        "description": "排序类型",
        "enum": [
          "pull_count",
          "last_push_at"
        ],
        "in": "query",
        "name": "ordering",
        "type": "string"
      },
      {
        "description": "搜索关键字",
        "in": "query",
        "name": "name",
        "type": "string"
      }
    ],
    "responses": {
      "200": {
        "description": "OK",
        "schema": {
          "$ref": "#/definitions/dto.Tag"
        }
      }
    },
    "path": "/{slug}/-/packages/{type}/{pkgname}/-/tags",
    "method": "get"
  }
}