Responses

  • 200 application/json
    Hide response attributes Show response attributes object
    • aliasstring | null Required

      If the path refers to a container file (a jks keystore, or a PKCS#12 file), it is the alias of the certificate. Otherwise, it is null.

    • expirystring | number Required

      A date and time, either as a string whose format can depend on the context (defaulting to ISO 8601), or a number of milliseconds since the Epoch. Elasticsearch accepts both as input, but will generally output a string representation.

      One of:

      Time unit for milliseconds

    • formatstring Required

      The format of the file. Valid values include jks, PKCS12, and PEM.

    • has_private_keyboolean Required

      Indicates whether Elasticsearch has access to the private key for this certificate.

    • issuerstring

      The Distinguished Name of the certificate's issuer.

    • pathstring Required

      The path to the certificate, as configured in the elasticsearch.yml file.

    • serial_numberstring Required

      The hexadecimal representation of the certificate's serial number.

    • subject_dnstring Required

      The Distinguished Name of the certificate's subject.

GET /_ssl/certificates
GET /_ssl/certificates
resp = client.ssl.certificates()
const response = await client.ssl.certificates();
response = client.ssl.certificates
$resp = $client->ssl()->certificates();
curl -X GET -H "Authorization: ApiKey $ELASTIC_API_KEY" "$ELASTICSEARCH_URL/_ssl/certificates"
Response examples (200)
A successful response from `GET /_ssl/certificates`, which provides information about the certificates on a single node of Elasticsearch.
[
  {
    "path": "certs/elastic-certificates.p12",
    "format": "PKCS12",
    "alias": "instance",
    "subject_dn": "CN=Elastic Certificate Tool Autogenerated CA",
    "serial_number": "a20f0ee901e8f69dc633ff633e5cd5437cdb4137",
    "has_private_key": false,
    "expiry": "2021-01-15T20:42:49.000Z"
  },
  {
    "path": "certs/elastic-certificates.p12",
    "format": "PKCS12",
    "alias": "ca",
    "subject_dn": "CN=Elastic Certificate Tool Autogenerated CA",
    "serial_number": "a20f0ee901e8f69dc633ff633e5cd5437cdb4137",
    "has_private_key": false,
    "expiry": "2021-01-15T20:42:49.000Z"
  },
  {
    "path": "certs/elastic-certificates.p12",
    "format": "PKCS12",
    "alias": "instance",
    "subject_dn": "CN=instance",
    "serial_number": "fc1905e1494dc5230218d079c47a617088f84ce0",
    "has_private_key": true,
    "expiry": "2021-01-15T20:44:32.000Z"
  }
]