Update account setting
2 minute read
PATCH
https://www.digicert.com/partner-subscription/api/v1/account/settings
Use this endpoint to update an account setting for the authenticated Partner Subscriptions account.
Each request updates one setting. To update a setting, provide the setting name and the new value in the request body.
- This endpoint updates settings for the account authenticated by the
X-PARTNER-APIKEYheader. Use a parent account Partner Subscriptions API key to update parent account settings. Use a subaccount Partner Subscriptions API key to update settings for that subaccount. - When you update a setting to the system default value, the account-specific override is removed. The next time you retrieve the setting,
is_defaultreturnstrue. - The
auto_renew_subscriptionsetting controls the default auto-renewal behavior for new ACME contracts. When set to1, new ACME contracts default to auto-renew enabled unless explicitly disabled during contract creation. When set to0, new ACME contracts default to auto-renew disabled unless explicitly enabled during contract creation.
Example requests and responses
curl -X PATCH \
https://www.digicert.com/partner-subscription/api/v1/account/settings \
-H 'Content-Type: application/json' \
-H 'X-PARTNER-APIKEY: {{partner_api_key}}' \
-d '{
"name": "auto_renew_subscription",
"value": "1"
}'import requests
url = "https://www.digicert.com/partner-subscription/api/v1/account/settings"
payload = "{\n \"name\": \"auto_renew_subscription\",\n \"value\": \"1\"\n}"
headers = {
'X-PARTNER-APIKEY': "{{partner_api_key}}",
'Content-Type': "application/json"
}
response = requests.request("PATCH", url, data=payload, headers=headers)
print(response.text)package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "https://www.digicert.com/partner-subscription/api/v1/account/settings"
payload := strings.NewReader("{\n \"name\": \"auto_renew_subscription\",\n \"value\": \"1\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-PARTNER-APIKEY", "{{partner_api_key}}")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}var request = require("request");
var options = {
method: 'PATCH',
url: 'https://www.digicert.com/partner-subscription/api/v1/account/settings',
headers: {
'Content-Type': 'application/json',
'X-PARTNER-APIKEY': '{{partner_api_key}}'
},
body: {
name: 'auto_renew_subscription',
value: '1'
},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});204 No Content
The account setting was updated successfully. The response does not include a body.
URL path and query parameters
This endpoint does not use URL path or query parameters.
Request parameters
| Name | Req/Opt | Type | Description | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| name | required | string | Name of the account setting to update. For example: auto_renew_subscription.Supported settings:
| ||||||||
| value | required | string | New value for the account setting. For auto_renew_subscription, use 0 to disable default auto-renewal or 1 to enable default auto-renewal for new ACME contracts. |
Response parameters
This endpoint does not return response parameters.
Was this page helpful?
Provide feedback