> For the complete documentation index, see [llms.txt](https://help.wotnot.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.wotnot.io/build/integrations/native/freshdesk.md).

# Freshdesk

{% hint style="info" %}
Available on the STARTER plan and above.
{% endhint %}

Freshdesk is a popular ticketing system that allows users to create and manage tickets.&#x20;

Using this integration, you will be able to;&#x20;

* Create tickets&#x20;
* Get ticket status

## Connecting your Freshdesk account

There are two ways through which you can connect your Freshdesk account with WotNot;

* **Through App Market:** Goto App Market > Freshdesk > Add Account&#x20;
* **Using the 'Freshdesk' action block:** On the action block, click on 'Add Account'&#x20;

Fields required to connect a Freshdesk account:

* **Name:** A name you would like to give for this Freshdesk account.
* **Helpdesk URL**: Subdomain URL of your Freshdesk account like, [https://yourdomain.freshdesk.com](https://yourdomain.freshdesk.com/)
* **API key**: API key of your Freshdesk account. [You can find it here](https://support.freshdesk.com/en/support/solutions/articles/215517-how-to-find-your-api-key)

<figure><img src="/files/5bfuo5fVCfqxOEv4cwQI" alt=""><figcaption></figcaption></figure>

## Create tickets

To create a ticket using the Fresdesk action block, follow these steps:

1. Connect/Choose the freshdesk account
2. Choose "Create ticket" as action
3. Map the Freshdesk fields with the variables
4. Save the ticket ID into a variable (Used to acknowledge the user that their ticket is created)

<figure><img src="/files/pTHhFnWLE99iNefO3E4J" alt=""><figcaption></figcaption></figure>

**Mandatory fields to create a ticket: Subject & Email**

{% hint style="info" %}
The system auto-populates fields from 'Freshdesk fields'. If you do not see your field, refresh the page and try again.
{% endhint %}

## Get ticket status:&#x20;

To fetch the ticket status using the Freshdesk integration, follow these steps:&#x20;

1. Connect/Choose the freshdesk account
2. Choose "Get ticket status" as action
3. Choose the variable containing the ticket number (Before this action block executes, make sure you collect and store the ticket number in a variable)
4. Map the freshdesk fields you want to store into variables&#x20;

<figure><img src="/files/Tnv05nGyxZeQtPHPxbvH" alt=""><figcaption></figcaption></figure>

Freshdesk sends the following list of fields as response when trying to fetching the status of a ticket.

```markup
// Fields received from Freshdesk when fetching ticket status
cc_emails/fwd_emails/reply_cc_emails/ticket_cc_emails: ["test@wotnot.io"]
email_config_id
group_id
priority: "Urgent"
requester_id: 84005322544, // visitor's unique Freshdesk ID
responder_id: null, // Freshdesk agent's ID
source: "Portal"
company_id
status: "Open"
subject: "Need support to fix this..."
product_id
id
type: "Question"
due_by/fr_due_by
description_text: "Some details on the issue .."
created_at: "2022-02-10T07:12:39Z"
updated_at: "2022-02-10T07:12:39Z"
tags
```

After saving the required fields into a variable, you can use them in a 'Send Message' block to show the user the ticket's status like:

```
Ticket status of #ID# is #STATUS#

Please wait to hear back from us.
```

## Next steps&#x20;

For each Freshdesk action block, you will notice two ports coming out:

**SUCCESS** — when the Freshdesk API gives a successful, the chat flow will proceed here.

**FAILURE** — when the Freshdesk API does not give a response, the chat flow will proceed here.

You can view the logs of each Freshdesk execution from the App market > Freshdesk > Logs


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.wotnot.io/build/integrations/native/freshdesk.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
