<bucket_name>
and <folder_name>
are provided during destination configuration.<table_name>
is the name of the table being transferred (see the schema tables below for examples).<transfer_date>
and <transfer_timestamp>
are generated at transfer time and based on the transfer’s start time. <transfer_date>
is of the form 2025-01-01
, while <transfer_timestamp>
is of the form 20250102150405
.<file_part>
is a monotonically increasing integer for a given timestamp, and does not carry any special meaning.Metronome data | Table name | Transfer Frequency† | Average Freshness†† | Table Type |
---|---|---|---|---|
Alerts | alert | 2 hours | 4 hours | Incremental |
Alerts | customer_alert_history | 2 hours | 4 hours | Incremental |
Finalized Invoices | invoice | 2 hours | 4 hours | Incremental |
Finalized Invoices | line_item | 2 hours | 4 hours | Incremental |
Product | product | 2 hours | 4 hours | Incremental |
Charges | contracts_scheduled_charges | 24 hours | 24 hours | Snapshot |
Contracts | contracts_contracts | 24 hours | 24 hours | Snapshot |
Contracts | contracts_commits | 24 hours | 24 hours | Snapshot |
Contracts | contracts_balances | 24 hours | 24 hours | Snapshot |
Contracts | contracts_recurring_commits_and_credits | 24 hours | 24 hours | Snapshot |
Contracts | contracts_usage_filter_schedule | 24 hours | 24 hours | Snapshot |
Contracts | contracts_billing_provider_configuration | 24 hours | 24 hours | Snapshot |
Contracts | contracts_usage_filters | 24 hours | 24 hours | Snapshot |
Contracts | contracts_prepaid_balance_threshold_configurations | 24 hours | 24 hours | Snapshot |
Contracts | contracts_spend_threshold_configurations | 24 hours | 24 hours | Snapshot |
Contract Modifications | contracts_overrides | 24 hours | 24 hours | Snapshot |
Contract Modifications | contracts_transitions | 24 hours | 24 hours | Snapshot |
Contract Modifications | contracts_edits | 24 hours | 24 hours | Snapshot |
Contract Modifications | contracts_amendments | 24 hours | 24 hours | Snapshot |
Contract Pricing | contracts_rate_cards | 24 hours | 24 hours | Snapshot |
Contract Pricing | contracts_rate_card_entries | 24 hours | 24 hours | Snapshot |
Contract Pricing | contracts_product_list_item_versions | 24 hours | 24 hours | Snapshot |
Customers | customer | 2 hours | 4 hours | Incremental |
Customers | customer_billing_provider_configuration | 2 hours | 4 hours | Incremental |
Draft Invoices | draft_invoice | 24 hours | 24 hours | Snapshot |
Draft Invoices | draft_line_item | 24 hours | 24 hours | Snapshot |
Events | events | 2 hours | 4 hours | Incremental |
Credit Type | credit_type | 2 hours | 4 hours | Incremental |
Invoice Breakdowns | breakdowns_invoices | 24 hours | 24 hours | Incremental |
Invoice Breakdowns | breakdowns_line_items | 24 hours | 24 hours | Incremental |
Invoice Breakdowns | breakdowns_draft_invoices | 24 hours | 24 hours | Snapshot |
Invoice Breakdowns | breakdowns_draft_line_items | 24 hours | 24 hours | Snapshot |
updated_at
column to pull the latest updates.archived_at
column defines whether the contract has been archived or not.
Tables
contracts_overrides
table holds any overrides on top of an existing contract. The contracts_transitions
and contracts_edits
tables contain information about contracts ending, renewing, or changing.
Tables
Example 1 - Fetch the most recent overrides on a contract.
events
table. The archived_at
column is used to determine if the customer is active.
The contracts_billing_provider_configuration
table adds further context on the billing provider for the customer.
Tables
Example 1 - Fetch total active customers
updated_at
column is the time that the invoice row was calculated while the snapshot_time
corresponds to the start of day (UTC). An invoice row will be populated once per day throughout a billing period until it is finalized or voided.
If an invoice is in a DRAFT_INCOMPLETE
state, it means that Metronome hasn’t fully computed the invoice. There will be no line items or total on the invoice. Exporting these invoices lets you know that the invoice exists, but Metronome has failed to compute it for some reason. Exporting incomplete invoices enables Metronome to send data to the specified destination as soon as possible. We expect these incomplete invoices to be hydrated in future snapshots.
Tables
Example 1 - Fetch daily invoice totals
Nullable
column in the table below reflects how your data is stored in Metronome.metadata
metadata
column of each table as well as certain JSON-encoded objects.
alert
Column | Type | Description |
---|---|---|
id | string | The ID of the alert |
name | string | The name of the alert |
alert_type | string | The type of alert |
threshold | decimal | The threshold to trigger the alert |
webhooks_enabled | boolean | Indicates if the alert is configured for webhooks |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
created_at | timestamp | The timestamp (UTC) of when the alert was created |
disabled_at | timestamp | The timestamp (UTC) of when the alert was disabled |
updated_at | timestamp | The timestamp (UTC) of when the alert was last updated |
archived_at | timestamp | The timestamp (UTC) of when the alert was archived |
billable_metric
Column | Type | Description |
---|---|---|
id | string | ID of the billable metric |
aggregate | string | The aggregation type |
aggregate_keys | json | The keys used for aggregation |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
group_keys | json | The group by keys associated with this billable metric |
name | string | Name of the billable metric |
created_at | timestamp | The timestamp (UTC) of when the billable_metric was created |
archived_at | timestamp | The timestamp (UTC) of when the billable_metric was archived |
updated_at | timestamp | The timestamp (UTC) of when the billable_metric was last updated |
contracts_contracts
Column | Type | Description |
---|---|---|
id | string | ID of the contract |
name | string | Name of the contract |
customer_id | string | The customer ID of the contract |
rate_card_id | string | The rate card ID of the contract |
starting_at | timestamp | The contract start timestamp (UTC) |
ending_before | timestamp | The contract end timestamp (UTC). This timestamp is exclusive. |
archived_at | timestamp | The timestamp (UTC) of when the contract was archived. |
multiplier_override_prioritization | string | The prioritization for a multiplier override. There are two options: • Lowest multiplier (default): The lowest multiplier, aka the biggest discount, is used. • Explicit: The override with the lowest priority will be prioritized. |
net_payment_terms_days | integer | The amount of time a customer has to pay a contract. For example, “net 30” |
usage_statement_schedule_frequency | string | The usage statement generation frequency. For example, “monthly” or “quarterly”. |
scheduled_charges_on_usage_invoices | string | Valid values are ALL if scheduled invoices will be combined with usage invoices on the same date, otherwise null. |
created_at | timestamp | The timestamp (UTC) of when the contract was created |
created_by | string | The entity the contract was created by |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the contract row |
metadata | Metadata | JSON encoded object |
contracts_balances
Column | Type | Description |
---|---|---|
id | string | The ID of the balance |
customer_id | string | The customer ID of the balance |
contract_id | string | The contract ID of the balance |
amendment_id | string | The amendment ID of the balance |
type | string | Either postpaid , prepaid , or credit |
name | string | The name of the balance |
priority | float | The priority that defines the order of balance application |
description | string | The description of the balance |
product_id | string | The product ID associated with the balance |
access_schedule | json | AccessSchedule |
invoice_schedule | json | InvoiceSchedule - The invoice_schedule is always set for “postpaid” commits, sometimes set for “prepaid” commits, and never for “credit” |
rollover_fraction | float | The fraction of the balance that was rolled over |
rate_type | string | Either COMMIT_RATE or LIST_RATE |
applicable_product_ids | json | JSON encoded list of applicable product IDs |
applicable_product_tags | json | JSON encoded list of applicable product tags |
specifiers | json | CommitSpecifier[] - JSON encoded list of applicable usage |
applicable_contract_ids | json | JSON encoded list of applicable contract IDs |
invoice_contract_id | string | The invoice contract ID associated with the balance |
ledger | json | CommitLedgerEntry[] |
rolled_over_from_commit_id | string | The commit ID the balance was rolled over from |
rolled_over_from_contract_id | string | The contract ID the balance was rolled over from |
recurring_commit_id | string | The ID of the parent config that created this commit / credit (null if this commit was not created by a recurring commit / credit) |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID of the row |
metadata | json | Metadata |
balance | float | The current balance of the credit or commit. This balance reflects the amount of credit or commit that the customer has access to use at this moment. Expired and upcoming credit or commit segments contribute 0 to the balance. The balance matches the sum of all ledger entries except when the sum of negative manual ledger entries exceeds the positive amount remaining on the credit or commit. In that case, the balance is 0. All manual ledger entries associated with active credit or commit segments are included in the balance, including future-dated manual ledger entries. |
balances.AccessSchedule
balances.InvoiceSchedule
balances.CommitLedgerEntry
balances.specifier
contracts_commits
Column | Type | Description |
---|---|---|
id | string | The commit |
contract_id | string | The contract ID of the commit |
amendment_id | string | The amendment ID associated with the commit |
type | string | The type of commit: postpaid or prepaid |
name | string | The name of the commit |
priority | float | The priority that defines the order in which commits should be applied |
description | string | The description of the commit |
product_id | string | The product ID associated with the commit |
amount | float | Deprecated (use the amount from the schedule items instead) |
access_schedule | json | AccessSchedule |
invoice_schedule | json | InvoiceSchedule The invoice_schedule is always set for “postpaid” commits, sometimes set for “prepaid” commits, and never for “credit” |
rollover_fraction | float | The fraction of the commit that was rolled over |
rate_type | string | Either COMMIT_RATE or LIST_RATE |
applicable_product_ids | json | JSON encoded list of applicable product IDs |
applicable_product_tags | json | JSON encoded list of applicable product tags |
specifiers | json | CommitSpecifier[] - JSON encoded list of applicable usage |
ledger | json | CommitLedgerEntry[] |
rolled_over_from_commit_id | string | The commit ID the commit was rolled over from |
rolled_over_from_contract_id | string | The contract ID the commit was rolled over from |
recurring_commit_id | string | The ID of the parent config that created this commit (null if this commit was not created by a recurring commit) |
updated_at | timestamp | The timestamp (UTC) of when the commit was last updated |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID of the row |
metadata | json | Metadata |
balance | float | The current balance of the commit. This balance reflects the amount of commit that the customer has access to use at this moment. Expired and upcoming commit segments contribute 0 to the balance. The balance matches the sum of all ledger entries except when the sum of negative manual ledger entries exceeds the positive amount remaining on the commit. In that case, the balance is 0. All manual ledger entries associated with active commit segments are included in the balance, including future-dated manual ledger entries. |
commits.AccessSchedule
commits.InvoiceSchedule
commits.CommitLedgerEntry
commits.Specifier
contracts_recurring_commits_and_credits
Column | Type | Description |
---|---|---|
id | string | The unique ID of the recurring commit/credit |
contract_id | string | The contract ID of the recurring commit/credit |
customer_id | string | The customer ID associated with the recurring commit/credit |
type | string | The type: commit or credit |
name | string | The name that’s passed down to created commits/credits |
priority | float | The priority that’s passed down to created commits/credits |
description | string | The description that’s passed down to created commits/credits |
product_id | string | The product ID that’s passed down to created commits/credits |
starting_at | timestamp | The timestamp (UTC) of when the recurring credit or commit starts (inclusive) |
ending_before | timestamp | The timestamp (UTC) of when the recurring credit or commit ends (exclusive) |
access_amount | json | AccessAmount |
invoice_amount | json | InvoiceAmount Not set for recurring credits, but optional for recurring commits |
rollover_fraction | float | The rollover amount that’s passed down to created commits/credits. Note that this controls rollover between contracts on contract transition, and not rollover from one period to the next. |
rate_type | string | The rate type that’s passed down to created commits/credits |
applicable_product_ids | json | The applicable product IDs passed down to created commits/credits |
applicable_product_tags | json | The applicable product tags passed down to created commits/credits |
specifiers | json | CommitSpecifier[] - JSON encoded list of applicable usage |
commit_duration | json | CommitDuration How long each created commit is valid for starting from the start date. Currently the unit is always PERIODS , representing the length of the contract’s billing periods (e.g. monthly, quarterly or annual) |
proration | string | Used to control whether the first or last billing periods are prorated. Valid values are NONE , FIRST , LAST , and FIRST_AND_LAST . Default is FIRST_AND_LAST . |
recurrence_frequency | string | If set, commits or credits are created based on the frequency specified and begin to recur at the start date specified on the recurring commit or credit config. Accepted values are MONTHLY , QUARTERLY , and ANNUAL . |
updated_at | timestamp | The timestamp (UTC) of when the recurring commit / credit was last updated |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID of the row |
metadata | json | Metadata |
subscription_config | json | SubscriptionConfig - Configuration for linked subscription |
recurringcommits.AccessAmount
recurringcommits.InvoiceAmount
recurringcommits.CommitDuration
recurringcommits.Specifier
recurringcommits.SubscriptionConfig
contracts_edits
Column | Type | Description |
---|---|---|
id | string | The ID of the contract edit |
contract_id | string | The contract ID of the edit |
timestamp | timestamp | The timestamp (UTC) of the edit |
edits | json | Details of the edits made |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
created_by | string | The entity the contract edit was created by |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
snapshot_id | string | The snapshot ID for the row |
contracts_amendments
Column | Type | Description |
---|---|---|
id | string | The ID of the contract amendment |
contract_id | string | The contract ID of the amendment |
effective_at | timestamp | The timestamp (UTC) of when the contract amendment is effective starting at |
created_at | timestamp | The timestamp (UTC) of when the contract amendment was created |
created_by | string | The entity the contract amendment was created by |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the row |
metadata | json | Metadata |
contracts_overrides
Column | Type | Description |
---|---|---|
id | string | The ID of the override |
contract_id | string | The contract ID of the override |
amendment_id | string | The amendment ID of the override |
product_id | string | The product ID of the override |
starting_at | timestamp | The timestamp (UTC) of when the override starts (inclusive) |
ending_before | timestamp | The timestamp (UTC) of when the override ends (exclusive) |
entitled | boolean | Whether or not the override is entitled |
rate_type | string | Either multiplier , overwrite_flat , or overwrite_percentage . NULL if this does not override the rate |
multiplier | float | The multiplier of the override |
priority | float | Only defined for contracts with EXPLICIT multiplier override prioritization |
new_rate | json | Rate |
credit_type_id | string | Only defined for “overwrite_flat”, “overwrite_tiered”, “overwrite_subscription”, or “overwrite_custom” rate types |
credit_type_name | string | Only defined for “overwrite_flat”, “overwrite_tiered”, “overwrite_subscription”, or “overwrite_custom” rate types |
applicable_product_tags | json | JSON encoded list of strings |
override_specifiers | json | OverrideSpecifier[] |
target | string | Either COMMIT_RATE or LIST_RATE . Indicates which rate the override applies to |
is_commit_specific | boolean | Whether or not the override is commit specific |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the row |
metadata | json | Metadata |
tiered_override | json | Rates and tiers for tiered overrides |
overrides.Rate
override.Specifier
contracts_prepaid_balance_threshold_configurations
Column | Type | Description |
---|---|---|
id | string | Same as contract_id |
contract_id | string | The contract ID associated with the prepaid balance threshold configuration |
enabled | boolean | Whether prepaid balance threshold billing is enabled |
threshold_amount | float | The prepaid balance threshold at which to trigger threshold commit creation |
recharge_to_amount | float | The amount to recharge the balance to when the threshold is reached |
commit_name | string | The name to use as the line item of the threshold charge |
commit_description | string | The description used in the threshold commit |
commit_product_id | string | The fixed product ID used for prepaid balance threshold commits |
commit_applicable_product_ids | json | JSON encoded list of applicable product IDs for the commit |
commit_applicable_product_tags | json | JSON encoded list of applicable product tags for the commit |
payment_gate_type | string | The payment gate type: STRIPE , EXTERNAL , or NONE |
tax_type | string | The tax provider used: STRIPE , ANROK , PRECALCULATED , or NONE |
stripe_payment_type | string | The payment type if using Stripe payment gate: PAYMENT_INTENT or INVOICE |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the row |
contracts_scheduled_charges
Column | Type | Description |
---|---|---|
id | string | The ID of the scheduled charge |
contract_id | string | The contract ID associated with the scheduled charge |
amendment_id | string | The amendment ID associated with the scheduled charge |
name | string | The name of the scheduled charge |
description | string | The description of the scheduled charge |
product_id | string | The product ID associated with the scheduled charge |
credit_type_id | string | The ID of the credit type or currency |
credit_type_name | string | The name of the credit type or currency |
schedule | json | Schedule |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the row |
scheduled_charges.Schedule
contracts_spend_threshold_configurations
Column | Type | Description |
---|---|---|
id | string | Same as contract_id |
contract_id | string | The contract ID associated with the spend threshold configuration |
enabled | boolean | Whether spend threshold billing is enabled |
threshold_amount | float | The spend threshold at which to trigger threshold commit creation |
commit_name | string | The name to use as the line item of the threshold charge |
commit_description | string | The description used in the threshold commit |
commit_product_id | string | The ID of the fixed product used for spend threshold commits |
payment_gate_type | string | The payment gate type: STRIPE , EXTERNAL , or NONE |
tax_type | string | The tax provider used: STRIPE , ANROK , PRECALCULATED , or NONE |
stripe_payment_type | string | The payment type if using Stripe payment gate: PAYMENT_INTENT or INVOICE |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the row |
contracts_subscriptions
Column | Type | Description |
---|---|---|
id | string | The ID of the transition event |
customer_id | string | The Metronome ID of the customer |
contract_id | string | The current contract ID |
product_id | string | The product ID of the subscription |
name | string | The name of the subscription |
description | string | The description of the subscription |
starting_at | timestamp | The timestamp (UTC) of when the subscription starts |
ending_before | timestamp | The timestamp (UTC) of when the subscription ends |
billing_frequency | string | The billing frequency of the subscription |
collection_schedule | string | The collection schedule of the subscription |
is_prorated | boolean | Whether or not the subscription is prorated |
invoice_behavior | string | The invoice behavior of the subscription |
quantity_schedule | json | The quantity schedule of the subscription |
fiat_credit_type_id | string | The fiat credit type ID used by the subscription |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
metadata | json | Metadata |
snapshot_id | string | The snapshot ID for the row |
contracts_transitions
Column | Type | Description |
---|---|---|
id | string | The ID of the transition event |
type | string | Either “renewal” or “supersede” |
contract_id | string | The current contract ID |
from_contract_id | string | The contract ID that applies prior to the transition |
to_contract_id | string | The contract ID that applies after the transition |
date | timestamp | The timestamp (UTC) of the transition |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The snapshot ID for the row |
contracts_usage_filter_schedule
contract_id
starting_at >= {TIME_PERIOD_START}
ending_before <= {TIME_PERIOD_END}
Column | Type | Description |
---|---|---|
id | string | The Metronome ID of the contract usage filter |
contract_id | string | The ID of the contract associated with the usage filter |
starting_at | timestamp | The timestamp (UTC) of the starting timestamp the usage filter is active (inclusive) |
ending_before | timestamp | The timestamp (UTC) of the ending timestamp the usage filter is active (inclusive) |
group_key | string | The group key for the usage filter |
group_values | json | Group values for this usage filter row, stored in a JSON encoded list |
metadata | json | Metadata |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
contracts_usage_filters
contract_id
and starting_at <= {TIME}
version
Column | Type | Description |
---|---|---|
id | string | The Metronome ID of the contract usage filter |
contract_id | string | The ID of the contract associated with the usage filter |
version | integer | The version of the usage filter |
starting_at | timestamp | The timestamp (UTC) of the starting timestamp the usage filter is active (inclusive) |
group_key | string | The group key for the usage filter |
group_values | json | Group values for this usage filter row, stored in a JSON encoded list |
updated_at | timestamp | The timestamp (UTC) at which this row was exported |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The ID of the snapshot this row was transferred during |
customer
Column | Type | Description |
---|---|---|
id | string | The Metronome ID of the customer |
name | string | The name of the customer |
ingest_aliases | json | The ingest aliases of the customer |
salesforce_account_id | string | The Salesforce account ID for the customer |
billing_provider_type | string | The billing provider connected to the customer |
billing_provider_customer_id | string | The billing provider ID of the customer |
custom_fields | json | Custom fields attached to the customer |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
created_at | timestamp | The timestamp (UTC) of when the customer was created |
updated_at | timestamp | The timestamp (UTC) of when the customer was last updated |
archived_at | timestamp | The timestamp (UTC) of when the customer was archived, if applicable |
invoice
Column | Type | Description |
---|---|---|
id | string | The Metronome invoice ID |
status | string | The Metronome invoice status: FINALIZED or VOID |
total | decimal | The invoice total |
credit_type_id | string | The credit type ID for the invoice |
credit_type_name | string | The name of the credit type associated with the invoice |
customer_id | string | The Metronome ID of the customer |
plan_id | string | Deprecated field - expect to be NULL |
plan_name | string | Deprecated field - expect to be NULL |
contract_id | string | The contract ID associated with the invoice |
start_timestamp | timestamp | Beginning of the usage period that this invoice covers (UTC) |
end_timestamp | timestamp | End of the usage period that this invoice covers (UTC) |
billing_provider_invoice_id | string | The external invoice ID from the billing provider (e.g., Stripe) |
billing_provider_type | string | The type of external system billing provider (e.g. Stripe) |
billing_provider_invoice_created_at | timestamp | The timestamp (UTC) the external invoice was created by Metronome |
billing_provider_invoice_external_status | string | The status of the invoice in the external system (e.g. Stripe) |
invoice_label | string | The categorical label of the invoice |
issued_at | timestamp | The timestamp (UTC) of when the invoice was issued |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
updated_at | timestamp | The timestamp (UTC) of when this row was last updated |
line_item
Column | Type | Description |
---|---|---|
id | string | The line item ID |
invoice_id | string | The Metronome invoice ID associated with the line item |
credit_grant_id | string | Deprecated field - expect to be NULL |
credit_type_id | string | The credit type ID associated with the line item |
credit_type_name | string | The name of the credit type associated with the line item |
name | string | The line item description |
quantity | decimal | The quantity associated with the line item; this will always be 1 for invoice adjustments |
total | decimal | The line item total |
commit_id | string | The commit ID associated with the line item. Only present for Contract Invoices |
product_id | string | The product ID associated with the line item; this will always be NULL for invoice adjustments |
group_key | string | The group key associated with the line item |
group_value | string | The group value associated with the line item |
unit_price | decimal | The price associated with the line item |
starting_at | timestamp | The timestamp (UTC) of when the line item is effective from (inclusive) |
ending_before | timestamp | The timestamp (UTC) of when the line item is effective to (exclusive) |
pricing_group_values | json | Optional pricing group values array |
metadata | json | Metadata |
updated_at | timestamp | The timestamp (UTC) of when the line item was last updated |
subscription_id | string | The subscription ID associated with the line item. Only present for subscription charges. |
is_prorated | boolean | Indicates if the value is prorated over the period. For subscription charges only. |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
draft_invoice
Column | Type | Description |
---|---|---|
_metronome_metadata_id | string | Unique identifier for each draft invoice ID + snapshot_time pair |
id | string | The Metronome invoice ID |
status | string | The Metronome invoice status: DRAFT or DRAFT_INCOMPLETE (see the invoice table for FINALIZED and VOID invoices) |
total | decimal | The invoice total |
credit_type_id | string | The credit type ID for the invoice |
credit_type_name | string | The name of the credit type associated with the invoice |
customer_id | string | The Metronome ID of the customer |
plan_id | string | Deprecated field - expect to be NULL |
plan_name | string | Deprecated field - expect to be NULL |
contract_id | string | The contract ID associated with the invoice |
start_timestamp | timestamp | Beginning of the usage period that this invoice covers (UTC) |
end_timestamp | timestamp | End of the usage period that this invoice covers (UTC) |
billable_status | string | Billable status of the invoice, BILLABLE or UNBILLABLE |
billing_provider_invoice_id | string | The external invoice ID from the billing provider (e.g., Stripe) |
billing_provider_invoice_created_at | timestamp | The timestamp (UTC) of when the external invoice was created by Metronome |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
snapshot_time | timestamp | The timestamp (UTC) aligning with the start of the snapshot |
label | string | The categorical label of the invoice |
draft_line_item
Column | Type | Description |
---|---|---|
_metronome_metadata_id | string | Opaque unique identifier for each row |
id | string | The line item ID |
invoice_id | string | The Metronome invoice ID associated with the line item |
credit_grant_id | string | Deprecated field - expect to be NULL |
credit_type_id | string | The credit type ID associated with the line item |
credit_type_name | string | The name of the credit type associated with the line item |
name | string | The line item description |
quantity | decimal | The quantity associated with the line item; this will always be 1 for invoice adjustments |
total | decimal | The line item total |
commit_id | string | The commit ID associated with the line item. Only present for Contract Invoices |
product_id | string | The product ID associated with the line item; this will always be NULL for invoice adjustments |
group_key | string | The group key associated with the line item |
group_value | string | The group value associated with the line item |
unit_price | decimal | The price associated with the line item |
pricing_group_values | json | Optional pricing group values array |
subscription_id | string | The subscription ID associated with the line item. Only present for subscription charges. |
is_prorated | boolean | Indicates if the value is prorated over the period. For subscription charges only. |
starting_at | timestamp | The timestamp (UTC) of when the line item is effective from (inclusive) |
ending_before | timestamp | The timestamp (UTC) of when the line item is effective to (exclusive) |
updated_at | timestamp | The timestamp (UTC) of when the line item was last updated |
snapshot_time | timestamp | The timestamp (UTC) aligning with the start of the snapshot |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
breakdowns_invoices
Column | Type | Description |
---|---|---|
id | string | The Metronome invoice breakdown ID |
invoice_id | string | The Metronome invoice ID associated with the breakdown |
customer_id | string | The Metronome customer ID associated with the breakdown |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_timestamp | timestamp | The timestamp (UTC) aligning with the start of the snapshot |
transfer_id | string | The Metronome transfer ID for this invoice breakdown |
credit_type_id | string | The ID of the credit type associated with the invoice |
net_payment_term_days | integer | The net payment term in days associated with the invoice |
credit_type_name | string | The name of the credit type associated with the invoice |
issued_at | timestamp | The timestamp (UTC) when this breakdown was issued |
subtotal | decimal | Deprecated field—expect to be NULL unless using Plans data model |
total | decimal | The total for the invoice |
type | string | The invoice type |
external_invoice | json | The external invoice data |
plan_id | string | Deprecated field—expect to be NULL unless using Plans data model |
contract_id | string | The contract ID associated with the invoice |
amendment_id | string | The amendment ID associated with the invoice |
custom_fields | json | Custom fields that apply to the invoice |
billable_status | string | The invoice’s billable status |
breakdown_start_timestamp | timestamp | The timestamp corresponding with the start of the breakdown window (inclusive) |
breakdown_end_timestamp | timestamp | The timestamp corresponding with the end of the breakdown window (exclusive) |
window_size | string | The size of the breakdown window—typically DAILY |
updated_at | timestamp | The timestamp (UTC) when this row last updated |
invoice_start_timestamp | timestamp | Beginning of the usage period that this invoice covers (UTC) (inclusive) |
invoice_end_timestamp | timestamp | End of the usage period that this invoice covers (UTC) (exclusive) |
metadata | json | Additional metadata in JSON format |
breakdowns_line_items
Column | Type | Description |
---|---|---|
id | string | The Metronome line item breakdown ID |
invoice_breakdown_id | string | The Metronome invoice breakdown ID associated with the line item |
name | string | The name of the line item associated with the breakdown |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_timestamp | timestamp | The timestamp (UTC) aligning with the start of the snapshot |
watermark_timestamp | timestamp | The timestamp indicating the latest modification to this row |
transfer_id | string | The Metronome transfer ID for this line item breakdown |
group_key | string | The group key associated with the line item |
group_value | string | The group value associated with the line item |
quantity | decimal | The quantity of this line item breakdown row—always 1 for invoice adjustments |
total | decimal | The total for the line item breakdown |
unit_price | decimal | The unit price for the line item |
product_id | string | The ID of the product for the line item—always NULL for invoice adjustments |
product_type | string | The type of product for the line item breakdown |
credit_type_id | string | The credit type ID associated with the line item |
credit_type_name | string | The name of the credit type associated with the line item |
commit_id | string | The commit ID associated with the line item breakdown |
commit_segment_id | string | The commit segment ID associated with the line item breakdown |
commit_type | string | The commit type associated with the line item breakdown |
subscription_id | string | The subscription ID associated with the line item breakdown—only present for subscription charges. |
is_prorated | boolean | Indicates if the value is prorated over the period. For subscription charges only. |
line_item_id | string | The unique line item id that can be used to join with records in the line_item table |
line_item_type | string | The unique line item type that defines the type of revenue represented in the line item |
custom_fields | json | Custom fields that apply to the breakdown |
breakdown_start_timestamp | timestamp | The timestamp corresponding with the start of the breakdown window (inclusive) |
breakdown_end_timestamp | timestamp | The timestamp corresponding with the end of the breakdown window (exclusive) |
pricing_group_values | json | The pricing group values associated with the line item breakdown |
presentation_group_values | json | The presentation group values associated with the line item breakdown |
billable_metric_id | string | The billable metric ID that applies to the line item breakdown |
updated_at | timestamp | The timestamp (UTC) when this row last updated |
metadata | json | Additional metadata in JSON format (see Metadata ) |
breakdowns_draft_invoices
Column | Type | Description |
---|---|---|
id | string | The Metronome invoice breakdown ID |
invoice_id | string | The Metronome invoice ID associated with the breakdown |
customer_id | string | The Metronome customer ID associated with the breakdown |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_timestamp | timestamp | The timestamp (UTC) aligning with the start of the snapshot |
transfer_id | string | The Metronome transfer ID for this invoice breakdown |
credit_type_id | string | The ID of the credit type associated with the invoice |
net_payment_term_days | integer | The net payment term in days associated with the invoice |
credit_type_name | string | The name of the credit type associated with the invoice |
issued_at | timestamp | The timestamp (UTC) when this breakdown was issued |
subtotal | decimal | Deprecated field—expect to be NULL unless using Plans data model |
total | decimal | The total for the invoice |
type | string | The invoice type |
external_invoice | json | The external invoice data |
plan_id | string | Deprecated field—expect to be NULL unless using Plans data model |
contract_id | string | The contract ID associated with the invoice |
amendment_id | string | The amendment ID associated with the invoice |
custom_fields | json | Custom fields that apply to the invoice |
billable_status | string | The invoice’s billable status |
breakdown_start_timestamp | timestamp | The timestamp corresponding with the start of the breakdown window (inclusive) |
breakdown_end_timestamp | timestamp | The timestamp corresponding with the end of the breakdown window (exclusive) |
window_size | string | The size of the breakdown window—typically DAILY |
updated_at | timestamp | The timestamp (UTC) when this row last updated |
invoice_start_timestamp | timestamp | Beginning of the usage period that this invoice covers (UTC) (inclusive) |
invoice_end_timestamp | timestamp | End of the usage period that this invoice covers (UTC) (exclusive) |
metadata | json | Additional metadata in JSON format |
breakdowns_draft_line_items
Column | Type | Description |
---|---|---|
id | string | The Metronome line item breakdown ID |
invoice_breakdown_id | string | The Metronome invoice breakdown ID associated with the line item |
name | string | The name of the line item associated with the breakdown |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_timestamp | timestamp | The timestamp (UTC) aligning with the start of the snapshot |
watermark_timestamp | timestamp | The timestamp indicating the latest modification to this row |
transfer_id | string | The Metronome transfer ID for this line item breakdown |
group_key | string | The group key associated with the line item |
group_value | string | The group value associated with the line item |
quantity | decimal | The quantity of this line item breakdown row; always 1 for invoice adjustments |
total | decimal | The total for the line item breakdown |
unit_price | decimal | The unit price for the line item |
product_id | string | The ID of the product for the line item; always NULL for invoice adjustments |
product_type | string | The type of product for the line item breakdown |
credit_type_id | string | The credit type ID associated with the line item |
credit_type_name | string | The name of the credit type associated with the line item |
commit_id | string | The commit ID associated with the line item breakdown |
commit_segment_id | string | The commit segment ID associated with the line item breakdown |
commit_type | string | The commit type associated with the line item breakdown |
subscription_id | string | The subscription ID associated with the line item breakdown; only present for subscription charges. |
is_prorated | boolean | Indicates if the value is prorated over the period. For subscription charges only. |
line_item_id | string | The unique line item id that can be used to join with records in the line_item table |
line_item_type | string | The unique line item type that defines the type of revenue represented in the line item |
custom_fields | json | Custom fields that apply to the breakdown |
breakdown_start_timestamp | timestamp | The timestamp corresponding with the start of the breakdown window (inclusive) |
breakdown_end_timestamp | timestamp | The timestamp corresponding with the end of the breakdown window (exclusive) |
pricing_group_values | json | The pricing group values associated with the line item breakdown |
presentation_group_values | json | The presentation group values associated with the line item breakdown |
billable_metric_id | string | The billable metric ID that applies to the line item breakdown |
updated_at | timestamp | The timestamp (UTC) when this row last updated |
metadata | json | Additional metadata in JSON format (see Metadata ) |
events
Column | Type | Description |
---|---|---|
transaction_id | string | The unique ID of the event |
customer_id | string | The ID of the customer the event applies to |
timestamp | timestamp | The timestamp (UTC) of the event |
event_type | string | The event type |
properties | json | The properties of the event |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
_metronome_metadata_id | string | Metronome metadata ID |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
credit_type
Column | Type | Description |
---|---|---|
_metronome_metadata_id | string | Metronome metadata ID |
id | string | The credit type ID |
name | string | The name of the credit type |
is_currency | boolean | Whether or not the credit type is a currency, TRUE or FALSE |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
contracts_billing_provider_configuration
Column | Type | Description |
---|---|---|
id | string | The Metronome contract billing provider configuration ID |
contract_id | string | The Metronome contract ID associated with this row |
customer_id | string | The customer ID associated with this row |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
billing_provider_config_id | string | The Metronome billing provider configuration ID associated with this row |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
contracts_product_list_item_versions
Column | Type | Description |
---|---|---|
id | string | The Metronome product list item version ID |
product_list_item_id | string | The product list item ID associated with the row |
type | string | The type of the product list item version |
version | integer | The version of the product list item |
name | string | The name of the product list item version |
starting_at | timestamp | The timestamp (UTC) the version is active starting at (inclusive) |
is_refundable | boolean | Whether or not the product list item version is refundable |
billable_metric_id | string | The billable metric ID associated with the product list item version |
composite_product_ids | json | The list of composite product IDs associated with the row |
tags | json | The list of tags associated with the row |
composite_tags | json | The list of composite tags associated with the row |
quantity_conversion | json | The quantity conversion for the row |
quantity_rounding | json | The quantity rounding for the row |
pricing_group_key | json | The pricing group key for the row |
presentation_group_key | json | The presentation group key for the row |
created_at | timestamp | The timestamp (UTC) this row was created at |
created_by | string | The entity this row was created by |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
metadata | json | Metadata |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
snapshot_id | string | The ID of the snapshot this row was transferred during |
contracts_rate_cards
Column | Type | Description |
---|---|---|
id | string | The Metronome contract rate card ID |
credit_type_conversions | json | The credit type conversions associated with the row |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
snapshot_id | string | The ID of the snapshot this row was transferred during |
metadata | json | Metadata |
aliases | json | List of aliases for the rate card |
fiat_credit_type_id | string | The fiat credit type ID associated with the rate card |
fiat_credit_type_name | string | The name of the fiat credit type associated with the rate card |
created_by | string | The creator of the rate card |
created_at | timestamp | The timestamp (UTC) this row was created |
description | string | The description of the rate card |
name | string | The name of the rate card |
archived_at | timestamp | The timestmap (UTC) this row was archived if applicable |
contracts_rate_card_entries
Column | Type | Description |
---|---|---|
id | string | The Metronome contract rate card entry ID |
rate_card_id | string | The Metronome rate card ID associated with this entry |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
product_id | string | The product ID associated with this entry |
version | integer | The version of this rate card entry |
starting_at | timestamp | The timestamp (UTC) the rate card entry starts at (inclusive) |
ending_before | timestamp | The timestamp (UTC) the rate card entry ends at (exclusive) |
entitled | boolean | Whether or not the entry is entitled |
rate | string | The rate that applies to the entry |
commit_rate | string | The commit rate that applies to the entry (if applicable) |
product_order | integer | The product order associated with the entry |
pricing_group_values | json | The pricing group values that apply to the entry |
updated_at | timestamp | The timestamp (UTC) this row was last updated |
snapshot_id | string | The ID of the snapshot this row was transferred during |
metadata | json | Metadata |
credit_type_id | string | The credit type ID associated with the rate card |
credit_type_name | string | The name of the credit type associated with the rate card |
billing_frequency | string | The billing frequency associated with the entry. For subscriptions only. |
customer_alert_history
Column | Type | Description |
---|---|---|
id | string | The Metronome ID of the customer alert history |
customer_id | string | The name of the customer associated with the alert history |
alert_id | string | The alert ID associated with the row |
alert_status | string | The alert status associated with the row |
additional_data | json | Additional data about the alert |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
created_at | timestamp | The timestamp (UTC) of when the customer was created |
customer_billing_provider_configuration
Column | Type | Description |
---|---|---|
id | string | The Metronome contract billing provider configuration ID |
configuration | string | The configuration associated with the row |
customer_id | string | The customer ID associated with this row |
environment_type | string | The Metronome environment, SANDBOX or PRODUCTION |
billing_provider | string | The billing provider associated with this row |
created_at | timestamp | The timestamp (UTC) of when the customer billing provider configuration was created |
updated_at | timestamp | The timestamp (UTC) this row was last updated |