#Meet Shah

1 messages · Page 1 of 1 (latest)

lucid arrowBOT
crystal mica
tough kestrel
#

Request req_d08wRCtG3vVuP3: You can only manually send an invoice if its collection method is 'send_invoice'.

#

giving me this error

crystal mica
#

Ah, then I guess you'd just do it via the Dashboard I'm afraid

#

Alternatively you can use get the invoice_pdf from the API and share it with your customer

tough kestrel
#

and how can I send recipt of paid status payment?

crystal mica
#

Again, from the Dashboard

#

We don't really have APIs to trigger that as it's done automatically (in live mode, assuming you have the setting enabled)

tough kestrel
#

so recipt will send to user automatically?

crystal mica
#

We don't send invoices/receipts in test mode automatically

tough kestrel
#

invoice = stripe.Invoice.create(
customer=customer_id,
stripe_account=account_id,
collection_method='charge_automatically',
auto_advance = True
)
inovoiceitem=stripe.InvoiceItem.create(
customer=customer_id,
stripe_account=account_id,
amount = 1500,
currency = 'usd',
invoice = invoice.id
)
invoice = stripe.Invoice.finalize_invoice(
invoice.id,
stripe_account=account_id
)
stripe.Invoice.pay(invoice.id,stripe_account=account_id,
receipt_email='meet@infy.tv')
I have aboce code

in this test mode invoice is getting genrated and payment is also getting completed

I want to send invoice and recipt to user

recipt will send as you said

For invoice I need to downlaod pdf and then need to send?

crystal mica
#

In test mode, you go to the Dashboard page for the Invoice and you can send it from there

#

Otherwise, in live mode, if you have the setting enabled it'll send automatically on payment

tough kestrel
#

okay so Invoice and recipt will be send automatically on live mode

#

am I right?

crystal mica
tough kestrel
#

okay thanks