Create User

Create User

API creates user group in keycloak. Username must be unique (password value must be of min. length 8, atleast contains 1 uppercase character, lowercase character, special character, digit)

Request
URI
POST
https://{api_host}/tcsa.host.com/tcsa/api/auth-management/v1/users
COPY
Request Body

describes keycloak user

KeycloakUser of type(s) application/json
Required
{
    "id": "c43add41-7fe0-4821-bc25-ef503abb9008",
    "createdTimestamp": "number",
    "username": "oper",
    "firstName": "oper",
    "lastName": "NGINX",
    "enabled": true,
    "emailVerified": false,
    "disableableCredentialTypes": [
        "string"
    ],
    "requiredActions": [
        "string"
    ],
    "notBefore": "number",
    "attributes": {
        "attributes": [
            "string"
        ]
    },
    "realmRoles": [
        "string"
    ],
    "clientRoles": {},
    "access": {},
    "groups": [
        "/Oper"
    ],
    "credentials": [
        {
            "type": "password",
            "value": "Oper@123",
            "temporary": false
        }
    ],
    "email": "string",
    "origin": "string",
    "self": "string"
}
string
id
Optional

user id

number
createdTimestamp
Optional

user created time

string
username
Optional

username of the user

string
firstName
Optional

firstName of the user

string
lastName
Optional

lastName of the user

boolean
enabled
Optional

enabled

boolean
emailVerified
Optional

email verified

array of string
disableableCredentialTypes
Optional

array of disableable Credential Types

array of string
requiredActions
Optional

array of requiredActions

number
notBefore
Optional

not Before

object
attributes
Optional

contains all attributes of user

array of string
realmRoles
Optional

array of realm roles

object
clientRoles
Optional

contains all client roles

object
access
Optional

contails access permissions of the group

array of string
groups
Optional

contains the group info

array of object
credentials
Optional

contains the user credentials

string
email
Optional

email of the user

string
origin
Optional

origin of the user

string
self
Optional

self of the user

Authentication
This operation uses the following authentication methods.
Responses
201

OK

Operation doesn't return any data structure

400

Invalid Request sent by the user

Returns KeycloakErrorDetails of type(s) application/json
{
    "error": "string"
}
string
error
Optional

Error message from keycloak


401

User authentication failed

Returns KeycloakErrorDetails of type(s) application/json
{
    "error": "string"
}
string
error
Optional

Error message from keycloak


403

Access to the requested resource/operation is forbidden

Returns KeycloakErrorDetails of type(s) application/json
{
    "error": "string"
}
string
error
Optional

Error message from keycloak


404

Cannot find requested resource

Returns KeycloakErrorDetails of type(s) application/json
{
    "error": "string"
}
string
error
Optional

Error message from keycloak


500

Internal server error

Returns KeycloakErrorDetails of type(s) application/json
{
    "error": "string"
}
string
error
Optional

Error message from keycloak