7.1.21 Execution agent status list acquisition API
This API acquires a list of the statuses of the execution agents that are registered on the manager host.
- Execution privileges
-
The logged-in JP1 user must have one of the following JP1 permissions:
-
JP1_JPQ_Admin privileges
-
JP1_JPQ_Operator privileges
-
JP1_JPQ_User privileges
-
- Request format
-
- Request line
GET /application/component/apiVersion/objects/execAgents/statuses?query httpVersion
- API version
-
v1
- Information that uniquely identifies a resource
-
None
- Parameter
-
The following table lists and describes the parameters that can be specified for query.
Table 7‒21: List of parameters for the Execution agent status list acquisition API Parameter
Description of the value
Required?
manager
Specify the manager host name or IP address by using a character string in the range from 1 to 255 bytes.
Y
mode
Specify a character string that indicates the acquisition-target mode. Specify agent for this parameter.
Y
- Status code
-
The following table lists and describes the status codes returned as a response:
Status code
Message
Description
200
OK
A list of the statuses of execution agents was acquired successfully.
400
Bad Request
The query character string is invalid.
401
Unauthorized
Authentication is required.
403
Forbidden
The operator does not have execution permission.
404
Not found
The operator does not have access permission for the resource, or the resource does not exist.
412
Precondition failed
The Web Console server is not available.
500
Server-side error
A processing error occurred in the Web Console server.
- Response format
-
- Response message body
{ "results":[Execution-agent-operation-result-object] }
- Return values
-
If the status code is 200, the following information is returned:
Member
Data type
Description
results
object[]
Returns an array of the execution agent operation result objects. In the returned array, the result of acquiring the statuses of execution agents is stored in element 0.
Also, if the command terminates abnormally on the manager host, a non-zero value is stored as the result code of the target processing and KNAK3696-E is stored as a message in the returned array.
For details about the execution agent operation result object, see 7.3.6 Execution agent operation result object.
- Example
-
The following shows an example of using the API to acquire a status list of execution agents.
- Example request:
GET /ajs/api/v1/objects/execAgents/statuses?manager=HOSTM&mode=agent HTTP/1.1 Host: HOSTW:22252 Accept-Language: ja X-AJS-Authorization: dXNlcjpwYXNzd29yZA==
- Example response:
HTTP/1.1 200 OK Content-Type: application/json Cache-Control: no-store, no-cache, max-age=0 Date: Wed, 26 Aug 2020 00:09:14 GMT Expires: Thu, 01 Jan 1970 00:00:00 GMT Pragma: no-cache Server: Cosminexus HTTP Server { "results": [ { "execAgent":"", "rtnCode":"0", "output": { "text":"", "serverTime":"2020-08-26T09:09:14+09:00", "statuses": [ { "comStatus":"NOTCHECKED", "conExe":5, "status":"EFFECTIVE", "description":"", "execAgent":"@SYSTEM", "execHost":"HISOL8139682", "que":0, "job":0, "event":0 }, { "comStatus":"NOTCHECKED", "conExe":20, "status":"BLOCKADE", "description":"test", "execAgent":"AGT01", "execHost":"AGT01", "que":0, "job":0, "event":0 } ], "definitions":null } } ] }