QueryJobsWithResult

Updated at:

Queries tasks based on task results.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

outboundbot:QueryJobsWithResult

get

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

PageNumber

integer

No

The page number.

1

PageSize

integer

No

The number of entries per page.

10

JobGroupId

string

Yes

The ID of the job group.

ad16fc35-d824-4102-a606-2be51c1aa6dd

QueryText

string

No

The search content. You can search by phone number.

1882020****

JobStatusFilter

string

No

The job status filter. Valid values:

  • Scheduling: Scheduling in progress.

  • Executing: Executing in progress.

  • Succeeded: Ended - Reached.

  • Paused: Paused.

  • Failed: Ended - Not reached.

  • Cancelled: Cancelled - Manual intervention.

Succeeded

HasAnsweredFilter

boolean

No

Specifies whether the call is answered.

true

HasHangUpByRejectionFilter

boolean

No

Specifies whether the call is hung up due to rejection.

false

HasReachedEndOfFlowFilter

boolean

No

Specifies whether the call has reached the end of the flow.

true

InstanceId

string

Yes

The instance ID.

9d53cd72-4050-4419-8c17-acc0bf158147

TaskStatusFilter

string

No

The call status. Example: ["Executing","Succeeded"]. Separate multiple values with commas.

Valid values:

(Note: The Succeeded status has been subdivided into specific reasons. The general Succeeded: 1 (Connected) status is no longer returned. Instead, specific sub-reason types are returned.)

  • Executing: 0 (Calling).

  • Succeeded: 1 (Connected).

  • NoAnswer: 2 (Not connected - No answer).

  • NotExist: 3 (Not connected - Nonexistent number).

  • Busy: 4 (Not connected - Busy).

  • Cancelled: 5 (Not dialed - Task stopped).

  • Failed: 6 (Failed).

  • NotConnected: 7 (Not connected - Unreachable).

  • PoweredOff: 8 (Not connected - Powered off).

  • OutOfService: 9 (Not connected - Callee out of service).

  • InArrears: 10 (Not connected - Callee has overdue payment).

  • EmptyNumber: 11 (Not dialed - Nonexistent number, no outbound call).

  • PerDayCallCountLimit: 12 (Not dialed - Daily limit exceeded).

  • ContactBlockList: 13 (Not dialed - Blacklisted).

  • CallerNotRegistered: 14 (Not dialed - Caller number not registered).

  • Terminated: 15 (Not dialed - Terminated).

  • VerificationCancelled: 16 (Not dialed - Pre-call verification failed, cancelled).

  • OutOfServiceNoCall: 17 (Not dialed - Callee out of service, no outbound call).

  • InArrearsNoCall: 18 (Not dialed - Callee has overdue payment, no outbound call).

  • CallingNumberNotExist: 19 (Not dialed - Caller number does not exist).

  • SucceededFinish: 20 (Connected - Normal completion).

  • SucceededChatbotHangUpAfterNoAnswer: 21 (Connected - Robot hung up after no recognition).

  • SucceededChatbotHangUpAfterSilence: 22 (Connected - Hung up due to silence timeout).

  • SucceededClientHangUpAfterNoAnswer: 23 (Connected - User hung up after no recognition).

  • SucceededClientHangUp: 24 (Connected - User hung up without reason).

  • SucceededTransferByIntent: 25 (Connected - Transferred to agent by intent match).

  • SucceededTransferAfterNoAnswer: 26 (Connected - Transferred to agent after no recognition).

  • SucceededInoInterAction: 27 (Connected - No interaction from user).

  • SucceededError: 28 (Connected - System exception interruption).

  • SucceededSpecialInterceptVoiceAssistant: 29 (Connected - Special intercept - Voice assistant).

  • SucceededSpecialInterceptExtensionNumberTransfer: 30 (Connected - Special intercept - Extension number transfer).

  • SucceededSpecialInterceptCustomSpecialIntercept: 31 (Connected - Special intercept - Custom intercept).

  • HighRiskSipCode: 32 (Not dialed - High risk, no outbound call).

["Executing"]

JobFailureReasonsFilter

string

No

The list of job failure reasons.

Valid values:

  • NoAnswer :

    no answer.

  • PerDayCallCountLimit :

    daily call count limit for the number.

  • InArrears :

    overdue payment.

  • OutOfService :

    out of service.

  • NoStrategy :

    strategy is empty or not found.

  • EmptyNumber :

    nonexistent number, no further outbound calls.

  • JobPerDayCallCountLimit :

    daily call count limit for the number.

  • NoneRepeatableJobMaxAttemptCountLimit :

    maximum attempt count for the task, effective when RepeatBy (@see) is None.

  • ContactSuspended :

    call suspended.

  • VerificationCancelled :

    cancelled due to pre-call verification failure.

  • Unknown :

    unknown error.

  • InvalidStrategy :

    invalid strategy, incorrect strategy configuration.

  • TimeUp :

    timeout detected during scheduling.

  • CallFailed :

    call failed.

  • ContactBlockList :

    outbound call blocklist.

["NoAnswer"]

StartActualTimeFilter

integer

No

The filter condition for the call start time.

1579055782000

EndActualTimeFilter

integer

No

The filter condition for the call end time.

1579055783000

LabelsJson

array

No

The label-based filter condition for calls.

Note

This condition supports filtering only by labels that have specific enumerated label values configured, that is, labels with specific label values configured in large language model scenarios.

string

No

The label and its corresponding values to filter by.

Note

Filters all calls that match a specific label and its specific values. For example, {"ValueList":["Satisfied","Unsatisfied"],"Name":"Satisfaction"} filters call information where the "Satisfaction" label has a value of "Satisfied" or "Unsatisfied".

{ "ValueList": [ "Satisfied", "Not satisfied" ], "Name": "Satisfaction" }

Response elements

Element

Type

Description

Example

object

The response object.

HttpStatusCode

integer

The HTTP status code.

200

Code

string

Code

OK

Message

string

The prompt message returned by the operation.

Success

RequestId

string

The request ID.

9bdaa1d1-a036-4451-ab11-ca0373679091

Success

boolean

Indicates whether the request was successful.

true

VariableNames

array

The label names to be collected.

string

The complete set of label keys.

Whether connected

Jobs

object

The jobs.

PageNumber

integer

The page number.

1

PageSize

integer

The number of entries per page.

10

PageCount

integer

The total number of pages.

1

RowCount

integer

The total number of entries.

1

List

array<object>

The job list.

array<object>

The job object.

Status

string

The job status. Valid values:

  • Scheduling(0, "Scheduling")

  • Executing(1, "Executing")

  • Succeeded(2, "Ended - Reached")

  • Paused(3, "Paused")

  • Failed(4, "Ended - Not reached")

  • Cancelled(5, "Cancelled - Manual intervention")

  • Drafted(6, "Draft")

Succeeded

StatusName

string

The job status name.

结束-已触达

JobFailureReason

string

The job failure reason.

- Unknown(未知错误) - NoAnswer(无人接听) - InvalidStrategy(无效的策略,策略配置不正确) - TimeUp(调度时发现超时) - NoStrategy(策略为空或没有找到) - CallFailed(呼叫失败) -PerDayCallCountLimit(号码每日呼叫次数限制) - ContactBlockList(禁止外呼名单) - EmptyNumber(空号不再外呼) - JobPerDayCallCountLimit(号码每日呼叫次数限制) - VerificationCancelled(呼叫前验证不通过取消) - ContactSuspended(止呼) - InArrears(欠费) - OutOfService(停机) - NoneRepeatableJobMaxAttemptCountLimit( 任务最大尝试次数, 当RepeatBy(@see )为None时生效)

Id

string

The job ID.

cc231a1d-3c05-4739-8926-193ecf4097ba

LatestTask

object

The latest call.

Status

string

The call status.

Succeeded

TaskEndReason

string

The call result.

FINISHED

HasAnswered

boolean

Indicates whether the call was answered.

true

CallDuration

integer

The call duration.

40000

HasReachedEndOfFlow

boolean

Specifies whether the call reached the end of the flow.

true

StatusName

string

The call status name.

未呼出-超出每日上限

CallTime

integer

The call time.

1615363297000

CallDurationDisplay

string

The call duration.

40

HasHangUpByRejection

boolean

Specifies whether the call was hung up due to rejection.

false

Extras

array<object>

The label names to be collected.

object

The pass-through parameter object.

Key

string

The label key.

是否已经接通

Value

string

The label value.

TagHits

array<object>

The label hit information (returned by the legacy canvas).

object

The label hit object (returned by the legacy canvas).

TagName

string

The label name.

猫幼年期,猫幼年期

TagGroup

string

The label group to which the label belongs.

动物

Contact

object

The contact.

Round

integer

The round number.

151

JobUuid

string

The job ID.

cc231a1d-3c05-4739-8926-193ecf4097ba

PreferredPhoneNumber

string

The phone number specified by the callee during the conversation. If provided, this number is actually dialed.

Note

Custom-defined by the customer. Passed in JSON format when calling the API to execute an outbound call task.

134123****

PhoneNumber

string

The phone number of the contact.

1882020****

State

string

The status of the contact, such as Available, WrongNumber, or DoesNotExist.

Note

Custom-defined by the customer. Passed in JSON format when calling the API to execute an outbound call task.

Available

Honorific

string

The honorific for the contact. If not specified, it defaults to the same value as the name.

Note

Custom-defined by the customer. Passed in JSON format when calling the API to execute an outbound call task.

张先生

Name

string

The name of the contact.

张三

Role

string

The role of the contact in this outbound call scenario. If not specified, no role distinction is made. For example, in a debt collection scenario, contact roles can include borrower, co-borrower, and guarantor.

Note

Custom-defined by the customer. Passed in JSON format when calling the API.

借款人

Id

string

The contact ID. A unique identifier generated by the system when the outbound call list is uploaded.

63860deb-6218-45df-b1e0-76f2b166e790

ReferenceId

string

The contact ID uploaded by the customer. This must be provided by the business side to avoid duplicate name issues.

C01

HasLastPlaybackCompleted

boolean

Indicates whether the playback was completed when the call was hung up.

true

DialExceptionCodes

array<object>

The call exception codes.

object

The call exception codes.

Code

string

The error code.

0

Hint

string

The error message.

HangUpDirection

string

被叫用户

VoiceName

string

Labels

array<object>

The label information that can be used as filter conditions.

object

The label object.

Name

string

The label name.

Satisfied or not

ValueList

array

The list of label values.

string

The label value.

["No","Yes"]

Examples

Success response

JSON format

{
  "HttpStatusCode": 200,
  "Code": "OK",
  "Message": "Success",
  "RequestId": "9bdaa1d1-a036-4451-ab11-ca0373679091",
  "Success": true,
  "VariableNames": [
    "是否已经接通"
  ],
  "Jobs": {
    "PageNumber": 1,
    "PageSize": 10,
    "PageCount": 1,
    "RowCount": 1,
    "List": [
      {
        "Status": "Succeeded",
        "StatusName": "结束-已触达",
        "JobFailureReason": "- Unknown(未知错误)\n- NoAnswer(无人接听)\n- InvalidStrategy(无效的策略,策略配置不正确)\n- TimeUp(调度时发现超时)\n- NoStrategy(策略为空或没有找到)\n- CallFailed(呼叫失败)\n-PerDayCallCountLimit(号码每日呼叫次数限制)\n- ContactBlockList(禁止外呼名单)\n- EmptyNumber(空号不再外呼)\n- JobPerDayCallCountLimit(号码每日呼叫次数限制)\n- VerificationCancelled(呼叫前验证不通过取消)\n- ContactSuspended(止呼)\n- InArrears(欠费)\n- OutOfService(停机)\n- NoneRepeatableJobMaxAttemptCountLimit( 任务最大尝试次数, 当RepeatBy(@see )为None时生效)",
        "Id": "cc231a1d-3c05-4739-8926-193ecf4097ba",
        "LatestTask": {
          "Status": "Succeeded",
          "TaskEndReason": "FINISHED",
          "HasAnswered": true,
          "CallDuration": 40000,
          "HasReachedEndOfFlow": true,
          "StatusName": "未呼出-超出每日上限",
          "CallTime": 1615363297000,
          "CallDurationDisplay": "40",
          "HasHangUpByRejection": false,
          "Extras": [
            {
              "Key": "是否已经接通",
              "Value": "是"
            }
          ],
          "TagHits": [
            {
              "TagName": "猫幼年期,猫幼年期",
              "TagGroup": "动物"
            }
          ],
          "Contact": {
            "Round": 151,
            "JobUuid": "cc231a1d-3c05-4739-8926-193ecf4097ba\n",
            "PreferredPhoneNumber": "134123****",
            "PhoneNumber": "1882020****",
            "State": "Available",
            "Honorific": "张先生",
            "Name": "张三",
            "Role": "借款人",
            "Id": "63860deb-6218-45df-b1e0-76f2b166e790",
            "ReferenceId": "C01"
          },
          "HasLastPlaybackCompleted": true,
          "DialExceptionCodes": [
            {
              "Code": "0",
              "Hint": "无"
            }
          ],
          "HangUpDirection": "被叫用户",
          "VoiceName": ""
        }
      }
    ]
  },
  "Labels": [
    {
      "Name": "是否满意",
      "ValueList": [
        "[\"否\",\"是\"]"
      ]
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

500 InternalError An error occurred while processing your request. Please try again later. Submit a ticket if the error still exists.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.