Pcml object
i2Rest PCML Object
Use this object to define API for calling existing programs on your IBM i server.
It is required to prepare formal description of program call parameters to be able to use existing *PGM or *SRVPGM as a API servce. i2Rest Server uses slightly extended version of Program Call Markup Language (PCML) as a basis of parameters documenting and processing.
PCML file can be created manually using any existing text editor, or generated automatically as part of CRTRPGMOD/CRTCBLMOD command (parameter PGMINFO). In any case, you have to put PCML file somewhere in IFS folder and include appropriate PCML object to the list of APIs that will be automatically loaded during i2Rest Server startup. As an option, you can publish PCML file to the running i2Rest Server instance using Add PCML API.
PCML Object structure:
Field | Type | Description | Default value |
pcml_mount | string | REUQIRED, PCML API mount point Defines PCML API mounting point. This parameter will be used as a part of URL where this PCML API will be accessible: |
|
pcml_file | string | REUQIRED, path to PCML API definition file Path to file with PCML API definition. Path can be specified as absolute path or as path relative to current directory of i2Rest Server instance. |
|
valid_in_anonymous | boolean | Valid in anonymous calls? Specifies whether this PCML API is available to calls without OAuth2 authorization token |
false |