@hamsa-ai/voice-agents-sdk 0.5.4 → 0.5.5-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hamsa-ai/voice-agents-sdk",
3
- "version": "0.5.4",
3
+ "version": "0.5.5-beta.1",
4
4
  "description": "Hamsa AI - Voice Agents JavaScript SDK",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",
@@ -195,6 +195,8 @@ export declare class LiveKitToolRegistry extends EventEmitter {
195
195
  private room;
196
196
  /** Array of client-side tools available for agent execution */
197
197
  private tools;
198
+ /** Set of currently registered RPC method names for cleanup */
199
+ private readonly registeredMethods;
198
200
  /** Debug logger instance for conditional logging */
199
201
  private readonly logger;
200
202
  /**
@@ -328,6 +330,23 @@ export declare class LiveKitToolRegistry extends EventEmitter {
328
330
  * 5. Tools become immediately available for agent calls
329
331
  */
330
332
  registerTools(): void;
333
+ /**
334
+ * Unregisters all currently registered RPC methods
335
+ *
336
+ * Removes all tool RPC handlers from the LiveKit room.
337
+ * This is called automatically before re-registering tools to prevent
338
+ * duplicate registration errors.
339
+ *
340
+ * @example
341
+ * ```typescript
342
+ * // Manually unregister all tools
343
+ * registry.unregisterAllTools();
344
+ *
345
+ * // Tools are no longer available to the agent
346
+ * console.log('All tools unregistered');
347
+ * ```
348
+ */
349
+ unregisterAllTools(): void;
331
350
  /**
332
351
  * Processes incoming data messages from voice agents and participants
333
352
  *