DDC Configurations
This page describes the APIs that can be used to retrieve and update StandbyMP Configurations.
Configuration(s) Listing API
Purpose:
Returns existing Configuration(s) and related settings, such as Automated Standby Update, Standby Update Delay, Email and Slack settings, Observer, etc.
API:
GET /api/configurations
to get information about all the Configurations
GET /api/configurations/{configurationId}
to get information about the specific one
Request body:
None.
Curl example:
curl -k -u admin:admin https://localhost:4433/api/configurations/1
Successful response body:
Edit Configuration API
Purpose:
Allows updating Configuration parameters and settings, such as Automated Standby Update, Standby Update Delay, Email and Slack settings, Observer, etc.
Warning: This API allows to change all the Configuration parameters. Please be careful while using.
Parameters in the request body override only the corresponding parameters in Configuration.
API:
PUT /api/configurations/{configurationId}
to bulk update parameters,
PUT /api/configurations/{configurationId}/Settings/AutomatedStandbyUpdate/Enabled
to update 1 parameter
Request body:
{
"Settings": {
"AutomatedStandbyUpdate": {
"Enabled": false
}
}
}
Curl example:
curl -k -u admin:admin -X PUT -d '{"Settings": {"AutomatedStandbyUpdate": {"Enabled": false}}}' https://localhost:4433/api/configurations/1
OR
curl -k -u admin:admin -X PUT -d 'false' https://localhost:4433/api/configurations/1/Settings/AutomatedStandbyUpdate/Enabled
Successful response body:
{
"Status": 200,
"Result": {}
}
Configuration(s) API Usage Examples
For getting comprehensive JSON output results, while using API, we parse all outputs with “jq” which can be easily installed by for example as root:
In all below examples we use authentication method via “-u” for authentication method via cookie, check the Authentication page
Configuration Details
To list all configurations keys and values information run:
List specific value for any key for all configurations:
To see specific value for specific key for specific configuration (In this example called MEGA):
Another example of listing all configurations and names with automated standby update disabled: