Proxy Get Config
Proxy Get Config - kintone.plugin.app.getProxyConfig()
Retrieves the headers and data that will be added to the request when running an external Web API with the following API.
Plug-in Proxy Request
This information will first need to be saved using the following API.
Proxy Set Config
Function
kintone.plugin.app.getProxyConfig(url, method)
Parameters
PARAMETER | TYPE | REQUIRED | DESCRIPTION |
---|---|---|---|
url | String | Yes | The URL of the API to be run. |
method | String | Yes | The HTTP method. Specify one of the following: GET / POST / PUT / DELETE . |
Returns
A JSON containing headers and data for the request required to run the external Web API.
PARAMETER | TYPE | DESCRIPTION |
---|---|---|
headers | Object | Request header specified as headers in Proxy Set Config API. |
data | Object | Request body specified as data in Proxy Set Config API. |
null
is returned for pages where it cannot be used.null
is returned, if there is no configuration settings set by Proxy Set Config API that matches.
Available Pages
This method can be used in the following pages:
- Plug-in Settings
Sample
Sample of using this API to retrieve saved values:
|
|
Notes
When using this API to retrieve the value specified for headers
in Proxy Set Config API, the value will always be a string.
For example, when integer or boolean values are assigned to the headers
:
|
|
In this case, when the following API is executed, values of integer or boolean types are returned as string types:
|
|