Self register (create user) using registration token
POST/login/registration/self-register
Given user data and a registration token, this will create a new user for the registration. The user will also be created in the backend.
For the creation to succeed, the registration token and the registration may not be expired yet.
Request
- application/json
Body
required
The register token issued during as result of the oauth registration flow. Scope of the token must contain "login-register".
Must be given.
The username to set for the new user. Must be given and cannot be empty
The name to display in the UI for the new user. Must be given and can't be empty
The email of the new user. Can be ommitted, but if given can't be empty.
Responses
- 200
- 201
- 400
- 401
If successful, the Default Return with operation 'self-register'
- application/json
- Schema
- Example (from schema)
Schema
A string representation of the operation performed
Possible values: [success
, failed
]
Default value: success
The result of the operation. Defaults to "success"
Default value: 2024-07-03T21:50:49.978Z
The time the operation was performed. Defaults to the current date+time
{
"operation": "self-register",
"result": "success",
"time": "2024-07-03T21:52:34.352Z"
}
- application/json
- Schema
- Example (from schema)
Schema
A string representation of the operation performed
Possible values: [success
, failed
]
Default value: success
The result of the operation. Defaults to "success"
Default value: 2024-07-03T21:50:49.978Z
The time the operation was performed. Defaults to the current date+time
{
"operation": "self-register",
"result": "success",
"time": "2024-07-03T21:52:34.352Z"
}
If any of the input data for the user creation are invalid or the username is already taken
If the given registration token is not/no longer valid or the registration time frame has expired