Skip to contents

This function returns examples of working IDs that can be used with the eesyapi functions, such as query_dataset().

Usage

example_id(level = "dataset", ees_environment = "test", group = "absence")

Arguments

level

Level of ID example to return. A range are available, although not every example group necessarily contains all possible examples. The following are generally available.

  • "all": Return full list of example options for given group.

  • "publication": Return example publication ID

  • "dataset": Return example data set ID

  • "time_period" / "time_periods": Return example time_period(s)

  • "location_id" / "location_ids": Return example location ID(s)

  • "location_code / location_codes": Return example location code(s)

  • "filter": Return example filter column ID

  • "filter_item" / "filter_items_short" / "filter_items_long": Return example filter ID or example short / long filter query list.

  • "indicator": Return example indicator ID

ees_environment

Environment to return a working example for: "dev" or "test"

group

Choose the publication group of examples to use. Options are:

  • "attendance": Large example data set, careful what you ask for

  • "public-api-testing": Smaller example data set

Value

String, vector or list containing example ID(s) present in the API

Examples

example_id()
#> [1] "e1ae9201-2fff-d376-8fa3-bd3c3660d4c8"
example_id("all")
#> $publication
#> [1] "25d0e40b-643a-4f73-3ae5-08dcf1c4d57f"
#> 
#> $dataset
#> [1] "e1ae9201-2fff-d376-8fa3-bd3c3660d4c8"
#> 
#> $location_id
#> [1] "NAT|id|mRj9K"
#> 
#> $location_code
#> [1] "NAT|code|E92000001"
#> 
#> $filter
#> [1] "arLPb"
#> 
#> $filter_item
#> [1] "VN5XE"
#> 
#> $filter_items
#> [1] "VN5XE" "PEebW"
#> 
#> $indicator
#> [1] "dPe0Z"
#> 
#> $indicators
#> [1] "OBXCL" "7YFXo"
#> 
example_id("all", ees_environment = "dev")
#> $publication
#> [1] "d823e4df-626f-4450-9b21-08dc8b95fc02"
#> 
#> $dataset
#> [1] "830f9201-9e11-ad75-8dcd-d2efe2834457"
#> 
#> $location_id
#> [1] "LA|id|ml79K"
#> 
#> $location_code
#> [1] "NAT|code|E92000001"
#> 
#> $location_codes
#> [1] "REG|code|E12000001" "REG|code|E12000002"
#> 
#> $filter
#> [1] "01tT5"
#> 
#> $filter_item
#> [1] "wEZcb"
#> 
#> $indicator
#> [1] "PbNeb"
#> 
example_id("publication")
#> [1] "25d0e40b-643a-4f73-3ae5-08dcf1c4d57f"
example_id("publication", group = "attendance")
#> [1] "25d0e40b-643a-4f73-3ae5-08dcf1c4d57f"
example_id("time_period", group = "attendance")
#> [1] "2024|W23"
example_id("location_ids", group = "attendance")
#> [1] "LA|id|arLPb"  "REG|id|zecFQ"
example_id("filter_items_short", group = "attendance")
#> $attendance_status
#> [1] "qGJjG"
#> 
#> $attendance_type
#> [1] "cZO31" "jgoAM"
#> 
#> $education_phase
#> [1] "Poqeb" "dPE0Z"
#> 
#> $day_number
#> [1] "AOhGK"
#> 
#> $reason
#> [1] "9Ru4v"
#> 
example_id("indicator", group = "attendance")
#> [1] "tj0Em"