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

Interface for Querying the RPA Task List

Description

This interface is invoked to query the RPA task list.

Interface Method

POST

URL

https://IP:PORT/oifde/rest/api/rpa/queryJob

Request

Table 1 Parameters in the request body

Parameter

Type

Position

Mandatory

Description

tenantId

String

Body

Yes

Tenant ID.

The value can contain a maximum of 64 characters.

pageNo

Integer

Body

No

Number of pages to be queried. The default value is 1.

pageSize

Integer

Body

No

Number of data records on each page. The default value is 50.

The value can be 5, 10, 20, or 50.

conditions

RpaJobCondition

Body

No

Search criteria.

authToken

String

Body

Yes

Valid token value for accessing the interface.

You can obtain the valid token information by invoking the interface for obtaining tokens.

For details, see C3 OIAP Interface Authentication.

The value can contain a maximum of 32 characters.

Table 2 RpaJobConditions

Parameter

Type

Position

Mandatory

Description

jobName

String

Body

No

Task name for fuzzy search.

status

Integer

Body

No

Task status for search. The options are as follows:

  • init: to be executed
  • running: running
  • suspend: suspended
  • success: completed

Response

Table 3 Parameters in the response body

Parameter

Type

Position

Mandatory

Description

errorCode

Int

Body

Yes

Error code.

The value 0 indicates success and other values indicates failure.

errorMsg

String

Body

No

Error message.

total

Int

Body

No

Total number of records.

jobs

RpaDetailJobResult[]

Body

No

Task list, which must be returned when the operation is successful.

Table 4 RpaDetailJobResult

Parameter

Type

Position

Mandatory

Description

uid

String

Body

No

Task UUID.

jobName

String

Body

No

Task name.

createTime

String

Body

No

Task creation time.

startTime

String

Body

No

Task start time.

status

String

Body

No

Task status. The options are as follows:

  • init: to be executed
  • running: running
  • success: completed
  • suspend: suspended

mode

String

Body

No

Execution mode. The options are once and repeat.

runMode

String

Body

No

Running mode. The options are online and offline.

timeout

Integer

Body

No

Task timeout period, in seconds.

description

String

Body

No

Task description.

Example

  • Request
    {
        "tenantId": "202201072597",
        "authToken": "hjbLf*******************RQFv3nq",
        "pageNo": 1,
        "pageSize": 10,
        "conditions": {}
    }
  • Response
    {
        "total": 1,
        "jobs": [
            {
                "uid": "0c9358552188478a8d5ff9203db8791f",
                "jobName": "AICC_RPA",
                "createTime": "2022-04-24 17:12:02",
                "startTime": "2022-04-29 11:47:25",
                "status": "running",
                "mode": "queueTrigger",
                "runMode": "online",
                "timeout": 120,
                "description": null
            }
        ],
        "errorCode": 0,
        "errorMsg": null
    }