2,500+ MCP servers ready to use
Vinkius

OilPrice MCP Server for Mastra AI 10 tools — connect in under 2 minutes

Built by Vinkius GDPR 10 Tools SDK

Mastra AI is a TypeScript-native agent framework built for modern web stacks. Connect OilPrice through Vinkius and Mastra agents discover all tools automatically. type-safe, streaming-ready, and deployable anywhere Node.js runs.

Vinkius supports streamable HTTP and SSE.

typescript
import { Agent } from "@mastra/core/agent";
import { createMCPClient } from "@mastra/mcp";
import { openai } from "@ai-sdk/openai";

async function main() {
  // Your Vinkius token. get it at cloud.vinkius.com
  const mcpClient = await createMCPClient({
    servers: {
      "oilprice": {
        url: "https://edge.vinkius.com/[YOUR_TOKEN_HERE]/mcp",
      },
    },
  });

  const tools = await mcpClient.getTools();
  const agent = new Agent({
    name: "OilPrice Agent",
    instructions:
      "You help users interact with OilPrice " +
      "using 10 tools.",
    model: openai("gpt-4o"),
    tools,
  });

  const result = await agent.generate(
    "What can I do with OilPrice?"
  );
  console.log(result.text);
}

main();
OilPrice
Fully ManagedVinkius Servers
60%Token savings
High SecurityEnterprise-grade
IAMAccess control
EU AI ActCompliant
DLPData protection
V8 IsolateSandboxed
Ed25519Audit chain
<40msKill switch
Stream every event to Splunk, Datadog, or your own webhook in real-time

* Every MCP server runs on Vinkius-managed infrastructure inside AWS - a purpose-built runtime with per-request V8 isolates, Ed25519 signed audit chains, and sub-40ms cold starts optimized for native MCP execution. See our infrastructure

About OilPrice MCP Server

Connect to OilPriceAPI and bring real-time energy commodity intelligence to any AI agent. Access 50+ energy commodities with prices updated every 5 minutes.

Mastra's agent abstraction provides a clean separation between LLM logic and OilPrice tool infrastructure. Connect 10 tools through Vinkius and use Mastra's built-in workflow engine to chain tool calls with conditional logic, retries, and parallel execution. deployable to any Node.js host in one command.

What you can do

  • WTI Crude Oil — Get current and historical West Texas Intermediate crude prices, the primary US oil benchmark
  • Brent Crude — Track international crude oil prices, the global benchmark for oil trading
  • Natural Gas — Monitor Henry Hub natural gas prices updated every 5 minutes
  • Refined Products — Access diesel, gasoline, heating oil, and jet fuel prices
  • Coal — Track Newcastle thermal coal benchmarks
  • Latest Prices — Fetch current spot prices for any or all commodities
  • Intraday Data — Analyze hourly price movements over the last 24 hours
  • Weekly Trends — Review daily prices for the last 7 days
  • Monthly Analysis — Examine daily prices for the last 30 days
  • Historical Data — Query custom date ranges for long-term trend analysis (paid tier)
  • Commodity Catalog — Explore all 50+ available energy commodities and their codes

The OilPrice MCP Server exposes 10 tools through the Vinkius. Connect it to Mastra AI in under two minutes — no API keys to rotate, no infrastructure to provision, no vendor lock-in. Your configuration, your data, your control.

How to Connect OilPrice to Mastra AI via MCP

Follow these steps to integrate the OilPrice MCP Server with Mastra AI.

01

Install dependencies

Run npm install @mastra/core @mastra/mcp @ai-sdk/openai

02

Replace the token

Replace [YOUR_TOKEN_HERE] with your Vinkius token

03

Run the agent

Save to agent.ts and run with npx tsx agent.ts

04

Explore tools

Mastra discovers 10 tools from OilPrice via MCP

Why Use Mastra AI with the OilPrice MCP Server

Mastra AI provides unique advantages when paired with OilPrice through the Model Context Protocol.

01

Mastra's agent abstraction provides a clean separation between LLM logic and tool infrastructure. add OilPrice without touching business code

02

Built-in workflow engine chains MCP tool calls with conditional logic, retries, and parallel execution for complex automation

03

TypeScript-native: full type inference for every OilPrice tool response with IDE autocomplete and compile-time checks

04

One-command deployment to any Node.js host. Vercel, Railway, Fly.io, or your own infrastructure

OilPrice + Mastra AI Use Cases

Practical scenarios where Mastra AI combined with the OilPrice MCP Server delivers measurable value.

01

Automated workflows: build multi-step agents that query OilPrice, process results, and trigger downstream actions in a typed pipeline

02

SaaS integrations: embed OilPrice as a first-class tool in your product's AI features with Mastra's clean agent API

03

Background jobs: schedule Mastra agents to query OilPrice on a cron and store results in your database automatically

04

Multi-agent systems: create specialist agents that collaborate using OilPrice tools alongside other MCP servers

OilPrice MCP Tools for Mastra AI (10)

These 10 tools become available when you connect OilPrice to Mastra AI via MCP:

01

get_brent_price

Prices update every 5 minutes. USE WHEN: - User asks specifically about Brent oil price - User needs the international crude oil benchmark - User wants to check European/global oil prices - User asks "what is Brent price" EXAMPLES: - "What is Brent price?" → call with no params - "Current Brent crude oil price" → call with no params - "Brent oil benchmark" → call with no params Get current Brent crude oil price

02

get_diesel_price

Important for tracking transportation fuel costs and refined product margins. USE WHEN: - User asks about diesel fuel prices - User needs refined product pricing - User wants to track diesel vs crude crack spreads - User asks "what is diesel price" EXAMPLES: - "What is diesel price?" → call with no params - "Current ULSD diesel price" → call with no params - "US diesel fuel cost" → call with no params Get current US Diesel (Ultra Low Sulfur) price

03

get_historical_prices

Requires a paid OilPriceAPI subscription. USE WHEN: - User asks about historical oil prices for a specific period - User wants long-term trend analysis or backtesting - User asks for prices from specific dates EXAMPLES: - "WTI prices for Q1 2026" → commodity_code="WTI_USD", start_date="2026-01-01", end_date="2026-03-31" - "Brent crude last year" → commodity_code="BRENT_CRUDE_USD", start_date="2025-01-01", end_date="2025-12-31" Get historical price data for a custom date range

04

get_latest_prices

Prices are updated every 5 minutes for oil, gas, and refined products. USE WHEN: - User asks about current oil prices - User needs the latest commodity prices - User wants to check current WTI or Brent prices - User asks what is the price of oil/gas/coal right now PARAMETERS: - commodity_code (OPTIONAL): Specific commodity code (e.g. "WTI_USD", "BRENT_CRUDE_USD") EXAMPLES: - "What is current oil price?" → call with commodity_code="WTI_USD" - "Latest Brent crude price" → call with commodity_code="BRENT_CRUDE_USD" - "Show all latest energy prices" → call with no params Get the latest spot prices for energy commodities

05

get_natural_gas_price

Prices update every 5 minutes. USE WHEN: - User asks about natural gas prices - User needs the US natural gas benchmark - User wants to check Henry Hub prices - User asks "what is natural gas price" EXAMPLES: - "What is natural gas price?" → call with no params - "Current Henry Hub gas price" → call with no params - "US natural gas benchmark" → call with no params Get current US Natural Gas (Henry Hub) price

06

get_past_day_prices

Perfect for tracking intraday price movements and volatility. USE WHEN: - User asks about oil price movements today - User needs hourly price data for the last day - User wants to track intraday volatility - User asks how prices changed in the last 24 hours PARAMETERS: - commodity_code (OPTIONAL): Specific commodity code EXAMPLES: - "Show WTI price movements today" → call with commodity_code="WTI_USD" - "Hourly natural gas prices last 24h" → call with commodity_code="NATURAL_GAS_USD" - "Brent crude intraday prices" → call with commodity_code="BRENT_CRUDE_USD" Get hourly prices data for the last 24 hours

07

get_past_month_prices

Great for monthly trend analysis and medium-term price tracking. USE WHEN: - User asks about oil price trends this month - User needs daily prices for the last 30 days - User wants to track monthly price movements - User asks how prices changed over the past month PARAMETERS: - commodity_code (OPTIONAL): Specific commodity code EXAMPLES: - "WTI price trends this month" → call with commodity_code="WTI_USD" - "Monthly natural gas prices" → call with commodity_code="NATURAL_GAS_USD" - "Brent crude last 30 days" → call with commodity_code="BRENT_CRUDE_USD" Get daily price data for the last 30 days

08

get_past_week_prices

Ideal for weekly trend analysis and short-term price tracking. USE WHEN: - User asks about oil price trends this week - User needs daily prices for the last week - User wants to track weekly price movements - User asks how prices changed over the past week PARAMETERS: - commodity_code (OPTIONAL): Specific commodity code EXAMPLES: - "WTI price trends this week" → call with commodity_code="WTI_USD" - "Weekly natural gas prices" → call with commodity_code="NATURAL_GAS_USD" - "Brent crude last 7 days" → call with commodity_code="BRENT_CRUDE_USD" Get daily price data for the last 7 days

09

get_wti_price

Prices update every 5 minutes. USE WHEN: - User asks specifically about WTI oil price - User needs the US crude oil benchmark - User wants to check American oil prices - User asks "what is WTI price" EXAMPLES: - "What is WTI price?" → call with no params - "Current WTI crude oil price" → call with no params - "West Texas Intermediate price" → call with no params Get current WTI (West Texas Intermediate) crude oil price

10

list_commodities

USE WHEN: - User wants to explore what commodities are available - User needs to find commodity codes for querying prices - User is exploring the API capabilities for the first time - User asks what energy commodities are supported AVAILABLE COMMODITY TYPES: - Crude Oil: WTI_USD, BRENT_CRUDE_USD - Refined Products: DIESEL_USD, GASOLINE_USD, HEATING_OIL_USD, JET_FUEL_USD - Natural Gas: NATURAL_GAS_USD - Coal: COAL_USD - And 40+ more energy commodities EXAMPLES: - "What commodities are available?" → call with no params - "Show me all commodity codes" → call with no params - "List all energy products" → call with no params List all available energy commodities in OilPriceAPI

Example Prompts for OilPrice in Mastra AI

Ready-to-use prompts you can give your Mastra AI agent to start working with OilPrice immediately.

01

"What is the current price of WTI crude oil?"

02

"Show me natural gas prices for the last week."

03

"Compare WTI and Brent crude prices today."

Troubleshooting OilPrice MCP Server with Mastra AI

Common issues when connecting OilPrice to Mastra AI through the Vinkius, and how to resolve them.

01

createMCPClient not exported

Install: npm install @mastra/mcp

OilPrice + Mastra AI FAQ

Common questions about integrating OilPrice MCP Server with Mastra AI.

01

How does Mastra AI connect to MCP servers?

Create an MCPClient with the server URL and pass it to your agent. Mastra discovers all tools and makes them available with full TypeScript types.
02

Can Mastra agents use tools from multiple servers?

Yes. Pass multiple MCP clients to the agent constructor. Mastra merges all tool schemas and the agent can call any tool from any server.
03

Does Mastra support workflow orchestration?

Yes. Mastra has a built-in workflow engine that lets you chain MCP tool calls with branching logic, error handling, and parallel execution.

Connect OilPrice to Mastra AI

Get your token, paste the configuration, and start using 10 tools in under 2 minutes. No API key management needed.