$ man current-weather-city
/current-weather-city
PRICE / CALL
$0.01
USDC · base mainnet · scheme: exact
──────────────────────────────────────────────────────────────────────────────
NAME
current-weather-city — looks up current weather conditions for any named city, worldwide, without requiring latitude and longitude coordinates SYNOPSIS
POST https://x402.agentutility.ai/current-weather-city
Content-Type: application/json
X-PAYMENT: <signed-transferWithAuthorization>
{ ... }↳ first call → 402 Payment Required. Sign USDCtransferWithAuthorization, retry with theX-PAYMENT header.
DESCRIPTION
Looks up current weather conditions for any named city, worldwide, without requiring latitude and longitude coordinates. Send a city name plus an optional two-letter country_code, units (metric or imperial), and forecast_days; the endpoint geocodes the place name against Open-Meteo, picks the best-scoring match (favoring capitals and larger populations when a country code is given), and returns current conditions plus an optional hourly or daily forecast. The response includes resolved_location with coordinates and timezone, alternate place matches for disambiguation, and the forecast payload. Use it as a city weather lookup API, weather-by-city-name tool, or current conditions endpoint for travel agents, dispatch tools, and location-aware assistants.
INPUT — request schema
| property | type | description | req? |
|---|
| city | string | City or place name. | required |
| country_code | string | Optional two-letter ISO country code. | optional |
| units | string | Unit system: 'metric' or 'imperial'. Passed through to the forecast backend. enum: metric · imperial | optional |
| forecast_days | number | Number of forecast days to include. Default 1 (current conditions). | optional |
| hourly | boolean | If true, includes hourly forecast data. Default false. | optional |
OUTPUT — response shape
| field | type | description |
|---|
| query | string | — |
| resolved_location | string | — |
| current | string | — |
EXAMPLES — two ways to call
EXAMPLE 1 · curl
curl -X POST https://x402.agentutility.ai/current-weather-city \
-H 'Content-Type: application/json' \
-d '{ }'first response = 402 Payment Required with payment requirements; sign + retry with X-PAYMENT.
EXAMPLE 2 · mcp
# Install the MCP package for this endpoint's cluster
npx -y @agentutility/mcp-<cluster>
# Required: EVM private key with USDC on Base
export X402_PRIVATE_KEY=0x...
# Then call the current-weather-city tool from your MCP-aware agent.
MCP server handles payment automatically — your coding agent just calls the tool by name.
METADATA
- tags
- localecurrentweathercitycurrent-weather-city
- methods
- POST
- cluster
- locale
- price
- $0.01 USDC per call
ADJACENT — other endpoints in locale
| endpoint | description | price |
|---|
| city-weather | Returns current weather by city name with an instant geocoded lookup. | $0.01 |
| current | Instant current weather by city name: geocodes a city or place name, then returns current Open-Meteo temperature, feels-like, humidity, w… | $0.01 |
| flight-status | Tracks live aircraft positions from the OpenSky Network. | $0.01 |
| property-tax | Property tax lookup. | $0.01 |
| property-tax-assessment | Searches county assessor records by address or parcel ID for owner, assessed value, and property details. | $0.01 |
| satellite-address | Turns a street address into a cloud-free satellite image in one call. | $0.01 |
| sports-schedule | Returns upcoming games and recent results for major sports leagues: MLB, NBA, NHL, NFL, WNBA, MLS, EPL, La Liga, Bundesliga, and Serie A. | $0.01 |
| weather-current-city | Returns current weather for any city or place name, no coordinates needed. | $0.01 |