← All integrations
Import.io + LlamaIndex

Web scraping tools for LlamaIndex

BasicMCPClient and McpToolSpec turn the Import.io Web Scraper MCP into tools for FunctionAgent, AgentWorkflow or your own workflows.

Connects via
MCP
Setup
10 min
Available on
10,000 free successful calls, then $0.0002 per call
Python
import asyncio, os
from llama_index.tools.mcp import BasicMCPClient, McpToolSpec
from llama_index.core.agent.workflow import FunctionAgent
from llama_index.llms.openai import OpenAI

async def main():
    client = BasicMCPClient(
        "https://mcp.import.io/mcp",
        headers={"Authorization": f"Bearer {os.environ['IMPORTIO_MCP_KEY']}"},
    )
    tools = await McpToolSpec(client=client).to_tool_list_async()
    agent = FunctionAgent(tools=tools, llm=OpenAI(model="gpt-5"),
                          system_prompt="Fetch live pages with Import.io before answering.")
    print(await agent.run("What are the current rates on https://example.com/rates?"))

asyncio.run(main())

How it connects.

Source

The web

Any public page, rendered, through managed proxies

Engine

Import.io

Rendering, proxy routing, captcha handling, extraction

Path

Import.io MCP

https://mcp.import.io/mcp

Destination

LlamaIndex

Import.io tools for LlamaIndex agents and workflows.

What teams do with it.

Fresh context for RAG

Fetch the pages a question depends on and add them to the context at query time.

What are the current rates on this page?

Index builders

Extract structured records from a site and write them into a LlamaIndex index.

Extract every FAQ question and answer from this help center.

Agent workflows with web steps

A workflow step that collects live data before analysis.

Collect today’s top 20 products in this category with prices.

Set it up.

  1. pip install llama-index llama-index-tools-mcp.
  2. Create a BasicMCPClient for https://mcp.import.io/mcp with a bearer header.
  3. Convert it with McpToolSpec(...).to_tool_list_async() and give the tools to your agent.

Questions.

Can I index extracted pages permanently?

Yes. Extract records with the MCP for ad-hoc work, or schedule an extractor and load its latest-run JSON into your index for repeatable pipelines.

What does the Import.io MCP cost?

Signup includes 10,000 successful calls. After that it is $0.0002 per successful call. Setup requests, tool listings, malformed requests, blocked requests and failed upstream calls are never billed, and you can set a monthly spend limit that stops paid usage when reached.

OAuth or API key?

Use OAuth in interactive clients that support it: the client opens a sign-in, stores the credentials and reuses them. Use an API key for scripts, servers and clients without OAuth, sent as Authorization: Bearer mcp_live_…. Keep keys out of prompts and shared config files.

Which tools does the server expose?

importio_web_fetch, importio_render, importio_extract_data and importio_get_html, page helpers such as importio_page_text, importio_page_links and importio_search_cards, and browser actions for clicks, form input, scrolling, pagination, waits, screenshots and captcha handling. Requests can pick a proxy country and type, with bounded retries when a page blocks.

Give LlamaIndex
the live web.