# Oil & Gas Inventory Report: Weekly Stocks and Draws (`scrapemint/oil-gas-inventory-report`) Actor

Keyless weekly energy inventory data that moves oil and gas prices worldwide. Crude, gasoline and distillate stocks with the weekly build or draw and the year ago comparison, the supply balance with production, imports and refinery runs, and natural gas storage against its five year average.

- **URL**: https://apify.com/scrapemint/oil-gas-inventory-report.md
- **Developed by:** [Ken M](https://apify.com/scrapemint) (community)
- **Categories:** Business, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$4.00 / 1,000 inventory rows

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Oil & Gas Inventory Report: Weekly Stocks and Draws

Twice a week the US government publishes the numbers the energy market trades on. The prints move Brent in Singapore as readily as WTI in Houston, which is why their release times sit in every energy trader's calendar.

This reads both reports directly and turns them into rows. No key, no login, no proxy.

### Three modes

**Stocks** returns one row per product: crude, gasoline, distillate, jet fuel, propane, residual fuel, the Strategic Petroleum Reserve and the totals.

| Field | Meaning |
| --- | --- |
| `stocks`, `priorWeekStocks` | Inventory in million barrels |
| `weeklyChange`, `weeklyPercentChange`, `direction` | The build or draw, the number the market reacts to |
| `yearAgoStocks`, `yearOverYearChange`, `yearOverYearPercentChange` | The same week a year earlier |
| `weekEnding`, `priorWeekEnding`, `yearAgoWeekEnding` | Which weeks are being compared |

**Supply** returns the full balance, about 37 lines: domestic production split between Alaska and the Lower 48, imports, exports, refinery inputs, processing gain, and products supplied, each with the weekly change, a four week average and a year to date average.

**Natural gas** returns the storage report: total in the ground, the net injection or withdrawal, the year ago level, and the five year average with the percentage gap to it.

### Example input

```json
{
  "mode": "stocks"
}
```

Just the draws in the products that matter:

```json
{
  "mode": "stocks",
  "productFilter": ["crude", "gasoline", "distillate"],
  "onlyDraws": true
}
```

### Two things worth knowing

**The petroleum file holds two tables, not one.** Part way down, a second header begins a completely different table with a different column count and a **different unit**: stocks are million barrels, the supply balance is thousand barrels per day. Read as a single CSV, every row after the break misaligns and the two units silently mix. This actor splits the file at each header and tags every row with its own unit.

**An undefined percentage is not zero.** Where a percentage change has no meaning, because the value crossed from positive to negative, the file carries a placeholder character rather than a number. Those fields come back null, so a stock change that swung from a draw to a build never reports as unchanged.

### Release timing

The petroleum report is published Wednesday and the gas report Thursday, both mid morning New York time, with holiday weeks shifting a day later. Between releases the actor returns the most recent published report, and every row carries the week it covers, so a scheduled run never leaves you guessing whether the number is fresh.

### Pricing

Pay per inventory row, `$0.004`. The first 2 rows of every run are free, and note rows are never charged. A full stocks run is about 19 rows and a full supply run about 37, in a couple of seconds.

### Related actors

- **Commodity Futures Prices: Gold, Oil, Grains and Rates** for the crude and gas prices these numbers move
- **European Electricity Prices** for the demand side in power markets
- **CFTC Commitments of Traders (COT) Tracker** for how traders are positioned into the release

# Actor input Schema

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

stocks = what is in storage and the weekly build or draw. supply = production, imports, exports and refinery runs. natural\_gas = the gas storage report against its five year average.

## `productFilter` (type: `array`):

Keep only rows whose name contains one of these, e.g. crude, gasoline, distillate, propane, jet. Empty returns every line of the report.

## `onlyDraws` (type: `boolean`):

Stocks mode. Keep only products where inventories FELL this week, which is the bullish half of the report.

## `onlyBuilds` (type: `boolean`):

Stocks mode. Keep only products where inventories ROSE this week.

## `maxRows` (type: `integer`):

Cap on rows returned. The stocks table has about 19 lines and the supply balance about 37.

## Actor input object example

```json
{
  "mode": "stocks",
  "productFilter": [],
  "onlyDraws": false,
  "onlyBuilds": false,
  "maxRows": 100
}
```

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("scrapemint/oil-gas-inventory-report").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("scrapemint/oil-gas-inventory-report").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 '{}' |
apify call scrapemint/oil-gas-inventory-report --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,scrapemint/oil-gas-inventory-report"
        }
    }
}

```

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/FfVagJzvwCcaxH9xw/builds/jmqaHts2P4ciqwusJ/openapi.json
