Skip to main content
POST
/
user
/
{user_id}
Update user
curl --request POST \
  --url https://api.partoo.co/v2/user/{user_id} \
  --header 'Content-Type: application/json' \
  --header 'x-APIKey: <api-key>' \
  --data '{
  "email": "perceval@kaamelott.com",
  "first_name": "Perceval",
  "last_name": "de Galles",
  "org_id": 123,
  "accesses": [
    [
      1,
      2
    ],
    [
      1,
      3
    ]
  ],
  "business_ids": [
    "<string>"
  ],
  "phone": "<string>",
  "role": "BUSINESS_MANAGER",
  "sidebar_pages": [
    "bulk_modification"
  ],
  "status": "active",
  "disabled": true,
  "password": "<string>",
  "lang": "fr",
  "sso_only": false,
  "keywords": [
    "<string>"
  ],
  "receive_reviews_email_notifications": true
}'
{
  "id": "5309c3a237bbc544d8e26737",
  "status": "success"
}

Authorizations

x-APIKey
string
header
required

The authentication system on Partoo API is using API Key that should be put in the header of the request (the name of the header is x-APIKey). An api_key is linked to a user. This user's role will give you different access level to the API features.

Path Parameters

user_id
string
required

User id

Body

application/json

Request body to update a user.

email
string<email>

User email

Example:

"perceval@kaamelott.com"

first_name
string

User first name

Example:

"Perceval"

last_name
string

User last name

Example:

"de Galles"

org_id
integer

Org to which the user should belong

accesses
integer[][]

List of (list of Group ID).

Accesses of the users for the new groups system, only for GROUP_MANAGER users.

See the Groups and Sections description

Example:
[[1, 2], [1, 3]]
business_ids
string[]

The list of business to which the user has access to. Will be taken into account only if user has BUSINESS_MANAGER role.

phone
string

User phone number

role
enum<string>

User role in the application

Available options:
ORG_ADMIN,
GROUP_MANAGER,
BUSINESS_MANAGER,
PUBLISHER
Example:

"BUSINESS_MANAGER"

sidebar_pages
enum<string>[]

List of features the user can access from the sidebar.

status
enum<string>

User status in the application

Available options:
active,
invited
Example:

"active"

disabled
boolean

The state of the User account.

password
string<password>

The User password. It should comply with the following rules:

  • should be at least 8 characters long
  • should have one upper case letter and one lower case letter
  • should have one special character
Minimum length: 8
lang
enum<string>

Available language in the application

Available options:
fr,
en,
es,
it,
pt-br,
de,
ar,
nl,
pl,
cs,
ca,
sk,
pt,
lv,
ro,
bg,
hu
Example:

"fr"

sso_only
boolean
default:false

Prevent the user from connecting directly from the Partoo connection page.

This field is available for users whose organization has defined an SSO configuration.

This field can be edited by a user with the role ORG_ADMIN or PROVIDER.

keywords
string[]

Array of keywords

Maximum length: 12
receive_reviews_email_notifications
boolean

The parameter decides if the user subscribes to negative reviews email notifications

Response

OK

id
string

User id

Example:

"5309c3a237bbc544d8e26737"

status
enum<string>
Available options:
success