Comments (2)
Hello, unfortunately, what you pass in the lineItems
array is beyond my control. This error seems to be an API error, meaning the the lineItems.0.invoice_item
is no longer available in the latest API. It must be because the docs for vue stripe vue 2 is outdated. But you can try to pass the latest object format from the docs to the lineItems
array. Let me know if it works
from vue-stripe.
Thank you for the fast reply.
I was checking the latest API:
https://docs.stripe.com/api/invoices/line_item
Based on the doc, this should have worked:
lineItems: [
{
price: "price_xxxxxxxxxxxx",
quantity: 1,
invoice_item: "ii_1Nzo1ZGgdF1VjufLzD1UUn9R",
},
],
This is the object of the latest API:
{
"id": "il_tmp_1Nzo1ZGgdF1VjufLzD1UUn9R",
"object": "line_item",
"amount": 1000,
"amount_excluding_tax": 1000,
"currency": "usd",
"description": "My First Invoice Item (created for API docs)",
"discount_amounts": [],
"discountable": true,
"discounts": [],
"invoice_item": "ii_1Nzo1ZGgdF1VjufLzD1UUn9R", <----------Here
"livemode": false,
"metadata": {},
"period": {
"end": 1696975413,
"start": 1696975413
},
"price": {
"id": "price_1NzlYfGgdF1VjufL0cVjLJVI",
"object": "price",
"active": true,
"billing_scheme": "per_unit",
"created": 1696965933,
"currency": "usd",
"custom_unit_amount": null,
"livemode": false,
"lookup_key": null,
"metadata": {},
"nickname": null,
"product": "prod_OnMHDH6VBmYlTr",
"recurring": null,
"tax_behavior": "unspecified",
"tiers_mode": null,
"transform_quantity": null,
"type": "one_time",
"unit_amount": 1000,
"unit_amount_decimal": "1000"
},
"proration": false,
"proration_details": {
"credited_items": null
},
"quantity": 1,
"subscription": null,
"tax_amounts": [],
"tax_rates": [],
"type": "invoiceitem",
"unit_amount_excluding_tax": "1000"
}
I also tried to pass metadata to it but it fails too(with the same error as to "lineItems.0.metadata"):
metadata: {
product_id: "6735"
},
Thanks
Ben
from vue-stripe.
Related Issues (20)
- Purge Gitbook HOT 1
- Purge current site
- Feature's List HOT 1
- Here
- U
- Share
- Vue elemenets not supporting typeScript and compliler complains HOT 2
- Improvement: Payment Element HOT 1
- Improvement: Link Authentication Element HOT 1
- Improvement: Pay Button Element HOT 1
- Improvement: Address Element HOT 3
- Website routes map idea HOT 2
- index.js:7 IntegrationError: stripe.confirmPayment(): the `confirmParams.return_url` argument is required when using automatic payment methods. HOT 1
- The bundle has both `use strict` and use non strict code from facebook's regenerator.
- Elements cannot start
- first time contribution HOT 1
- Vue warning with Nuxt 3 HOT 3
- Vue Router issue when using Vue Stripe package with Vue 3 HOT 1
- Update to stripe.js v3 HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vue-stripe.