-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
849d86e
commit fdc561e
Showing
3 changed files
with
71 additions
and
3 deletions.
There are no files selected for viewing
64 changes: 64 additions & 0 deletions
64
...shboard/apigateway/apigateway/editions/ee/data/apidocs/zh/revoke_permissions.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
### 描述 | ||
|
||
回收蓝鲸应用访问网关资源的权限 | ||
|
||
### 输入参数 | ||
|
||
#### 路径参数 | ||
|
||
| 参数名称 | 参数类型 | 必选 | 描述 | | ||
| -------- | -------- | ---- | ------ | | ||
| api_name | string | 是 | 网关名 | | ||
|
||
#### 请求参数 | ||
|
||
| 参数名称 | 参数类型 | 必选 | 描述 | | ||
| ---------------- | -------- | ---- | --------------------------------- | | ||
| target_app_codes | array | 是 | 待回收权限的应用列表 | | ||
| grant_dimension | string | 是 | 授权维度,可选值:api(按网关授权) | | ||
|
||
### 请求参数示例 | ||
|
||
```json | ||
{ | ||
"target_app_codes": ["bk-sops"], | ||
"grant_dimension": "api" | ||
} | ||
``` | ||
|
||
### SDK 调用示例 | ||
|
||
```python | ||
from bkapi.bk_apigateway.shortcuts import get_client_by_request | ||
|
||
client = get_client_by_request(request) | ||
result = client.api.revoke_permissions( | ||
{ | ||
"target_app_codes": ["bk-sops"], | ||
"grant_dimension": "api" | ||
}, | ||
path_params={ | ||
"api_name": "demo", | ||
}, | ||
headers={"Content-Type": "application/json"}, | ||
) | ||
``` | ||
|
||
|
||
### 响应示例 | ||
|
||
```json | ||
{ | ||
"code": 0, | ||
"message": "OK", | ||
"data": null | ||
} | ||
``` | ||
|
||
### 响应参数说明 | ||
|
||
| 字段 | 类型 | 描述 | | ||
| ------- | ------ | ---------------------------------- | | ||
| code | int | 返回码,0 表示成功,其它值表示失败 | | ||
| message | string | 错误信息 | | ||
| data | object | 空 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters