core_users_service_account_create
POST/api/v3//core/users/service_account/
Create a new user account that is marked as a service account
Request
- application/json
Body
required
name stringrequired
Possible values: non-empty
create_group boolean
expiring boolean
Default value: true
expires date-time
If not provided, valid for 360 days
Responses
- 200
- 400
- 403
- application/json
- Schema
- Example (from schema)
Schema
username stringrequired
token stringrequired
user_uid stringrequired
user_pk integerrequired
group_pk string
{
"username": "string",
"token": "string",
"user_uid": "string",
"user_pk": 0,
"group_pk": "string"
}
- application/json
- Schema
- Example (from schema)
Schema
non_field_errors string[]
code string
{
"non_field_errors": [
"string"
],
"code": "string"
}
- application/json
- Schema
- Example (from schema)
Schema
detail stringrequired
code string
{
"detail": "string",
"code": "string"
}
- curl
- python
- go
- nodejs
- ruby
- csharp
- php
- java
- powershell
- CURL
curl -L -X POST '/api/v3/core/users/service_account/' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
--data-raw '{
"name": "string",
"create_group": false,
"expiring": true,
"expires": "2024-09-27T14:26:17.885Z"
}'