/** * AgentHub Client is a JavaScript library to access the AgentHub service, * which is part of the Olos Anywhere product. Add it to your frontend * project to allow agents to establish a connection with the server and * receive events from the Olos platform. * * Example of utilization: * * ```javascript * import { Connection } from "@olostecnologia/agenthub-client" * * const conn = Connection() * * conn.on("connected", (agentInfo) => { * console.log("Agent connected", agentInfo) * }) * * conn.on("disconnected", () => { * console.log("Agent disconnected") * }) * * conn.on("onlineUsers", renderOnlineUsers) * * conn.on("ScreenPopVoice", (event) => { * console.log("Displaying a voice screen pop:", event) * }) * * conn.on("ThirdParty", (event) => { * console.log("Handling a 3rd party event:", event) * }) * * conn.connect(() => token, "https://agenthub.api.olos.live") * ``` * * Please refer to the README file for more information. * * @module AgentHubClient */ import { Connection, IConnection } from "./connection.js"; export { Connection, IConnection };