Web API Reference Guide > Available API Methods > Job Queue Methods > The jobqueueJobsList Method

The jobqueueJobsList Method

Job Queue API actions provide external actors with ways to query and manipulate jobs and their recurring definitions.

Version: 1.3

Required Permissions: Read-only

HTTP method: GET

Supported by Editions: Zend Server

Request Parameters:  

Parameter

 Type

Required

Description

limit

Integer

No

Row limit to retrieve, defaults to value defined in zend-user-user.ini

offset

Integer

No

The page offset to be displayed, defaults to 0

orderBy

String

No

Column to sort the result by (), defaults to Date

direction

String

No

Sorting direction , defaults to Desc

filter

Array

No

Associative array, accteps any of the following keys: app_id, name, script, priority, status, rule_id, scheduled_before, scheduled_after, executed_before, executed_after, freeText The priority key, accepts the following values: low, normal, high, urgent. The status key, accepts the following values: Active, Waiting, Running, Completed, Failed, Timeout, Removed, Scheduled, Suspended, Retry

Expected Response Code: 200 OK - Returned for successfully retrieving a list of jobs according to the provided parameters. For more information see Response Format.

Response Format: A list of jobs, their dependent information and a total count of records for the provided filter

Possible Action Specific Error Codes:

HTTP Code

 Error Code

Description

500

internalServerError

Retrieving a list of jobs failed due to an internal problem

Example

Usage Example

Request

GET /ZendServerManager/Api/jobqueueJobsList

Response

<?xml version="1.0" encoding="UTF-8"?>

<zendServerAPIResponse xmlns="http://www.zend.com/server/api/1.3">

<requestData>

<apiKeyName><![CDATA[Admin]]></apiKeyName>

<method>jobqueueJobsList</method>

</requestData>

<responseData>

<jobs>

<job>

<id>1</id>

<type>absolute</type>

<nodeId>5</nodeId>

<queueName>default</queueName>

<status>ok</status>

<priority>normal</priority>

<persistent>No</persistent>

<script><![CDATA[http://url/of/job]]></script>

<vars></vars>

<creationTime></creationTime>

<startTime></startTime>

<endTime></endTime>

<schedule></schedule>

<scheduleTime></scheduleTime>

<scheduleId></scheduleId>

<job>

</jobs>

<total>1</total>

</responseData>

<zendServerAPIResponse>

 

Read Also

  Available API Methods    
  Job Queue Methods