v1

latestOpenAPI 3.1.02026-07-132363652.9 MB
Users

Create a new user

Create a new user

post/api/v1/users

Request body

emailstring email required

User email address

first_namestring

First name of the user

last_namestring

Last name of the user

default_partner_idstring uuid

Default partner context

default_merchant_idstring uuid

Default merchant context

rolesstring[]

Initial roles to assign to the user

Example request

{
  "email": "user@example.com",
  "first_name": "John",
  "last_name": "Doe",
  "default_partner_id": "123e4567-e89b-12d3-a456-426614174001",
  "default_merchant_id": "123e4567-e89b-12d3-a456-426614174001",
  "roles": [
    "partner:admin:123e4567-e89b-12d3-a456-426614174001"
  ]
}

Response

Created

successboolean required

Indicates if the request was successful

Example response

{
  "success": true,
  "data": {
    "id": "123e4567-e89b-12d3-a456-426614174001",
    "email": "user@example.com",
    "first_name": "John",
    "last_name": "Doe",
    "default_partner_id": "123e4567-e89b-12d3-a456-426614174001",
    "default_merchant_id": "123e4567-e89b-12d3-a456-426614174001",
    "created_at": "2024-03-19T12:00:00Z",
    "updated_at": "2024-03-19T12:00:00Z",
    "role_assignments": [
      {
        "id": "123e4567-e89b-12d3-a456-426614174001",
        "role": "global:admin",
        "created_at": "2024-03-19T12:00:00Z"
      }
    ]
  }
}