Search API Connector Documentation

Print

Import Freshdesk Data to Google Sheets

In this article we'll be connecting to the Freshdesk API from Google Sheets, using the API Connector add-on for Sheets.

Freshdesk is a cloud-based customer support platform with a rich collection of API endpoints that allow you to easily collect data from just about anywhere within your customer support pipeline. So let's jump in and see what we can fetch!

Contents

Before You Begin

Click here to install the API Connector add-on from the Google Marketplace.

Part 1: Get your Freshdesk API Key

  1. Log in to Freshdesk to gain access to your API key. Once logged in, navigate to the main dashboard, click on your profile pic in the top right corner and click Profile Settings.
  2. Your API key will be on the right side, ready to go! Copy that down as we'll need it shortly.
    freshdesk-img2
  3. One last step. Freshdesk uses Basic Authentication, so you need to encode your API key. To encode your credentials, type your API key into this form, using the format APIkey:X (your API key, a colon, and then the capital letter X). Your encoded credentials will appear underneath.

    The encoding script runs in your browser, and none of your credentials are seen or stored by this site.

     

Part 2: Pull Data from Freshdesk into Sheets

The easiest way to get started with the Freshdesk API is through API Connector’s built-in integration.

  1. Select Freshdesk from the drop-down list of applications
    freshdesk-application
  2. Under Authorization, enter your encoded API key with the word Basic in front.
    freshdesk-authorization
  3. Choose an endpoint, for example /tickets
  4. Enter your Freshdesk domain in the path parameters section.
  5. Choose a destination sheet, name your request, and hit Run to see the response data in your sheet.
    freshdesk-response

Part 3: Create a Custom API Request

Alternatively, you can create a custom request instead of using API Connector’s pre-built integration, using any of the endpoints and parameters shown in the API documentation. To create a custom request, add the complete URL into the request URL field, and include a header of Key = Authorization, Value = Basic your_encoded_API_key

freshdesk-custom

To easily convert from a preset request to a custom API URL, tick the Add request URL box before running your preset request (under Output options). This will print out your complete API URL, which you can then copy/paste into the request URL field.

Part 4: Handle Pagination

By default, Freshdesk limits the number of records returned at one time to 30, as described here.freshdesk-img7

You can loop through pages automatically with pagination handling (paid feature). Freshdesk’s documentation shows that next page URLs are provided in a field called “Link”, so you would loop through your records like this:

  • Pagination: next page URL
  • Next page path: Link
  • Run until: choose when to stop fetching data
    pagination-nextpageurl-Link

Part 5: API Documentation

Official API documentation: https://developers.freshdesk.com/api/

8 thoughts on “Import Freshdesk Data to Google Sheets”

  1. Thanks Ana for this great work.
    As I connected to the Freshdesk API I needed to make some changes to the headers Authorization value. It worked using only the API key with a ":" at the end (no API nor x) and encode this string. Hope this saves some time for somebody using Freshdesk and Mixed Analytics.
    Best regards

    Reply
    • You don't actually need to be logged in to use their API, so they're providing a rather misleading error message. It just means you have entered invalid credentials. Please doublecheck that you've encoded your token and there aren't any typos.

      Reply
    • Based on their documentation, that's not possible.

      The maximum number of objects that can be retrieved per page is 100. Invalid values and values greater than 100 will result in an error.

      The pagination section of this article shows how you can loop through to retrieve more than 100 values.

      Reply
  2. We use Freshservice and are successfully using the Mixed Analytics API Connector for Google Sheets. However, when we do a scheduled daily/weekly import (OVERWRITE) the Column Headers reorder (same names but the column numbers are different). Is there a way to ensure the Google Sheets Column headers stay in the same order after each import?

    Reply

Leave a Reply to Sebastian Cancel reply

Jump To...