ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Communication / HTTP functions
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
OpenAPIToHTTP (Function)
In french: OpenAPIVersHTTP
Builds the HTTP request to call a function of an API.
Example
// Standard call that is using the full call to a WebService method
stParam1 is Param1
stParam1.String = "a string"
stParam1.Int = 2
stRet is MyResult
stRet = MyFunction(stParam1)
// Retrieve the Buffer for the call using OpenAPIToHTTP
stParam1 is Param1
stParam1.String = "a string"
stParam1.Int = 2
cMyRequest is httpRequest = OpenAPIToHTTP(MyFunction, stParam1)
HTTPSend(cMyRequest)
Syntax
<Result> = OpenAPIToHTTP(<Function> [, <Parameter 1> [... [, <Parameter N>]]])
<Result>: httpRequest variable
httpRequest variable corresponding to the generated HTTP request.
<Function>: Character string
Name of the function for which the HTTP request must be built.
<Parameter 1>: Optional variant
First parameter expected by the function.
<Parameter N>: Optional variant
Nth parameter expected by the function.
Remarks
OpenAPIToHTTP builds the HTTP request (as a variable of type httpRequest) that can be sent to the API via the following syntax:
<API function>([<Function parameter 1> [, ... [<Function parameter N>]]])
The generated request can then be sent using HTTPSend.
Component: wd290com.dll
Minimum version required
  • Version 28
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 09/07/2022

Send a report | Local help