Query All the YMP Users

HTTP method and endpoint

GET /api/v1/system/users

Request parameters

Parameter Importance Type Description
pageNumber Optional Integer Defines which page is displayed.
pageSize Optional Integer Defines how many records per page.
sort Optional String Defines the sorting field.
  • id: Displays the YMP users by the id order.
order Optional String Defines the sorting order.
  • asc: Displays the YMP users by the ascending order.
  • desc: Displays the YMP users by the descending order.

Response parameters

YMP User Information

Parameter Type Description
id Integer User ID.
name String Name.
externalId String External ID.
email String Email address.
phoneNumber String Phone number.
userMode String User mode.
  • regular: YMP regular user.
  • hosting: YMP hosting user.
extension Integer How many extensions the user owns.
concurrentCall Integer How many concurrent calls the user owns.
recordingCapacity Integer How many recording capacity the user owns.
instance Integer How many PBX instances the user owns.
minExtension Integer The minimum extensions the user owns.

Page Information

Parameter Type Description
list Array<SystemUser> YMP user list.
total Integer The total number of YMP users.
pageSize Integer How many records per page.

Examples

Request example

  • Display the page 1.
  • Display 2 users per page.
  • Display the users by the ascending order.
GET /api/v1/system/users?pageSize=2&amp;pageNumber=1&amp;order=asc HTTP/1.1
Host: ympapi.yeastarcloud.com
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJsb2dpbl9uYW1lIjoiY2VjaWxpYUB5ZWFzdGFyLmNvbSIsInNjb3BlIjpbInRydXN0Il0sImV4cCI6MTU0NjkzNTg1OCwiYXV0aG9yaXRpZXMiOlsiUk9MRV9hZG1pbiJdLCJqdGkiOiJlNzJkMjNlYi03NjdhLTRhZmItYjQ2Zi03YzYxNmJmN2EzYjgiLCJjbGllbnRfaWQiOiI5Nzg5OTNmMDk2YzQ0MTFmYTljYzgwZWUyZTYyZjFmMiJ9.1HyxxEGbGNDc9A4ihm-dXGoKRhFh_YKYeOrNgt1IhRc
Cache-Control: no-cache

Response example

HTTP/1.1 200 OK
{
    "status": "Success",
    "users": {
        "list": [
            {
                "email": "liam@yeastar.com",
                "externalId": "",
                "id": 192,
                "name": "liam",
                "phoneNumber": "",
                "userMode": "regular"
            },
            {
                "email": "fannie@yeastar.com",
                "externalId": "",
                "id": 193,
                "name": "fannie",
                "phoneNumber": "",
                "userMode": "regular"
            }
        ],
        "pageSize": 2,
        "total": 20
    }
}