Directive Variable Access path
Authentication type /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
NameTrans /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name IP_address_templete
Authorization /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
ObjectType /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
Service /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name* IP_address_template
Data Filter /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name:function_name:function_name
Log /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
Error /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
PostExit /URL /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
ServerTerm /QSYS.LIB/MYLIB/MYGWAPI.SRVPGM:function_name
Server API directive variables
The variables in these directives have the following meanings:
type Used only with the Authentication directive. This variable determines if
your application function is called. Valid values are:
Basic Application function is called only for basic authentication requests
*Application function is called for all requests
/URL Determines for which URLs your application function is called.
URL specifications in these directives are virtual (they do not
include the protocol) but a slash (/) precedes them. For example,
/www.ics.raleigh.ibm.com is correct, but
http://www.ics.raleigh.ibm.com is not. Validvalues are:
A specific URL
Application function is called only for that URL
URL templete
Application function is called only for URLs that match the
template. You can specify a template as /URL*,/*, or *.
Note: An URL template is required with the Service
directive if you want path translation to occur.
/path/file
The fully qualified file name of your compiled program
:function_name
The name you gave your application function within your
program
In the DataFilter directive, you must supply the names of
the open, write, and close functions.
The Service directive requires an asterisk (*) after the
:function_name, if you want to have access to path
information.
init_string
Optional on the ServerInit directive, this can contain any
Chapter7. Writing Server API programs 121