Updated on 2023-09-27 GMT+08:00

Querying the Retry Policy of an Outbound Campaign

Prerequisites

  • You have applied for a developer account.
  • For intelligent outbound calls, the customer needs to develop the IVR. For details, see IVR IDE User Guide.

Scenario

This interface is invoked to query the retry policy of a specified outbound campaign.

Method

This interface supports only the GET method.

URI

https://ip:port/rest/isales/v1/openapi/campaigns/{vdnId}/retryPolicy/{campaignId}

In the URL, ip indicates the IP address of the CC-iSales server, and port indicates the HTTPS port number of the CC-iSales server.

Table 1 Parameters in the URL

No.

Parameter

Type

Mandatory or Not

Description

1

vdnId

Integer

Yes

VDN ID.

The value is an integer ranging from 1 to 9999.

2

campaignId

Integer

Yes

ID of an outbound campaign.

Request Description

Table 2 Request header parameters

No.

Parameter

Type

Mandatory or Not

Description

1

Content-Type

String

Yes

The value is fixed to application/json; charset=UTF-8.

2

Authorization

String

Yes

For details about the generation mode, see C2 Monitoring, System Outbound Call, CDR, and Knowledge Base Interface Authentication.

No request body exists.

Response Description

Table 3 Response body parameters

No.

Parameter

Type

Description

1

resultCode

String

Error code. The value 0200000 indicates success, and other values indicate failure.

For details, see Table 8.

2

resultDesc

String

Description.

3

data

Object

Outbound call retry policy. For details, see Table 4.

4

returnCode

String

Error code. The value 0200000 indicates success, and other values indicate failure.

For details, see Table 8.

5

returnDesc

String

Description.

Table 4 Parameter description of data

No.

Parameter

Type

Description

3.1

retryPolicyId

String

Retry policy ID.

3.2

policyType

Integer

Retry policy type.

  • 0: global policy
  • 1: number classification policy

3.3

policyJson

String

Retry policy parameters. For details, see Table 5.

3.4

noRetryPolicy

String

Result codes for which no retry policy is configured. The result codes come from the resultCode field in the data attribute of the interface for querying the definitions of outbound call results.

3.5

busiPolicy

String

False

JSON string of the business result policy.

For details about the parameters of this object, see Table 6.

Table 5 Parameter description of policyJson

No.

Parameter

Type

Description

3.3.1

dataType

String

Number type.

3.3.2

policy

String

JSON string of the policy that is matched based on the result.

For details about the parameters of this object, see Table 7.

3.3.3

retryDay

Integer

Number of call attempt days in a common policy.

3.3.4

retryTimes

Integer

Number of call attempts per day in a common policy.

3.3.5

type

Integer

Retry logic policy type.

  • 0: common policy
  • 1: result policy
Table 6 Parameter description of busiPolicy

No.

Parameter

Type

Mandatory or Not

Description

14.7.1

busiResultCode

String

Yes

Business result code.

14.7.2

busiResultSubCode

String

--

Business result subcode. (This parameter is associated with the business result code.)

14.7.3

busiResultPolicy

Integer

Yes

Call policy for a business result.

0: Stop calling. 1: Call the next number. 2: Call the current number.

14.7.4

callInterval

Integer

--

Outbound call interval, in seconds.

If the call policy is set to 0, you do not need to set this parameter. Otherwise, this parameter is mandatory. The value ranges from 1 to 3600.

Table 7 Parameter description of policy

No.

Parameter

Type

Description

3.3.2.1

callInterval

Integer

Delay time.

3.3.2.2

result

Integer

Result type.

3.3.2.3

retryNumber

Integer

Number of retry times.

Triggered Event

None

Error Codes

Table 8 Error code description

No.

Error Code

Description

1

0200001

Parameter error. For details about the error, see resultDesc.

2

02000001

Empty parameter.

3

02000002

The parameter contains invalid characters.

4

02000003

The parameter length cannot exceed the maximum length.

5

02000004

The parameter length cannot be less than the minimum length.

6

02000005

The parameter length must be within the specified range.

7

02000006

Incorrect parameter type.

8

02000007

Incorrect parameter value.

9

02000008

Parameter conversion error. Check the request parameters.

10

02000009

Incorrect parameter combination. Check the request parameters.

11

02000010

The hour and minute parameters must be set at the same time.

12

02000011

The number of parameters cannot exceed the specified number.

Example

  • The following provides an example of the request body of this interface:

    None

  • The following provides an example of the response body of this interface:
    {
      "returnCode": "0200000",
      "data": {
        "retryPolicyId": "1871694313",
        "policyType": 0,
        "policyJson": "[{'retryTimes':1,'retryDay':2,'type':0,'policy':[]}]"
      },
      "returnDesc": null
    }