Update current user account data

Circularo REST API example

Updates logged in user account information and preferences. Then uploads new profile photo.

Step 1 - Sign in

Sign user in.

Endpoint

POST - /login

Example

/login

Content-Type: application/json

{
  "name": "mary.griffin@circularo.com",
  "password": "#32Password1!",
  "tenant": "default"
}

Response

Note following properties in response object:

  • token - In response object at position ‘token‘. It may have value of “gwYagjrjmTI4h0ycaN8X9MNW1miSZbmSTfA1wWJumRciyaBfiGEoPU2CxTjbpMBv“.

Step 2 - Update user account information

Updates user full name, phone and role information.

Endpoint

PUT - /configuration

Example

/configuration?token=gwYagjrjmTI4h0ycaN8X9MNW1miSZbmSTfA1wWJumRciyaBfiGEoPU2CxTjbpMBv

Content-Type: application/json

{
  "fullname": "Mary N. Griffin",
  "phone": "+123456789",
  "role": "PR Manager"
}

Step 3 - Update user preferences

Updates user language and notification preferences.

Endpoint

PUT - /configuration/config

Example

/configuration/config?token=gwYagjrjmTI4h0ycaN8X9MNW1miSZbmSTfA1wWJumRciyaBfiGEoPU2CxTjbpMBv

Content-Type: application/json

{
  "language": "en",
  "notifications": {
    "inApp": [
      "documentSigned",
      "itemArchived",
      "mention",
      "newItemInInbox",
      "rightsAdded",
      "shareForSign",
      "shareForView",
      "shareUserIsYou",
      "shareViewed",
      "shareReminder",
      "shareCancelled"
    ],
    "mail": [
      "documentSigned",
      "itemArchived",
      "newItemInInbox",
      "mention",
      "rightsAdded",
      "shareForSign",
      "shareForView",
      "shareRejected",
      "shareUserIsYou",
      "shareViewed",
      "shareReminder",
      "shareExpired",
      "shareCancelled"
    ],
    "enableAlerts": false
  }
}

Step 4 - Update profile photo

Updates profile photo.

Endpoint

PUT - /configuration/images

Example

/configuration/images?token=gwYagjrjmTI4h0ycaN8X9MNW1miSZbmSTfA1wWJumRciyaBfiGEoPU2CxTjbpMBv

Content-Type: multipart/form-data

{
  "photo": "blob"
}

Step 5 - Sign out (Optional)

Sign user out.

Endpoint

GET - /logout

Example

/logout?token=gwYagjrjmTI4h0ycaN8X9MNW1miSZbmSTfA1wWJumRciyaBfiGEoPU2CxTjbpMBv