Skip to content

Instantly share code, notes, and snippets.

@xaviablaza
Created May 30, 2025 11:12
Show Gist options
  • Select an option

  • Save xaviablaza/5b9d04f358cb1277fcb6668f9e716b44 to your computer and use it in GitHub Desktop.

Select an option

Save xaviablaza/5b9d04f358cb1277fcb6668f9e716b44 to your computer and use it in GitHub Desktop.
customer invoice for 1x infrastructure project plus minimum spend of a 2vcpu-2gb machine both billed at 672 hours each
{
"id":"upcoming_in_1RUQpCByiGkVepzsKuLqQlxI",
"object":"invoice",
"account_country":"US",
"account_name":"Hostari",
"account_tax_ids":null,
"amount_due":1600,
"amount_overpaid":0,
"amount_paid":0,
"amount_remaining":1600,
"amount_shipping":0,
"application":null,
"attempt_count":0,
"attempted":false,
"auto_advance":true,
"automatic_tax":{
"disabled_reason":null,
"enabled":false,
"liability":null,
"provider":null,
"status":null
},
"automatically_finalizes_at":null,
"billing_reason":"upcoming",
"collection_method":"charge_automatically",
"created":1751281618,
"currency":"usd",
"custom_fields":null,
"customer":"cus_SPFFdB1PVMutlZ",
"customer_address":null,
"customer_email":"jennyrosen-2468850@example.com",
"customer_name":"Jenny Rosen",
"customer_phone":null,
"customer_shipping":null,
"customer_tax_exempt":"none",
"customer_tax_ids":[
],
"default_payment_method":null,
"default_source":null,
"default_tax_rates":[
],
"description":null,
"discounts":[
],
"due_date":null,
"effective_at":null,
"ending_balance":0,
"footer":null,
"from_invoice":null,
"hosted_invoice_url":null,
"invoice_pdf":null,
"issuer":{
"type":"self"
},
"last_finalization_error":null,
"latest_revision":null,
"lines":{
"object":"list",
"data":[
{
"id":"il_tmp_1a2957ByiGkVepzsd87d39e2",
"object":"line_item",
"amount":800,
"currency":"usd",
"description":"672 × Pro Plan - Infrastructure Project Hour (Tier 1 at $0.011904761905 / month)",
"discount_amounts":[
],
"discountable":true,
"discounts":[
],
"invoice":"in_1RUQpCByiGkVepzsMM8386DY",
"livemode":false,
"metadata":{
},
"parent":{
"invoice_item_details":null,
"subscription_item_details":{
"invoice_item":null,
"proration":false,
"proration_details":{
"credited_items":null
},
"subscription":"sub_1RUQm6ByiGkVepzsqX0oYEJv",
"subscription_item":"si_SPFGxnrRbHZXOT"
},
"type":"subscription_item_details"
},
"period":{
"end":1751281560,
"start":1748603218
},
"pretax_credit_amounts":[
],
"pricing":{
"price_details":{
"price":"price_1RUQlJByiGkVepzsAykoRG3b",
"product":"prod_SPFEoCDNb42vnW"
},
"type":"price_details",
"unit_amount_decimal":"1.1904761905"
},
"quantity":672,
"taxes":[
]
},
{
"id":"il_tmp_1223ccByiGkVepzs18d3e655",
"object":"line_item",
"amount":800,
"currency":"usd",
"description":"672 × Pro Plan - Machine Hours from Minimum Spend (at $0.011904761905 / month)",
"discount_amounts":[
],
"discountable":true,
"discounts":[
],
"invoice":"in_1RUQpCByiGkVepzsMM8386DY",
"livemode":false,
"metadata":{
},
"parent":{
"invoice_item_details":null,
"subscription_item_details":{
"invoice_item":null,
"proration":false,
"proration_details":{
"credited_items":null
},
"subscription":"sub_1RUQm6ByiGkVepzsqX0oYEJv",
"subscription_item":"si_SPFGgeRDc5yNQx"
},
"type":"subscription_item_details"
},
"period":{
"end":1751281560,
"start":1748603218
},
"pretax_credit_amounts":[
],
"pricing":{
"price_details":{
"price":"price_1RUQlJByiGkVepzslBDJ9L3K",
"product":"prod_SPFEUlkvrDxiZw"
},
"type":"price_details",
"unit_amount_decimal":"1.1904761905"
},
"quantity":672,
"taxes":[
]
}
],
"has_more":false,
"total_count":2,
"url":"/v1/invoices/upcoming_in_1RUQpCByiGkVepzsKuLqQlxI/lines"
},
"livemode":false,
"metadata":{
},
"next_payment_attempt":1751285218,
"number":null,
"on_behalf_of":null,
"parent":{
"quote_details":null,
"subscription_details":{
"metadata":{
},
"subscription":"sub_1RUQm6ByiGkVepzsqX0oYEJv"
},
"type":"subscription_details"
},
"payment_settings":{
"default_mandate":null,
"payment_method_options":null,
"payment_method_types":null
},
"period_end":1751281618,
"period_start":1748603218,
"post_payment_credit_notes_amount":0,
"pre_payment_credit_notes_amount":0,
"receipt_number":null,
"rendering":null,
"shipping_cost":null,
"shipping_details":null,
"starting_balance":0,
"statement_descriptor":null,
"status":"draft",
"status_transitions":{
"finalized_at":null,
"marked_uncollectible_at":null,
"paid_at":null,
"voided_at":null
},
"subtotal":1600,
"subtotal_excluding_tax":1600,
"test_clock":null,
"total":1600,
"total_discount_amounts":[
],
"total_excluding_tax":1600,
"total_pretax_credit_amounts":[
],
"total_taxes":[
],
"webhooks_delivered_at":null
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment