Skip to main content

LangChain tools for the Metalift web context API

Project description

Metalift LangChain integration

LangChain tools for Metalift — a hosted web context API that turns URLs into LLM-ready markdown for agents. This package wraps the Metalift REST API; it does not use @langchain/community RecursiveUrlLoader or any local server-side HTTP fetch of user-supplied URLs.

Get an API key

  1. Sign up for Metalift Cloud and verify your email.
  2. Complete onboarding on the dashboard.
  3. Copy your API key from Dashboard → API keys.

New accounts receive 1,000 free credits/month on the Free tier. Use the hosted API at https://api.metalift.ai, or point api_url at your own self-hosted scrape API.

Do not commit API keys into source code — pass them at runtime or via the METALIFT_API_KEY environment variable.

Security

  • All URL fetching runs on the Metalift scrape API with SSRF guards: manual redirect validation, private/metadata IP blocklist, DNS pinning, and Playwright egress isolation.
  • Do not use LangChain's built-in RecursiveUrlLoader (or similar loaders with automatic redirect following) for untrusted URLs — see CVE-2026-27795 and Metalift security.

Usage

pip install metalift-langchain
from metalift_langchain import get_metalift_tools

tools = get_metalift_tools(api_url="https://api.metalift.ai", api_key="YOUR_API_KEY")

Requires the metalift-sdk package and a reachable Metalift scrape API.

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

metalift_langchain-1.0.3.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

metalift_langchain-1.0.3-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file metalift_langchain-1.0.3.tar.gz.

File metadata

  • Download URL: metalift_langchain-1.0.3.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for metalift_langchain-1.0.3.tar.gz
Algorithm Hash digest
SHA256 3cc2f4453b594babb9819bf053adf03623f692685c274ac5f8365f39021d7d01
MD5 e82124042746931273c1f2d2704c0878
BLAKE2b-256 3a99f5c030c82e8e09551e323f81b5d9bfcba7b986acf86c5a9199e005caf63a

See more details on using hashes here.

File details

Details for the file metalift_langchain-1.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for metalift_langchain-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 a5e46b6dde204fdfd082250affee0e22aa5de0eb5a5246a1b78aa8be9bd4e35a
MD5 7e34fc969ab8fa4d41182baa0d5ca1ec
BLAKE2b-256 ec46be6e816d5899ff32fe3f7c286bf73eed55ca49bac9a171988badc34580b2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page