Update a cross-cluster API key
Update the attributes of an existing cross-cluster API key, which is used for API key based remote cluster access.
Path parameters
-
The ID of the cross-cluster API key to update.
Body Required
-
Additional properties are allowed.
-
expiration string
A duration. Units can be
nanos
,micros
,ms
(milliseconds),s
(seconds),m
(minutes),h
(hours) andd
(days). Also accepts "0" without a unit and "-1" to indicate an unspecified value. -
metadata object
PUT
/_security/cross_cluster/api_key/{id}
curl \
-X PUT http://api.example.com/_security/cross_cluster/api_key/{id} \
-H "Content-Type: application/json" \
-d '{"access":{"replication":[{"names":"string","allow_restricted_indices":true}],"search":[{"field_security":{"except":"string","grant":"string"},"names":"string","":"string","allow_restricted_indices":true}]},"expiration":"string","metadata":{"additionalProperty1":{},"additionalProperty2":{}}}'
Request examples
{
"access": {
"replication": [
{
"names": "string",
"allow_restricted_indices": true
}
],
"search": [
{
"field_security": {
"except": "string",
"grant": "string"
},
"names": "string",
"": "string",
"allow_restricted_indices": true
}
]
},
"expiration": "string",
"metadata": {
"additionalProperty1": {},
"additionalProperty2": {}
}
}
Response examples (200)
{
"updated": true
}