get_alerts
Retrieve active government weather alerts and warnings for any location worldwide. Provides severity, urgency, affected areas, and detailed descriptions to help users stay informed about hazardous weather conditions.
Instructions
Get active government weather alerts and warnings for a location. Covers USA, UK, Europe, and rest of world. Returns headline, severity, urgency, affected areas, and full description.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| q | Yes | Location query — city name, lat/lon, zip, postcode, IATA, or IP. |
Implementation Reference
- src/index.ts:337-341 (handler)The handler for the 'get_alerts' tool, which calls the weatherRequest utility with the '/alerts.json' endpoint.
case "get_alerts": { const { q } = args as { q: string }; result = await weatherRequest("/alerts.json", { q }); break; } - src/index.ts:240-254 (schema)The input schema definition for the 'get_alerts' tool.
{ name: "get_alerts", description: "Get active government weather alerts and warnings for a location. Covers USA, UK, Europe, and rest of world. Returns headline, severity, urgency, affected areas, and full description.", inputSchema: { type: "object", properties: { q: { type: "string", description: "Location query — city name, lat/lon, zip, postcode, IATA, or IP.", }, }, required: ["q"], }, },