Help Center/ ModelArts/ API Reference/ Model Training/ Training Job Management (New Version)/ Obtaining the Historical Scheduling Information of a Training Job Instance
Updated on 2026-09-01 GMT+08:00

Obtaining the Historical Scheduling Information of a Training Job Instance

Function

This API is used to obtain the historical scheduling information about a training job instance. This API is applicable to scenarios such as task O&M check, scheduling history tracing, and resource allocation viewing. It can be used to obtain information such as the instance IP address and node IP address scheduled by a training job, and obtain a specified record by the number of scheduling times. You can also use the schedule_count parameter to obtain the instance information of a specific scheduling. You must have the permission to view the corresponding training job and pass a valid project ID and training job ID. If the API is successfully called, the scheduling history data is returned. If the parameters are invalid, you do not have the permission, or the resource does not exist, an error message is returned.

Debugging

You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.

Authorization Information

Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.

  • If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
  • If you are using identity policy-based authorization, the following identity policy-based permissions are required.

    Action

    Access Level

    Resource Type (*: required)

    Condition Key

    Alias

    Dependencies

    modelarts:trainJob:list

    List

    -

    -

    -

    -

URI

GET /v2/{project_id}/training-jobs/{training_job_id}/tasks

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Definition: Project ID. For details, see Obtaining a Project ID and Name.

Constraints: The value can contain 1 to 64 characters. Letters, digits, and hyphens (-) are allowed.

Range: N/A

Default Value: N/A

training_job_id

Yes

String

Definition: Training job ID. For details, see Obtaining Training Jobs.

Constraints: N/A

Range: N/A

Default Value: N/A

Table 2 Query Parameters

Parameter

Mandatory

Type

Description

schedule_count

No

Integer

Number of the scheduling of a training job.

Request Parameters

None

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

[items]

Array of TaskHistory objects

Definition: Information about an instance of a training job, including the instance IP address, IP address of the node where the instance is located, and the scheduling sequence of the instance.

Table 4 TaskHistory

Parameter

Type

Description

task

String

Definition: Instance name.

Range: N/A.

ip

String

Definition: Instance IP address.

Range: N/A.

host_ip

String

Definition: IP address of the node where the instance is located.

Range: N/A.

schedule_count

Integer

Definition: Number of the scheduling that the instance belongs to.

Range: N/A.

Example Requests

None

Example Responses

Status code: 200

OK

[ {
  "task" : "worker-0",
  "ip" : "172.0.0.1",
  "host_ip" : "192.168.0.1",
  "schedule_count" : 1
} ]

Status Codes

Status Code

Description

200

OK

Error Codes

See Error Codes.