This article contains a list of REST API commands that pertain to queue managers.
For a walk-through of the Navigator REST API using the demo site, see Using the REST API using the Navigator demo system. No installation is required. The article Performing REST API operations using the Swagger UI includes three detailed examples, as well as instructions for issuing plain text or JSON-formatted MQSC Commands through the REST API.
Jump ahead: |
Search Queue Managers
GET /qmgrs
Purpose: Finds a queue manager on the specified node and list its properties.
Curl example
curl -X GET "http://jenkins.nastel.com:8019/rest/v1/qmgrs?nodeName=LEUNAME&qmgrName=TEST%2A&attributes=general.%2A%2Cextended.%2A" -H "accept: application/json" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
[
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"name": "TESTMQ4",
"general": {
"description": "",
"deadLetterQName": "SYSTEM.DEAD.LETTER.QUEUE",
"maxMsgLength": 4194304,
"maxUncmMsg": 10000,
"commandSrvControl": "QMgr",
"msgMarkBrowseInterval": 5000,
"maxHandles": 256,
"triggerInterval": 999999999,
"chinitControl": "QMgr",
"maxPropertiesLength": -1,
"custom": "",
"version": "09020300",
"collectSysMetrics": "No"
},
"extended": {
"expiryInterval": 0,
"sharedQMgrName": "Use",
"maxChannels": 100,
"maxActiveChannels": 100,
"tcpChannels": 0,
"lu62Channels": 0,
"adoptNewMcaType": "No",
"adoptNewMcaCheck": "None",
"outboundPortMax": 0,
"outboundPortMin": 0,
"receiveTimeout": 0,
"receiveTimeoutMin": 0,
"receiveTimeoutType": "Multiply",
"lsrTimer": 0,
"dnsWlm": "No",
"dnsGroup": "",
"chinitAdapters": 0,
"chinitDispatchers": 0,
"chinitTraceAutoStart": "No",
"chinitTraceTblSize": 0,
"tcpName": "",
"tcpStackType": "Single",
"ipaddrVer": "IPv4",
"tcpKeepAlive": "No",
"luGroupName": "",
"luName": "",
"lu62ArmSuffix": "",
"collectSysMetrics": false
}
},
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"name": "TESTQM1",
"general": {
"description": "",
"deadLetterQName": "SYSTEM.DEAD.LETTER.QUEUE",
"maxMsgLength": 4194304,
"maxUncmMsg": 10000,
"commandSrvControl": "QMgr",
"msgMarkBrowseInterval": 5000,
"maxHandles": 256,
"triggerInterval": 999999999,
"chinitControl": "QMgr",
"maxPropertiesLength": -1,
"custom": "",
"version": "09020300",
"collectSysMetrics": "No"
},
"extended": {
"expiryInterval": 0,
"sharedQMgrName": "Use",
"maxChannels": 100,
"maxActiveChannels": 100,
"tcpChannels": 0,
"lu62Channels": 0,
"adoptNewMcaType": "No",
"adoptNewMcaCheck": "None",
"outboundPortMax": 0,
"outboundPortMin": 0,
"receiveTimeout": 0,
"receiveTimeoutMin": 0,
"receiveTimeoutType": "Multiply",
"lsrTimer": 0,
"dnsWlm": "No",
"dnsGroup": "",
"chinitAdapters": 0,
"chinitDispatchers": 0,
"chinitTraceAutoStart": "No",
"chinitTraceTblSize": 0,
"tcpName": "",
"tcpStackType": "Single",
"ipaddrVer": "IPv4",
"tcpKeepAlive": "No",
"luGroupName": "",
"luName": "",
"lu62ArmSuffix": "",
"collectSysMetrics": false
}
},
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"name": "TESTQM3",
"general": {
"description": "",
"deadLetterQName": "SYSTEM.DEAD.LETTER.QUEUE",
"maxMsgLength": 4194304,
"maxUncmMsg": 10000,
"commandSrvControl": "QMgr",
"msgMarkBrowseInterval": 5000,
"maxHandles": 256,
"triggerInterval": 999999999,
"chinitControl": "QMgr",
"maxPropertiesLength": -1,
"custom": "",
"version": "09020300",
"collectSysMetrics": "No"
},
"extended": {
"expiryInterval": 0,
"sharedQMgrName": "Use",
"maxChannels": 100,
"maxActiveChannels": 100,
"tcpChannels": 0,
"lu62Channels": 0,
"adoptNewMcaType": "No",
"adoptNewMcaCheck": "None",
"outboundPortMax": 0,
"outboundPortMin": 0,
"receiveTimeout": 0,
"receiveTimeoutMin": 0,
"receiveTimeoutType": "Multiply",
"lsrTimer": 0,
"dnsWlm": "No",
"dnsGroup": "",
"chinitAdapters": 0,
"chinitDispatchers": 0,
"chinitTraceAutoStart": "No",
"chinitTraceTblSize": 0,
"tcpName": "",
"tcpStackType": "Single",
"ipaddrVer": "IPv4",
"tcpKeepAlive": "No",
"luGroupName": "",
"luName": "",
"lu62ArmSuffix": "",
"collectSysMetrics": false
}
}
]
Read Queue Manager Data
GET /qmgrs/{nodeName}/{qmgrName}
Purpose: Finds a queue manager and its properties on the specified node.
Curl example
curl -X GET "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/TESTQM1?attributes=general.%2A%2Cextended.%2A" -H "accept: application/json" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"name": "TESTQM1",
"general": {
"description": "",
"deadLetterQName": "SYSTEM.DEAD.LETTER.QUEUE",
"maxMsgLength": 4194304,
"maxUncmMsg": 10000,
"commandSrvControl": "QMgr",
"msgMarkBrowseInterval": 5000,
"maxHandles": 256,
"triggerInterval": 999999999,
"chinitControl": "QMgr",
"maxPropertiesLength": -1,
"custom": "",
"version": "09020300",
"collectSysMetrics": "No"
},
"extended": {
"expiryInterval": 0,
"sharedQMgrName": "Use",
"maxChannels": 100,
"maxActiveChannels": 100,
"tcpChannels": 0,
"lu62Channels": 0,
"adoptNewMcaType": "No",
"adoptNewMcaCheck": "None",
"outboundPortMax": 0,
"outboundPortMin": 0,
"receiveTimeout": 0,
"receiveTimeoutMin": 0,
"receiveTimeoutType": "Multiply",
"lsrTimer": 0,
"dnsWlm": "No",
"dnsGroup": "",
"chinitAdapters": 0,
"chinitDispatchers": 0,
"chinitTraceAutoStart": "No",
"chinitTraceTblSize": 0,
"tcpName": "",
"tcpStackType": "Single",
"ipaddrVer": "IPv4",
"tcpKeepAlive": "No",
"luGroupName": "",
"luName": "",
"lu62ArmSuffix": "",
"collectSysMetrics": false
}
}
Ping Queue Manager
PATCH /qmgrs/{nodeName}/{qmgrName}/ping
Purpose: Pings the specified queue manager on the specified node.
Curl example
curl -X PATCH "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/QA/ping" -H "accept: */*" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
Code: 204 (Queue Manager Pinged)
Response headers:
date: Wed, 29 Dec 2021 18:55:23 GMT
server: Jetty(9.4.28.v20200408)
Search Queue Manager Events
GET /qmgrs/{nodeName}/{qmgrName}/events
Purpose: Lists queue manager events of a certain type (if specified) on the specified node and queue manager.
Curl example
curl -X GET "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/QA/events?eventType=QMgr&attributes=%2A" -H "accept: application/json" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response (partial)
[
{
"wgsName": "MQM",
"type": "QMgr",
"eventNo": 34,
"uri": "/rest/v1/events/QMgr/34",
"general": {
"eventTimeStamp": 1638382291000,
"nodeName": "LEUNAME",
"qmgrName": "QA"
},
"diagnostic": {
"eventIdentifier": 20011,
"userId": "",
"eventTime": 2607912,
"reasonQualifier": 0,
"origUserId": "",
"objectName": ""
},
"extended": {
"eventDescription": "",
"command": 0,
"msgPutDate": "",
"msgPutTime": ""
},
"qmgr": {
"applType": "NO CONTEXT",
"applName": "",
"baseQName": "",
"objectQmgrName": "",
"xmitQName": "",
"adminTopicNames": "",
"topicString": "",
"baseType": "None",
"openOptions": 0,
"subOptions": 0
}
},
{
"wgsName": "MQM",
"type": "QMgr",
"eventNo": 26,
"uri": "/rest/v1/events/QMgr/26",
"general": {
"eventTimeStamp": 1638331345000,
"nodeName": "LEUNAME",
"qmgrName": "QA"
},
"diagnostic": {
"eventIdentifier": 20017,
"userId": "",
"eventTime": 2658858,
"reasonQualifier": 0,
"origUserId": "",
"objectName": ""
},
"extended": {
"eventDescription": "",
"command": 0,
"msgPutDate": "20211101",
"msgPutTime": "04022500"
},
"qmgr": {
"applType": "NO CONTEXT",
"applName": "",
"baseQName": "",
"objectQmgrName": "",
"xmitQName": "",
"adminTopicNames": "",
"topicString": "",
"baseType": "None",
"openOptions": 0,
"subOptions": 0
}
},
{
"wgsName": "MQM",
"type": "QMgr",
"eventNo": 15,
"uri": "/rest/v1/events/QMgr/15",
"general": {
"eventTimeStamp": 1638331345000,
"nodeName": "LEUNAME",
"qmgrName": "QA"
},
"diagnostic": {
"eventIdentifier": 20011,
"userId": "",
"eventTime": 2658858,
"reasonQualifier": 0,
"origUserId": "",
"objectName": ""
},
"extended": {
"eventDescription": "",
"command": 0,
"msgPutDate": "",
"msgPutTime": ""
},
"qmgr": {
"applType": "NO CONTEXT",
"applName": "",
"baseQName": "",
"objectQmgrName": "",
"xmitQName": "",
"adminTopicNames": "",
"topicString": "",
"baseType": "None",
"openOptions": 0,
"subOptions": 0
}
},
{
"wgsName": "MQM",
"type": "QMgr",
"eventNo": 8,
"uri": "/rest/v1/events/QMgr/8",
"general": {
"eventTimeStamp": 1638244948000,
"nodeName": "LEUNAME",
"qmgrName": "QA"
},
"diagnostic": {
"eventIdentifier": 20017,
"userId": "",
"eventTime": 2745255,
"reasonQualifier": 0,
"origUserId": "",
"objectName": ""
},
"extended": {
"eventDescription": "",
"command": 0,
"msgPutDate": "20211030",
"msgPutTime": "04022800"
},
"qmgr": {
"applType": "NO CONTEXT",
"applName": "",
"baseQName": "",
"objectQmgrName": "",
"xmitQName": "",
"adminTopicNames": "",
"topicString": "",
"baseType": "None",
"openOptions": 0,
"subOptions": 0
}
},
{
"wgsName": "MQM",
"type": "QMgr",
"eventNo": 1000,
"uri": "/rest/v1/events/QMgr/1000",
"general": {
"eventTimeStamp": 1638244947000,
"nodeName": "LEUNAME",
"qmgrName": "QA"
},
"diagnostic": {
"eventIdentifier": 20011,
"userId": "",
"eventTime": 2745256,
"reasonQualifier": 0,
"origUserId": "",
"objectName": ""
},
"extended": {
"eventDescription": "",
"command": 0,
"msgPutDate": "",
"msgPutTime": ""
},
"qmgr": {
"applType": "NO CONTEXT",
"applName": "",
"baseQName": "",
"objectQmgrName": "",
"xmitQName": "",
"adminTopicNames": "",
"topicString": "",
"baseType": "None",
"openOptions": 0,
"subOptions": 0
}
}
]
Create Queue Manager
GET /qmgrs/{nodeName}/{qmgrName}
Purpose: Creates a new queue manager on the specified node.
Curl example
curl -X POST "http://jenkins.nastel.com:8019/rest/v1/qmgrs" -H "accept: */*" -H "Authorization: Basic QWRtaW46YWRtaW4=" -H "Content-Type: application/json" -d "{\"wgsName\":\"MQM\",\"nodeName\":\"LEUNAME\",\"name\":\"TESTQM\",\"uri\":\"/rest/v1/qmgrs/TESTQM\"}"
JSON example
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"name": "TESTQM",
"uri": "/rest/v1/qmgrs/TESTQM"
}
Example Response
Code: 201 (Object Created)
Response headers:
content-length: 0
date: Wed, 29 Dec 2021 16:09:07 GMT
server: Jetty(9.4.28.v20200408)
Change Queue Manager
PATCH /qmgrs/{nodeName}/{qmgrName}
Purpose: Changes one or more attributes of the specified queue manager on the specified node. In the example below, the name of the queue manager is being changed from TESTQM to TESTQM1.
Curl example
curl -X POST "http://jenkins.nastel.com:8019/rest/v1/qmgrs" -H "accept: */*" -H "Authorization: Basic QWRtaW46YWRtaW4=" -H "Content-Type: application/json" -d "{\"wgsName\":\"MQM\",\"nodeName\":\"LEUNAME\",\"name\":\"TESTQM\",\"uri\":\"/rest/v1/qmgrs/TESTQM\"}"
JSON example
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"name": "TESTQM1",
"uri": "/rest/v1/qmgrs/TESTQM1"
}
Example Response
Code: 204 (Object Changed)
Response headers:
date: Wed, 29 Dec 2021 16:28:59 GMT
server: Jetty(9.4.28.v20200408)
Delete Queue Manager
DELETE /qmgrs/{nodeName}/{qmgrName}
Purpose: Deletes the specified queue manager on the specified node. For a queue managers to be eligible for deletion, it must be inactive.
Curl example
curl -X DELETE "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/TESTQM" -H "accept: */*" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
Code: 204 (Object Deleted)
Response headers:
date: Wed, 29 Dec 2021 17:27:30 GMT
server: Jetty(9.4.28.v20200408)
Search Queue Manager Connections
GET /qmgrs/{nodeName}/{qmgrName}/connections
Purpose: Lists queue manager connections and their properties.
Curl example
curl -X GET "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/QA/connections" -H "accept: application/json" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
[
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"qmgrName": "QA",
"connectionId": "414D514351412020202020202020202007FBC46100270040",
"genericConnectionId": "414D514351412020202020202020202007FBC46100270040",
"type": "Connection",
"general": {
"connectionTag": "4D5143543037464243343631303032373030343051415F323031342D30382D32395F31352E31342E34315C4E617374656C5C6170776D715C62696E5C6E73717075622E65786500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"processId": 4624,
"threadId": 4,
"applDesc": "",
"applTag": "\\Nastel\\apwmq\\bin\\nsqpub.exe",
"applType": "User application",
"channelName": "",
"clientId": "",
"connectionName": "",
"userId": "SYSTEM"
},
"uow": {
"asynchronousState": "None",
"logExtent": "",
"uowStartDate": "",
"uowStartTime": "",
"logStartDate": "",
"logStartTime": "",
"uowType": "Queue manager",
"uowExternalId": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"uowQmgrId": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"uowState": "None"
}
},
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"qmgrName": "QA",
"connectionId": "414D514351412020202020202020202007FBC461001D0040",
"genericConnectionId": "414D514351412020202020202020202007FBC461001D0040",
"type": "Connection",
"general": {
"connectionTag": "4D5143543037464243343631303031443030343051415F323031342D30382D32395F31352E31342E34317068657265204D51385C62696E36345C616D7166637862612E65786500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"processId": 9800,
"threadId": 1,
"applDesc": "IBM MQ Queued Pub/Sub Worker",
"applTag": "phere MQ8\\bin64\\amqfcxba.exe",
"applType": "Queue manager",
"channelName": "",
"clientId": "",
"connectionName": "",
"userId": "MUSR_MQADMIN"
},
"uow": {
"asynchronousState": "None",
"logExtent": "",
"uowStartDate": "",
"uowStartTime": "",
"logStartDate": "",
"logStartTime": "",
"uowType": "Queue manager",
"uowExternalId": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"uowQmgrId": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"uowState": "None"
}
},
]
Read Queue Manager Connection
GET /qmgrs/{nodeName}/{qmgrName}/connections/{connectionId}
Purpose: Lists queue manager connections and their properties.
Curl example
curl -X GET "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/QA/connections/414D514351412020202020202020202007FBC461001D0040" -H "accept: application/json" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
[
{
"wgsName": "MQM",
"nodeName": "LEUNAME",
"qmgrName": "QA",
"connectionId": "414D514351412020202020202020202007FBC461001D0040",
"genericConnectionId": "414D514351412020202020202020202007FBC461001D0040",
"type": "Connection",
"general": {
"connectionTag": "4D5143543037464243343631303031443030343051415F323031342D30382D32395F31352E31342E34317068657265204D51385C62696E36345C616D7166637862612E65786500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"processId": 9800,
"threadId": 1,
"applDesc": "IBM MQ Queued Pub/Sub Worker",
"applTag": "phere MQ8\\bin64\\amqfcxba.exe",
"applType": "Queue manager",
"channelName": "",
"clientId": "",
"connectionName": "",
"userId": "MUSR_MQADMIN"
},
"uow": {
"asynchronousState": "None",
"logExtent": "",
"uowStartDate": "",
"uowStartTime": "",
"logStartDate": "",
"logStartTime": "",
"uowType": "Queue manager",
"uowExternalId": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"uowQmgrId": "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"uowState": "None"
}
}
]
Read MQ Object Authority Records
GET /qmgrs/{nodeName}/{qmgrName}/auth-recs
Purpose: Lists authority records for the queue manager.
Curl example
curl -X GET "http://jenkins.nastel.com:8019/rest/v1/qmgrs/LEUNAME/QA/auth-recs?objectType=qmgr" -H "accept: application/json" -H "Authorization: Basic QWRtaW46YWRtaW4="
Example Response
{
"authRecs": [
{
"objectType": "qmgr",
"principalName": "jsmith@TEST",
"auths": [
"altusr",
"chg",
"connect",
"dlt",
"dsp",
"inq",
"set",
"setall",
"setid",
"ctrl",
"system"
]
},
{
"objectType": "qmgr",
"groupName": "mqm@LEUNAME",
"auths": [
"altusr",
"chg",
"connect",
"dlt",
"dsp",
"inq",
"set",
"setall",
"setid",
"ctrl",
"system"
]
},
{
"objectType": "qmgr",
"objectName": "@CLASS",
"principalName": "jsmith@TEST",
"auths": [
"crt"
]
},
{
"objectType": "qmgr",
"objectName": "@CLASS",
"groupName": "mqm@LEUNAME",
"auths": [
"crt"
]
}
],
"overallCompletionCode": 0,
"overallReasonCode": 0
}