Skip to main content

Geonode for LangChain: Web Scraping Tools for AI Agents

Geonode for LangChain: Web Scraping Tools for AI Agents

Give your LangChain agents web search and page content for research and retrieval workflows. Extract pages, crawl sites, discover URLs and run batches. Use the returned content in your own research and RAG pipelines, with tools to retrieve or wait for background jobs.

Try Geonode for free

Integrations page · Geonode API docs · LangChain setup guide · View package on PyPI · View source on GitHub · Complete guide

Quick start · Available operations · Example: a research workflow in LangChain · Setup questions

Workflow ideas

  • Research with source material. Let an agent search for relevant pages and extract their content before composing an answer with source URLs.
  • Prepare a retrieval corpus. Map a site, select relevant URLs and extract Markdown for your own indexing pipeline.

Quick start

Requires Python 3.10 or newer and a Geonode API key from the dashboard. The direct-tool example works without a language model.

pip install geonode-scraper-langchain
export GEONODE_SCRAPER_API_KEY="your-api-key"
import os

from geonode_scraper_langchain import build_langchain_tools
from geonode_scraper_tools_core import ScraperToolSettings

settings = ScraperToolSettings(
    host="https://scraper.geonode.io",
    api_key=os.environ["GEONODE_SCRAPER_API_KEY"],
)
tools = build_langchain_tools(settings=settings, operations=["extract"])
extract = next(tool for tool in tools if tool.name == "scraper_extract_content")
outcome = extract.invoke({"url": "https://example.com", "formats": ["markdown"]})

if outcome["ok"]:
    print(outcome["result"]["data"]["markdown"])
else:
    print(outcome["error"]["status"], outcome["error"]["message"])

API calls use your Geonode plan. Successful tools return ok, operation, attempts and result; API failures return a structured error with status, message and retryability. Validation or framework errors may still raise before an API request.

Use with an agent

Install your model provider's integration and set its credentials separately. Set LANGCHAIN_MODEL to a model identifier supported by your installed LangChain version. Install langchain in addition to this package; the package itself depends only on langchain-core.

Continue from the configured tools above:

from langchain.agents import create_agent

agent = create_agent(os.environ["LANGCHAIN_MODEL"], tools=tools)
result = agent.invoke({"messages": [{"role": "user", "content": "Summarize https://example.com"}]})
print(result["messages"][-1].content)

The model chooses tool calls. Restrict the available operations to the tasks your agent needs:

tools = build_langchain_tools(
    settings=settings,
    operations=["extract", "map_urls", "search"],
)

Available operations

Task Operations
Extract pages extract, get_job_result, wait_for_job, list_jobs
Batch extraction create_batch, get_batch_status, wait_for_batch, list_batch_jobs
Crawl websites create_crawl, get_crawl_status, wait_for_crawl, list_crawl_jobs
Map website URLs map_urls, list_map_jobs, get_map_job
Search the web search, list_search_jobs, get_search_job
Account and service get_statistics, get_concurrency_usage, health_check

The complete guide lists each tool ID, settings, polling and response handling. The shared geonode-scraper-tools-core runtime is installed automatically. This package integrates directly with LangChain; it does not start an MCP server.

Understand the tool result

The toolkit wraps successful API results with ok, operation, attempts and result. For synchronous Markdown extraction, check ok before reading result.data.markdown. API failures return an error with status, code, message and retryable; argument-validation or framework errors can raise before that envelope is returned.

The quick start calls a tool directly, without a model. Once that succeeds, give the selected tools to your agent and configure its model provider separately. The Geonode key and model-provider key are different credentials.

Example: a research workflow in LangChain

  1. Choose only the extract, map_urls and search operations for a focused research task.
  2. Ask the agent to discover relevant URLs, select a small set, and extract those pages as Markdown.
  3. Require it to inspect tool errors and retain the source URL for every page it uses.
  4. Pass the extracted content to the model for analysis, then save the answer with its sources in your own application.
  5. Use explicit page limits and a separate completion check if the task needs a crawl or batch.

Expected result: The tools return web content and job results. The model performs the reasoning and summarization; these toolkits do not supply a vector database, a model subscription or a ready-made research agent.

Setup questions

Why is the agent not calling a tool? First run the direct-tool example, then check that your agent receives the selected tools and that its model supports tool calling. Installing the package alone does not configure an agent.

Why did a long job time out? Request timeouts and wait-tool polling timeouts are separate. Preserve the job ID and retrieve its state before retrying a submission.

Do I need agent tools core separately? The framework package installs the shared runtime as a dependency. Use it directly only when building your own adapter.

Is this MCP? These are native framework tools. Use the separate Geonode MCP connection for an MCP-compatible assistant.

These recipes describe source-supported workflows. They have not been run as authenticated end-to-end examples in this review.

Development and support

See CONTRIBUTING.md for local checks and releases.

For API or account questions, contact Geonode. For security issues, follow SECURITY.md. Licensed under MIT.

Try Geonode for free

Metadata

Release files for geonode-scraper-langchain 0.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for geonode-scraper-langchain 0.5.0
File Size Uploaded Provenance Actions
geonode_scraper_langchain-0.5.0.tar.gz 13.6 kB With provenance Details for geonode_scraper_langchain-0.5.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for geonode-scraper-langchain 0.5.0
File Interpreter ABI Platform Actions
geonode_scraper_langchain-0.5.0-py3-none-any.whl Python 3 none any Details for geonode_scraper_langchain-0.5.0-py3-none-any.whl

Total release size: 20.3 kB

Release files / geonode_scraper_langchain-0.5.0.tar.gz

Download URL geonode_scraper_langchain-0.5.0.tar.gz
Size 13.6 kB
Tags Source
SHA-256 checksum
How to use checksums
4ad0a1ba6e0a74ec9ce1c76ecfe8c3c0369de01a2532ccf0039362022f0add05
BLAKE2b-256 checksum
How to use checksums
f14194e9f08712cd882a9176f3f83bdff023c3289ab0eee2604e9f4c1f82352c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Release files / geonode_scraper_langchain-0.5.0-py3-none-any.whl

Download URL geonode_scraper_langchain-0.5.0-py3-none-any.whl
Size 6.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
818f7e4abaa6ada0f2cd31fd7321d535f3eed4f370c4918c5c32d566b200e053
BLAKE2b-256 checksum
How to use checksums
7891daacaf1c50c93537313df89b8274831725fa35a3f40a4dbc74c5f2a1d87f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

Security for geonode-scraper-langchain 0.5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for geonode_scraper_langchain-0.5.0.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 26, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page