aboutsummaryrefslogtreecommitdiff
path: root/packages/lib/api.ts
diff options
context:
space:
mode:
authorDhravya Shah <[email protected]>2025-09-18 20:34:18 -0700
committerDhravya Shah <[email protected]>2025-09-18 21:03:49 -0700
commit1fcb56908920da386900abb4ce2383374a625c72 (patch)
tree0f9d7f695d4c9b1b85be3950fc869e0061dff3ed /packages/lib/api.ts
parentrefetching logic change (diff)
downloadsupermemory-09-18-formatting.tar.xz
supermemory-09-18-formatting.zip
Diffstat (limited to 'packages/lib/api.ts')
-rw-r--r--packages/lib/api.ts18
1 files changed, 18 insertions, 0 deletions
diff --git a/packages/lib/api.ts b/packages/lib/api.ts
index ad343050..82c0b8ef 100644
--- a/packages/lib/api.ts
+++ b/packages/lib/api.ts
@@ -10,6 +10,7 @@ import {
DeleteProjectSchema,
DocumentsWithMemoriesQuerySchema,
DocumentsWithMemoriesResponseSchema,
+ GetMemoryResponseSchema,
ListMemoriesResponseSchema,
ListProjectsResponseSchema,
MemoryAddSchema,
@@ -126,7 +127,24 @@ export const apiSchema = createSchema({
input: SettingsRequestSchema,
output: SettingsResponseSchema,
},
+
+ "@get/documents/:id": {
+ output: GetMemoryResponseSchema,
+ params: z.object({ id: z.string() }),
+ },
+
// Memory operations
+ "@get/documents": {
+ output: ListMemoriesResponseSchema,
+ query: z
+ .object({
+ limit: z.number().optional(),
+ page: z.number().optional(),
+ status: z.string().optional(),
+ containerTags: z.array(z.string()).optional(),
+ })
+ .optional(),
+ },
"@post/documents": {
input: MemoryAddSchema,
output: MemoryResponseSchema,