设置组织成员角色
根据用户名设置该用户在组织下的角色
Path Parameters
- org string required
组织命名空间
- username string required
要操作的用户的用户名
Header Parameters
- Authorization required
Oauth2 token或者私人token(需以Bearer加空格开头)
- application/json
Request Body
- role string
设定用户的角色:maintainer、developer、guest。
Responses
- 200
操作成功
- application/json
- Schema
- Example (from schema)
Schema
- url string
组织成员详细信息的openApi地址
- state string
组织状态
- role string
要查询组织成员角色
- organization_url string
组织详细信息的openApi地址
user object
被查询用户名详细信息
login string被查询的用户名
id string被查询的用户id
avatar_url string被查询的用户头像
url string被查询的用户详细信息的openApi地址
html_url string被查询的用户在atomgit访问地址
followers_url string被查询的用户followers地址
followering_url string被查询的用户followering地址
gists_url string被查询的用户gists地址
starred_url string被查询的用户starred地址
subscriptions_url string被查询的用户subscriptions地址
organizations_url string被查询的用户organizations地址
repos_url string被查询的用户repos地址
events_url string被查询的用户events地址
received_events_url string被查询的用户received events地址
type string被查询的用户类型
site_admin string被查询的用户是管理员
organization object
当前操作的组织信息
login string组织名称
id string组织id
url string组织的OepnApi地址
repos_url string组织的repos地址
events_url string组织的event地址
hooks_url string组织的hooks地址
issues_url string组织的issue地址
members_url string组织的members地址
public_members_url string组织的public members地址
avatar_url string组织头像地址
description string组织的描述
{
"url": "https://api.atomgit.com/orgs/csdn",
"state": "active",
"role": "maintainer",
"organization_url": "https://api.atomgit.com/orgs/csdn",
"user": {
"login": "mrpuatomgit",
"id": "63db126c0566d2f7d2c9498c",
"avatar_url": "https://img-host/uploads/user/1656318880150_5104.png",
"url": "https://api.atomgit.com/users/leige",
"html_url": "https://atomgit.com/mrpuatomgit",
"followers_url": null,
"followering_url": null,
"gists_url": null,
"starred_url": null,
"subscriptions_url": null,
"organizations_url": null,
"repos_url": null,
"events_url": null,
"received_events_url": null,
"type": "user",
"site_admin": false
},
"organization": {
"login": "csdn",
"id": "62b59720cbcaeffdff0148ce",
"url": "https://api.atomgit.com/orgs/csdn",
"repos_url": "https://api.atomgit.com/orgs/csdn/repos",
"events_url": "https://api.atomgit.com/orgs/csdn/events",
"hooks_url": "https://api.atomgit.com/orgs/csdn/hooks",
"issues_url": "https://api.atomgit.com/orgs/csdn_test2/issues",
"members_url": "https://api.atomgit.com/orgs/csdn/members/{/member}",
"public_members_url": "https://api.atomgit.com/orgs/csdn/public_members/{/member}",
"avatar_url": "https://img-host/uploads/org/1656042927816_7741.png",
"description": "csdn is a goog website"
}
}
Loading...