diff --git a/app/docs/slate/source/includes/_projects.md b/app/docs/slate/source/includes/_projects.md index d4899a710..e133bcdda 100644 --- a/app/docs/slate/source/includes/_projects.md +++ b/app/docs/slate/source/includes/_projects.md @@ -849,4 +849,36 @@ await octokit.request('POST /api/:owner/:repo/applied_transfer_projects/cancel.j "created_at": "2021-04-26 09:54", "time_ago": "1分钟前" } +``` + +## 退出项目 +供项目成员(开发者、报告者)退出项目用 + +> 示例: + +```shell +curl -X POST http://localhost:3000/api/ceshi1/ceshi_repo1/quit.json +``` + +```javascript +await octokit.request('POST /api/:owner/:repo/quit.json') +``` + +### HTTP 请求 +`POST /api/:owner/:repo/quit.json` + +### 请求参数 +参数 | 必选 | 默认 | 类型 | 字段说明 +--------- | ------- | ------- | -------- | ---------- +|owner |是| |string |用户登录名 | +|repo |是| |string |项目标识identifier | + + +> 返回的JSON示例: + +```json +{ + "status": 0, + "message": "success" +} ``` \ No newline at end of file diff --git a/public/docs/api.html b/public/docs/api.html index 45da64400..8ef6924b9 100644 --- a/public/docs/api.html +++ b/public/docs/api.html @@ -467,6 +467,9 @@
  • 取消迁移项目
  • +
  • + 退出项目 +
  • @@ -6026,6 +6029,49 @@ http://localhost:3000/api/ceshi1/ceshi_repo1/applied_transfer_projects/organizat "created_at": "2021-04-26 09:54", "time_ago": "1分钟前" } +

    退出项目

    +

    供项目成员(开发者、报告者)退出项目用

    + +
    +

    示例:

    +
    +
    curl -X POST http://localhost:3000/api/ceshi1/ceshi_repo1/quit.json
    +
    await octokit.request('POST /api/:owner/:repo/quit.json')
    +

    HTTP 请求

    +

    POST /api/:owner/:repo/quit.json

    +

    请求参数

    + + + + + + + + + + + + + + + + + + + + + + + +
    参数必选默认类型字段说明
    ownerstring用户登录名
    repostring项目标识identifier
    + +
    +

    返回的JSON示例:

    +
    +
    {
    +    "status": 0,
    +    "message": "success"
    +}
     

    Repositories

    仓库详情

    仓库详情