Create dashboard user
Create a dashboard user
POST
/appid-{appId}/recipe/dashboard/userAuthorization
api-keyAPI key · headerrequiredThe core service API token. If you are using a self-hosted core service and you have not generated a token, you can omit the header.
Header parameters
ridstringcdi-versionstringX.Y of the X.Y.Z CDI version.
Request body
application/jsonemailstringpasswordstringResponses
200Indicates success with the status property
One of:
object
statusstringAllowed:
OKuserobjectShow propertiesHide properties
userIdstringemailstringtimeCreatednumberobject
statusstringAllowed:
EMAIL_ALREADY_EXISTS_ERRORobject
statusstringAllowed:
PASSWORD_WEAK_ERRORmessagestringobject
statusstringAllowed:
INVALID_EMAIL_ERROR400error code 400
string401error code 401
string402Indicates ayment required
statusstringAllowed:
USER_LIMIT_REACHED_ERRORmessagestring404error code 404
string500error code 500
stringTry it
Server
Authorization
Parameters
Bodyapplication/json
Request
curl -X POST "/appid-{appId}/recipe/dashboard/user" \
-H "api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"email": "[email protected]",
"password": "password@123"
}'const response = await fetch("/appid-{appId}/recipe/dashboard/user", {
method: "POST",
headers: {
"api-key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
body: JSON.stringify({
"email": "[email protected]",
"password": "password@123"
})
});import requests
response = requests.post(
"/appid-{appId}/recipe/dashboard/user",
headers={
"api-key": "YOUR_API_KEY",
"Content-Type": "application/json"
},
json={
"email": "[email protected]",
"password": "password@123"
},
)Response
{
"status": "OK",
"user": {
"userId": "example-userid",
"email": "[email protected]",
"timeCreated": 1231321231
}
}"string""Invalid API key"{
"status": "USER_LIMIT_REACHED_ERROR",
"message": "You have reached the free limit for creating users, please purchase the dashboard feature to create new users"
}"Not Found""Internal Error"