A quick API question


I was testing out the PHP SDK. But when I created an invoice with the following code:

$invoice = $client->createInvoice();
$invoice->addInvoiceItem(‘Item’, ‘Some notes’, 10);

I saw that the invoice was created as concept. How can an invoice be send from the PHP SDK API?

Thanks in advance!

By ‘concept’ do you mean quote?

Oh I’m sorry, I mean draft :slight_smile:

Try adding $invoice->is_public = true;

I see that it now has the status ‘sent’. But does that also send an email to the customer? Or do I need to send that myself?

Try setting email_invoice to true

Thank you so much! That worked :smiley: