# Australian Financial Review (AFR) Article Scraper (`xtracto/afr-scraper`) Actor

Extract full article text, authors, dates and categories from afr.com articles and live blogs, or list the newest AFR headlines. HTTP-only, no browser.

- **URL**: https://apify.com/xtracto/afr-scraper.md
- **Developed by:** [Farhan Febrian Nauval](https://apify.com/xtracto) (community)
- **Categories:** News
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $5.00 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.

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

## Australian Financial Review (AFR) Article Scraper

Extract the full text, headline, summary, authors, dates and categories of any **afr.com** article or live blog, or list the newest AFR headlines. The Australian Financial Review is Australia's main business and finance daily, covering companies, markets, deals (Street Talk), politics and policy.

### Why Use This Actor?

- **Full article text** - the whole story, not just the intro paragraphs. In our November 2026 sample the text matched AFR's own word count on 13 of 13 articles.
- **Live blogs too** - each post is returned with its timestamp and headline, newest first.
- **Clean metadata** - authors, published and modified dates, AFR section categories, image and word count.
- **Fast and light** - an article takes a couple of seconds; no browser is started.
- **You only pay for articles** - a URL that is not an article, or cannot be loaded, is left out and not charged. If no URL succeeds, the run ends Failed and says why.

### Input

```json
{
  "url": "https://www.afr.com/companies/infrastructure/data-centre-rush-needs-a-5b-electricity-upgrade-in-south-australia-20261108-p61at9",
  "urls": [
    "https://www.afr.com/street-talk/article-one-20261108-p61cde",
    "https://www.afr.com/companies/financial-services/article-two-20261108-p61c5k"
  ],
  "mode": "article"
}
```

| Field | Description |
|---|---|
| `url` | One article URL. |
| `urls` | A list of article URLs. |
| `mode` | `article` (default) extracts the URLs; `latest` lists the newest AFR headlines. |
| `limit` | How many headlines `latest` returns. Default 10. |
| `proxyConfiguration` | Optional. A URL that does not load is retried up to 3 times, each through a new proxy session. |

### Output

```json
{
  "url": "https://www.afr.com/companies/infrastructure/data-centre-rush-needs-a-5b-electricity-upgrade-in-south-australia-20261108-p61at9",
  "source": "Australian Financial Review",
  "title": "Data centre rush needs a $5b electricity upgrade in South Australia",
  "description": "The owner of the state's transmission network is weighing up work on power lines and substations, as data centres clamour for connections.",
  "content": "A proposed $5 billion upgrade of electricity grid transmission capacity in South Australia would only be finished by 2032, ...",
  "published_date": "2026-11-08T09:00:00Z",
  "modified_date": "2026-11-08T09:00:00Z",
  "authors": ["Simon Evans", "Jenny Wiggins"],
  "categories": ["Companies", "Infrastructure"],
  "word_count": 1213,
  "image": "https://static.ffx.io/images/...",
  "language": "en_AU"
}
```

Live blogs also carry `"is_live": true`; their `content` holds one block per post (`[timestamp] headline`, then the text), separated by `---`.

### Fetch Latest News

Set `mode` to `"latest"` to list the newest AFR articles instead of extracting one:

```json
{ "mode": "latest", "limit": 10 }
```

Each item has `url`, `title`, `published_date` and `source`.

### Scheduled monitoring

1. Schedule a run with `{"mode": "latest", "limit": 20}` (Apify Console ▸ Schedules), for example `*/30 * * * *`.
2. Chain an `article` run on the new URLs with an "Actor finished" webhook.
3. Each article run appends full text and metadata to your dataset.

### Use responsibly

Article text is copyrighted by Nine / the Australian Financial Review. Output is meant for research, monitoring and analysis; republishing the text is generally not permitted. You are responsible for complying with AFR's terms of service and applicable law.

# Actor input Schema

## `url` (type: `string`):

Single article URL to extract.

## `urls` (type: `array`):

List of article URLs to extract.

## `mode` (type: `string`):

Operation mode: 'article' to extract a single article (default), 'latest' to fetch newest headlines from the source's RSS feed.

## `limit` (type: `integer`):

Number of latest articles to return when mode is 'latest'. Default: 10.

## `proxyConfiguration` (type: `object`):

Optional. Requests go through Apify Proxy when enabled; an article that does not load is retried up to 3 times, each through a new proxy session.

## Actor input object example

```json
{
  "url": "https://www.afr.com/companies/infrastructure/data-centre-rush-needs-a-5b-electricity-upgrade-in-south-australia-20261108-p61at9",
  "mode": "article",
  "limit": 10
}
```

# Actor output Schema

## `results` (type: `string`):

One row per scraped record, stored in the run's default dataset.

# 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 = {
    "url": "https://www.afr.com/companies/infrastructure/data-centre-rush-needs-a-5b-electricity-upgrade-in-south-australia-20261108-p61at9"
};

// Run the Actor and wait for it to finish
const run = await client.actor("xtracto/afr-scraper").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 = { "url": "https://www.afr.com/companies/infrastructure/data-centre-rush-needs-a-5b-electricity-upgrade-in-south-australia-20261108-p61at9" }

# Run the Actor and wait for it to finish
run = client.actor("xtracto/afr-scraper").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 '{
  "url": "https://www.afr.com/companies/infrastructure/data-centre-rush-needs-a-5b-electricity-upgrade-in-south-australia-20261108-p61at9"
}' |
apify call xtracto/afr-scraper --silent --output-dataset

```

## MCP server setup

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

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/bxj7qgu4D6OOZ3NB1/builds/liOD1eHTWPuHI4e2u/openapi.json
