Add or update license

PUT /platform/license

Adds a new or updates an existing license.

application/json

Body Required

The license to add or update.

  • license object Required

    License data

    Hide license attributes Show license attributes object
    • version integer(int32)

      Version of the license

    • uid string Required

      Unique identifier of the license

    • issuer string Required

      Issuer of the license

    • issued_to string Required

      Entity the license was issued to

    • issue_date_in_millis integer(int64) Required

      When the license was issued, in milliseconds since the Unix epoch

    • type string Required

      Type of the license

    • subscription_type string

      Type of the license subscription

    • signature string Required

      Digital signature

    • start_date_in_millis integer(int64) Required

      Initial validity of the license, in milliseconds since the Unix epoch

    • expiry_date_in_millis integer(int64) Required

      When the license expires, in milliseconds since the Unix epoch

    • max_allocators integer(int32)

      Maximum number of allocators. Empty for version >= 3

    • max_ram_per_allocator_mb integer(int32)

      Maximum RAM per allocator in MB. Empty for version >= 3

    • max_instances integer(int32)

      Maximum number of instances. Only present for version 3

    • max_resource_units integer(int32)

      Maximum number of resource units, where each unit is 64GB. Only present for version > 3

    • operation_mode string

      Operation mode

    • cluster_licenses array[object]

      List of cluster licenses

      Information about the Elasticsearch cluster license.

      Hide cluster_licenses attribute Show cluster_licenses attribute object
      • license object Required

        Object containing the cluster license data

Responses

  • 200 application/json

    The license was updated.

  • 400 application/json

    The license could not be updated. (code: license.invalid_license)

    Hide headers attribute Show headers attribute
    • x-cloud-error-codes string

      The error codes associated with the response

      Value is license.invalid_license.

    Hide response attribute Show response attribute object
    • errors array[object] Required

      A list of errors that occurred in the failing request

      Hide errors attributes Show errors attributes object
      • code string Required

        A structured code representing the error type that occurred

      • message string Required

        A human readable message describing the error that occurred

      • fields array[string]

        If the error can be tied to a specific field or fields in the user request, this lists those fields

PUT /platform/license
curl \
 --request PUT 'https://{{hostname}}/api/v1/platform/license' \
 --user "username:password" \
 --header "Content-Type: application/json" \
 --data '{"license":{"version":42,"uid":"string","issuer":"string","issued_to":"string","issue_date_in_millis":42,"type":"string","subscription_type":"string","signature":"string","start_date_in_millis":42,"expiry_date_in_millis":42,"max_allocators":42,"max_ram_per_allocator_mb":42,"max_instances":42,"max_resource_units":42,"operation_mode":"string","cluster_licenses":[{"license":{}}]}}'