Skip to main content


It was working find few days back. Today I encountered that it returned the error as



--



{"description":"Validation failed","errors":[{"field":"person","message":"It should be one of these values: 'First Person,Second Person,Third Persson,fourth Person,Fifth'","code":"missing_field"}]}



--






The same code had worked earlier. I even tried with sample code on api documentation from fiddler & received the same error.






Can somebody look into this?






The fiddler query was



---



POST https://<myDomain>.freshdesk.com/api/v2/tickets HTTP/1.1
Content-Type: application/json
Authorization: Basic Base64Encode(APIKey:X)
Host: mydomain.freshdesk.com
Content-Length: 196

{ "description": "Details about the issue...", "subject": "Support Needed...", "email": "tom@outerspace.com", "priority": 1, "status": 2, "cc_emails": ["ram@freshdesk.com","diana@freshdesk.com"] }



---





From the response we can deduce that a custom_field called "person" is missing in the params. From the response we can conclude that as a dropdown field configured with the choices "First Person, Second Person,Third Persson, fourth Person, Fifth'" Also it is marked as "Required when submitting the form" in agent's behaviour. The following JSON will work






{ "description": "Details about the issue...", "subject": "Support Needed...", "email": "tom@outerspace.com", "priority": 1, "status": 2, "cc_emails": ["ram@freshdesk.com","diana@freshdesk.com"], "custom_fields" : { "person": "First Person" } }