#Masum-invoice-items
1 messages · Page 1 of 1 (latest)
Hi there! Are you creating invoice items or passing a price ID? Have you taken a look at https://stripe.com/docs/invoicing/integration?
No I am not passing any price id just customer id
Gotcha so that is why you are hitting that error. Can you tell me more about what you are trying to do?
I was trying to create invoice with this code $stripe->invoices->create([
'customer' => 'cus_4QE4N83DfMpDkX',
]);
Using my own customer id of course
but it is showing "Nothing to invoice..."
Sure but what is your goal? Are you trying to charge them for something?
Why are you creating the invoice?
My goal is to create invoice and send it to customer
'collection_method' => 'send_invoice'
Okay and will you know what you want to charge the customer when you create the invoice?
Like how much you want to charge them?
yes, I have product for that
Got it, then take a look at the above docs and you must create an Invoice Item first before you create the invoice. Then the invoice will pick up that item to charge.
Wahoo!
It's created but as draft
Yep, did you read the above doc? You will want to finalize/send it via the API