Generate the stub file

Use the fglrestful tool to generate the client stub from a REST Web service URL.

The generated stub file contains the complete code to manage calls made by client apps to the Web service resources. You must import the stub file into the client app.
Note: The "MyService" GWS REST service must be running on the specified port in order to provide the service information.

Steps

  1. Use the fglrestful tool to generate the stub
    fglrestful -o clientstub http://localhost:8090/MyService?openapi.json
    Where:
    1. clientstub specifies the file name of the stub in the output (-o) option.
    2. The URL of the Web service is specified with the query string ?openapi.json to get the specification file.

    The clientstub.4gl is generated from the specification.

  2. Compile the stub file.
    fglcomp clientstub.4gl