Users API

Organization & Account Management

Get the currently logged-in user

Retrieves the currently authenticated user's profile data. This is a GET operation. The JSON response contains user attributes such as email, name, role, and default account.

Create a new user

Creates a new user profile. This is a POST operation that accepts a JSON body and returns the created user object in JSON format.

post{hostname}/users
Body:
{
"country_id": "CA # Type: string",
"email": "daniel@sajmx.com # Type: string",
"first_name": "Jamie # Type: string",
"last_name": "Jackson # Type: string",
"other_id": "sdh23yv3bobe6yob82 # Type: string"
}

API Request Parameters

NameTypeRequired FieldDescription
country_idstringFalseUser Country code. Reference: https://gist.github.com/keeguon/2310008)
emailstringFalseUser email address
first_namestringFalseUser first name
last_namestringFalseUser last name
other_idstringFalseThis can represent the ID of an external system linked to the user

Update current user

Updates the current user's profile information. This is a PUT operation that accepts a JSON body and returns the updated user object.

Body:
{
"country_id": "CA # Type: string",
"email": "smith@cool.com # Type: string",
"first_name": "Smith # Type: string",
"last_name": "Pierre # Type: string",
"other_id": "12a3x34 # Type: string"
}

API Request Parameters

NameTypeRequired FieldDescription
country_idstringTrueCountry
emailstringTrueUser email
first_namestringTrueUser first name
last_namestringFalseUser last name
other_idstringFalseThis can represent the ID of an external system linked to the user

Delete current user

Deletes the currently authenticated user's profile. This is a DELETE operation. Returns HTTP 200 or 204 if the profile was removed.

Update current user's default account

Updates the default account associated with the currently authenticated user. This is a PUT operation that accepts a JSON object specifying the new default account ID.

Body:
{
"organization_id": "113 # Type: integer"
}

API Request Parameters

NameTypeRequired FieldDescription
organization_idintegerTrueThe numeric ID of the of the account

Find user's by their registration emails

Searches for a user by their registered email address. This is a GET operation. The JSON response containing the user's profile data if found.

API Request Parameters

NameTypeRequired FieldDescription
emailstringTrueThe registered email address of the user to look up. Type: string. Must be included in the URL path. Required.