Billing / Client / update_billing_preferences
update_billing_preferences¶
- Billing.Client.update_billing_preferences(**kwargs)¶
Updates billing preferences for the specified feature. Each feature targets a distinct billing capability and has its own set of supported keys. The action sets the value for each provided key; keys not present in the request are unchanged.
Sharing keys (
RI_SHARING,CREDIT_SHARING,CREDIT_LEVEL_SHARING, and sharing keys underCREDIT_PREFERENCE_OPTIONS) may only be set by the management account of a consolidated billing family. Thecredit/{creditId}/statuskey may be set by member accounts for credits they own, or by the management account for any credit in the family.See also: AWS API Documentation
Request Syntax
response = client.update_billing_preferences( feature='RI_SHARING'|'RI_SHARING_HISTORY'|'CREDIT_SHARING'|'CREDIT_SHARING_HISTORY'|'CREDIT_LEVEL_SHARING'|'BILLING_ALERTS'|'CREDIT_PREFERENCE_OPTIONS', billingPreferencesPerKey=[ { 'key': 'string', 'value': 'ENABLED'|'DISABLED' }, ] )
- Parameters:
feature (string) –
[REQUIRED]
The feature to update. Valid values:
BILLING_ALERTS,RI_SHARING,CREDIT_SHARING,CREDIT_LEVEL_SHARING,CREDIT_PREFERENCE_OPTIONS. The history features (RI_SHARING_HISTORYandCREDIT_SHARING_HISTORY) are read-only and cannot be updated.billingPreferencesPerKey (list) –
[REQUIRED]
Key/value pairs to apply. All keys in a single request must be valid for the specified
featureand must not be duplicated. ForCREDIT_PREFERENCE_OPTIONS, all keys must reference the samecreditId.(dict) –
A single key/value entry used to update a billing preference.
key (string) – [REQUIRED]
The preference key. Format depends on the feature being updated.
value (string) – [REQUIRED]
The preference value. Valid values:
ENABLEDorDISABLED.
- Return type:
dict
- Returns:
Response Syntax
{}Response Structure
(dict) –
Exceptions