CreateDisasterRecoverGroup

Last updated: 2020-08-14 10:08:53

1. API Description

Domain name for API request: cvm.tencentcloudapi.com.

This API is used to create a spread placement group. After you create one, you can specify it for an instance when you create the instance,

A maximum of 10 requests can be initiated per second for this API.

Note: This API supports Finance regions. If the common parameter Region is a Finance region, a domain name with the Finance region needs to be specified, for example: cvm.ap-shanghai-fsi.tencentcloudapi.com

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common parameter. The value used for this API: CreateDisasterRecoverGroup.
Version Yes String Common parameter. The value used for this API: 2017-03-12.
Region Yes String Common parameter. For more information, please see the list of regions supported by the product.
Name Yes String Name of the spread placement group. The name must be 1-60 characters long and can contain both Chinese characters and English letters.
Type Yes String Type of the spread placement group. Valid values:
  • HOST: physical machine
  • SW: switch
  • RACK: rack
  • ClientToken No String A string used to ensure the idempotency of the request, which is generated by the user and must be unique to each request. The maximum length is 64 ASCII characters. If this parameter is not specified, the idempotency of the request cannot be guaranteed.
    For more information, see 'How to ensure idempotency'.

    3. Output Parameters

    Parameter Name Type Description
    DisasterRecoverGroupId String List of spread placement group IDs.
    Type String Type of the spread placement group. Valid values:
  • HOST: physical machine
  • SW: switch
  • RACK: rack.
  • Name String Name of the spread placement group. The name must be 1-60 characters long and can contain both Chinese characters and English letters.
    CvmQuotaTotal Integer The maximum number of CVMs in a placement group.
    CurrentNum Integer The current number of CVMs in a placement group.
    CreateTime Timestamp Creation time of the placement group.
    RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

    4. Example

    Example1 Creating a spread placement group

    Create a spread placement group

    Input Example

    GET https://cvm.tencentcloudapi.com/?Action=CreateDisasterRecoverGroup
    &Name=Physical machine disaster recovery group
    &Type=HOST
    &<Common request parameter>

    Output Example

    {
      "Response": {
        "Type": "HOST",
        "DisasterRecoverGroupId": "ps-qajfd25h",
        "Name": "Physical machine disaster recovery group",
        "CvmQuotaTotal": 50,
        "CurrentNum": 0,
        "CreateTime": "2018-06-08T07:26:38Z",
        "RequestId": "21387009-9b9c-4b57-8fa2-8228f702ff6c"
      }
    }

    5. Developer Resources

    API Explorer

    This tool allows online call, signature authentication, SDK code generation and quick search of APIs to greatly improve the efficiency of using TencentCloud APIs.

    SDK

    TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

    Command Line Interface

    6. Error Code

    The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

    Error Code Description
    InvalidParameterValue.Range Invalid parameter value: invalid parameter value range.
    InvalidParameterValue.TooLong Invalid parameter value: parameter value is too long.

    Was this page helpful?

    Was this page helpful?

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