邀请
邀请和管理组织的邀请。受邀用户将自动添加到 Default 项目中。
列出邀请
示例请求
1
2
3
curl https://api.openai.com/v1/organization/invites?after=invite-abc&limit=20 \
-H "Authorization: Bearer $OPENAI_ADMIN_KEY" \
-H "Content-Type: application/json"
响应
创建邀请
示例请求
1
2
3
4
5
6
7
curl -X POST https://api.openai.com/v1/organization/invites \
-H "Authorization: Bearer $OPENAI_ADMIN_KEY" \
-H "Content-Type: application/json" \
-d '{
"email": "user@example.com",
"role": "owner"
}'
响应
检索邀请
示例请求
1
2
3
curl https://api.openai.com/v1/organization/invites/invite-abc \
-H "Authorization: Bearer $OPENAI_ADMIN_KEY" \
-H "Content-Type: application/json"
响应
删除邀请
invite 对象
代表个人invite
到组织。
OBJECT 邀请对象
1
2
3
4
5
6
7
8
9
10
{
"object": "organization.invite",
"id": "invite-abc",
"email": "user@example.com",
"role": "owner",
"status": "accepted",
"invited_at": 1711471533,
"expires_at": 1711471533,
"accepted_at": 1711471533
}