Can`t create ticket via API with attachment and tags

Hello! I`m successfully creates tickets via API with attachment without tags, but then I add tags gets result: "{"message":"We're sorry, but something went wrong."}"


Success attempt:

curl -v -u APIKEY:test -F "attachments[]=@/home/user/Downloads/photo_2020-06-24_10-25-44.jpg" -F "email=superman@freshdesk.com" -F "subject=Test attach" -F "description=this is a sample ticket" -F "status=2" -F "priority=1" -F "source=2" -X POST 'https://SUBDOMAIN.freshdesk.com/api/v2/tickets'

 Failed attempts:

curl -v -u APIKEY:test -F "attachments[0]=@/home/user/Downloads/photo_2020-06-24_10-25-44.jpg" -F "email=superman@freshdesk.com" -F "subject=Test attach" -F "description=this is a sample ticket" -F "status=2" -F "priority=1" -F "source=2" -F "tags[]=Tagname" -X POST 'https://SUBDOMAIN.freshdesk.com/api/v2/tickets'

curl -v -u APIKEY:test -F "attachments[0]=@/home/user/Downloads/photo_2020-06-24_10-25-44.jpg" -F "email=superman@freshdesk.com" -F "subject=Test attach" -F "description=this is a sample ticket" -F "status=2" -F "priority=1" -F "source=2" -F "tags[0]=Tagname" -X POST 'https://SUBDOMAIN.freshdesk.com/api/v2/tickets'

curl -v -u APIKEY:test -F "attachments[0]=@/home/user/Downloads/photo_2020-06-24_10-25-44.jpg" -F "email=superman@freshdesk.com" -F "subject=Test attach" -F "description=this is a sample ticket" -F "status=2" -F "priority=1" -F "source=2" -F "tags=Tagname" -X POST 'https://SUBDOMAIN.freshdesk.com/api/v2/tickets'

 

1 Comment

 It`s fails only in multipart requests. I`m correctly creates tickets with tags in json requests. But in this case unable append attachments in same request

Login or Signup to post a comment