GET
/
v1
/
risks
/
environmental
/
forecast
cURL
curl --request GET \
  --url https://api.goes.health/v1/risks/environmental/forecast \
  --header 'Authorization: Bearer <token>'
{
  "responseId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "forecast": [
    {
      "time": "2023-11-07T05:31:56Z",
      "risks": [
        {
          "id": "sunburn",
          "title": "Sunburn",
          "status": "applicable",
          "score": 2,
          "summary": "<string>",
          "tips": [
            "<string>"
          ],
          "error": "<string>"
        }
      ]
    }
  ]
}
Get a 48-hour, hour-by-hour forecast of environmental risks for a location.

Request

Headers

Authorization
string
required
Your API key for authentication. Format: Bearer YOUR_API_KEY

Query Parameters

location
string
required
The latitude and longitude for the location to check, formatted as {latitude},{longitude}.
ids
string
A comma-separated list of risk IDs to include. If omitted, all environmental risks are returned.

Response

responseId
string
A unique identifier for this response. Use this ID if submitting feedback about the forecast.
forecast
array
An array of 48 hourly forecast entries.

Example

curl "http://api.goes.health/v1/risks/environmental/forecast?location=34.0522,-118.2437" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "responseId": "123e4567-e89b-12d3-a456-426614174000",
  "forecast": [
    {
      "time": "2024-06-27T00:00:00Z",
      "risks": [
        {
          "id": "sunburn",
          "title": "Sunburn",
          "status": "applicable",
          "score": 2,
          "summary": "...",
          "tips": [
            "..."
          ]
        }
      ]
    }
  ]
}

Authorizations

Authorization
string
header
required

Enter your API key

Query Parameters

location
string
required

The latitude and longitude, formatted as {latitude},{longitude}.

ids
string

A comma-separated list of environmental risk IDs to include in the forecast.

exclude
string

Comma-separated list of sections to exclude from the response. Options: tips, summary, score

Response

200
application/json

A 48-hour forecast of environmental risks.

The response is of type object.