Configuring the messaging REST API
By default, the mqweb server which hosts the IBM® MQ Console and REST API has the messaging REST API enabled. You can configure whether messaging is enabled or disabled by using the setmqweb properties command.
Before you begin
You can view the current configuration of the messaging REST API by using the following command:
dspmqweb properties -a The
mqRestMessagingEnabled field shows whether the messaging REST API is enabled or
disabled. For more information, see dspmqweb.To use the messaging REST API the caller must be authenticated to the mqweb server and must be a
member of the ![[z/OS]](../common/../com.ibm.mq.con.doc/ngzos.gif)
Attention:
MQWebUser role. The MQWebAdmin and
MQWebAdminRO roles are not applicable for the messaging REST API. The caller must
also be authorized through OAM/RACF. For more information about security for the REST API, see IBM MQ Console and REST API
security.![[z/OS]](../common/../com.ibm.mq.con.doc/ngzos.gif)
Attention:
Before issuing either the setmqweb or dspmqweb commands on z/OS®, you must set the WLP_USER_DIR environment variable, so that the variable points to your mqweb server configuration.
To do this, issue the following
command:
export WLP_USER_DIR=WLP_user_directory where
WLP_user_directory is the name of the directory that is passed
to crtmqweb.sh. For
example:export WLP_USER_DIR=/var/mqm/web/installation1For more information, see Create the Liberty server definition.
Procedure
Use the following method to configure the messaging REST API:
- Use the setmqweb properties command:
- Configure whether the messaging REST API is enabled, by using the following command:
setmqweb properties -k mqRestMessagingEnabled -v enabledwhere enabled is the value
trueif you want the messaging REST API enabled, orfalseotherwise.
- Configure whether the messaging REST API is enabled, by using the following command: