Up - API Reference - Home
Requires JWT.
Deactivate an API user.
A deactivated user can no longer access the project.
Only the owner of the project can deactivate an API user.
POST /api/p/<project gid>/apikeys/deactivate
Authorization: Bearer <JWT>
{
"user": "<api user gid>",
}
user
an API user's gid for this project.
Authorization: <JWT>
{
"success": true,
"result": {
"user": "<api user gid>",
},
"data": {
"cc.users": {
"<api user gid>": {
"gid": "<api user gid>",
"name": "Import/export data",
"avatar": null,
"username": null
},
},
"cc.projects_members": [
{
"project_gid": "<project gid>",
"user_gid": "<api user gid>",
"status": "inactive",
"roles": [
"api"
],
"options": {
"rate_limit_per_second": null
}
}
]
}
}
user
is the API user's gid.
cc.users
is a dictionary with an entry for the API user.
cc.projects_members
is a list with updated metadata for the API user for this project.
401
Unauthorized - missing or expired JWT
403
Forbidden - not the owner of this project
422
Unprocessable entity - deactivation failed