Skip to content

Latest commit

 

History

History
43 lines (35 loc) · 1.17 KB

README.md

File metadata and controls

43 lines (35 loc) · 1.17 KB

@firesquad/api-sdk

Properly integrate your Nodejs apps with firesquad usign this SDK.

Firesquad

Quick Start

For getting started, Create an API Integration on Firesquad. After that, you can use this firesquad package:

import { Firesquad, ConversationContentMessageType } from "@firesquad/api-sdk";

export const fs = new Firesquad(
  "https://<your-account>.api.firesquad.io",
  "<your-api-id>",
  "<your-api-key>"
);

/* You can use firesquad methods after creating the instance, such as: */
fs.PostConversationItem(
  {
    internal: false,
    content: {
      message: [
        {
          type: ConversationContentMessageType.Paragraph,
          children: [{ text: "Hello, World!" }],
        },
      ],
    },
  },
  "<your-conversation-id>"
)
  /* And wait for the response */
  .then((response) => console.log(response));