List Instance Devices
get
/20160918/instances/{instance_id}/devices
Get a list of all devices for the instance. You can optionally filter results by device availability.
Request
Supported Media Types
- application/json
Path Parameters
-
instanceId(required): string
The OCID of the instance.
Query Parameters
-
isAvailable: boolean
A filter to return only available devices or only used devices.
-
limit: integer
Minimum Value:
1
Maximum Value:1000
For list pagination. The maximum number of results per page, or items to return in a paginated List call. 1 is the minimum, 1000 is the maximum.Default Value:100
-
name: string
Minimum Length:
3
Maximum Length:9
A filter to return only devices that match the given name exactly. -
page: string
Minimum Length:
1
Maximum Length:512
For list pagination. The value of the opc-next-page response header from the previous List call.Default Value:0
-
sortBy: string
The optional field to sort the results by.Allowed Values:
[ "TIMECREATED", "NAME" ]
-
sortOrder: string
The sort order to use, either ascending (ASC) or descending (DESC).Default Value:
ASC
Allowed Values:[ "ASC", "DESC" ]
Header Parameters
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Response
Supported Media Types
- application/json
200 Response
List of devices
Headers
-
opc-next-page: string
For list pagination. When this header appears in the response, additional pages of results remain. For important details about how pagination works, see [List Pagination](/iaas/Content/API/Concepts/usingapi.htm#nine).
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : schema
Type:
Show Source
array
-
Array of:
object Device
Device Path corresponding to the block devices attached to instances having a name and isAvailable flag.
Nested Schema : Device
Type:
object
Device Path corresponding to the block devices attached to instances having a name and isAvailable flag.
Show Source
-
isAvailable(required):
boolean
The flag denoting whether device is available.
-
name(required):
string
Minimum Length:
3
Maximum Length:100
The device name.
400 Response
Bad Request
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
401 Response
Unauthorized
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
404 Response
Not Found
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
500 Response
Internal Server Error
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
Default Response
An error has occurred.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.