Search email by meaning, not keywords.
InboxParse indexes every email thread with fulltext, semantic vectors, and hybrid retrieval - all available through a single search endpoint.
# Semantic search - find by meaning, not exact words
curl "https://inboxparse.com/api/v1/search?q=renewal+offer+pricing&mode=semantic&limit=10" \
-H "Authorization: Bearer ip..."
# Fulltext search - BM25 keyword matching
curl "https://inboxparse.com/api/v1/search?q=invoice+Q1+2026&mode=fulltext&limit=10" \
-H "Authorization: Bearer ip..."
# Hybrid search - best of both worlds (recommended)
curl "https://inboxparse.com/api/v1/search?q=customer+churn+risk&mode=hybrid&limit=10" \
-H "Authorization: Bearer ip..."
# Response
{
"data": [
{
"id": "thread_01jxxx",
"subject": "Re: Contract renewal - 20% discount offer",
"score": 0.94,
"snippet": "...we'd like to offer you a 20% renewal discount...",
"labels": { "category": "sales", "action": "reply" }
}
]
}Three search modes
Fulltext (BM25), semantic (vector), and hybrid - switch with a single query parameter. No extra config.
Managed vector index
We embed and index every email automatically. No pgvector migrations, no Pinecone projects, no maintenance.
Label-based filtering
Narrow search results by AI labels: ?filter=category:sales or ?filter=action:reply. Precision retrieval.
Agent-ready endpoint
Give your LLM agent a tool that calls this endpoint. Agents can now search your entire email archive by intent.
MCP tool built-in
The search endpoint is also available as an MCP tool - Claude Desktop and Cursor can search your email natively.
Mailbox scoping
Search across all mailboxes or scope to a specific one with ?mailbox_id=. Works with IMAP and Gmail.
Build an email search tool for your LLM agent
Copy-and-paste ready. No boilerplate.
import { openai } from "@ai-sdk/openai"
import { generateText, tool } from "ai"
import { z } from "zod"
const result = await generateText({
model: openai("gpt-4o-mini"),
tools: {
searchEmails: tool({
description: "Search the email archive by meaning. Returns relevant threads.",
parameters: z.object({
query: z.string().describe("What to search for"),
mode: z.enum(["semantic", "fulltext", "hybrid"]).default("hybrid"),
}),
execute: async ({ query, mode }) => {
const res = await fetch(
`https://inboxparse.com/api/v1/search?q=${encodeURIComponent(query)}&mode=${mode}&limit=5`,
{ headers: { Authorization: "Bearer ip..." } }
)
const { data } = await res.json()
return data
},
}),
},
prompt: "Find all emails about contract renewals from enterprise customers.",
})
console.log(result.text)Frequently asked questions
What is the difference between fulltext, semantic, and hybrid search?+
Fulltext search uses BM25 keyword matching - fast and exact. Semantic search uses vector embeddings to find results by meaning, even when exact words differ. Hybrid combines both for the best precision and recall. Switch modes with a single query parameter.
Do I need to manage my own vector database?+
No. InboxParse embeds and indexes every email automatically. You get semantic search out of the box without setting up pgvector, Pinecone, or any other vector store.
Can I filter search results by AI labels?+
Yes. Add label filters like ?filter=category:sales or ?filter=action:reply to narrow results. Combine with semantic search for precise, intent-aware retrieval.
Explore more use cases
Your email archive is a knowledge base. Treat it like one.
Semantic search ready out of the box. No vector infra to manage.