All Products
Search
Document Center

Elasticsearch:DescribeCollector

Last Updated:Feb 10, 2025

Queries the information about a shipper.

Debugging

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

This operation does not have operation-specific request headers and uses only common request headers. For more information, see the "Common request headers" section of the "Common parameters" topic.

Request syntax

GET /openapi/collectors/[ResId] HTTP/1.1

Request parameters

Parameter

Type

Location

Required

Example

Description

ResId

String

Path

Yes

ct-cn-rg31ahn82m0qd****

The shipper ID.

Response parameters

Parameter

Type

Example

Description

RequestId

String

5FFD9ED4-C2EC-4E89-B22B-1ACB6FE1****

The request ID.

Result

Struct

The returned result.

collectorPaths

List

["/var/log"]

The collection path of the shipper.

configs

Array of configs

The information about the configuration file of the shipper.

content

String

fileBeat.inputs:xxx

The content of the configuration file.

fileName

String

filebeat.yml

The name of the configuration file.

dryRun

Boolean

false

Indicates whether a dry run is performed. Valid values:

  • true

  • false

extendConfigs

Array of extendConfigs

The extended configurations of the shipper.

configType

String

collectorDeployMachine

The configuration type. Valid values:

  • collectorTargetInstance: indicates the information about the output of the shipper.

  • collectorDeployMachine: indicates the information about the machine on which the shipper is installed.

  • collectorElasticsearchForKibana: indicates the information about the Elasticsearch cluster for which Kibana Dashboard is enabled.

enableMonitoring

Boolean

true

Indicates whether Kibana Monitoring is enabled. This parameter is returned only when the value of configType is collectorTargetInstance. Valid values:

  • true

  • false

groupId

String

default_ct-cn-5i2l75bz4776****

The ID of the machine group. This parameter is returned only when the value of configType is collectorDeployMachine.

host

String

es-cn-n6w1o1x0w001c****-kibana.internal.elasticsearch.aliyuncs.com:5601

The address that is used to access Kibana over an internal network after you enable Kibana Dashboard. This parameter is returned only when the value of configType is collectorElasticsearchForKibana.

hosts

List

["es-cn-n6w1o1x*****.elasticsearch.aliyuncs.com:9200"]

The access addresses of the output of the shipper. This parameter is returned only when the value of configType is collectorTargetInstance.

instanceId

String

es-cn-n6w1o1****

The ID of the object that is associated with the shipper. If the value of configType is collectorTargetInstance, the value of this parameter is the ID of the resource specified in the output configuration part of the shipper. If the value of configType is collectorDeployMachine and the value of type is ACKCluster, the value of this parameter is the ID of the Container Service for Kubernetes (ACK) cluster.

instanceType

String

elasticsearch

The type of the output of the shipper. Valid values: elasticsearch and logstash. This parameter is returned only when the value of configType is collectorTargetInstance.

kibanaHost

String

https://es-cn-nif1z89fz003i****.kibana.elasticsearch.aliyuncs.com:5601

The address that is used to access Kibana over the Internet after you enable Kibana Dashboard. This parameter is returned only when the value of configType is collectorElasticsearchForKibana.

machines

Array of machines

The information about the ECS instances on which the shipper is installed. This parameter is returned only when the value of configType is collectorDeployMachine and the value of type is ECSInstanceId.

agentStatus

String

heartOk

The status of the shipper on the ECS instance. Valid values:

  • heartOk: The heartbeat is normal.

  • heartLost: The heartbeat is abnormal.

  • uninstalled: The shipper is not installed.

  • failed: The shipper fails to be installed.

instanceId

String

i-bp1gyhphjaj73jsr****

The ID of the ECS instance on which the shipper is installed.

protocol

String

HTTP

The transfer protocol that is used. It is the same as the protocol over which you can access the output of the shipper. Valid values: HTTP and HTTPS. This parameter is returned only when the value of configType is collectorTargetInstance.

successPodsCount

String

8

The number of pods from which data is succcessfully collected in the ACK cluster.

totalPodsCount

String

10

The number of pods from which logs needed to be collected in the ACK cluster.

type

String

ECSInstanceId

The type of the machine on which the shipper is installed. This parameter is returned only when the value of configType is collectorDeployMachine. Valid values:

  • ECSInstanceId

  • ACKCluster

userName

String

elastic

The username that is used to access the output of the shipper. Default value: elastic. This parameter is returned only when the value of configType is collectorTargetInstance or collectorElasticsearchForKibana.

gmtCreatedTime

String

2020-06-20T07:26:47.000+0000

The time when the shipper was created.

gmtUpdateTime

String

2020-06-20T07:26:47.000+0000

The time when the shipper was updated.

name

String

ct-cn-4135is2tj194p****

The name of the shipper.

ownerId

String

16852099488*****

The account ID.

resId

String

ct-cn-rg31ahn82m0qd****

The shipper ID.

resType

String

fileBeat

The type of the shipper. Valid values: fileBeat, metricBeat, heartBeat, and auditBeat.

resVersion

String

6.8.5_with_community

The version of the shipper.

status

String

active

The status of the shipper. Valid values:

  • activing: The shipper is being initialized.

  • active: The shipper is in effect.

vpcId

String

vpc-bp16k1dvzxtma*****

The ID of the virtual private cloud (VPC) in which the shipper resides.

The parameters returned in extendConfigs vary based on the value of configType. Valid values of configType include collectorTargetInstance, collectorElasticsearchForKibana, and collectorDeployMachine.

  • collectorTargetInstance

    • ECS

      configType, instanceId, instanceType, hosts, userName, password, protocol, and enableMonitoring

    • ACK

      configType, instanceId, instanceType, userName, password, protocol, and enableMonitoring

  • collectorElasticsearchForKibana

    • ECS

      configType, instanceId, host, kibanaHost, userName, password, and protocol

    • ACK

      configType

  • collectorDeployMachine

    • ECS

      configType, type, machines, and groupId

    • ACK

      configType, type, instanceId, totalPodsCount, and successPodsCount

Examples

Sample requests

GET /openapi/collectors/ct-cn-6z8b5eblvi706**** HTTP/1.1
Common request parameters

Sample success responses

JSON format

{
    "name": "filebeats",
    "resVersion": "6.8.5_with_community",
    "resId": "ct-cn-6fy17c8z99c7i****",
    "resType": "fileBeat",
    "ownerId": "168520994880****",
    "status": "active",
    "vpcId": "vpc-bp16k1dvzxtmagcva****",
    "dryRun": false,
    "gmtCreatedTime": "2020-11-05T12:42:47.000+0000",
    "gmtUpdateTime": "2020-11-06T05:13:10.000+0000",
    "collectorPaths": "/var/log/*.log",
    "configs": {
        "fileName": "/conf/filebeat.yml",
        "content": "fileBeat.inputs:xxx"
    },
    "extendConfigs": [
        {
            "instanceId": "es-cn-n6w1o1x0w001c****",
            "configType": "collectorElasticsearchForKibana",
            "host": "es-cn-n6w1o1x0w001c****-kibana.internal.elasticsearch.aliyuncs.com:5601",
            "kibanaHost": "https://es-cn-n6w1o1x0w001c****.kibana.elasticsearch.aliyuncs.com:5601",
            "userName": "elastic",
            "protocol": "HTTPS"
        },
        {
            "instanceId": "es-cn-n6w1o1x0w001c****",
            "instanceType": "elasticsearch",
            "configType": "collectorTargetInstance",
            "hosts": [
                "es-cn-n6w1o1x0w001c****.elasticsearch.aliyuncs.com:9200",
                "es-cn-nif1z89fz003i****.elasticsearch.aliyuncs.com:9200"
            ],
            "userName": "elastic",
            "protocol": "HTTPS",
            "enableMonitoring": true
        },
        {
            "machines": [
                {
                    "instanceId": "es-cn-n6w1o1x0w001c****",
                    "agentStatus": "heartOk"
                },
                {
                    "instanceId": "es-cn-nif1z89fz003i****",
                    "agentStatus": "heartOk"
                }
            ],
            "type": "ECSInstanceId",
            "configType": "collectorDeployMachine",
            "groupId": "default_ct-cn-6fy17c8z99c7i****"
        }
    ]
}

Error codes

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