Skip to contents

Creates the index.json content listing all available endpoints, their descriptions, and URLs for the static JSON API.

Usage

generate_api_index(
  base_url = "https://JohnGavin.github.io/coMMpass-analysis/api/v1"
)

Arguments

base_url

Base URL for the static API. Defaults to the GitHub Pages URL.

Value

A list suitable for JSON serialization containing endpoint catalogue, version, and generated timestamp.

Examples

if (FALSE) { # \dontrun{
idx <- generate_api_index()
cat(jsonlite::toJSON(idx, pretty = TRUE, auto_unbox = TRUE))
} # }