diegosouzapw/OmniRoute · error
Memory not found: ${memoryId}
Error message
Memory not found: ${memoryId} What it means
Error "Memory not found: ${memoryId}" thrown in diegosouzapw/OmniRoute.
Source
Thrown at src/lib/skills/memoryBuiltins.ts:37
] as const;
const MEMORY_TYPES = ["factual", "episodic", "procedural", "semantic"] as const;
function toMemoryType(value: unknown): MemoryType {
return MEMORY_TYPES.includes(value as (typeof MEMORY_TYPES)[number])
? (value as MemoryType)
: MemoryType.FACTUAL;
}
function toPositiveInt(value: unknown, fallback: number, max: number): number {
const parsed = Number(value);
if (!Number.isInteger(parsed) || parsed <= 0) return fallback;
return Math.min(parsed, max);
}
async function assertOwner(memoryId: string, apiKeyId: string): Promise<void> {
const memory = await getMemory(memoryId);
if (!memory) throw new Error(`Memory not found: ${memoryId}`);
if (memory.apiKeyId !== apiKeyId) {
throw new Error("Memory does not belong to this API key");
}
}
function memoryToPlain(memory: Awaited<ReturnType<typeof createMemory>>) {
return {
id: memory.id,
type: memory.type,
key: memory.key,
content: memory.content,
metadata: memory.metadata,
createdAt: memory.createdAt.toISOString(),
updatedAt: memory.updatedAt.toISOString(),
};
}
async function handleMemorySave(input: Record<string, unknown>, context: { apiKeyId: string; sessionId: string }) {View on GitHub (pinned to a179ffed5b)
When it happens
Trigger: Thrown at src/lib/skills/memoryBuiltins.ts:37 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of diegosouzapw/OmniRoute@a179ffed5b (2026-08-25).
Data as JSON: /api/errors/fe07ac3fa52a0bcf.
Report an issue: GitHub.