From Bright Pattern Documentation
Jump to: navigation, search
m
Line 8: Line 8:
 
=== HTTP Method ===
 
=== HTTP Method ===
 
POST
 
POST
 +
 +
=== Content-Type ===
 +
application/json
 +
 +
=== Parameters ===
 +
{|border="1" style="border-collapse:collapse" cellpadding="5"
 +
| '''Parameter'''
 +
| '''Data-Type'''
 +
| '''Description'''
 +
| '''Example'''
 +
|-
 +
| loginId
 +
| string
 +
| The username of the new user
 +
| "sheila.thomas"
 +
|-
 +
| firstName
 +
| string
 +
| The first name of the new user
 +
| "Sheila"
 +
|-
 +
| lastName
 +
| string
 +
| The last name of the new user
 +
| "Thomas"
 +
|-
 +
| team
 +
| string
 +
| The name of the team assigned to the new user
 +
| "Customer Service"
 +
|-
 +
| email
 +
| string
 +
| The email address of the new user
 +
| "sheila.thomas@yourcompany.com"
 +
|-
 +
| roles
 +
| array
 +
| The role assigned to the new user
 +
| ["Agent"], ["Supervisor"]
 +
|}
 +
 +
=== Example Request Body Content ===
 +
<syntaxhighlight  lang="json">
 +
{
 +
"loginId" : "sheila.thomas",
 +
"firstName" : "Sheila",
 +
"lastName" : "Thomas",
 +
"team" : "Customer Service",
 +
"email": "sheila.thomas@yourcompany.com",
 +
"roles": ["Agent"]
 +
}
 +
</syntaxhighlight>
  
 
== Response ==
 
== Response ==
  {
+
In response to a successful request, the new user is created. Verify the new user in ''Contact Center Administrator > Users & Teams > [[5.3:Contact-center-administrator-guide/Users |  Users]]''.
  "loginId": "test008",
+
 
  "password": "top secret",
+
Failed requests result in an error code, and the user is not created.
  "firstName": "test",
+
 
  "lastName": "008",
+
=== Response Codes ===
  "team": "Maintenance Renewal",
+
{|border="1" style="border-collapse:collapse" cellpadding="5"
                   
+
| '''Code'''
  "extension": "2072",
+
| '''Description'''
  "workPhone": "123456",
+
|-
  "mobilePhone": "78910",
+
| 200 OK
  "email": "test008@nowhere.net",
+
| Success - user created
  "disabled": false,
+
|-
  "changePassword": true,
+
| 400
  "skills": {
+
| Bad request
  "Maintenance Renewal": 100,
+
|-
  "English": 33
+
| 405
  },
+
| Method not allowed
  "roles": [
+
|}
  "Agent",
+
 
  "Supervisor"
 
  ]
 
  }
 
  
  

Revision as of 23:55, 7 March 2019

• 5.2

<translate>= Create User= Creates a new user in the system.

Request

URL

http[s]://<host>/configapi/v2/user

HTTP Method

POST

Content-Type

application/json

Parameters

Parameter Data-Type Description Example
loginId string The username of the new user "sheila.thomas"
firstName string The first name of the new user "Sheila"
lastName string The last name of the new user "Thomas"
team string The name of the team assigned to the new user "Customer Service"
email string The email address of the new user "sheila.thomas@yourcompany.com"
roles array The role assigned to the new user ["Agent"], ["Supervisor"]

Example Request Body Content

 {
 "loginId" : "sheila.thomas",
 "firstName" : "Sheila",
 "lastName" : "Thomas",
 "team" : "Customer Service",
 "email": "sheila.thomas@yourcompany.com",
 "roles": ["Agent"]
 }

Response

In response to a successful request, the new user is created. Verify the new user in Contact Center Administrator > Users & Teams > Users.

Failed requests result in an error code, and the user is not created.

Response Codes

Code Description
200 OK Success - user created
400 Bad request
405 Method not allowed



</translate>

< Previous | Next >