Skip to main content
POST
/
user
/
Create User
curl --request POST \
  --url https://server26-dot-royalti-project.uc.r.appspot.com/user/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "firstName": "<string>",
  "lastName": "<string>",
  "nickName": "<string>",
  "userType": "<string>",
  "email": "jsmith@example.com",
  "ipi": "<string>",
  "role": "<string>",
  "phone": "<string>",
  "country": "<string>",
  "sendEmail": true,
  "redirect_url": "<string>",
  "message": "<string>"
}'
{
  "fullName": "Emmanuel Royalti",
  "phone": "+1234567890",
  "country": "Nigeria",
  "message": "Welcome to Royalti!",
  "sendEmail": true,
  "redirect_url": "https://app.royalti.io/welcome",
  "id": "3d5c9971-451e-4711-8874-ff498d55e601",
  "isVerified": false,
  "isActive": false,
  "firstName": "Emmanuel",
  "lastName": "Royalti",
  "TenantUsers": [
    {
      "UserId": "3d5c9971-451e-4711-8874-ff498d55e601",
      "TenantId": 1,
      "nickName": "iEmmanuel104",
      "userType": [
        "Artist"
      ],
      "paymentSettings": null,
      "lastLogin": null,
      "permissions": null
    }
  ],
  "email": "emmanuel@royalti.io",
  "updatedAt": "2023-02-19T11:26:45.512Z",
  "createdAt": "2023-02-19T11:26:45.512Z",
  "externalId": null,
  "ipi": null,
  "role": null
}
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Code Examples

const response = await fetch('https://server26-dot-royalti-project.uc.r.appspot.com/user/', {
  method: 'POST',
  headers: {
    'Authorization': `Bearer ${token}`,
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    "firstName": "sample-firstName",
    "lastName": "sample-lastName",
    "nickName": "sample-nickName",
    "userType": "sample-userType",
    "email": "sample-email",
    "ipi": "sample-ipi",
    "role": "sample-role",
    "phone": "sample-phone",
    "country": "sample-country",
    "sendEmail": true,
    "redirect_url": "sample-redirect_url",
    "message": "sample-message"
  })
});

const data = await response.json();
console.log(data);

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Body

application/json
firstName
string
required

The first name of the user

lastName
string
required

The last name of the user

nickName
string
required

The nickname of the user

userType
string
required

The type of user (e.g., Artist, Manager)

email
string<email>
required

The email address of the user

role
string
required

The role of the user in the workspace

ipi
string

The IPI (Interested Parties Information) of the user

phone
string

The user's phone number

country
string

The user's country

sendEmail
boolean
default:true

This sends an invite email to the user, by default it is true

redirect_url
string

The URL to redirect the user to after the creation

message
string

For passing the invite email custom message

Response

Success

fullName
string
id
string
isVerified
boolean
isActive
boolean
firstName
string
lastName
string
TenantUsers
object[]
email
string
updatedAt
string<date-time>
createdAt
string<date-time>
externalId
string | null
phone
string | null
country
string | null
ipi
string | null
role
string | null