"""ARC before_checkout through llama-index-tools-mcp. No model, no key. pip install llama-index-tools-mcp python example.py """ import asyncio import os from llama_index.tools.mcp import BasicMCPClient, McpToolSpec ARC = os.environ.get("ARC_MCP_URL", "https://www.arcreport.ai/api/ask") async def main() -> None: tools = await McpToolSpec(client=BasicMCPClient(ARC)).to_tool_list_async() by_name = {t.metadata.name: t for t in tools} # Call before_checkout before you send the user to checkout. record = await by_name["before_checkout"].acall(url="https://allbirds.com") print(record) asyncio.run(main())