Skip to contents

Specifies the Host URL of the API to use

Usage

get_host_url(api, version = "v1")

Arguments

api

Either "kobo", "kobohr", "ona", or a custom (full) URL. API URLs are made available for KoBo Toolbox ("kobo", https://kc.kobotoolbox.org/api/v1/), KoBo Humanitarian Response ("kobohr", https://kc.humanitarianresponse.info/api/v1/), Ona ("ona", https://api.ona.io/api/v1/) and Unhcr ("unhcr", https://kobocat.unhcr.org/api/v1/) . For your own installation, or other installations using the same API but accessed at a different URL, enter the full URL.

version

Wether using the API "v1" or "v2"

Value

An URL

Author

Ananda Mahto

Examples


get_host_url("unhcr")
#> [1] "https://kobocat.unhcr.org/api/v1"
get_host_url("https://kobocat.unhcr.org/api/v1/")
#> [1] "https://kobocat.unhcr.org/api/v1/"