Dropping a Db2 REST service
You can use the Db2 REST service manager API to drop a user-defined service if you have the required authority. Dropping a service removes the service, frees its associated package, and deletes the corresponding row from the SYSIBM.DSNSERVICE catalog table. You can also issue the FREE SERVICE command to drop a REST service.
Before you begin
Procedure
Example
To drop the V1 version of service simpleSelect1, enter the
following URI to start an HTTPS POST request:
POST https://<host>:<port>/services/DB2ServiceManager
Specify the following HTTP header fields for the request:
Accept:application/json
Content-Type:application/json
Specify the following HTTP body for the request:
{
"requestType": "dropService",
"collectionID": "SYSIBMSERVICE",
"serviceName": "simpleSelect1",
"version": "V1"
}
Db2 returns the following response in JSON:
{
"StatusCode":200,
"StatusDescription": "DB2 Rest Service SYSIBMSERVICE.simpleSelect1.(V1) was dropped successfully."
}
The response shows that service simpleSelect1 was successfully removed.
