Get List of Call Center Rooms
    • Dark
      Light
    • PDF

    Get List of Call Center Rooms

    • Dark
      Light
    • PDF

    Article summary

    Get
    /api/v1/voip/rooms

    Permissions required:

    • For an admin: view-livechat-rooms
    • For an agent: view-l-room
    Header parameters
    X-Auth-Token
    stringRequired

    The authToken of the authenticated user.

    ExampleRScctEHSmLGZGywfIhWyRpyofhKOiMoUIpimhvheU3f
    X-User-Id
    stringRequired

    The userId of the authenticated user.

    ExamplerbAXPnMktTFbNpwtJ
    Query parameters
    agents
    string

    List of agent information.

    Examplestring[]
    open
    string

    The status of the room. The value can be true or false.

    createdAt
    string

    The date and time when the room was created.

    Example2021-07-09T20:20:58.755Z
    closedAt
    string

    The date and time when the room was closed.

    Example2021-07-09T21:20:58.755Z
    tags
    string

    List of tag information.

    Examplestring[]
    queue
    string

    The ID assigned to the call (opaque ID).

    visitorId
    string

    The visitor ID.

    direction
    string

    The direction of the call.

    Exampleinbound
    roomName
    string

    The name of the room.

    ExampleThe name of the room.
    offset
    integer

    Number of items to "skip" in the query, i.e. requests return count items, skipping the first offset items.

    Example50
    count
    integer

    The number of items to return.

    Example25
    sort
    (object)

    List of fields to order by, and in which direction. JSON object, with properties listed in desired order, with values of 1 for ascending, or -1 for descending. For example, sort = {"value": -1, "_id": 1}

    fields

    This parameter accepts a JSON object with properties that have a value of 1 or 0 to include or exclude them in the response. For example, to only retrieve the usernames of users: fields = {"username": 1}

    Responses
    200

    OK

    Success Example
    {
      "room": {
        "_id": "kCJDd5peKiZnGJLPq",
        "fname": "Mary",
        "t": "l",
        "v": {
          "_id": "47Dajwh9DjpnTAugW",
          "username": "guest-165",
          "token": "8s7e9ony6ctl27e1qf8kue",
          "status": "offline",
          "lastMessageTs": "2021-07-09T20:20:58.755Z"
        },
        "departmentId": "CAJioQNAvLnYWTy8i",
        "default": false,
        "ro": false,
        "sysMes": true,
        "open": true,
        "msgs": 7,
        "ts": "2021-07-09T20:12:19.795Z",
        "_updatedAt": "2021-07-09T20:21:07.334Z",
        "lm": "2021-07-09T20:20:58.755Z",
        "customFields": {
          "salesforceCrmContactId": "0032y000009mtOIAAY"
        },
        "usersCount": 2,
        "cl": false,
        "departmentAncestors": [
          "sriw2wmP2Zz2pPrre"
        ],
        "lastMessage": {
          "_id": "SgrsSm3HNGrG5xTmk",
          "rid": "kCJDd5peKiZnGJLPq",
          "msg": "d",
          "token": "8s7e9ony6ctl27e1qf8kue",
          "alias": "Mary",
          "ts": "2021-07-09T20:20:58.755Z",
          "u": {
            "_id": "47Dajwh9DjpnTAugW",
            "username": "guest-165",
            "name": "Mary"
          },
          "_updatedAt": "2021-07-09T20:20:58.896Z",
          "urls": [],
          "mentions": [],
          "channels": [],
          "md": [
            {
              "type": "PARAGRAPH",
              "value": [
                {
                  "type": "PLAIN_TEXT",
                  "value": "d"
                }
              ]
            }
          ],
          "newRoom": false,
          "showConnecting": true
        },
        "metrics": {
          "reaction": {
            "fd": "2021-07-09T20:19:53.243Z",
            "ft": 23.821,
            "tt": 24.006
          },
          "response": {
            "avg": 226.4365,
            "fd": "2021-07-09T20:19:53.243Z",
            "ft": 452.688,
            "total": 2,
            "tt": 452.873
          },
          "v": {
            "lq": "2021-07-09T20:20:58.755Z"
          },
          "servedBy": {
            "lr": "2021-07-09T20:19:53.077Z"
          }
        },
        "servedBy": {
          "_id": "XycfA5CetCPuEjqxw",
          "username": "kim.jane",
          "ts": "2021-07-09T20:19:29.422Z"
        },
        "waitingResponse": true
      },
      "success": true
    }
    Expand All
    object
    room
    object
    _id
    string
    fname
    string
    t
    string
    v
    object
    _id
    string
    username
    string
    token
    string
    status
    string
    lastMessageTs
    string
    departmentId
    string
    default
    boolean
    ro
    boolean
    sysMes
    boolean
    open
    boolean
    msgs
    integer
    ts
    string
    _updatedAt
    string
    lm
    string
    customFields
    object
    salesforceCrmContactId
    string
    usersCount
    integer
    cl
    boolean
    departmentAncestors
    Array of string
    string
    lastMessage
    object
    _id
    string
    rid
    string
    msg
    string
    token
    string
    alias
    string
    ts
    string
    u
    object
    _id
    string
    username
    string
    name
    string
    _updatedAt
    string
    urls
    Array of object
    object
    mentions
    Array of object
    object
    channels
    Array of object
    object
    md
    Array of object
    object
    type
    string
    value
    Array of object
    object
    type
    string
    value
    string
    newRoom
    boolean
    showConnecting
    boolean
    metrics
    object
    reaction
    object
    fd
    string
    ft
    number
    tt
    number
    response
    object
    avg
    number
    fd
    string
    ft
    number
    total
    integer
    tt
    number
    v
    object
    lq
    string
    servedBy
    object
    lr
    string
    servedBy
    object
    _id
    string
    username
    string
    ts
    string
    waitingResponse
    boolean
    success
    boolean
    401

    Unauthorized

    Authorization Error
    {
      "status": "error",
      "message": "You must be logged in to do this."
    }
    object
    status
    string
    message
    string
    403

    Forbidden

    Example 1
    {
      "success": false,
      "error": "User does not have the permissions required for this action [error-unauthorized]"
    }
    Example 2
    {
      "success": false,
      "error": "unauthorized"
    }
    object
    success
    boolean
    error
    string

    Was this article helpful?

    Changing your password will log you out immediately. Use the new password to log back in.
    First name must have atleast 2 characters. Numbers and special characters are not allowed.
    Last name must have atleast 1 characters. Numbers and special characters are not allowed.
    Enter a valid email
    Enter a valid password
    Your profile has been successfully updated.