Skip to content

Add user

POST
/users/add
curl --request POST \
--url https://acme.mykreezalid.com/api/v1/users/add \
--header 'Authorization: Basic <credentials>' \
--header 'Content-Type: application/json' \
--data '{ "email": "jane@example.com", "group_id": 784568, "password": "example", "avatar": "example", "external_id": "ABCdef123456", "account_type": "individual", "first_name": "Jane", "last_name": "Doe", "username": "janedoe", "business_name": "ACME", "address_line1": "example", "address_line2": "example", "address_city": "example", "address_zipcode": "example", "address_state": "example", "address_country": "US", "nationality": "US", "phone_country_code": "+1", "phone_number": "212-398-2600", "lang": "en", "timezone": "America/New_York" }'

Creates a user in an existing group. The answer always has the HTTP status 200: check success. When the user cannot be created, message says why: a sentence, or an object listing the invalid fields.

Media typeapplication/json
object
email
required

Must not be used by another user

string

Example

jane@example.com
group_id
required

Identifier of an existing group

integer

Example

784568
password

If you leave it out on creation, a random password is set: the user then chooses one with the password reset.

string
avatar

URL of an image to download and use as the profile image

string
external_id
string

Example

ABCdef123456
account_type
string
Allowed values: individual company non_profit soletrader
first_name
string

Example

Jane
last_name
string

Example

Doe
username
string

Example

janedoe
business_name
string

Example

ACME
address_line1
string
address_line2
string
address_city
string
address_zipcode
string
<= 20 characters
address_state
string
address_country

Two-letter country code. Defaults to your marketplace’s country on creation.

string

Example

US
nationality

Two-letter country code. Defaults to your marketplace’s country on creation.

string

Example

US
phone_country_code
string

Example

+1
phone_number
string

Example

212-398-2600
lang
string

Example

en
timezone

Defaults to your marketplace’s time zone on creation.

string

Example

America/New_York

Whether the user has been created

Media typeapplication/json
object
id

Identifier of the new user; null when it was not created

integer
nullable
success
boolean
message
One of:
string
content

Always empty

Array

Example

{
"id": 545353,
"success": true,
"message": "User created"
}