AskElephant MCP
Hosted MCP server that lets staff search and retrieve AskElephant call transcripts from claude.ai, with tools for listing meetings, searching transcript excerpts, and fetching full transcripts.
README
AskElephant MCP
A Cloudflare Worker that lets Meticulosity staff dig into AskElephant call transcripts from claude.ai, on the web and on mobile.
Live: https://askelephant-mcp.<your-subdomain>.workers.dev/mcp
Deploy your own: SETUP.md
Setup for staff: docs/install-guide.md
How to ask for things: docs/usage-examples.md
Why this exists
AskElephant ships an MCP server, but it runs locally over stdio. That works for Cursor, VS Code, Windsurf and Claude Desktop, and it does nothing for claude.ai, which can only talk to a hosted endpoint. Our team works in claude.ai, so transcripts were out of reach there. This Worker is the hosted endpoint.
It is read-only. Every path to AskElephant is a GET. Nothing in this codebase can change, delete, or create anything in your AskElephant account.
The problem it actually solves
Transcripts are enormous. Measured across the real corpus:
| characters | approx tokens | |
|---|---|---|
| average call | 41,518 | 10,400 |
| largest measured | 129,088 | 32,300 |
Handing whole transcripts to a model costs about 415,000 tokens for a forty-call search, which does not fit in a 200,000-token context window. So the design principle is:
The Worker does the reading. Claude does the thinking.
Transcript text never reaches the model unless someone explicitly asks for it. A forty-call search costs roughly 12,400 tokens instead of 415,000, because the Worker fetches the transcripts, scans them itself, and returns only the matching passages.
The five tools, cheapest first
| Tool | What it does | Cost |
|---|---|---|
list_meetings |
Compact rows: id, title, date, duration, companies | ~30 tokens per row |
list_companies / list_contacts |
Name to id lookup for the filters | negligible |
search_transcripts |
Searches inside transcripts, returns short excerpts with speaker and timestamp | ~12,400 tokens for 40 calls |
get_transcript |
Full raw text, in chunks | up to ~32,000 tokens for one call |
The tool descriptions themselves steer Claude toward the cheap ones. That is
deliberate: get_transcript describes itself as expensive and points at
search_transcripts first.
search_transcripts requires a narrowing filter (a date range, a company, a
contact, or title terms). Without one it would scan the entire corpus of 3,705
engagements, so it refuses instead.
Architecture
claude.ai --MCP over Streamable HTTP--> Worker --REST--> app.askelephant.ai/api/v2
|
+-- KV cache (transcripts, 90 day TTL)
Stateless apart from the cache. No database, no ingestion pipeline, no sync job. The Worker is fully correct with the cache empty; the cache only saves refetching.
Login is Cloudflare Access over OIDC with PKCE.
@cloudflare/workers-oauth-provider makes the Worker its own OAuth server so
claude.ai can register itself, and delegates the actual login upstream to
Cloudflare Access. Access is restricted to the named individuals in CONFIG.allowedEmails.
Repo layout
| Path | What |
|---|---|
src/config.ts |
Every deployment-specific value. The seam a fork changes. |
src/askelephant.ts |
The only code that talks HTTP to AskElephant |
src/meetings.ts |
Listing and the compact projection |
src/cache.ts |
Read-through KV transcript cache |
src/search.ts |
Pure excerpt scanner, no IO |
src/search_meetings.ts |
Search orchestration, caps and guards |
src/mcp.ts |
The five tools |
src/access_handler.ts |
Cloudflare Access OIDC login |
docs/api-notes.md |
Verified AskElephant API reference. See below. |
docs/api-notes.md is the valuable part
AskElephant's v2 API is not publicly documented. docs/api-notes.md records what
we established by probing it, with the raw commands and raw output, including
where an earlier conclusion was wrong and how it was corrected. Some of it is
genuinely surprising:
- The auth header takes the raw key with no
Bearerprefix processing_statusreportsPENDINGfor every engagement ever, including calls from 2023, so it is useless as a filtersearchmatches titles only, never transcript bodies, which is the entire reason the excerpt scanner exists- Date filters reject a plain
2026-01-01and require a full UTC datetime filter[company_ids]returns a 400 without an operator; it needsfilter[company_ids][in]- There is no summary and no action-items content: the transcript is all you get
Every one of those cost us a bug or a wrong assumption first. Read that file before changing anything that talks to the vendor.
Development
npm install # requires the committed .npmrc, see below
npm test # 143 tests, no network access
npm run typecheck
Why .npmrc exists. Plain npm install fails with ERESOLVE because
wrangler, agents and @cloudflare/workers-types declare peer ranges that
npm's strict resolver will not reconcile, even though every individual range is
satisfiable. .npmrc sets legacy-peer-deps=true, which restores npm's
pre-v7 behaviour and changes which versions actually install not at all. Without
that file the build is not reproducible on a clean checkout.
Tests never touch the network. Every AskElephant response in the suite comes from a recorded fixture built from real probe output.
Deploying
The Worker lives on the Meticulosity Cloudflare account. Note that a global
CLOUDFLARE_API_TOKEN in a shell profile may point somewhere else entirely, so
pass the token explicitly:
export CLOUDFLARE_API_TOKEN=$(security find-generic-password -s cloudflare_api_token -w)
export CLOUDFLARE_ACCOUNT_ID=<YOUR_CLOUDFLARE_ACCOUNT_ID>
npx wrangler deploy
Secrets are set with wrangler secret put and never live in this repo:
ASKELEPHANT_API_KEY, ACCESS_CLIENT_ID, ACCESS_CLIENT_SECRET,
ACCESS_ISSUER, COOKIE_ENCRYPTION_KEY.
Data retention
Transcripts the Worker reads are cached in Cloudflare KV with a 90 day
expiry (CONFIG.cacheTtlDays). That is a retention decision, not a performance
knob: without it the Worker would keep a permanent second copy of every
transcript it ever read, outside AskElephant's own retention controls. Lower it
if your client agreements require it.
Access and offboarding
Access is an explicit list of named people in CONFIG.allowedEmails, enforced
twice: the Cloudflare Access policy names the same individuals, and the Worker
re-checks the identity before registering any tools.
It is not domain-wide, and that is a correction rather than a preference. We
first granted the whole @example.com domain, reasoning that revocation
could be delegated upstream because everyone uses a company-controlled Claude
account, so deprovisioning that account would take the connector with it. That
reasoning is wrong. The connector can be added from any Claude account,
including a personal one, because the only identity the Worker ever sees is the
Cloudflare Access identity. This was demonstrated during setup, when two
separate Claude clients registered against the same address.
Revoking someone
Removing a person from CONFIG.allowedEmails and from the Access policy stops
them getting a new grant. It does not touch a grant they already hold, which
lives in OAUTH_KV and keeps working until it expires.
To cut someone off immediately:
scripts/revoke.sh someone@example.com # deletes their grants and tokens
scripts/revoke.sh --list # show every live grant
Do all three: revoke the grant, remove them from CONFIG.allowedEmails and
redeploy, and remove them from the Cloudflare Access policy. The first cuts off
the session they have; the other two stop them logging back in.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。