Reputation: 119
I have integrated XERO with my php(codeigniter) website, everything i have implemented is working just fine. I want to send the invoice through an email i have created.
I am using XeroOAuth.
//This line is working properly
$response = $this->XeroOAuth->request('GET', $this->XeroOAuth->url('Invoices/'.$invoiceId, 'core'), array(), "", 'pdf');
//but cant send email through xero api
$send_email = $this->XeroOAuth->request('POST', $this->XeroOAuth->url('Invoices/'.$invoiceId.'/Email', 'core'), array() );
As their documentation explain that, this line of code should trigger the xero send mail option, but its returning error 401
Upvotes: 2
Views: 472