Skip to main content
Get notices by campground id
curl --request GET \
  --url https://api.campflare.com/v2/campground/:id/notices
import requests

url = "https://api.campflare.com/v2/campground/:id/notices"

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://api.campflare.com/v2/campground/:id/notices', 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.campflare.com/v2/campground/:id/notices",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.campflare.com/v2/campground/:id/notices"

req, _ := http.NewRequest("GET", url, nil)

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.campflare.com/v2/campground/:id/notices")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.campflare.com/v2/campground/:id/notices")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
[
  {
    "id": "<string>",
    "title": "<string>",
    "source": {
      "name": "<string>",
      "url": "<string>"
    },
    "description": "<string>",
    "start": "2023-11-07T05:31:56Z",
    "end": "2023-11-07T05:31:56Z",
    "geometry_summary": {
      "point": {
        "latitude": 123,
        "longitude": 123
      },
      "bbox": {
        "min_latitude": 123,
        "max_latitude": 123,
        "min_longitude": 123,
        "max_longitude": 123
      }
    },
    "target": {
      "id": "<string>"
    },
    "geometry": {}
  }
]
{
"error": {
"message": "<string>",
"kind": "<string>"
}
}
GET /campground/:id/notices
This endpoint only includes relevant notices. Notices will automatically expire when they are no longer relevant. Historical notices will be supported in a future version of this API.

Path Parameters

id
string
required

Unique identifier of the campground

Query Parameters

include_geometry
boolean
default:false

Includes the GeoJSON of the notice (Point, Polygon, or Multipolygon).

include_intersecting
boolean
default:false

Includes notices that overlap the campground geometrically. For example a notice at the park level or an extreme weather alert.

Response

Array of notices

id
string
required

Globally unique notice identifier

title
string
required

Human-readable headline

source
object
required
description
string

Optional long-form body text

kind
enum<string>

Top-level category. Note that more kinds may be added here.

Available options:
weather,
fire,
closure
severity
enum<string>

Relative urgency / impact

Available options:
info,
minor,
moderate,
severe,
extreme
start
string<date-time>

ISO-8601 start timestamp

end
string<date-time>

ISO-8601 end timestamp

geometry_summary
object

Lightweight geometry hint

target
object

If the notice is directly tied to a target (campground, land, etc), this field will be set. Omitted for free-floating polygons such as random weather alerts.

geometry
object

GeoJSON geometry object (Point, Polygon, MultiPolygon, etc.). Set the include_geometry flag to populate this field.