Generate a weather summary for a location across a specific time window, powered by Tomorrow.io's weather intelligence.
POST: https://api.tomorrow.io/v4/gale-ai/summary
Body Parameters
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
location | object | Yes | — | One of location id, location name, or a GeoJSON (see below supported formatting). |
startTime | string | Yes | — | ISO-8601 window start. Must be before endTime. |
endTime | string | Yes | — | ISO-8601 window end. Must be after startTime. |
language | string | No | account default | Response language. Overrides your account language when provided. |
units | string | No | metric | Unit system: metric or imperial. |
timezone | string | No | location-local | IANA timezone used for time phrasing. Invalid zones return 400. Omit to use the location's local timezone. |
sessionId | string | No | stateless | Conversation id used as a session key so recent entities persist across calls. Omit for a stateless call. |
The location object supports exactly one of these forms:
| Form | Fields | Description |
|---|---|---|
| Location ids | locationIds: string[] | One or more saved location ids. |
| Name | name: string | A free-text location name (e.g. "Boston, MA"). |
| GeoJSON | type + coordinates | Inline GeoJSON geometry. type is Point, LineString, or Polygon. Coordinates: Point → [lon, lat]; LineString → [[lon,lat], ...]; Polygon → [[[lon,lat], ...]] (closed ring). |
Example Requests
By location id:
curl -X POST "https://api.tomorrow.io/v4/gale-ai/summary?apikey=YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"location": { "locationIds": ["123"] },
"startTime": "2026-07-08T00:00:00Z",
"endTime": "2026-07-15T00:00:00Z"
}'By location name:
curl -X POST "https://api.tomorrow.io/v4/gale-ai/summary?apikey=YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"location": { "name": "Boston, MA" },
"startTime": "2026-07-08T00:00:00Z",
"endTime": "2026-07-15T00:00:00Z"
}'By GeoJSON point:
curl -X POST "https://api.tomorrow.io/v4/gale-ai/summary?apikey=YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"location": { "type": "Point", "coordinates": [-74.006, 40.7128] },
"startTime": "2026-07-06T00:00:00Z",
"endTime": "2026-07-07T00:00:00Z",
"units": "imperial"
}'Response
200 OK — header X-Quota-Remaining-Gale: <integer>
{
"data": {
"answer": "Over the next week, expect mostly dry conditions with highs near 28°C, and a chance of thunderstorms midweek.",
"id": "req_def456"
}
}| Field | Type | Description |
|---|---|---|
data.answer | string | Structured natural-language weather summary. |
data.id | string | Request id (use it when contacting support). |
Errors
| Status | Meaning |
|---|---|
400 | Missing/invalid startTime or endTime; startTime not before endTime; location is not provided; invalid timezone; or an unresolvable location name. |
402 | No Gale interactions remaining (GALE_QUOTA_LIMIT_REACHED). |
404 | The location id(s) do not exist. |
500 | Unexpected server error. |
Error responses use the shape:
{
"data": {
"error": "Description of what went wrong."
}
}