Skip to main content
Resource Center/Hardware/Host Operations/USB Pass-through Operations
GETUSB Pass-through OperationsSince 2.2SynchronousAuth Required

GetUsbDeviceCandidatesForAttachingVm

GetUsbDeviceCandidatesForAttachingVm

Execution Availability

Try It Out

Submit a mock request using the current auth context and example-driven inputs.

Path Parameters

Query Parameters

Request Inputs

Path Parameters

  • vmInstanceUuidStringRequired

    The VM instance UUID.

Query Parameters

  • attachTypeString

    Optional. The attach type.

  • systemTagsList

    Optional. The system tags.

  • userTagsList

    Optional. The user tags.

Responses

200 OK

On success, this API returns the following response structure.

  • successbooleanRequired

    The API succeeded.

  • errorErrorCodeRequired

    The error code. If not null, the operation fails, or vice versa. For more information, see error.

    • codeStringRequired

      The error code, which is a numbered or alphanumeric code that specifies an error. For example, SYS.1000, HOST.1001.

    • descriptionStringRequired

      The brief description of the error.

    • detailsStringRequired

      The details about the error.

    • elaborationStringRequired

      The reserved field. Default value: null.

    • opaqueLinkedHashMapRequired

      The reserved field. Default value: null.

    • causeErrorCodeRequired

      The root error, which is the associated root cause of the current error. If no root error exists, this parameter is null.

  • inventoriesListRequired

    See inventories.

    • uuidStringRequired

      The resource UUID.

    • nameStringRequired

      The resource name.

    • descriptionStringRequired

      The detailed description of the resource.

    • hostUuidStringRequired

      The host UUID.

    • vmInstanceUuidStringRequired

      The VM instance UUID.

    • busNumStringRequired

      The bus No.

    • devNumStringRequired

      The device No.

    • idVendorStringRequired

      The vendor ID.

    • idProductStringRequired

      The device ID.

    • iManufacturerStringRequired

      The manufacturer.

    • iProductStringRequired

      The device type.

    • iSerialStringRequired

      The serial No.

    • usbVersionStringRequired

      The USB version.

    • attachTypeStringRequired

      The attach type.

    • createDateTimestampRequired

      The creation date.

    • lastOpDateTimestampRequired

      The last operation date.

    • stateUsbDeviceStateRequired

      See state.

      • nameStringRequired

        The resource name.

      • ordinalintRequired

        No description provided.

Endpoint

GET/zstack/v1/vm-instances/{vmInstanceUuid}/candidate-usb-devices

/zstack/v1/vm-instances/{vmInstanceUuid}/candidate-usb-devices

Operation ID

GetUsbDeviceCandidatesForAttachingVm

Permalink

Request Example

curl -X GET 'http://{host}/zstack/v1/vm-instances/{vmInstanceUuid}/candidate-usb-devices?attachType=<attachType>&systemTags=<systemTags>&userTags=<userTags>' -H 'Authorization: OAuth {sessionUuid}'

Response Example

200
{ "inventories": [ { "uuid": "b58b4b48b3b8398f93b8b529f6f5b53a", "name": "usb", "hostUuid": "9f7438cf6fd233cf8fc27d4f311326ca", "vmInstanceUuid": "ccdfb1d443433e1a8beac3a1d54374d5", "state": "Enabled", "busNum": "001", "devNum": "001", "idVendor": "0781", "idProduct": "5591", "iManufacturer": "SanDisk", "iProduct": "Ultra USB 3.0", "iSerial": "000000000001", "usbVersion": "3.0", "attachType": "PassThrough" } ] }

Change History

This API has no change history records yet.

View all change history