Skip to contents

Get a NINA warning (JSON)

Usage

nina_warning_json(identifier, safe = TRUE, refresh = FALSE)

Arguments

identifier

Warning identifier.

safe

Logical; if TRUE (default), apply rate-limiting and cache GET responses to tools::R_user_dir("bunddev", "cache").

refresh

Logical; if TRUE, ignore cached responses and re-fetch from the API (default FALSE).

Value

A one-row tibble with CAP warning fields.

identifier

Warning identifier (character).

sender

Sender identifier (character).

sent

Sent timestamp string (character).

status

Alert status (character).

msg_type

Message type (character).

scope

Alert scope (character).

code

Alert code entries (list).

info

Alert info blocks (list).

sent_time

Parsed sent timestamp (POSIXct, Europe/Berlin).

Details

Returns a warning in JSON format.

Examples

if (FALSE) { # \dontrun{
map <- nina_mapdata("mowas")
nina_warning_json(map$id[[1]])
} # }