Integration guide
apifare for LangGraph
Give LangGraph one prepaid key for every API it needs. There is no separate provider account or provider API key for eligible capabilities, and it all runs under hard caps and a kill switch.
1 · Get a key
Create an account at /start: email in, token out (shown once). Save the token somewhere safe.
2 · Add apifare to LangGraph
In LangGraph v1, the prebuilt agent is create_agent from langchain.agents, which runs on LangGraph and replaces create_react_agent. Load apifare's tools with LangChain's MCPAdapter and pass them in: the agent you get back is a compiled LangGraph graph.
pip install "langchain[mcp]"import asyncio, os
from fastmcp.client import Client
from langchain.agents import create_agent
from langchain.mcp import MCPAdapter
async def main():
client = Client("https://apifare.com/mcp", auth=os.environ["APIPAY_TOKEN"])
async with MCPAdapter(client) as adapter:
tools = await adapter.list_tools()
agent = create_agent("claude-sonnet-5", tools)
result = await agent.ainvoke(
{"messages": [{"role": "user", "content": "What's the weather in London?"}]}
)
print(result["messages"][-1].content)
asyncio.run(main())Set APIPAY_TOKEN and your model provider's key, then run it. The token goes in as auth without the word "Bearer": FastMCP adds it.
3 · Try it
Ask your LangGraph agent to search the web for X, then to fetch a URL, then what's the weather in London. Every call is debited from your balance and lands on your signed, exportable audit chain.
4 · Stay in control
Set daily or monthly caps per agent, and keep the kill switch ready. Both are checked before a call is dispatched. When the balance runs out, your agent gets an HTTP 402 with a top-up link it can hand you; the error catalog lists every stop and what unblocks it.
What LangGraph can call
Everything on the key: search, filings, registries, weather, and ready-to-run tools, plus any provider key you vault yourself. Exact per-call prices are on /capabilities.
Config checked against LangGraph's MCP docs on 2026-09-13. Markdown version: /integrations/langgraph.md.
More integrations
Claude Code · Claude Desktop · Cursor · Windsurf · Zed · Cline · GitHub Copilot (VS Code) · OpenAI Codex CLI · Gemini CLI · Hermes Agent · Kimi CLI · Qwen Code · JetBrains (Junie) · Warp · Raycast · n8n · Dify · LangChain · CrewAI · Vercel AI SDK · LobeHub · AnythingLLM · OpenClaw · OpenAI Agents SDK · LlamaIndex · Mastra · Goose · LibreChat
Model guides
Calling a model's API directly instead? Give it apifare tools with a plain tool loop: DeepSeek · Kimi · Qwen · OpenAI GPT · Gemini.