Introduction

Authentication

Test cards

Establishments

Users

Customers

Cards

Payment links

Error codes

Payment Split

Products

Discount Coupons

Sales

Signatures

Webhooks

Financial


On this page:


POST Add user

https://api.premepay.com/v1/users

Follow the route above to make a request and add a new user to use the API. You will need to send the request containing some mandatory fields. Below, you can view our List of Field Descriptions for Adding User.

<aside> <img src="/icons/light-bulb_red.svg" alt="/icons/light-bulb_red.svg" width="40px" /> Business type users have access to all the Stores associated with a Business, while Store type users have access only to the Store they are associated with.

</aside>

List of Parameters

Parameter Type Description Required
name string Name Yes
username email Email Yes
password string Password Yes
permission object Permission No
entityId int Identifier Yes
entityType string Store or Business Yes
role int Permission level Yes

Role is related to the user's access level and accepts the following integer values.

EntityId is the ID of the store or business where the user will have access.

Role Permission level
0 Owner
1 Administrator
2 Agent
3 ViewOnly
4 API

Example of a request for creating Business type users:

This is an example of how your request should look like for creating Business type users.

Response

If your request is successful, you will receive the user object as the response.

If your request has invalid creation parameters - for example, specifying an invalid field or value - you may receive an error response. Below is the complete list of possible responses:

Example of a request for creating Store type users

This is an example of how your request should look like for creating Store type users.

Responses

If your request is successful, you will receive the user object as the response.


Related Content

<aside> <img src="https://s3-us-west-2.amazonaws.com/secure.notion-static.com/bfe6a9ef-6d9a-405e-9fbe-484666d3fb5e/PUT.png" alt="https://s3-us-west-2.amazonaws.com/secure.notion-static.com/bfe6a9ef-6d9a-405e-9fbe-484666d3fb5e/PUT.png" width="40px" /> PUT - Edit user

</aside>

<aside> <img src="https://s3-us-west-2.amazonaws.com/secure.notion-static.com/a22a31f7-bd92-40af-8042-7685c0c0859a/GET.png" alt="https://s3-us-west-2.amazonaws.com/secure.notion-static.com/a22a31f7-bd92-40af-8042-7685c0c0859a/GET.png" width="40px" /> GET - Get user

</aside>