Delete Multiple Devices
delete
/mobile/system/locationManagement/devices
Deletes all devices that correspond to the IDs provided in the list if they exist.
Permissions
Only team members with the Administrator
role can access the Location Management API.
Request
Query Parameters
-
id: string
Comma-separated list of IDs of the devices to delete.
Response
Supported Media Types
- application/json
200 Response
The batch delete request completed. See the response body for individual results.
Root Schema : Batch Delete Response
Type:
object
Title:
Show Source
Batch Delete Response
-
batch:
array batch
Minimum Number of Items:
1
An array of responses for individual delete requests.
Nested Schema : batch
Type:
array
Minimum Number of Items:
1
An array of responses for individual delete requests.
Show Source
-
Array of:
object Batch Delete Item Response
Title:
Batch Delete Item Response
Nested Schema : Batch Delete Item Response
Type:
object
Title:
Show Source
Batch Delete Item Response
-
body:
object Batch Delete Response Item Body
Title:
Batch Delete Response Item Body
Response body for the item's delete request. -
code:
integer
Response status code for the item's delete request.
Nested Schema : Batch Delete Response Item Body
Type:
object
Title:
Batch Delete Response Item Body
Response body for the item's delete request.
Show Source
-
id:
integer
Resource's ID.
-
message(optional):
string
Optional return message.
Example Response (application/json)
{
"batch":[
{
"code":200,
"body":{
"id":121,
"message":"device was deleted successfully."
}
},
{
"code":200,
"body":{
"id":122,
"message":"device was deleted successfully."
}
},
{
"code":404,
"body":{
"id":123,
"message":"device not found."
}
}
]
}
400 Response
Bad request.
Root Schema : Error
Type:
object
Title:
Error
The error JSON object returned by the service.
Show Source
-
detail:
string
Message that provides the error details.
-
o:ecid:
string
Execution context ID, which is a unique identifier to correlate events or requests that are associated with the same transaction across several components.
-
o:errorCode:
string
The service's error code.
-
o:errorDetails(optional):
array o:errorDetails
Minimum Number of Items:
0
Included when the error is caused by multiple issues. -
o:errorPath:
string
The relative point in the API path where the error occurred.
-
status:
integer
HTTP status code. See http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html for more details.
-
title:
string
Summary of the problem.
-
type:
string
The URI to the link that provides details about the HTTP status code.
Nested Schema : o:errorDetails
Type:
array
Minimum Number of Items:
0
Included when the error is caused by multiple issues.
Show Source
-
Array of:
object Error Detail
Title:
Error Detail
Nested Schema : Error Detail
Type:
object
Title:
Show Source
Error Detail
-
instance:
string
URI to the link that provides more detailed information about the error.
-
o:errorCode:
string
The service's error code.
-
o:errorPath:
string
The relative point in the API path where the error occurred.
-
title:
string
Summary of the problem.
-
type:
string
The URI to the link that provides details about the HTTP status code.
Examples
This example shows how to use cURL to delete one or more devices by submitting a DELETE request on the REST resource.
curl -i \ -X DELETE \ -u administrator@example.com:password \ -H "Oracle-Mobile-Backend-ID: ABCD9278-091f-41aa-9cb2-184bd0586fce" \ http://fif.cloud.oracle.com/mobile/system/locationManagement/devices?id=121,122,123
Example of Response Header
Here's an example of the response header.
200 OK Content-Type: application/json Date: Mon, 27 Nov 2017 19:15:50 GMT
Example of Response Body
Here's an example of the response body:
{
"batch":[
{
"body":{
"id":121,
"message":"device was deleted successfully."
},
"code":200
},
{
"body":{
"id":122,
"message":"device was deleted successfully."
},
"code":200
},
{
"body":{
"id":123,
"message":"device not found."
},
"code":404
}
]
}