Hi Travis,
Yes, if any field is set to be a mandatory field while creation and if the same is not defined while creating the ticket via API, the validation will fail. Please make sure that all the mandatory fields required for ticket creation are defined while using the API to create a ticket.
Hope this clarifies.
Travis Tubbs
We're doing some tests to see about creating tickets in Freshservice via the API. However, when doing so, we're receiving a validation error.
The code we're trying through the terminal is as follows:
APIKeyHere = my API Key as obtained through my profile in Freshservice
existing-contact@emai.here = Email Address of an existing contact
domain = our Freshservice subdomain name
When I run the above command, I receive the following error:
Looking through the API v2 documentation, "department_id" is not listed as a required field. This particular contact does have a Department/Company associated with the account (as do a majority of our contacts).
If an existing contact has any Departments/Companies added to their record, does that make the department_id field required? Or is this because we have Department/Company as a required field when submitting and close a ticket? (We have this set for both the agents and customers.)