Skip to main content
Resource Center/Resource Pool/Image Operations

CreateDataVolumeTemplateFromVolume

CreateDataVolumeTemplateFromVolume

POST/zstack/v1/images/data-volume-templates/from/volumes/{volumeUuid}

Operation ID

CreateDataVolumeTemplateFromVolume

Since

0.6

Execution Mode

Synchronous

Auth Context

Auth Required

Auth Context

Send these values as request headers when calling this API.

AuthorizationstringRequired

Bearer Token

X-Tenant-IDstring

X-Tenant-ID

Request Inputs

application/json

Path Parameters

  • volumeUuid
    StringRequired

    Path parameter.

Body Fields

  • params
    ObjectRequired

    Request body parameter object.

    • name
      StringRequired

      The name of the data volume image.

    • description
      String

      Optional. The detailed description of the data volume image.

    • volumeUuid
      StringRequired

      The UUID of the volume from which the data volume image is to be created.

    • backupStorageUuids
      List

      Optional. The backup storage UUID list.

    • resourceUuid
      String

      Optional. The UUID of the data volume image. If specified, the data volume image will use the specified value as UUID.

    • tagUuids
      List

      Optional. The tag UUID.

  • systemTags
    List

    Optional. The system tags.

  • userTags
    List

    Optional. The user tags.

Responses

200 OK
200 OK

On success, this API returns the following response structure.

  • success
    BooleanRequired

    Whether the operation succeeded.

  • error
    ErrorCodeRequired

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

    • code
      StringRequired

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

    • description
      StringRequired

      The brief description of the error.

    • details
      StringRequired

      The details about the error.

    • elaboration
      StringRequired

      The reserved field. Default value: null.

    • opaque
      LinkedHashMapRequired

      The reserved field. Default value: null.

    • cause
      ErrorCodeRequired

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

  • inventory
    ImageInventoryRequired

    See inventory.

    • uuid
      StringRequired

      The resource UUID.

    • name
      StringRequired

      The resource name.

    • description
      String

      Optional. The detailed description of the resource.

    • state
      StringRequired

      The state of the image.

    • status
      StringRequired

      The status of the image.

    • size
      LongRequired

      The image size.

    • actualSize
      LongRequired

      The actual size of the image.

    • md5Sum
      StringRequired

      The MD5 checksum of the image.

    • url
      StringRequired

      The URL of the image.

    • mediaType
      StringRequired

      The image type.

    • guestOsType
      StringRequired

      The guest operating system type of the image.

    • type
      StringRequired

      The reserved field.

    • platform
      StringRequired

      The system platform of the image.

    • architecture
      StringRequired

      The image architecture.

    • format
      StringRequired

      The image format, for example, raw.

    • system
      BooleanRequired

      Whether the image is a system image.

    • virtio
      BooleanRequired

      Whether virtio is supported or not.

    • createDate
      TimestampRequired

      The creation date.

    • lastOpDate
      TimestampRequired

      The last operation date.

    • backupStorageRefs
      ListRequired

      See backupStorageRefs.

      • imageUuid
        StringRequired

        The image UUID.

      • backupStorageUuid
        StringRequired

        The backup storage UUID.

      • installPath
        StringRequired

        The installation path.

      • exportUrl
        StringRequired

        The export URL.

      • exportMd5Sum
        StringRequired

        The export MD5 sum.

      • status
        StringRequired

        The resource status.

      • createDate
        TimestampRequired

        The creation date.

      • lastOpDate
        TimestampRequired

        The last operation date.