Methods
request(configuration, axiosRequest) → {Promise}
The request client takes configuration from state and an axios request object
then (1) logs the method and URL, (2) applies standard headers and auth
before spreading the rest of the axios configuration, and (3) executes an
axios request.
Parameters:
Name | Type | Description |
---|---|---|
configuration |
object | configuration must have a username and password |
axiosRequest |
object | the axiosRequest contains valid axios params: https://axios-http.com/docs/req_config |
Returns:
a promise that will resolve to either a response object or an error object.
- Type
- Promise
selectId(resourceType) → {string}
Determines the attribute name for a DHIS2 system ID given a resource type.
Parameters:
Name | Type | Description |
---|---|---|
resourceType |
string |
Returns:
- Type
- string