Delete a sequential and partitioned data set
You can use this operation to delete sequential and partitioned data sets on a z/OS system.
HTTP method and URI path
DELETE /zosmf/restfiles/ds/<dataset-name>
DELETE /zosmf/restfiles/ds/-(<volume>)/<dataset-name>
where:
- /zosmf/restfiles specifies the z/OS data set and file REST interface
- /ds indicates a data set request
- <dataset-name> is the name of a z/OS data set, that you are going to delete.
- <volume> is where the data set is resided, when the data set is uncataloged.
Request Body
None.Standard headers
None.
Custom headers
None.
Query parameters
None.Content type
The content type is application/json.
Required authorizations
Usage considerations
Expected response
On completion, the service returns an HTTP response, which includes a status code
indicating whether your request completed. Status code 204
indicates success. A
status code of 4nn
or 5nn
indicates that an error
has occurred. For more details, see Error handling.
If the request is successfully executed, status code 204 indicates success and no content is returned.
Example request
In the following example, the DELETE method is used to delete a data set.
DELETE /zosmf/restfiles/ds/JIAHJ.REST.TEST.DATASET HTTP/1.1
Example response
A sample response is shown in Figure 1.
Example request
The DELETE method is used to delete an uncataloged data set.
DELETE /zosmf/restfiles/ds/-(ZMF046)/JIAHJ.REST.TEST.DATASET2 HTTP/1.1
Example response
A sample response is shown in Delete
uncataloged data set.