| 58 | } |
| 59 | |
| 60 | export interface Backend { |
| 61 | add( |
| 62 | content?: string, |
| 63 | messages?: Record<string, unknown>[], |
| 64 | opts?: AddOptions, |
| 65 | ): Promise<Record<string, unknown>>; |
| 66 | |
| 67 | search( |
| 68 | query: string, |
| 69 | opts?: SearchOptions, |
| 70 | ): Promise<Record<string, unknown>[]>; |
| 71 | |
| 72 | get(memoryId: string): Promise<Record<string, unknown>>; |
| 73 | |
| 74 | listMemories(opts?: ListOptions): Promise<Record<string, unknown>[]>; |
| 75 | |
| 76 | update( |
| 77 | memoryId: string, |
| 78 | content?: string, |
| 79 | metadata?: Record<string, unknown>, |
| 80 | ): Promise<Record<string, unknown>>; |
| 81 | |
| 82 | delete( |
| 83 | memoryId?: string, |
| 84 | opts?: DeleteOptions, |
| 85 | ): Promise<Record<string, unknown>>; |
| 86 | |
| 87 | deleteEntities(opts: EntityIds): Promise<Record<string, unknown>>; |
| 88 | |
| 89 | ping(): Promise<Record<string, unknown>>; |
| 90 | |
| 91 | status(opts?: { userId?: string; agentId?: string }): Promise< |
| 92 | Record<string, unknown> |
| 93 | >; |
| 94 | |
| 95 | entities(entityType: string): Promise<Record<string, unknown>[]>; |
| 96 | |
| 97 | listEvents(): Promise<Record<string, unknown>[]>; |
| 98 | |
| 99 | getEvent(eventId: string): Promise<Record<string, unknown>>; |
| 100 | } |
| 101 | |
| 102 | export class AuthError extends Error { |
| 103 | constructor( |
no outgoing calls
no test coverage detected