llama-index-tools-webz
Search global news with Webz.io from Python - in natural language, with the most relevant articles first.
Webz.io News Search covers news and current events from sources worldwide. Ask a question in plain language, narrow results with filters (language, country, date, sentiment, domain, ticker, and more), and get back focused article excerpts with titles, URLs, and metadata.
Use this package on its own, or plug it into LlamaIndex agents.
What you get
- Natural-language search - no keyword hacking. Example:
"EU AI Act enforcement updates"or"How is Tesla stock reacting to earnings?" - Worldwide coverage - semantic search over Webz.io's global news index.
- Rich filters - language, country, days, sentiment, domain, ticker, person, organization, topic, and more. See the MCP tool reference.
- Live schema - filters are loaded from the hosted MCP server (
tools/list). New Webz filters appear automatically, without republishing this package.
Install
pip install llama-index-tools-webz
export WEBZ_API_TOKEN="your-webz-api-token"
Get a token from your Webz.io dashboard (same token as the News Search API).
Full setup and client options: MCP Server docs.
Direct search (no agent required)
from llama_index.tools.webz import WebzNewsSearch, flatten_tool_result
tool = WebzNewsSearch() # reads WEBZ_API_TOKEN from the environment
# tool = WebzNewsSearch(api_token="your-webz-api-token")
result = tool.call(
query="recent developments on EU AI regulation",
k=10,
days=30,
)
print(flatten_tool_result(result))
To see every filter your connection supports:
print(sorted(WebzNewsSearch().metadata.fn_schema.model_fields))
With a LlamaIndex agent
The agent discovers the live tool schema and picks filters itself. Any tool-calling LLM works (Llama, GPT, Claude, and others). The snippet uses Llama via OpenRouter.
from llama_index.core.agent.workflow import FunctionAgent
from llama_index.llms.openai_like import OpenAILike
from llama_index.tools.webz import get_webz_tools
tools = get_webz_tools()
# OpenAI-compatible client; any tool-calling LLM works (Llama shown here)
llm = OpenAILike(
model="meta-llama/llama-3.3-70b-instruct",
api_key="your-openrouter-key",
api_base="https://openrouter.ai/api/v1",
is_chat_model=True,
is_function_calling_model=True,
)
agent = FunctionAgent(
tools=tools,
llm=llm,
system_prompt="You are a helpful assistant that searches global news with Webz.",
)
response = await agent.run(
"Search Webz news for renewable energy investments "
"from the past 30 days and summarize with sources."
)
print(str(response))
Async helpers (when you already run inside an event loop):
from llama_index.tools.webz import aget_webz_tools, awebz_news_search
tools = await aget_webz_tools()
tool = await awebz_news_search()
How it works
This package connects to the hosted Webz News Search MCP server at https://news-search-mcp.webz.io/mcp using llama-index-tools-mcp. Each call runs a regular News Search API request with your token (same credits and rate limits). It does not hardcode filter fields - the tool schema comes from the live server.
Configuration
| Name | Default | Purpose |
|---|---|---|
WEBZ_API_TOKEN |
required | Webz API token from the dashboard |
WEBZ_MCP_URL |
https://news-search-mcp.webz.io/mcp |
Override for local MCP testing |
You can also pass api_token= and mcp_url= to the helpers.
Links
Metadata
Release files for llama-index-tools-webz 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| llama_index_tools_webz-0.1.0.tar.gz | 5.8 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| llama_index_tools_webz-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.6 kB
Release files / llama_index_tools_webz-0.1.0.tar.gz
| Download URL | llama_index_tools_webz-0.1.0.tar.gz |
|---|---|
| Size | 5.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
109f8edccedbe35f5bea6864569b955b08f09d3d7fc85fdcd2258b9f011ceb32
|
|
BLAKE2b-256 checksum How to use checksums |
eff2c6a322603fc070ca55672ae13250ac4fe56ce847595542490e0d00da6bef
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.12
|
Release files / llama_index_tools_webz-0.1.0-py3-none-any.whl
| Download URL | llama_index_tools_webz-0.1.0-py3-none-any.whl |
|---|---|
| Size | 6.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6b1a1e19ee06fba0ad981d57ceb1b1fce72377c96bee203553d5a40fc4d598f4
|
|
BLAKE2b-256 checksum How to use checksums |
b22b172e40c3076110684456f3f9276045c7dbf03d1787e8066641fe317721ad
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.12
|
Security for llama-index-tools-webz 0.1.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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
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.