Billing

class coto.clients.billing.Client(session)[source]

A low-level client representing Biling:

import coto

session = coto.Session()
client = session.client('billing')

These are the available methods:

account_status()[source]

Obtain the status of the account.

Status:
ACTIVE:
Active
SUSPENDED:
Suspended, will be deleted within 90 days
Request Syntax:
response = client.account_status()
Returns:status
Return type:string
close_account()[source]

Close the account. Returns True iff successful, otherwise throws an exception.

Request Syntax:
client.close_account()
Returns:success
Return type:boolean
delete_tax_registration(TaxRegistration)[source]

Delete the given tax registrations from the account.

Request Syntax:
response = client.delete_tax_registration(
    TaxRegistration={
        'address': {
            'addressLine1': str,
            'addressLine2': str,
            'city': str,
            'countryCode': str,
            'postalCode': str,
            'state': str,
        },
        'authority': {
            'country': str,
            'state': str
        },
        'legalName': str,
        'localTaxRegistration': bool,
        'registrationId': str,
    }
)
Parameters:TaxRegistration (dict) – Tax registration to delete.
list_alternate_contacts()[source]

Lists the alternate contacts set for the account. In order to keep the right people in the loop, you can add an alternate contact for Billing, Operations, and Security communications.

Request Syntax:
response = client.list_alternate_contacts()
Returns:Response Syntax
[
    {
        'contactId': int,
        'contactType': 'billing' | 'operations' | 'security',
        'email': str,
        'name': str,
        'phoneNumber': str,
        'title': str
    },
]
Return type:dict
list_tax_registrations()[source]

Lists the tax registrations set for the account. Set your tax information so that your 1099K or W-88EN is generated appropriately. Setting this information up also allows you to sell more than 200 transactions or $20,000 in Reserved Instances.

Status:
Verified:
Verified
Pending:
Pending
Deleted:
Deleted
Request Syntax:
response = client.list_tax_registrations()
Returns:Response Syntax
[
    {
        'address': {
            'addressLine1': str,
            'addressLine2': str,
            'city': str,
            'countryCode': str,
            'postalCode': str,
            'state': str,
        },
        'authority': {
            'country': str,
            'state': str
        },
        'currentStatus': 'Verified' | 'Pending',
        'legalName': str,
        'localTaxRegistration': bool,
        'registrationId': str
    },
]
Return type:dict
set_alternate_contacts(AlternateContacts)[source]

Sets the alternate contacts set for the account. In order to keep the right people in the loop, you can add an alternate contact for Billing, Operations, and Security communications.

Please note that, the primary account holder will continue to receive all email communications.

Contact Types:
billing:
The alternate Billing contact will receive billing-related notifications, such as invoice availability notifications.
operations:
The alternate Operations contact will receive operations-related notifications.
security:
The alternate Security contact will receive security-related notifications. For additional AWS security-related notifications, please access the Security Bulletins RSS Feed.
Request Syntax:
response = client.set_alternate_contacts(
    AlternateContacts=[
        {
            'contactType': 'billing',
            'email': str,
            'name': str,
            'phoneNumber': str,
            'title': str
        },
        {
            'contactType': 'operations',
            'email': str,
            'name': str,
            'phoneNumber': str,
            'title': str
        },
        {
            'contactType': 'security',
            'email': str,
            'name': str,
            'phoneNumber': str,
            'title': str
        },
    ]
)
Parameters:AlternateContacts (list) – List of alternate contacts.
set_tax_registration(TaxRegistration)[source]

Set the tax registrations for the account. Set your tax information so that your 1099K or W-88EN is generated appropriately. Setting this information up also allows you to sell more than 200 transactions or $20,000 in Reserved Instances.

Request Syntax:
response = client.set_tax_registration(
    TaxRegistration={
        'address': {
            'addressLine1': str,
            'addressLine2': str,
            'city': str,
            'countryCode': str,
            'postalCode': str,
            'state': str,
        },
        'authority': {
            'country': str,
            'state': str
        },
        'legalName': str,
        'localTaxRegistration': bool,
        'registrationId': str,
    }
)
Parameters:TaxRegistration (dict) – Desired tax registration.