Help Center/ Cloud Operations Center/ API Reference/ API/ Script Tickets/ Displaying Basic Information about Script Service Tickets
Updated on 2024-04-19 GMT+08:00

Displaying Basic Information about Script Service Tickets

Function

This API is used to query basic information of a script service ticket, including execution type, execution name, creator, creation time, end time, execution status, and tag (script ID, script name, script execution parameters, execution user, timeout duration, and success rate threshold), and

different keys in the consumption tag of different task types.

URI

GET /v1/job/script/orders/{execute_uuid}

Table 1 Path parameters

Parameter

Mandatory or Not

Type

Description

execute_uuid

Yes

String

Execution ID of a script service ticket, which is obtained from the response bodies of executeJobScript and ListJobScriptOrders.

Minimum length: 1 character

Maximum length: 26 characters

Request Parameters

None

Response Parameters

Status code: 200

Table 2 Response body parameters

Parameter

Type

Description

execute_uuid

String

Execution UUID

gmt_created

Long

Execution creation time

gmt_finished

Long

Execution completion time

execute_costs

Long

Execution duration in seconds.

creator

String

Creator.

status

String

Execution status.

The value can be:

  • READY
  • PROCESSING
  • ERROR
  • PAUSED
  • CANCELED
  • FINISHED
  • ROLLBACKED

properties

JobScriptOrderInfoProp object

Attributes: script ID, script name, script execution parameters, execution user, timeout interval, success rate threshold, and index of the current execution batch

Table 3 JobScriptOrderInfoProp

Parameter

Type

Description

script_uuid

String

Script UUID.

script_name

Long

Script Name

script_version_uuid

Long

Script version UUID.

script_version_name

String

Script Version Name

current_execute_batch_index

Integer

Index of the current execution batch.

execute_param

ScriptExecuteParam object

Script execution parameters, execution user, timeout interval, and success rate threshold

Table 4 ScriptExecuteParam

Parameter

Type

Description

resourceful

Boolean

Whether resources are limited. The value true indicates that resources are not limited, and the value false indicates that resources are limited.

timeout

Integer

Timeout interval, in seconds. The value range is to be determined. The value is greater than 5 and less than 1800.

Minimum value: 5

Maximum value: 1800

success_rate

Double

Success rate. The value can contain one decimal place.

Minimum value: 1

Maximum value: 100

execute_user

String

User who executes the script. The script must be executed by user root.

Minimum length: 1 character

Maximum length: 32 characters

script_params

Array of ScriptExecuteInputParam objects

Script Input Parameter List

Table 5 ScriptExecuteInputParam

Parameter

Type

Description

param_name

String

Name of a script input parameter. The parameter name must be unique in the same script.

Minimum length: 1 character

Maximum length: 64 characters

param_value

String

Value of the script input parameter.

Minimum length: 0 character

Maximum length: 1,024 characters

The value can be:

  • ^((?!\.{2
  • })[a-zA-Z0-9_\-\/\.\x20\?:"
  • =+@\\\[\{\]\}])*$

param_order

Integer

Parameter sequence. The value starts from 1 and must be consecutive.

Minimum value: 1

Maximum value: 20

Request Example

None

Response Example

Status code: 200

Basic Execution Information

{
  "data" : {
    "execute_uuid" : "SCT2023102211473xxxxxxxxxx",
    "gmt_created" : 1697946452186,
    "gmt_finished" : 1697946763469,
    "execute_costs" : 311282,
    "creator" : "xxxxxxxxxxxcontainer1",
    "status" : "CANCELED",
    "properties" : {
      "script_uuid" : "SC2023101717xxxxxxxxxxxxx",
      "script_name" : "xjptxxxxxxxx",
      "current_execute_batch_index" : 1,
      "execute_param" : {
        "resourceful" : true,
        "timeout" : 300,
        "execute_user" : "root",
        "success_rate" : 100,
        "script_params" : [ ]
      },
      "script_source" : "CUSTOM_SCRIPT"
    }
  }
}

Status Code

Status Code

Description

200

Basic Execution Information

Error code

See Error code.