# Webz.io News API (`webzio/news-search`) Actor

Describe the news you need in plain language. Webz.io finds relevant articles worldwide,
ready for your product, research, or AI application, with precise filtering options.

- **URL**: https://apify.com/webzio/news-search.md
- **Developed by:** [Webz.io](https://apify.com/webzio) (community)
- **Categories:** News, AI, Integrations
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $2.00 / 1,000 news searches

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Webz.io News Search

[Search for news](https://webz.io/products/news-search-api/) in plain language. [Webz.io](https://webz.io) finds relevant articles worldwide, ready for your product, research, or AI application, with precise filtering options. Search in plain language. The Actor returns one dataset row per article: title, URL, publish time, match score, excerpt, and source metadata.

This Actor calls the [Webz.io News Search API](https://docs.webz.io/docs/webz/news-search-api) (`POST /api/news/context`). It does not crawl the web.

### What you pay

You pay Apify. There is no Webz token to paste.

A successful run charges one `search` event, plus one `apify-default-dataset-item` event per article saved. Prices are on this Actor's page. An invalid query is not charged.

### Input

| Field | Required | What it does |
| --- | --- | --- |
| Query | Yes | Natural-language topic or question. Max 750 characters and 100 words. |
| Number of articles | No | 1–50. Default 10. |
| Published within days | No | Last N days, UTC. Coverage is 30 days. |
| Filters | No | Language, country, sentiment, domain, ticker, and the rest of the News Search filters. |

Pass **Published within days** or **Published from**, not both.

### Output

The dataset has one item per article. The main columns are `score`, `title`, `url`, `published_at`, `text`, `domain`, `language`, `country`, `sentiment`, and `ticker`. Other metadata from the article is included when the API sends it.

The key-value store record `OUTPUT` holds `query` and `total_results`.

### Run from code

```python
from apify_client import ApifyClient

client = ApifyClient("<APIFY_TOKEN>")
run = client.actor("webzio/news-search").call(run_input={
    "query": "recent developments on EU AI regulation",
    "k": 10,
    "days": 7,
    "language": ["english"],
})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["score"], item["title"], item["url"])
```

Agents can call the same Actor through the Apify MCP server with `?tools=webzio/news-search`.

# Actor input Schema

## `query` (type: `string`):

Natural-language topic or question. Maximum 750 characters and 100 words.

## `k` (type: `integer`):

How many articles to return.

## `days` (type: `integer`):

Only articles published in the last N days, counted in UTC. Coverage is 30 days. Leave empty to use the API default. Do not set this together with Published from.

## `score_gte` (type: `number`):

Minimum semantic match score, 0 to 10. The API default is 4. Use 0 to disable the floor.

## `score_lte` (type: `number`):

Maximum semantic match score, 0 to 10.

## `allow_multiple_chunks_per_article` (type: `boolean`):

Return more than one matching passage from the same article.

## `language` (type: `array`):

Article languages, for example english.

## `country` (type: `array`):

Source countries as ISO-2 codes, for example US or GB.

## `category` (type: `array`):

Article categories, for example Politics.

## `sentiment` (type: `array`):

positive, negative, or neutral.

## `published_from` (type: `string`):

Earliest publish date, YYYY-MM-DD. Do not set this together with Published within days.

## `published_to` (type: `string`):

Latest publish date, YYYY-MM-DD.

## `domain` (type: `array`):

Only these source domains, for example cnn.com.

## `exclude_domain` (type: `array`):

Skip these source domains. A domain cannot be in both Domain and Exclude domain.

## `topic` (type: `array`):

Topic tags, finer than category.

## `person` (type: `array`):

People mentioned in the article.

## `organization` (type: `array`):

Organizations mentioned in the article.

## `location` (type: `array`):

Locations mentioned in the article.

## `ticker` (type: `array`):

Stock tickers of mentioned organizations, for example NVDA.

## `political_bias` (type: `array`):

Source bias: left, center, or right.

## `trust_category` (type: `string`):

trusted_news, fake_news, or satirical_news.

## `source_type` (type: `string`):

local_news, newsroom, or gov_news.

## `domain_rank_gte` (type: `integer`):

Minimum Tranco domain rank. 1 is the most popular.

## `domain_rank_lte` (type: `integer`):

Maximum Tranco domain rank.

## Actor input object example

```json
{
  "query": "recent developments on EU AI regulation",
  "k": 10
}
```

# Actor output Schema

## `articles` (type: `string`):

No description

## `summary` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "query": "recent developments on EU AI regulation"
};

// Run the Actor and wait for it to finish
const run = await client.actor("webzio/news-search").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "query": "recent developments on EU AI regulation" }

# Run the Actor and wait for it to finish
run = client.actor("webzio/news-search").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "query": "recent developments on EU AI regulation"
}' |
apify call webzio/news-search --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,webzio/news-search"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/XrlQ3NfsPFZxP2fcq/builds/WOKTF40ztfGybfmUe/openapi.json
