Modify a setting
PUT /accounts/{account_id}/core/v1/settings/{setting_id}
Replaces the entire stored resource with the supplied JSON request body while preserving key values that are not user-modifiable.
Parameters
Name | Type | In | Required | Description |
---|---|---|---|---|
account_id |
string |
path |
True |
ID of the containing account resource
|
setting_id |
string |
path |
True |
ID of the setting collection to list |
Request Body
Replaces the entire stored resource with the supplied JSON request body while preserving key values that are not user-modifiable.
Name | Type | Required | Description |
---|---|---|---|
type |
string |
True |
Media type of the resource. Defined values are:
|
version |
string |
True |
Version of the resource. Defined values are:
|
id |
string |
False |
Globally unique identifier of the resource. Defined values are:
|
name |
string |
False |
JSON string containing a name for the setting, in hierarchal dot notation (.). Defined values are:
|
currentConfig |
False |
JSON object containing keys and values that make up the current configuration for this setting. The contents of this object must conform to the JSON Schema contained in the configSchema field. Default values are supplied by the configmap. After defaults are changed by the user, they will not be overwritten. |
|
desiredConfig |
False |
JSON object containing keys and values that make up the requested configuration for this setting. The contents of this object must conform to the JSON schema contained in the configSchema field. The object does not exist until specified. When specified, this triggers the feature service to notify the corresponding service to request that the desired configuration can be applied. The corresponding service can then perform validation and apply the desired configuration to the current configuration. |
|
configSchema |
False |
JSON object containing the JSON schema for the config property in this resource. Must conform to JSON Schema Draft 7. If config values are present in the resource, validation against the indicated configSchema is mandatory. As a common convention, configurations are recommended to have an "isEnabled" field, when appropriate. The "isEnabled" field contains a value that indicates whether the setting is turned on ("true") or off ("false"). |
|
state |
string |
False |
JSON string containing a value indicating the operational state of the application. Defined values are:
|
stateUnready |
array[string] |
False |
JSON array of JSON strings, each indicating a reason why the setting was not successfully applied. Defined values are:
|
metadata |
False |
Client and service-specified metadata associated with the resource. Defined values are:
|
Example request
{
"type": "application/astra-setting",
"version": "1.0",
"desiredConfig": {
"credential": "e3d2ea77-398e-49be-85fd-ec66d9426a06",
"port": 587,
"relayServer": "smtp.sendgrid.net",
"isEnabled": "true"
}
}
Response
Status: 204, Indicates if the setting resource was updated.
Response
Status: 401, Unauthorized
Name | Type | Required | Description |
---|---|---|---|
type |
string |
True |
|
title |
string |
True |
|
detail |
string |
False |
|
status |
string |
True |
|
correlationID |
string |
False |
Example response
{
"type": "https://astra.netapp.io/problems/3",
"title": "Missing bearer token",
"detail": "The request is missing the required bearer token.",
"status": "401"
}
Response
Status: 400, Bad request
Name | Type | Required | Description |
---|---|---|---|
type |
string |
True |
|
title |
string |
True |
|
detail |
string |
False |
|
status |
string |
True |
|
correlationID |
string |
False |
|
invalidFields |
array[invalidFields] |
False |
List of invalid request body fields |
Example response
{
"type": "https://astra.netapp.io/problems/5",
"title": "Invalid query parameters",
"detail": "The supplied query parameters are invalid.",
"status": "400"
}
Response
Status: 409, Conflict
Name | Type | Required | Description |
---|---|---|---|
type |
string |
True |
|
title |
string |
True |
|
detail |
string |
False |
|
status |
string |
True |
|
correlationID |
string |
False |
|
invalidFields |
array[invalidFields] |
False |
List of invalid request body fields |
Example response
{
"type": "https://astra.netapp.io/problems/10",
"title": "JSON resource conflict",
"detail": "The request body JSON contains a field that conflicts with an idempotent value.",
"status": "409"
}
Response
Status: 403, Forbidden
Name | Type | Required | Description |
---|---|---|---|
type |
string |
True |
|
title |
string |
True |
|
detail |
string |
False |
|
status |
string |
True |
|
correlationID |
string |
False |
Example response
{
"type": "https://astra.netapp.io/problems/11",
"title": "Operation not permitted",
"detail": "The requested operation isn't permitted.",
"status": "403"
}
Error
Status: 404, Not found
Name | Type | Required | Description |
---|---|---|---|
type |
string |
True |
|
title |
string |
True |
|
detail |
string |
False |
|
status |
string |
True |
|
correlationID |
string |
False |
Example error response
{
"type": "https://astra.netapp.io/problems/2",
"title": "Collection not found",
"detail": "The collection specified in the request URI wasn't found.",
"status": "404"
}
Definitions
See Definitions
type_json
JSON object containing keys and values that make up the current configuration for this setting. The contents of this object must conform to the JSON Schema contained in the configSchema field. Default values are supplied by the configmap. After defaults are changed by the user, they will not be overwritten.
type_json
JSON object containing keys and values that make up the requested configuration for this setting. The contents of this object must conform to the JSON schema contained in the configSchema field. The object does not exist until specified. When specified, this triggers the feature service to notify the corresponding service to request that the desired configuration can be applied. The corresponding service can then perform validation and apply the desired configuration to the current configuration.
properties
type_json_schema
JSON object containing the JSON schema for the config property in this resource. Must conform to JSON Schema Draft 7. If config values are present in the resource, validation against the indicated configSchema is mandatory. As a common convention, configurations are recommended to have an "isEnabled" field, when appropriate. The "isEnabled" field contains a value that indicates whether the setting is turned on ("true") or off ("false").
Name | Type | Required | Description |
---|---|---|---|
$schema |
string |
True |
|
type |
string |
True |
|
properties |
True |
||
additionalProperties |
boolean |
True |
|
required |
array[string] |
True |
type_astra_label
Name | Type | Required | Description |
---|---|---|---|
name |
string |
True |
|
value |
string |
True |
type_astra_metadata_update
Client and service-specified metadata associated with the resource. Defined values are:
-
Conforms to the Astra Metadata Schema If not specified on update, the metadata object's labels, creationTimestamp and createdBy, will be preserved without modification.
Name | Type | Required | Description |
---|---|---|---|
labels |
array[type_astra_label] |
False |
|
creationTimestamp |
string |
False |
|
modificationTimestamp |
string |
False |
|
createdBy |
string |
False |
|
modifiedBy |
string |
False |
invalidParams
Name | Type | Required | Description |
---|---|---|---|
name |
string |
True |
Name of the invalid query parameter |
reason |
string |
True |
Reason why the query parameter is invalid |
invalidFields
Name | Type | Required | Description |
---|---|---|---|
name |
string |
True |
Name of the invalid request body field |
reason |
string |
True |
Reason why the request body field is invalid |