Creates a Logstash cluster.

Before you call the API operation, note that:

  • Before you call this operation, make sure that you have fully understood the payment method and price of Logstash.
  • Before you create an instance, you must complete real-name verification.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request headers

POST /openapi/logstashes

Request syntax

POST /openapi/logstashes HTTP/1.1

Request parameters

Parameter Type Position Required Example Description
clientToken String Query No 5A2CFF0E-5718-45B5-9D4D-70B3FF****

The client token that is used to ensure the idempotence of the request. You can use the client to generate the value, but you must ensure that the value is unique among different requests. The token can contain only ASCII characters and cannot exceed 64 characters in length.

Object Body Yes

The body of the request.

paymentType String Body No prepaid

The billing method of the instance. Default value: DEFAULT. Valid values:

  • prepaid: subscription
  • postpaid: pay-as-you-go
version String Body Yes 6.7_with_X-Pack

The version of the instance. Default value: DEFAULT. Valid values:

  • 6.7_with_X-Pack
  • 7.4_with_X-Pack
nodeAmount Integer Body Yes 2

The number of nodes contained in the instance.

nodeSpec Object Body Yes

The configuration of data nodes.

disk Long Body No 50

The disk size of the core node. Unit: GB.

diskType String Body No cloud_ssd

The disk type of the node. Default value: DEFAULT. Valid values:

  • cloud_ssd
  • cloud_efficiency
spec String Body Yes logstash.n4.small

node specifications, the specification information can be viewed by product specifications.

networkConfig Object Body Yes

The network configurations.

type String Body No vpc

The network type. Currently, only Virtual Private Cloud is supported.

vpcId String Body Yes vpc-bp16k1dvzxtmagcva****

The VPC ID of the cluster.

vswitchId String Body Yes vsw-bp1k4ec6s7sjdbudw****

The ID of the vSwitch.

vsArea String Body Yes cn-hangzhou-i

The zone where the cluster resides.

paymentInfo Object Body No

The payment details of a subscription instance. This parameter is required when you create a subscription instance.

duration Long Body No 1

The purchase duration. Monthly and yearly purchases are supported. Unit: January to September, 1 to 3 years.

pricingCycle String Body No Month

The unit of subscription. Valid values:

  • Year
  • Month
isAutoRenew Boolean Body No false

Indicates whether auto-renewal is enabled. Valid values:

  • true: Plug-ins are used.
  • false: Plug-ins are not used.
autoRenewDuration Long Body No 3

The duration for which the ApsaraDB for HBase cluster is automatically renewed after the cluster expires. Unit: month. This parameter is required if the isAutoRenew parameter is set to true. The range of parameter values is the same as that on the buy page.

description String Body No ls-cn-abc

The name of the VPC.

Response parameters

Parameter Type Example Description
RequestId String 5FFD9ED4-C2EC-4E89-B22B-1ACB6FE*****

The ID of the request.

Result Logstash

The result of the request.


Sample requests

POST /openapi/logstashes?clientToken=5A2CFF0E-5718-45B5-9D4D-70B3FF**** HTTP/1.1

  "paymentType" : "prepaid",
  "version" : "6.7_with_X-Pack",
  "nodeAmount" : 2,
  "nodeSpec" : {
    "disk" : 50,
    "diskType" : "cloud_ssd",
    "spec" : "logstash.n4.small"
  "networkConfig" : {
    "type" : "vpc",
    "vpcId" : "vpc-bp16k1dvzxtmagcva****",
    "vswitchId" : "vsw-bp1k4ec6s7sjdbudw****",
    "vsArea" : "cn-hangzhou-i"
  "paymentInfo" : {
    "duration" : 1,
    "pricingCycle" : "Month",
    "isAutoRenew" : false,
    "autoRenewDuration" : 3
  "description" : "ls-cn-abc"

Sample success responses

JSON format

HTTP/1.1 200 OK

  "RequestId" : "5FFD9ED4-C2EC-4E89-B22B-1ACB6FE*****",
  "Result" : [ {
    "instanceId" : "ls-cn-n6w1o5jq****",
    "version" : "6.7_with_X-Pack",
    "description" : "test",
    "nodeAmount" : 1,
    "paymentType" : "postpaid",
    "status" : "active",
    "enablePublic" : false,
    "nodeSpec" : {
      "spec" : "elasticsearch.sn1ne.large",
      "disk" : 20,
      "diskType" : "cloud_ssd"
    "networkConfig" : {
      "vpcId" : "vpc-bp16k1dvzxtmagcva****",
      "vswitchId" : "vsw-bp1k4ec6s7sjdbudw****",
      "vsArea" : "cn-hangzhou-i",
      "type" : "vpc"
    "createdAt" : "2020-05-27T01:30:15.947Z",
    "updatedAt" : "2020-05-27T01:40:51.333Z",
    "commodityCode" : "elasticsearch_logstash_post",
    "extendConfigs" : [ ],
    "endTime" : 4746268800000,
    "clusterTasks" : [ ],
    "resourceGroupId" : "rg-acfm2h5vbzd****",
    "zoneCount" : 1,
    "protocol" : "HTTP",
    "zoneInfos" : [ {
      "zoneId" : "cn-hangzhou-i",
      "status" : "NORMAL"
    } ],
    "instanceType" : "logstash",
    "inited" : true,
    "tags" : [ ],
    "config" : { },
    "endpointList" : [ {
      "host" : "172.16.**.**",
      "port" : 9600,
      "zoneId" : "cn-hangzhou-i"
    } ]
  } ]

Error codes

For a list of error codes, see Service error codes.