Tools · data

Weather forecast for any point (MET Norway, 9 days)

The weather forecast for any point on Earth from MET Norway: current conditions, hourly rows (1 h steps for ~2.5 days, then 6 h) and up to 9 daily rows (UTC days) with min/max temperature, total precipitation and the main condition. A forecast, not observations; no air quality, no alerts. Send {} for the published example point. An answer it cannot produce is not charged. Pay-per-call via x402.

$0.0018 per call, paid in USDC on Base or Solana with x402 — no account, no API key. POST https://fiatdock.com/v1/weather/forecast (or GET with the same fields as query parameters) · MCP tool weather_forecast. An answer the tool cannot produce is refused with 4xx/5xx and is not charged.

Inputs

FieldTypeDescriptionExample
latnumberLatitude in decimal degrees, -90 to 90 (required with lon; an empty body answers the published example point)24.7136
lonnumberLongitude in decimal degrees, -180 to 180 (required with lat)46.6753
hoursintegerHow many hours ahead the `hourly` rows reach, 1-72 (default 24). Steps are 1 h for about the first 2.5 days and 6 h after24
daysintegerHow many daily summary rows (UTC calendar days, today first), 1-9 (default 3)3

Example

Request body

{"lat":24.7136,"lon":46.6753,"hours":3,"days":2}

Answer (the published example)

{"location":{"lat":24.7136,"lon":46.6753,"elevationM":628},"current":{"time":"2026-10-08T16:00:00Z","airTemperatureC":36.7,"relativeHumidityPct":10.1,"windSpeedMs":2.9,"windFromDeg":68.4,"cloudCoverPct":0,"precipitationNext1hMm":0,"symbol":"clearsky_night"},"hourly":[{"time":"2026-10-08T16:00:00Z","airTemperatureC":36.7,"precipitationMm":0,"periodHours":1,"windSpeedMs":2.9,"symbol":"clearsky_night"},{"time":"2026-10-08T17:00:00Z","airTemperatureC":35.9,"precipitationMm":0,"periodHours":1,"windSpeedMs":2.7,"symbol":"clearsky_night"},{"time":"2026-10-08T18:00:00Z","airTemperatureC":35.1,"precipitationMm":0,"periodHours":1,"windSpeedMs":2.5,"symbol":"clearsky_night"}],"daily":[{"date":"2026-10-08","minTempC":29.6,"maxTempC":36.7,"precipitationMm":0,"hoursCovered":8,"symbol":"clearsky"},{"date":"2026-10-09","minTempC":27.7,"maxTempC":39.3,"precipitationMm":0,"hoursCovered":24,"symbol":"clearsky"}],"units":{"airTemperature":"°C","precipitation":"mm","windSpeed":"m/s","windFromDirection":"degrees (where the wind blows FROM; 0 = north, 90 = east)","relativeHumidity":"%","cloudCover":"%"},"modelUpdatedAt":"2026-10-08T13:16:55Z","forecastEndsAt":"2026-10-18T00:00:00Z","attribution":"Weather forecast data from MET Norway (the Norwegian Meteorological Institute), https://api.met.no/ — licensed under CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) and NLOD 2.0 (https://data.norge.no/nlod/en/2.0). Changed by FiatDock: reformatted, and the daily rows are computed from MET's forecast.","source":"MET Norway Locationforecast 2.0 (api.met.no, complete product)","asOf":"2026-10-08T16:15:52.847Z","note":"A forecast, not an observation. All times are UTC. Daily rows are UTC calendar days, not local days; the first starts at the current hour."}

Call it

curl

# 1) ask: an unpaid call answers 402 with the exact price (free)
curl -i -X POST https://fiatdock.com/v1/weather/forecast -H 'content-type: application/json' -d '{"lat":24.7136,"lon":46.6753,"hours":3,"days":2}'
# 2) pay: any x402 client signs that 402 and resends — see Node or Python below

Node

// npm i @x402/fetch @x402/evm viem
import { wrapFetchWithPaymentFromConfig } from "@x402/fetch";
import { ExactEvmScheme } from "@x402/evm";
import { privateKeyToAccount } from "viem/accounts";

const pay = wrapFetchWithPaymentFromConfig(fetch, {
  schemes: [{ network: "eip155:*", client: new ExactEvmScheme(privateKeyToAccount(process.env.AGENT_PRIVATE_KEY)) }],
});
const r = await pay("https://fiatdock.com/v1/weather/forecast", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({"lat":24.7136,"lon":46.6753,"hours":3,"days":2}),
});
console.log(r.status, await r.json());

Python

# pip install "x402[httpx,evm]"
import asyncio, json, os
from eth_account import Account
from x402 import x402Client
from x402.http.clients import x402HttpxClient
from x402.mechanisms.evm.exact import register_exact_evm_client

async def main():
    client = register_exact_evm_client(x402Client(), Account.from_key(os.environ["AGENT_PRIVATE_KEY"]))
    async with x402HttpxClient(client) as http:
        r = await http.post("https://fiatdock.com/v1/weather/forecast", json=json.loads("{\"lat\":24.7136,\"lon\":46.6753,\"hours\":3,\"days\":2}"))
        print(r.status_code, r.json())

asyncio.run(main())

MCP (Claude, Cursor, any MCP client)

{"mcpServers":{"fiatdock":{"command":"npx","args":["-y","fiatdock-mcp"],"env":{"AGENT_PRIVATE_KEY":"0x<your agent wallet key>"}}}}
// then call the tool "weather_forecast" — the package pays each call from that wallet

The wallet needs USDC on Base. Prefer no install? The remote server https://fiatdock.com/mcp answers the 402 as tool output for an agent that signs its own payments.

Related tools

Machine-readable: OpenAPI · tools.json · llms.txt · /.well-known/x402