fabiog1901.cockroachdb.cc_invoice_info module – List invoices for a given organization.
Note
This module is part of the fabiog1901.cockroachdb collection (version 1.0.0).
To install it, use: ansible-galaxy collection install fabiog1901.cockroachdb
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: fabiog1901.cockroachdb.cc_invoice_info
.
New in fabiog1901.cockroachdb 1.0.0
Synopsis
List invoices for a given organization.
A Cockroach Cloud Service Account API Key is required.
Export the key as environment variable ‘CC_KEY’ or pass it on module invokation
Requirements
The below requirements are needed on the host that executes this module.
cockroachdb-cloud-client
Parameters
Parameter |
Comments |
---|---|
Define details for the API client |
|
The API version to use Default: |
|
The Service Account API key This value is log redacted By default it reads the env variable ‘CC_KEY’ |
|
the hostname of the API server Default: |
|
the path to the API endpoint Default: |
|
the port number, as a string, for the API server Default: |
|
http or https Choices:
|
|
whether the client should verify the server cert Choices:
|
|
Examples
- name: list my bills
fabiog1901.cockroachdb.cc_invoice_info:
# invoice_id:
api_client:
api_version: '2022-09-20'
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
Invoices are sorted by PeriodStart time. [ Invoice message represents the details and the total charges associated with one billing period, which starts at the beginning of the month and ends at the beginning of the next month. The message also includes details about each invoice item. ] Returned: always |
|
Balances are the amounts of currency left at the time of the invoice. Returned: always |
|
Amount is the quantity of currency. Returned: always |
|
Currency is the set of currencies supported in CockroachCloud. Allowed: USD┃CRDB_CLOUD_CREDITS Returned: always |
|
Returned: always |
|
InvoiceItems are sorted by the cluster name. Returned: always |
|
Returned: success |
|
Returned: always |
|
GCP: The Google Cloud Platform cloud provider. AWS: The Amazon Web Services cloud provider. Allowed: GCP┃AWS Returned: always |
|
Returned: always |
|
config details for either dedicated or serverless. Returned: always |
|
present only if dedicated cluster Returned: success |
|
DiskIOPs is the number of disk I/O operations per second that are permitted on each node in the cluster. Zero indicates the cloud provider-specific default. Returned: always |
|
MachineType is the machine type identifier within the given cloud provider, ex. m5.xlarge, n2-standard-4. Returned: always |
|
NumVirtualCPUs is the number of virtual CPUs per node in the cluster. Returned: always |
|
StorageGiB is the number of storage GiB per node in the cluster. Returned: always |
|
present only if serverless cluster Returned: success |
|
Used to build a connection string. Returned: always |
|
Spend limit in US cents. Returned: always |
|
date-time Returned: always |
|
Returned: always |
|
date-time Returned: success |
|
Returned: always |
|
Returned: always |
|
Allowed: CLUSTER_STATUS_UNSPECIFIED┃CRDB_MAJOR_UPGRADE_RUNNING┃CRDB_MAJOR_UPGRADE_FAILED┃CRDB_MAJOR_ROLLBACK_RUNNING┃CRDB_MAJOR_ROLLBACK_FAILED┃CRDB_PATCH_RUNNING┃CRDB_PATCH_FAILED┃CRDB_SCALE_RUNNING┃CRDB_SCALE_FAILED┃MAINTENANCE_RUNNING┃CRDB_INSTANCE_UPDATE_RUNNING┃CRDB_INSTANCE_UPDATE_FAILED┃CRDB_EDIT_CLUSTER_RUNNING┃CRDB_EDIT_CLUSTER_FAILED┃CRDB_CMEK_OPERATION_RUNNING┃CRDB_CMEK_OPERATION_FAILED┃TENANT_RESTORE_RUNNING┃TENANT_RESTORE_FAILED┃CRDB_LOG_EXPORT_OPERATION_RUNNING┃CRDB_LOG_EXPORT_OPERATION_FAILED Returned: always |
|
DEDICATED: A paid plan that offers dedicated hardware in any location. CUSTOM: A plan option that is used for clusters whose machine configs are not supported in self-service. All INVOICE clusters are under this plan option. SERVERLESS: A paid plan that runs on shared hardware and caps the users’ maximum monthly spending to a user-specified (possibly 0) amount. Allowed: DEDICATED┃CUSTOM┃SERVERLESS Returned: always |
|
Returned: always |
|
InternalDns is the internal DNS name of the cluster within the cloud provider’s network. It is used to connect to the cluster with PrivateLink or VPC peering. Returned: always |
|
cluster name Returned: always |
|
NodeCount will be 0 for serverless clusters. Returned: always |
|
SqlDns is the DNS name of SQL interface of the cluster. It is used to connect to the cluster with IP allowlisting. Returned: always |
|
UiDns is the DNS name used when connecting to the DB Console for the cluster. Returned: always |
|
LOCKED: An exclusive operation is being performed on this cluster. Other operations should not proceed if they did not set a cluster into the LOCKED state. Allowed: CREATING┃CREATED┃CREATION_FAILED┃DELETED┃LOCKED Returned: always |
|
Returned: always |
|
LineItems contain all the relevant line items from the Metronome invoice. Returned: success |
|
Description contains the details of the line item (i.e t3 micro). Returned: always |
|
Quantity is the number of the specific line items used. Returned: always |
|
Billing QuantityUnitType is the unit type for a quantity of billing line item. Allowed: HOURS┃REQUEST_UNITS Returned: success |
|
Returned: success |
|
Amount is the quantity of currency. Returned: always |
|
Currency is the set of currencies supported in CockroachCloud. Allowed: USD┃CRDB_CLOUD_CREDITS Returned: always |
|
UnitCost is the cost per unit of line item. Returned: always |
|
Totals is a list of the total amounts of line items per currency. Returned: success |
|
Amount is the quantity of currency. Returned: always |
|
Currency is the set of currencies supported in CockroachCloud. Allowed: USD┃CRDB_CLOUD_CREDITS Returned: always |
|
PeriodEnd is the end of the billing period (exclusive). Returned: always |
|
PeriodStart is the start of the billing period (inclusive). Returned: always |
|
Returned: success |
|
Amount is the quantity of currency. Returned: always |
|
Currency is the set of currencies supported in CockroachCloud. Allowed: USD┃CRDB_CLOUD_CREDITS Returned: always |
Authors
Cockroach Labs