/freshworks-api-sdk

Node.js client SDK for Freshworks' REST APIs, currently in beta. Supports Freshteam and Freshservice (partially).

Primary LanguageJavaScriptMIT LicenseMIT

Freshworks API SDK

Node.js SDK for working with Freshworks HTTP APIs. Currently supports Freshteam and partially supports Freshservice.

Installation

npm install --save @freshworks/api-sdk

Supported product APIs

Product Status
Freshteam
Freshservice 🏁

🏁 - Partially supported services

Get started

This section depicts example of using different API capabilities offered with examples

Freshteam

This section depicts example of interacting with Freshteam API

const { Freshteam } = require("@freshworks/api-sdk");

const ft = new Freshteam(domain, apiKey);

Call a method, e.g., list all employees (who match a search criteria):

const res = await ft.employees.list({ first_name: "Arthur", last_name: "Dent" });
// Access the response body as an Array of `Employee` objects
const employees = res.json();

Freshservice

This section depicts example of interacting with Freshservice API

const { Freshservice } = require("@freshworks/api-sdk");

const fs = new Freshservice(domain, apiKey);

Call a method, e.g., fetch a Freshservice Ticket

// Get a tick with given ticket ID
const res = await fs.tickets.get(14000239432);
// Access the response body as a `Ticket` object
const ticket = res.json();

Documentation


License

MIT