A class to interact with the KoboToolbox API, extending crul::HttpClient
.
Super class
crul::HttpClient
-> KoboClient
Methods
Method new()
Initialization method for class "KoboClient".
Usage
KoboClient$new(base_url, kobo_token = Sys.getenv("KBTBR_TOKEN"))
Method get()
Perform a GET request (with additional checks)
Usage
KoboClient$get(path, query = list(), ...)
Arguments
path
character. Path component of the endpoint.
query
list. A named list which is parsed to the query component. The order is not hierarchical.
...
crul-options. Additional option arguments, see
crul::HttpClient
for reference
Method post()
Perform a POST request
Arguments
path
character. Path component of the endpoint.
body
R list. A data payload to be sent to the server.
...
crul-options. Additional option arguments, see
crul::HttpClient
for reference
Returns
Returns an object of class crul::HttpResponse
.