Share Images

Last updated: 2020-06-05 20:53:24


    This is a legacy API which has been hidden and will no longer be updated. We recommend using the new CVM API 3.0 which is standardized and faster.

    1. API Description

    This API (ShareImage) is used to share images.

    Domain name for API request:

    • Sharers of the image can use this image to create instances.
    • Each custom image can be shared to a maximum of 50 accounts.
    • A shared image can only be used to create instances and its name and description cannot be changed.
    • The share-to region of image should be the region of the sharer.

    2. Input Parameters

    The following list only provides API request parameters. For additional parameters, refer to Common Request Parameters page.

    Parameter Name Required Type Description
    imageId Yes String Image ID, which can be obtained from unImgId in the returned field of DescribeImages API.
    uinList.n Yes String Account ID of the user sharing the image (This API allows passing multiple IDs at a time. For the format of this parameter, refer to id.n section of API Introduction).

    3. Output Parameters

    Parameter Name Type Description
    code Int Common error code. A value of 0 indicates success, and other values indicate failure. For more information, refer to Common Error Codes on Error Code page.
    message String Module error message description depending on API. For more information, refer to Module Error Codes on Error Code page.

    4. Example

    &<Common request parameters>



    Was this page helpful?

    Was this page helpful?

    • Not at all
    • Not very helpful
    • Somewhat helpful
    • Very helpful
    • Extremely helpful
    Send Feedback