A Webhook is a callback to an application or web service that is triggered when a specific event occurs. That means you can set up a Webhook to look for a specific update, change or action to occur in your Helpdesk and it will automatically push the information you specify to the application you want. In simple words, two applications communicate using Webhooks.
Webhooks can be triggered via the automations, Dispatch'r and Observer, in Freshdesk.
An API key is a unique alphanumeric identifier, for each agent on your Freshdesk Account. Irrespective of which version of Freshdesk's APIs you use, you will need to provide either your username and password combination or your API key for authorization when making API calls by triggering webhooks. Here's how you can retrieve your API key:
- Login to your Freshdesk Account.
- Click on your Agent Avatar on the top right and select Profile Settings.
On the right pane, you would find the API Key.
Copy-paste this as required to authenticate third-party solutions.
If you are using the V1, the rate limit is 1000 calls/hour.
On the V2, the following rates will apply:
Calls per hour allowed
Blossom and Garden
Estate and Forest
If you are looking to increase your API limit, please drop an email to email@example.com with a complete description of your use-case and we'll help you sort this out.
Any webhook you have set up within your helpdesk - be it from Dispatch'r or Observer, or even external webhooks from Zapier and TimeCamp - will contribute towards adding to the API calls resulting in meeting with your rate limits.
You could create tickets using API and also simultaneously update ticket fields in the ticket. To create tickets via API from a remote location, you can make use of the documentation mentioned in this article.
We also have a full-fledged API documentation that would help you with all the possibilities of Freshdesk's API.
This can be done using using API. Setup a dispatcher rule as follows:
Condition : Description contains "..........."
Action: Trigger a webhook
Kindly refer to this link for API for ticket update and copy the code accordingly for changing the subject.
You can view the tickets from a custom ticket list view, using API. You could make use of v1 of API to have this done. Please refer to this documentation for detailed information on the same.
You could use the API to "View a Ticket" and as part of the response, you would be able to receive the Tag added to the ticket.
Command : Get
Callback URL : /api/v2/tickets/[id]
Sample Curl : curl -v -u username:password -H "Content-Type: application/json" -X GET 'https://domain.freshdesk.com/api/v2/tickets/20'
As of now, the V2 of Freshdesk's API supports only the Freshdesk URL on HTTPs. Making calls using the vanity URL isn't supported.
This is a notification email that is auto-generated when a Webhook which is triggered from your account fails. This Webhook might be a part of the automations or from your server.
When you set-up webhooks, you would have entered an incorrect URL or the content in the script for webhooks might be incorrect. Please confirm that you have entered the right URL for those webhooks and verify if the rules are set correctly.
This email is an auto-generated alert that is sent to the Admins of your Freshdesk Account, when a Webhook from your account is dropped.
Freshdesk allows you to set up as many Webhooks for event triggers as you want, but will execute them only based on the API rate limit for your account. So, if you schedule more than the assigned call rate, you will hit your rate limits and any Webhooks beyond that limit will be postponed to the next hour.
If more Webhooks are triggered within the hour then, depending on the timing, the excess webhooks from the previous hour would be postponed for execution. If a webhook keeps getting postponed from execution for more than 24 hours, then it will be dropped.
A webhook would be dropped only if it exceeds the permitted API rate limit of your Freshdesk Account. Please write to firstname.lastname@example.org with details regarding the webhook and use-case for which you had set it up. One of our agents would get in contact with you to discuss on making this more efficient for you, after which you could trigger the webhooks and keep it within the rate limit.
The following are the possible error messages related to an API call in Freshdesk:
|HTTP STATUS CODE
||Client or Validation Error
||The request body/query string is not in the correct format. For example, the Create a ticket API requires the requester_id field to be sent as part of the request and if it is missing, this status code is returned.
||Indicates that the Authorization header is either missing or incorrect. You can learn more about the Authorization header here.
||This indicates that the agent whose credentials were used in making this request was not authorized to perform this API call. It could be that this API call requires admin level credentials or perhaps the Freshdesk portal doesn't have the corresponding feature enabled. It could also indicate that the user has reached the maximum number of failed login attempts or that the account has reached the maximum number of agents
||Requested Resource not Found
||This status code is returned when the request contains invalid ID/Freshdesk domain in the URL or an invalid URL itself. For example, an API call to retrieve a ticket with an invalid ID will return a HTTP 404 status code to let you know that no such ticket exists.
||Method not allowed
||This API request used the wrong HTTP verb/method. For example, an API PUT request on /api/v2/tickets endpoint will return a HTTP 405 as /api/v2/tickets allows only GET and POST requests.
||Unsupported Accept Header
||Only application/json and */* are supported.
When uploading files multipart/form-data is supported.
||The resource that is being created/updated is in an inconsistent or conflicting state. For example, if you attempt to Create a Contact with an email that is already associated with an existing user, this code will be returned.
||Content type application/xml is not supported. Only application/json is supported.
||Rate Limit Exceeded
||The API rate limit allotted for your Freshdesk domain has been exhausted.
||Unexpected Server Error
||Phew!! You can't do anything more here. This indicates an error at Freshdesk's side. Please email us your API script along with the response headers. We will reach you out to you and fix this ASAP.
Freshdesk API documentation could be found under - https://developers.freshdesk.com/api. Using the information available here, you would be able to build your own account specific API based on your business requirements.