cURL
curl --request DELETE \ --url https://api.example.com/v1/storage/objects \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "object_keys": [ "my-file.pdf", "my-file.doc" ], "path": [ "pdf/", "doc/" ] } '
{ "code": 200, "data": { "deleted_object_count": 3, "deleted_objects": [ "my-file.pdf", "my-file.doc", "doc/my-file-2.doc" ], "errors": [ { "error_code": "404", "error_message": "Objects not exist in path", "key": "pdf/" } ] }, "exception": null, "success": true }
Delete multiple objects from the storage by object keys and path.
Bearer token authentication. Include the token in the Authorization header as 'Bearer '
The objects to delete from storage.
List of object keys to delete. e.g. ["pdf/test.pdf", "pdf/test2.pdf"]
Path of the objects to delete. e.g. "pdf/"
Success to delete objects from storage.
HTTP status code.
x >= 0
Whether the request was successful.
Show child attributes