-
Notifications
You must be signed in to change notification settings - Fork 8
serve
OGER Version: 1.0
Start a server with a simple RESTful API like so:
oger serve -s settings.ini
Use GET or POST requests to process individual articles. The RESTful API supports specifying input and output format.
Submitting a plain GET request to the port on which the server is listening returns an HTML page with a form for sending requests through the browser. Any request with an unkown location will yield a usage message, which describes the expected URL structure.
See also the documentation of the public REST API.
The server's host (IP) and port can be specified through the command-line options -i
/--host
and -p
/--port
, respectively.
The -d
/--debug
flag activates showing debugging information in the served responses.
Through the -s
/--settings
option, settings files can be specified (as described here).
Parameters can be overridden individually through the -c
/--config
option, which takes a key/value pair as arguments and can be repeated (described here).
Please note that the shortcut options (like -p
/--postfilter
) are not available for the serve
command; all parameters must be specified in settings files or through the -c
/--config
meta-option.
Also note that it doesn't make much sense to specify input/output parameters on server start-up, since loading and exporting is handled by the API's methods based on incoming requests. Instead, it is useful to configure termlist and postfiltering parameters.