HelpDesk App Framework SDK

1.0.16 · active · verified Tue Apr 21

The HelpDesk App Framework (BAF) SDK, currently at version 1.0.16, is a JavaScript library designed to streamline cross-frame communication for applications integrated into the HelpDesk helpdesk platform. It provides a unified interface for apps running within iframes to interact seamlessly with the host framework. Key capabilities include secure data access (retrieving and updating ticket, contact, and chat information), robust event handling for platform events, managing app instances, and accessing runtime context and metadata. This SDK primarily targets developers building custom applications that need to embed and interact deeply within the HelpDesk ecosystem, simplifying complex cross-origin communication patterns.

Common errors

Warnings

Install

Imports

Quickstart

Initializes the BAF SDK, logs basic context information, and demonstrates fetching data after successful initialization.

import BAFClient from 'helpdesk-app-framework-sdk';

const client = BAFClient.init((context) => {
  console.log('App initialized and ready!');
  console.log('Current Module:', context.module);       // E.g., 'ticket', 'contact', 'chat'
  console.log('Object ID:', context.objectId);          // ID of the current object being viewed
  console.log('User Name:', context.user.name);
  console.log('User Email:', client.context.getUserEmail()); // Access context details directly from client instance

  // Example: Fetching ticket subject after initialization
  client.get('ticket.subject').then(data => {
    console.log('Ticket Subject:', data['ticket.subject']);
  }).catch(error => {
    console.error('Failed to get ticket subject:', error);
  });
});

view raw JSON →