Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pedro-vasconcelos/559313703e3c20ac76c1e5b0d61580f7 to your computer and use it in GitHub Desktop.
Save pedro-vasconcelos/559313703e3c20ac76c1e5b0d61580f7 to your computer and use it in GitHub Desktop.
stripe_event: invoice.payment_action_required
{
"id": "evt_1KmnD1LueXt1u2td8vlmcTAh",
"object": "event",
"api_version": "2020-08-27",
"created": 1649545006,
"data": {
"object": {
"id": "in_1KmnCzLueXt1u2tdoXp43QHS",
"object": "invoice",
"account_country": "BG",
"account_name": "Hotspotty LTD",
"account_tax_ids": null,
"amount_due": 1700,
"amount_paid": 0,
"amount_remaining": 1700,
"application_fee_amount": null,
"attempt_count": 0,
"attempted": true,
"auto_advance": true,
"automatic_tax": {
"enabled": true,
"status": "complete"
},
"billing_reason": "subscription_update",
"charge": null,
"collection_method": "charge_automatically",
"created": 1649545005,
"currency": "usd",
"custom_fields": null,
"customer": "cus_LTkd0SWPVpHLem",
"customer_address": {
"city": "West Petra",
"country": "MD",
"line1": "93001 Ondricka Wall",
"line2": "4881 Jacobi Oval",
"postal_code": "29162",
"state": null
},
"customer_email": "me@pedrovasconcelos.com",
"customer_name": "Pedro Vasconcelos",
"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,
"discount": null,
"discounts": [],
"due_date": null,
"ending_balance": 0,
"footer": null,
"hosted_invoice_url": "https://invoice.stripe.com/i/acct_1JoEuhLueXt1u2td/test_YWNjdF8xSm9FdWhMdWVYdDF1MnRkLF9MVGtpbG05MzdyUWt6aXdic2hUVVlzcU54WUZLSTBLLDQwMDg1ODA30200q4sCoK8T?s=ap",
"invoice_pdf": "https://pay.stripe.com/invoice/acct_1JoEuhLueXt1u2td/test_YWNjdF8xSm9FdWhMdWVYdDF1MnRkLF9MVGtpbG05MzdyUWt6aXdic2hUVVlzcU54WUZLSTBLLDQwMDg1ODA30200q4sCoK8T/pdf?s=ap",
"last_finalization_error": null,
"lines": {
"object": "list",
"data": [
{
"id": "il_1KmnCzLueXt1u2tdLf6ARKAF",
"object": "line_item",
"amount": -500,
"currency": "usd",
"description": "Unused time on 10 × Hotspots after 09 Apr 2022",
"discount_amounts": [],
"discountable": false,
"discounts": [],
"invoice_item": "ii_1KmnCzLueXt1u2tdlpyRGcRo",
"livemode": false,
"metadata": [],
"period": {
"end": 1652136748,
"start": 1649545005
},
"plan": {
"id": "price_1KlLdPLueXt1u2tdXD73qduR",
"object": "plan",
"active": true,
"aggregate_usage": null,
"amount": null,
"amount_decimal": null,
"billing_scheme": "tiered",
"created": 1649200683,
"currency": "usd",
"interval": "month",
"interval_count": 1,
"livemode": false,
"metadata": [],
"nickname": "Monthly Plan",
"product": "prod_LSG9zz7NuiNfVH",
"tiers_mode": "volume",
"transform_usage": null,
"trial_period_days": null,
"usage_type": "licensed"
},
"price": {
"id": "price_1KlLdPLueXt1u2tdXD73qduR",
"object": "price",
"active": true,
"billing_scheme": "tiered",
"created": 1649200683,
"currency": "usd",
"livemode": false,
"lookup_key": null,
"metadata": [],
"nickname": "Monthly Plan",
"product": "prod_LSG9zz7NuiNfVH",
"recurring": {
"aggregate_usage": null,
"interval": "month",
"interval_count": 1,
"trial_period_days": null,
"usage_type": "licensed"
},
"tax_behavior": "exclusive",
"tiers_mode": "volume",
"transform_quantity": null,
"type": "recurring",
"unit_amount": null,
"unit_amount_decimal": null
},
"proration": true,
"proration_details": {
"credited_items": {
"invoice": "in_1Kmn8qLueXt1u2tdOdCffCIN",
"invoice_line_items": [
"il_1Kmn8qLueXt1u2tdn9OSn4PT"
]
}
},
"quantity": 10,
"subscription": "sub_1Kmn8qLueXt1u2td7xdxWbzZ",
"subscription_item": "si_LTkeaEEHylXwtX",
"tax_amounts": [],
"tax_rates": [],
"type": "invoiceitem"
},
{
"id": "il_1KmnCzLueXt1u2tdI7VQ6IfS",
"object": "line_item",
"amount": 2200,
"currency": "usd",
"description": "Remaining time on 110 × Hotspots after 09 Apr 2022",
"discount_amounts": [],
"discountable": false,
"discounts": [],
"invoice_item": "ii_1KmnCzLueXt1u2td45Qv8Vqg",
"livemode": false,
"metadata": [],
"period": {
"end": 1652136748,
"start": 1649545005
},
"plan": {
"id": "price_1KlLdPLueXt1u2tdXD73qduR",
"object": "plan",
"active": true,
"aggregate_usage": null,
"amount": null,
"amount_decimal": null,
"billing_scheme": "tiered",
"created": 1649200683,
"currency": "usd",
"interval": "month",
"interval_count": 1,
"livemode": false,
"metadata": [],
"nickname": "Monthly Plan",
"product": "prod_LSG9zz7NuiNfVH",
"tiers_mode": "volume",
"transform_usage": null,
"trial_period_days": null,
"usage_type": "licensed"
},
"price": {
"id": "price_1KlLdPLueXt1u2tdXD73qduR",
"object": "price",
"active": true,
"billing_scheme": "tiered",
"created": 1649200683,
"currency": "usd",
"livemode": false,
"lookup_key": null,
"metadata": [],
"nickname": "Monthly Plan",
"product": "prod_LSG9zz7NuiNfVH",
"recurring": {
"aggregate_usage": null,
"interval": "month",
"interval_count": 1,
"trial_period_days": null,
"usage_type": "licensed"
},
"tax_behavior": "exclusive",
"tiers_mode": "volume",
"transform_quantity": null,
"type": "recurring",
"unit_amount": null,
"unit_amount_decimal": null
},
"proration": true,
"proration_details": {
"credited_items": null
},
"quantity": 110,
"subscription": "sub_1Kmn8qLueXt1u2td7xdxWbzZ",
"subscription_item": "si_LTkeaEEHylXwtX",
"tax_amounts": [],
"tax_rates": [],
"type": "invoiceitem"
}
],
"has_more": false,
"total_count": 2,
"url": "/v1/invoices/in_1KmnCzLueXt1u2tdoXp43QHS/lines"
},
"livemode": false,
"metadata": [],
"next_payment_attempt": null,
"number": null,
"on_behalf_of": null,
"paid": false,
"paid_out_of_band": false,
"payment_intent": "pi_3KmnCzLueXt1u2td15TcNIsq",
"payment_settings": {
"payment_method_options": null,
"payment_method_types": null
},
"period_end": 1649545005,
"period_start": 1649544748,
"post_payment_credit_notes_amount": 0,
"pre_payment_credit_notes_amount": 0,
"quote": null,
"receipt_number": null,
"starting_balance": 0,
"statement_descriptor": null,
"status": "open",
"status_transitions": {
"finalized_at": 1649545005,
"marked_uncollectible_at": null,
"paid_at": null,
"voided_at": null
},
"subscription": "sub_1Kmn8qLueXt1u2td7xdxWbzZ",
"subtotal": 1700,
"tax": null,
"test_clock": null,
"total": 1700,
"total_discount_amounts": [],
"total_tax_amounts": [],
"transfer_data": null,
"webhooks_delivered_at": null
}
},
"livemode": false,
"pending_webhooks": 2,
"request": {
"id": "req_FMTG6rMvABWSKu",
"idempotency_key": "7fd566a6-8cb4-4d2b-a28a-a8b4e02e0b8e"
},
"type": "invoice.payment_action_required"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment