freshworks / fresh-samples

Samples of code created by freshdesk
184 stars 181 forks source link

How can I post more than one attachments? #48

Closed vslovik closed 5 years ago

vslovik commented 6 years ago

https://github.com/freshdesk/fresh-samples/blob/8de3cee918be7e3fc2f89921f5c4b9a4dbbfc7bd/PHP/create_ticket_with_attachment.php#L13

NettoPassaro commented 5 years ago

Could you solve this question?

I'm trying add curl_file_create() files into a array, but getting: {"description":"Validation failed","errors":[{"field":"attachments","message":"It should contain elements of type valid file format only","code":"datatype_mismatch"}]}

NettoPassaro commented 5 years ago

Now i get it with other example...

here

hrishikesh-p commented 5 years ago

https://github.com/freshdesk/fresh-samples/blob/master/PHP/create_ticket_with_multiple_attachments.php