Marine forecast
curl --request POST \
--url https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"area_id": "m0000028"
}
'import requests
url = "https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast"
payload = { "area_id": "m0000028" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({area_id: 'm0000028'})
};
fetch('https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'area_id' => 'm0000028'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast"
payload := strings.NewReader("{\n \"area_id\": \"m0000028\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"area_id\": \"m0000028\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"area_id\": \"m0000028\"\n}"
response = http.request(request)
puts response.read_body{
"area": {
"country": "CA",
"id": "m0000028",
"name": "Strait of Georgia",
"region": "Pacific Coast",
"sub_region": "Georgia Basin"
},
"attribution": "Data Source: Environment and Climate Change Canada",
"extended_forecast": {
"issued_at": "2026-10-25T23:00:00Z",
"issued_at_local": "2026-10-25T16:00:00-07:00",
"locations": [
{
"name": null,
"periods": [
{
"name": "Tuesday",
"text": "Wind northwest 10 to 20 knots becoming southeast 10 to 20 in the afternoon."
},
{
"name": "Wednesday",
"text": "Wind northwest 5 to 15 knots becoming southeast 10 to 20."
},
{
"name": "Thursday",
"text": "Wind east 10 to 20 knots backing to northerly 5 to 15 late in the day."
}
]
}
]
},
"lang": "en",
"last_updated": "2026-10-25T22:55:26Z",
"licence_url": "https://eccc-msc.github.io/open-data/licence/readme_en/",
"observed_at_ms": 1792969238535,
"other_area_ids": [],
"regular_forecast": {
"issued_at": "2026-10-25T17:30:00Z",
"issued_at_local": "2026-10-25T10:30:00-07:00",
"locations": [
{
"air_temperature": null,
"freezing_spray": null,
"name": "Strait of Georgia - north of Nanaimo",
"period_of_coverage": "Today Tonight and Monday.",
"status": null,
"weather_visibility": "Showers ending Monday morning.",
"wind": "Wind southeast 10 to 20 knots except north 5 to 15 over northern sections. Wind becoming northwest 5 to 15 this afternoon. Wind northwest 5 to 15 tonight and Monday."
},
{
"air_temperature": null,
"freezing_spray": null,
"name": "Strait of Georgia - south of Nanaimo",
"period_of_coverage": "Today Tonight and Monday.",
"status": null,
"weather_visibility": "Showers ending Monday morning.",
"wind": "Wind easterly 15 to 25 knots becoming easterly 10 to 20 this afternoon then becoming northwest 10 to 20 near midnight. Wind diminishing to light Monday evening."
}
]
},
"source_url": "https://api.weather.gc.ca/collections/marineweather-realtime/items/m0000028?f=json",
"warnings": [
{
"category": "marine",
"location": "Strait of Georgia - south of Nanaimo",
"name": "Strong wind warning",
"status": "IN EFFECT",
"type": "warning"
}
],
"wave_forecast": null
}Environment and Climate Change Canada weather and climate (api.weather.gc.ca)
Marine forecast
Boating or shipping weather on Canadian coastal waters and the Great Lakes.
POST
https://api.aisa.one
/
apis
/
v1
/
api-weather-gc-ca
/
weather
/
marine-forecast
Marine forecast
curl --request POST \
--url https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"area_id": "m0000028"
}
'import requests
url = "https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast"
payload = { "area_id": "m0000028" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({area_id: 'm0000028'})
};
fetch('https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'area_id' => 'm0000028'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast"
payload := strings.NewReader("{\n \"area_id\": \"m0000028\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"area_id\": \"m0000028\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"area_id\": \"m0000028\"\n}"
response = http.request(request)
puts response.read_body{
"area": {
"country": "CA",
"id": "m0000028",
"name": "Strait of Georgia",
"region": "Pacific Coast",
"sub_region": "Georgia Basin"
},
"attribution": "Data Source: Environment and Climate Change Canada",
"extended_forecast": {
"issued_at": "2026-10-25T23:00:00Z",
"issued_at_local": "2026-10-25T16:00:00-07:00",
"locations": [
{
"name": null,
"periods": [
{
"name": "Tuesday",
"text": "Wind northwest 10 to 20 knots becoming southeast 10 to 20 in the afternoon."
},
{
"name": "Wednesday",
"text": "Wind northwest 5 to 15 knots becoming southeast 10 to 20."
},
{
"name": "Thursday",
"text": "Wind east 10 to 20 knots backing to northerly 5 to 15 late in the day."
}
]
}
]
},
"lang": "en",
"last_updated": "2026-10-25T22:55:26Z",
"licence_url": "https://eccc-msc.github.io/open-data/licence/readme_en/",
"observed_at_ms": 1792969238535,
"other_area_ids": [],
"regular_forecast": {
"issued_at": "2026-10-25T17:30:00Z",
"issued_at_local": "2026-10-25T10:30:00-07:00",
"locations": [
{
"air_temperature": null,
"freezing_spray": null,
"name": "Strait of Georgia - north of Nanaimo",
"period_of_coverage": "Today Tonight and Monday.",
"status": null,
"weather_visibility": "Showers ending Monday morning.",
"wind": "Wind southeast 10 to 20 knots except north 5 to 15 over northern sections. Wind becoming northwest 5 to 15 this afternoon. Wind northwest 5 to 15 tonight and Monday."
},
{
"air_temperature": null,
"freezing_spray": null,
"name": "Strait of Georgia - south of Nanaimo",
"period_of_coverage": "Today Tonight and Monday.",
"status": null,
"weather_visibility": "Showers ending Monday morning.",
"wind": "Wind easterly 15 to 25 knots becoming easterly 10 to 20 this afternoon then becoming northwest 10 to 20 near midnight. Wind diminishing to light Monday evening."
}
]
},
"source_url": "https://api.weather.gc.ca/collections/marineweather-realtime/items/m0000028?f=json",
"warnings": [
{
"category": "marine",
"location": "Strait of Georgia - south of Nanaimo",
"name": "Strong wind warning",
"status": "IN EFFECT",
"type": "warning"
}
],
"wave_forecast": null
}请求规范
- 方法与路径: POST /apis/v1/api-weather-gc-ca/weather/marine-forecast
- 可用状态: enabled
- 请求 URL 模板:
https://api.aisa.one/apis/v1/api-weather-gc-ca/weather/marine-forecast
{
"operationId": "api-weather-gc-ca.weather.marine-forecast",
"method": "POST",
"path": "/apis/v1/api-weather-gc-ca/weather/marine-forecast",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"examples": {
"provider": {
"summary": "Official provider example; checked against AIsa request constraints",
"value": {
"area_id": "m0000028"
}
}
},
"schema": {
"additionalProperties": true,
"properties": {
"area_id": {
"description": "Marine area id, e.g. m0000028 Strait of Georgia, m0000144 Lake Ontario, m0000053 Halifax Harbour; or use lat/lon. Pattern: ^[mM][0-9]{7}$.",
"type": "string",
"x-alexandria-option-metadata": {
"in": "body"
}
},
"lang": {
"default": "en",
"description": "Language of names and texts: en (English) or fr (French). Numbers are the same in both.\n\nProvider reference: allowed values [\"en\", \"fr\"]; default \"en\".",
"type": "string",
"x-alexandria-option-metadata": {
"in": "body",
"oneOf": [
"en",
"fr"
]
}
},
"lat": {
"description": "Latitude in decimal degrees (Canada spans about 41 to 84). Give with lon.\n\nProvider reference: minimum -90; maximum 90.",
"type": "number",
"x-alexandria-option-metadata": {
"in": "body",
"max": 90,
"min": -90
}
},
"lon": {
"description": "Longitude in decimal degrees, west negative (Canada spans about -142 to -52). Give with lat.\n\nProvider reference: minimum -180; maximum 180.",
"type": "number",
"x-alexandria-option-metadata": {
"in": "body",
"max": 180,
"min": -180
}
}
},
"type": "object"
}
}
},
"required": false
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
费用与请求规则
按实际用量收费。 默认请求预估费用:$0.0005 USD。 最终费用以实际用量为准。 账户适用价格可能不同;支持报价的接口可按实际请求获取报价。授权
请求体
application/json
响应
ECCC marine forecast and warnings for one marine area (weather.gc.ca/marine): regular forecast per sub-area (winds, weather and visibility, air temperature, freezing spray), the extended forecast, the wave forecast where issued, and marine warnings in effect. Choose by area_id or by lat/lon on the water (the containing area). An unknown area_id is not_found.
The response contains the tool result directly.
| Documented field | Provider type | Description |
|---|---|---|
area | object | |
attribution | string | Attribution the ECCC Data Servers End-use Licence requires when the data is republished. |
extended_forecast | object | Extended forecast; null when not issued. |
lang | string | Language of the texts. |
last_updated | string | |
licence_url | string | The ECCC Data Servers End-use Licence. |
observed_at_ms | number | When this program read the source, epoch milliseconds. |
other_area_ids | string[] | Other areas containing the point (lat/lon only). |
regular_forecast | object | Regular forecast; null when not in season. |
source_url | string | The api.weather.gc.ca request this answer was read from. |
warnings | object[] | Marine warnings; empty when none. |
wave_forecast | object | Wave forecast; null where ECCC issues none. |
These are the provider's documented fields. Field requiredness, nullability and nested object structures are specified only where the descriptions explicitly say so.