All Products
Search
Document Center

Serverless App Engine:ListJobs

Last Updated:Mar 17, 2026

Call the ListJobs API to retrieve a list of job templates.

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

sae:ListJobs

list

*All Resource

*

None None

Request syntax

GET /pop/v1/sam/job/listJobs HTTP/1.1

Request parameters

Parameter

Type

Required

Description

Example

CurrentPage

integer

No

Current page number. Starts from 1.

1

PageSize

integer

No

Page size. Value range: [0, 200].

20

AppName

string

No

Job template name.

demo-app

NamespaceId

string

No

Namespace ID.

cn-beijing:demo

Tags

string

No

List of tags, JSON string. Values are described as follows:

  • key: Tag key.

  • value: Tag value.

[{"key":"key","value":"value"}]

OrderBy

string

No

Sort job templates. Values are described as follows:

  • running: Sort by the number of running instances.

  • instances: Sort by the number of target instances.

running

Reverse

boolean

No

Sort by the field name passed in the OrderBy parameter. Values are described as follows:

  • true: Sort in ascending order.

  • false: Sort in descending order.

true

FieldType

string

No

Set the dimension for filtering job templates. Values are described as follows:

  • appName: Job template name.

  • appIds: Job template ID.

appName

FieldValue

string

No

Based on the filtering dimension set by FieldType, enter the job template name or job template ID of the target job template.

demo-app

Workload

string

No

Workload must be set to job.

job

Response elements

Element

Type

Description

Example

object

Response data.

Message

string

Additional information about the call result.

success

RequestId

string

Request ID.

B4D805CA-926D-41B1-8E63-7AD0C1ED****

Data

object

List of job templates.

CurrentPage

integer

Current page number.

1

TotalSize

integer

Total number of job templates.

2

PageSize

integer

Page size.

20

Applications

array<object>

List of job templates.

array<object>

Job template details.

AppName

string

Job template name.

demo-app

NamespaceId

string

Namespace ID.

cn-beijing:demo

AppId

string

Job template ID.

f7730764-d88f-4b9a-8d8e-cd8efbfe****

Tags

array<object>

Job template tags.

object

Job template tag details.

Key

string

Tag key.

key

Value

string

Tag value.

value

RegionId

string

Region ID.

cn-beijing

AppDescription

string

Job template description.

description

TriggerConfig

string

The trigger configuration for the job. Configure the trigger based on the job type.

  • Scheduled task: Set the type field to time. The config field is a Cron expression, and the timezone field specifies the time zone. Example: {"type":"time","config":"0 1 */1 * ?","timezone":"GMT+8:00"}

  • One-time job: Set the type field to http. Use the config field to specify the HTTP trigger rules. For more information, see SourceHttpEventParameters. Example: {"type":"http","config":{"type":"HTTPS","method":["GET"],"ip":[],"referer":[],"securityConfig":"none"}}

{"type":"time","config":"0 1 */1 * ?","timezone":"GMT+8:00"}

Suspend

boolean

Whether to pause the job template.

false

Active

integer

Number of running instances.

0

Succeeded

integer

Number of successfully run instances.

3

Failed

integer

Number of failed instances.

0

LastStartTime

integer

Last job start time.

1657522800

CompletionTime

integer

Last job completion time.

1657522839

LastChangeorderState

string

Whether the last release order executed successfully. Values are described as follows:

  • 0: Release order execution failed.

  • 1: Release order execution succeeded.

1

LastJobState

string

Last job running status. Values are described as follows:

  • 0: Not executed.

  • 1: Execution succeeded.

  • 2: Execution failed.

  • 3: Executing.

0

Cpu

integer

CPU required for each instance, in millicores. Cannot be 0. Currently, only the following defined specifications are supported:

  • 500

  • 1000

  • 2000

  • 4000

  • 8000

  • 16000

  • 32000

500

Mem

integer

Memory required for each instance, in MB. Cannot be 0. It has a one-to-one correspondence with CPU. Currently, only the following defined specifications are supported:

  • 1024: Corresponds to 500 millicores and 1000 millicores CPU.

  • 2048: Corresponds to 500, 1000, and 2000 millicores CPU.

  • 4096: Corresponds to 1000, 2000, and 4000 millicores CPU.

  • 8192: Corresponds to 2000, 4000, and 8000 millicores CPU.

  • 12288: Corresponds to 12000 millicores CPU.

  • 16384: Corresponds to 4000, 8000, and 16000 millicores CPU.

  • 24576: Corresponds to 12000 millicores CPU.

  • 32768: Corresponds to 16000 millicores CPU.

  • 65536: Corresponds to 8000, 16000, and 32000 millicores CPU.

  • 131072: Corresponds to 32000 millicores CPU.

1024

Message

string

Additional information about the call result.

success

ImageUrl

string

ErrorCode

string

Error code. Values are described as follows:

  • Request successful: The ErrorCode field is not returned.

  • Request failed: The ErrorCode field is returned. For details, see the Error Codes section in this topic.

Code

string

API status or POP error code. Values are described as follows:

  • 2xx: Success.

  • 3xx: Redirection.

  • 4xx: Request error.

  • 5xx: Server error.

200

Success

boolean

Whether the list of job templates was retrieved successfully. Values are described as follows:

  • true: Retrieved successfully.

  • false: Failed to retrieve.

true

CurrentPage

integer

Current page number.

1

TotalSize

integer

Total number of job templates.

2

PageSize

integer

Page size.

20

Examples

Success response

JSON format

{
  "Message": "success",
  "RequestId": "B4D805CA-926D-41B1-8E63-7AD0C1ED****",
  "Data": {
    "CurrentPage": 1,
    "TotalSize": 2,
    "PageSize": 20,
    "Applications": [
      {
        "AppName": "demo-app",
        "NamespaceId": "cn-beijing:demo",
        "AppId": "f7730764-d88f-4b9a-8d8e-cd8efbfe****",
        "Tags": [
          {
            "Key": "key",
            "Value": "value"
          }
        ],
        "RegionId": "cn-beijing",
        "AppDescription": "description",
        "TriggerConfig": "{\"type\":\"time\",\"config\":\"0 1 */1 * ?\",\"timezone\":\"GMT+8:00\"}",
        "Suspend": false,
        "Active": 0,
        "Succeeded": 3,
        "Failed": 0,
        "LastStartTime": 1657522800,
        "CompletionTime": 1657522839,
        "LastChangeorderState": "1",
        "LastJobState": "0",
        "Cpu": 500,
        "Mem": 1024,
        "Message": "success",
        "ImageUrl": ""
      }
    ]
  },
  "ErrorCode": "空",
  "Code": "200",
  "Success": true,
  "CurrentPage": 1,
  "TotalSize": 2,
  "PageSize": 20
}

Error codes

HTTP status code

Error code

Error message

Description

404 InvalidAppId.NotFound The specified AppId does not exist.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.