new APIHelper(params)
Create an APIHelper.
Parameters:
Name | Type | Description | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
params |
Object | The API parameters.
Properties
|
- Source:
Members
provider
Getter of provider.
- Source:
provider
Setter of provider.
- Source:
query
Getter of API call query.
- Source:
query
Setter of query.
- Source:
resource
Getter of resource requested from API call.
- Source:
resourceExpected
Setter of resource requested from API call.
- Source:
response
Getter of response of API call.
- Source:
response
Setter of response of API call.
- Source:
Methods
setParams()
Set the parameters of the APIHelper.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
params.provider |
string |
<optional> |
The API provider (e.g., NodeGeocoder, Cloudinary, Google, etc.). |
params.query |
string |
<optional> |
The query of a specified API call. |
params.resource |
string |
<optional> |
The resource requested from a specified API call. |
- Source:
(async) setResponse((Function))
Sets the response of the APIHelper as the response of the API call specified.
Parameters:
Name | Type | Description |
---|---|---|
(Function) |
apiCall - The specified API function to be called. |
- Source: