Replaces the low balance notification and auto top-up settings. The update writes the
whole setting, so send every field you want to keep; omitted fields take their
defaults.
When `send_topup` is `true`, `topup_amount_in_microdollars` and
`topup_payment_method_id` are required. The threshold must be a whole number of cents
between 5,000,000 and 1,000,000,000,000 microdollars, and the top-up amount a whole
number of cents of at least 10,000,000 microdollars (10.00 USD). Some spaces are
required to keep auto top-up on; disabling it there is rejected with
`send_topup_cannot_be_disabled`.
#### Permissions
Authenticate with a [Personal access token](/docs/apis/authorization#personal-access-tokens) whose holder is an owner or admin of the space. A project API token is not accepted on this endpoint, and a Personal access token has no scopes: the holder's role in the space is the whole authorization decision.
Request
This endpoint expects an object.
threshold_in_microdollarslongOptional5000000-1000000000000
The balance, in microdollars, below which notifications and auto top-up trigger. A whole number of cents, at least 5,000,000 (5.00 USD) and at most 1,000,000,000,000 (1,000,000 USD). Defaults to the platform default when omitted.
send_emailbooleanOptionalDefaults to true
Whether to send an email when the balance falls below the threshold.
send_webhookbooleanOptionalDefaults to false
Whether to send a webhook when the balance falls below the threshold.
webhook_urlstringOptional
The URL to send the low balance webhook to. Required when send_webhook is true (webhook_url_missing).
webhook_methodenumOptionalDefaults to POST
The HTTP method for the low balance webhook: GET or POST.
send_topupbooleanOptionalDefaults to false
Whether to top the balance up automatically when it falls below the threshold. Some spaces are required to keep auto top-up on; disabling it there is rejected with send_topup_cannot_be_disabled.
topup_amount_in_microdollarslongOptional>=10000000
The amount, in microdollars, to deposit on each auto top-up. Required when send_topup is true (topup_amount_missing). A whole number of cents and at least 10,000,000 (10.00 USD).
topup_payment_method_idstringOptionalformat: "uuid"
The payment method to charge on each auto top-up. Required when send_topup is true (topup_payment_method_missing) and must name a payment method on this space (topup_payment_method_invalid).
Response
The request has succeeded.
typeenum
The object type. Always low_balance_setting.
threshold_in_microdollarslong
The balance, in microdollars, below which notifications and auto top-up trigger. Falls back to the platform default when never configured.
thresholddouble
The threshold in US dollars. The same value as threshold_in_microdollars.
send_emailboolean
Whether an email is sent when the balance falls below the threshold.
send_webhookboolean
Whether a webhook is sent when the balance falls below the threshold.
webhook_urlstring or null
The URL the low balance webhook is sent to, or null when none is set.
webhook_methodenum or null
The HTTP method used for the low balance webhook, or null when none is set.
send_topupboolean
Whether auto top-up is enabled.
topup_amount_in_microdollarslong or null
The amount, in microdollars, deposited by each auto top-up. Can be null.
topup_amountdouble or null
The auto top-up amount in US dollars. The same value as topup_amount_in_microdollars.
topup_payment_method_idstring or nullformat: "uuid"
The payment method charged by auto top-up, or null when none is set.