From 0aa0f44ac4bb233590ebad675fa88901289b2ffa Mon Sep 17 00:00:00 2001 From: Soumil Rathi Date: Mon, 13 Apr 2026 13:20:25 -0700 Subject: [PATCH] fix: revert search return type to Array (matches unwrap logic) Someone else's changes unwrap the v3 envelope in the client, so the return type should stay as Array for consistency. Co-Authored-By: Claude Opus 4.6 (1M context) --- mem0-ts/src/client/mem0.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mem0-ts/src/client/mem0.ts b/mem0-ts/src/client/mem0.ts index 8cc1b253a..a9b6cd15e 100644 --- a/mem0-ts/src/client/mem0.ts +++ b/mem0-ts/src/client/mem0.ts @@ -280,7 +280,7 @@ export default class MemoryClient { async search( query: string, options?: SearchMemoryOptions, - ): Promise<{ results: Array }> { + ): Promise> { if (this.telemetryId === "") await this.ping(); const payloadKeys = Object.keys(options || {}); this._captureEvent("search", [payloadKeys]);