Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

57
Views
Los datos proporcionados no eran válidos "La cantidad solicitada no está disponible", NextJS y Commerce JS

Hola chicos, estoy creando un comercio electrónico con CommerceJs y NextJS cuando manejo el pago, recibo este error

mensaje: "Los datos proporcionados no son válidos". tipo: "entidad_no procesable" line_items.item_7RyWOwmK5nEa2V.quantity: ["La cantidad solicitada no está disponible".]

Traté de cambiar mi código como los documentos pero no tuve suerte.

 const orderData = { line_items: { item_7RyWOwmK5nEa2V: { quantity: 1, } }, customer: { firstname: 'John', lastname: 'Doe', email: 'john.doe@example.com' }, shipping: { name: 'John Doe', street: '123 Fake St', town_city: 'San Francisco', county_state: 'US-CA', postal_zip_code: '94103', country: 'US' }, fulfillment: { shipping_method: 'ship_7RyWOwmK5nEa2V' }, billing: { name: 'John Doe', street: '234 Fake St', town_city: 'San Francisco', county_state: 'US-CA', postal_zip_code: '94103', country: 'US' }, payment: { gateway: 'stripe', stripe: { payment_method_id: paymentMethod.id, }, } }
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Debe ingresar a su panel de commerce.js y editar la cantidad disponible de su producto allí. Lo verá en el panel de control > productos > nombre del producto > inventario disponible. Asegúrese de verificar también si tiene variantes, que la variante seleccionada también tenga un inventario disponible para extraer...

Puede usar este código para probar si su inventario de productos está disponible...

 commerce.checkout.checkQuantity("your-checkout-token", 'item-id', { amount: 1, variant_id: 'your-variant-id-OPTIONAL' }).then((response) => console.log(response.available));
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!