n8n-io/n8n · error · NodeOperationError
Collection ${collectionName} not found
Error message
Collection ${collectionName} not found What it means
Thrown in the Zep vector store populate path when Zep rejects with HTTP 400 and the responseData text contains 'CreateDocumentCollectionRequest'. n8n interprets that combination as the target collection not existing / not being auto-creatable, and surfaces a friendlier message. The message also warns that collection names must be alphanumeric.
Source
Thrown at packages/@n8n/nodes-langchain/nodes/vector_store/VectorStoreZep/VectorStoreZep.node.ts:142
collectionName,
embeddingDimensions: options.embeddingDimensions ?? 1536,
isAutoEmbedded: options.isAutoEmbedded ?? true,
};
try {
if (credentials.cloud) {
await ZepCloudVectorStore.fromDocuments(documents, embeddings, zepConfig);
} else {
await ZepVectorStore.fromDocuments(documents, embeddings, {
...zepConfig,
apiUrl: credentials.apiUrl,
});
}
} catch (error) {
const errorCode = (error as IDataObject).code as number;
const responseData = (error as IDataObject).responseData as string;
if (errorCode === 400 && responseData.includes('CreateDocumentCollectionRequest')) {
throw new NodeOperationError(context.getNode(), `Collection ${collectionName} not found`, {
itemIndex,
description:
'Please check that the collection exists in your vector store, or make sure that collection name contains only alphanumeric characters',
});
}
throw new NodeOperationError(context.getNode(), error as Error, { itemIndex });
}
},
}) {}
View on GitHub (pinned to 5ac6606e81)
Solutions
- Set collectionName to alphanumeric characters only (letters and digits), e.g. 'memories' not 'my-memories' or 'Memories!'.
- Pre-create the collection in Zep if auto-create is disabled or failing.
- Confirm the zepApi credential cloud flag matches your actual Zep deployment (cloud vs self-hosted apiUrl).
- Sanitize any user-derived collection name (strip/replace non-alphanumerics) before passing it to the node.
Example fix
// before: collectionName = 'my-memories_v1' // after: collectionName = 'mymemoriesv1'
Defensive patterns
Strategy: validation
Validate before calling
function sanitizeCollectionName(name: string): string { return name.replace(/[^a-zA-Z0-9]/g, ''); } if (!/^[a-zA-Z0-9]+$/.test(collectionName)) { collectionName = sanitizeCollectionName(collectionName); } Type guard
function isAlphanumericCollection(name: unknown): name is string { return typeof name === 'string' && /^[a-zA-Z0-9]+$/.test(name); } Try / catch
try { await ZepVectorStore.fromDocuments(...) } catch (e) { if (e.code === 400 && /CreateDocumentCollectionRequest/.test(String(e.responseData))) { /* sanitize name and retry */ } else throw e; } Prevention
- Restrict collection names to alphanumerics at the input boundary.
- If collection auto-create is unreliable, pre-create collections in Zep.
- Match the zepApi cloud flag to your real deployment (cloud vs self-hosted).
- Sanitize user-derived names before they reach the node parameter.
When it happens
Trigger: ZepCloudVectorStore.fromDocuments (cloud) or ZepVectorStore.fromDocuments (self-hosted) rejects with error.code === 400 and error.responseData includes 'CreateDocumentCollectionRequest' — i.e. Zep tried to auto-create the collection and the request was invalid (most often because collectionName contains non-alphanumeric characters).
Common situations: collectionName has spaces, hyphens, underscores-as-separators, or other symbols Zep rejects; collection does not exist and isAutoEmbedded/auto-create is blocked; Zep cloud vs self-hosted API mismatch; collection name derived from an unsanitized user input.
Related errors
- MCP server name "${cfg.name}" is already registered
- Index ${indexField} not found
- Table ${tableName} not found
- ${error.message}
- Reflector output did not contain a JSON object
AI-assisted analysis of n8n-io/n8n@5ac6606e81 (2026-08-12).
Data as JSON: /api/errors/92f628e0b0a5140f.
Report an issue: GitHub.