This guide is for AI agents and automation clients that need deterministic access to the MindSpring backend.
Required environment variables:
export MINDSPRING_BASE_URL="https://mindspring.blue-pine-edf6.workers.dev"
export MINDSPRING_API_KEY="<ingest-or-admin-key>"Auth header used on all requests:
-H "Authorization: Bearer ${MINDSPRING_API_KEY}"Allowed type values:
conversation_archivedev_docsstyle_guidenarrative_bibleworkflow_opspersonal_archiveresearch
WORKSPACE_ID=$(uuidgen | tr '[:upper:]' '[:lower:]')
curl -sS -X POST "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}" \
-H "Content-Type: application/json" \
-d '{
"title": "My Knowledge Notebook",
"type": "research",
"instructions": "Answer only from source evidence and cite chunks."
}'Capture id as NOTEBOOK_ID.
For small payloads (< 5MB), use simple upload:
UPLOAD_PAYLOAD='{"id":"thread-1","title":"Example","create_time":1710000000,"messages":[{"author":{"role":"user"},"content":{"parts":["Hello"]}}]}'
UPLOAD_ID=$(curl -sS -X POST "${MINDSPRING_BASE_URL}/api/uploads/simple" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}" \
-H "Content-Type: application/x-ndjson" \
-H "X-File-Name: source.ndjson" \
--data-binary "${UPLOAD_PAYLOAD}" | jq -r '.uploadId')curl -sS -X POST "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/sources" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}" \
-H "Content-Type: application/json" \
-d "{\"title\":\"Source A\",\"type\":\"chat_export\",\"sourceUploadId\":\"${UPLOAD_ID}\",\"parserType\":\"chat_export\"}"Capture jobId.
JOB_ID="<job-id>"
curl -sS "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/jobs/${JOB_ID}" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}"Terminal states:
completedfailed(checkerrorMessage)
curl -sS -X POST "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/search" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}" \
-H "Content-Type: application/json" \
-d '{"query":"What are recurring ingestion themes?","limit":10,"threshold":0.0}'curl -sS -X POST "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/chat" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}" \
-H "Content-Type: application/json" \
-d '{"message":"Summarize this notebook and cite sources."}'Response includes response + citations[].
curl -sS -X POST "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/artifacts" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}" \
-H "Content-Type: application/json" \
-d '{"template":"briefing_doc"}'curl -sS "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/artifacts" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}"
curl -sS "${MINDSPRING_BASE_URL}/api/v2/workspaces/${WORKSPACE_ID}/notebooks/${NOTEBOOK_ID}/artifacts/<artifactId>" \
-H "Authorization: Bearer ${MINDSPRING_API_KEY}"Artifact responses include snapshotHashes and stale.
MindSpring returns 429 with:
Retry-AfterX-RateLimit-*headers
Agent policy:
- On
429, waitRetry-Afterseconds. - Retry with exponential backoff and jitter for 5xx/network errors.
- Do not poll job status faster than every 2 seconds.
- Re-uploading already ingested conversations is safe for v1 dedupe semantics via
processed:<id>. - For v2 source registration, treat each
sourceUploadId+notebookIdpair as a single source intent.
404on notebook/source/job endpoints: verifyworkspaceIdand object IDs are from same workspace scope.failedingestion job: inspecterrorMessage, fix parser type or source payload shape, retry with a fresh upload/source registration.
POST /api/v2/workspaces/:workspaceId/notebooksGET /api/v2/workspaces/:workspaceId/notebooksGET /api/v2/workspaces/:workspaceId/notebooks/:notebookIdPATCH /api/v2/workspaces/:workspaceId/notebooks/:notebookIdDELETE /api/v2/workspaces/:workspaceId/notebooks/:notebookId(soft delete)POST /api/v2/workspaces/:workspaceId/notebooks/:notebookId/sourcesGET /api/v2/workspaces/:workspaceId/notebooks/:notebookId/sourcesGET /api/v2/workspaces/:workspaceId/notebooks/:notebookId/sources/:sourceIdGET /api/v2/workspaces/:workspaceId/notebooks/:notebookId/jobs/:jobIdPOST /api/v2/workspaces/:workspaceId/notebooks/:notebookId/searchPOST /api/v2/workspaces/:workspaceId/notebooks/:notebookId/chatGET /api/v2/workspaces/:workspaceId/notebooks/:notebookId/chunksPOST /api/v2/workspaces/:workspaceId/notebooks/:notebookId/artifactsGET /api/v2/workspaces/:workspaceId/notebooks/:notebookId/artifactsGET /api/v2/workspaces/:workspaceId/notebooks/:notebookId/artifacts/:artifactId