Purpose: Retrieves a longest waiting task for the particular service (identified by ServiceId or Service SipUri) 

Request URI/v1.0/services/{service}/longestwaitingtask

Method

GET

ParametersDescription

service *
string

(path)

The identifier of a service. It could be a Guid ("4E99C65C-B0D6-48C2-9AD7-ADDC2086B473") string or Service's sip Uri (sip:test.service@yourdomain.com)

Responses

CodeDescription / Example 
200

Longest waiting task for the provided service.

{
  "Id": "string",
  "ExternalTaskId": "string",
  "Type": "string",
  "State": "string",
  "CustomerIdentifier": "string",
  "Created": "2019-06-14T08:35:12.246Z",
  "QueueStarted": "2019-06-14T08:35:12.246Z",
  "Connected": "2019-06-14T08:35:12.246Z",
  "InitialModalityType": "string",
  "OriginType": "string",
  "OriginTypeCustom": "string",
  "ContextParameters": [
    {
      "Name": "string",
      "Value": "string"
    }
  ],
  "ReservedUserObject": {
    "Id": "string",
    "DisplayName": "string",
    "OrganizationUnitName": "string",
    "SipUri": "string",
    "UserPrincipalName": "string",
    "SecurityIdentifier": "string",
    "SamAccountName": "string",
    "AgentProfileName": "string",
    "ResponsibleSinceLevel": 0,
    "SelectionAlgorithm": "string"
  }
}
CODE
500
{
  "Error": {
    "Code": "NotInitialized",
    "Message": "string"
  }
}
CODE