Endpoint to send document by email

-1

Good afternoon.

Where can I find more complete endpoint documentation for sending documents via email? More specifically, I wanted to programmatically replicate the functionality that appears in the Jasmin UI in each document with the "Send - > Print" button.

I have not found anything in the Web API Reference. I only found this mention in link , but I have to specify the content of the email, thus losing the advantage of the template completed and the possibility of sending the document in attachment.

I could get the document through the endpoint print and then resend it, but that would probably be reinventing the wheel ...

Thank you very much in advance.

    
asked by anonymous 02.10.2018 / 18:58

1 answer

2

Good morning John,

In fact, using the web API you can opt for the two alternatives:

  • Draw a new template (writing text or HTTML in the body property)
  • Reuse a template defined in Jasmin
  • To reuse a template, you need to:

  • Make template GET
    link {{account}} / {{subscription}} / billing / invoices / {{id_invoice}} / emailinfo
  • Use it as body in send mail POST, filling only what is missing link {{account}} / {{subscription}} / billing / invoices / {{id_invoice}} / send
  • Regards,

        
    03.10.2018 / 10:38