Hi.
I want to send an attachment file via API, but I get error "500". We search in API documentation, technical support, and nothing.
This is the example code found in Github :
$jsondata = array (
'helpdesk_ticket[email]' => 'john@freshdesk.com',
'helpdesk_ticket[subject]' => 'test',
'helpdesk_ticket[description]' => 'testing description content',
'helpdesk_ticket[attachments][][resource]' => "@" . "/Users/johnpaul/Examples/tommy1.jpg"
);
$header[] = "Content-type: multipart/form-data";
But when I tried this always to my own URL (i.e. $url = 'http://yourcompany.freshdesk.com/helpdesk/tickets.json') the error is 500.