man/stubmatic.1
Usage: stubmatic [OPTIONS]
Command:
$ stubmatic [--version] [-v|--verbose [--debug]] [-l|--logs] [-d <repo location>] [-p|--port <port number>] [-P <port number>] [-c|--config <config file>] [--target <remote URL> [--record <directory/path>] ]
$ stubmatic init [<repo name>]
$ stubmatic validate <json|yaml|xml file name>
Arguments
-p, --port http port number (default is 7777)
-P https port number
--host Host name
-c, --config config file name. It must be json file.
-h, --help display on screen help
-d absolute or relative location of repo. '.' is default.
-v, --verbose verbose; to enable on screen logging
-l, --logs To enable file based logging
--version Show currently installed version
--debug To debug request calls (use with -v option)
--target To make stubmatic as proxy server. Helpful with 'record' or 'debug' option
--record To record proxy requests to a file.
Considerations:
if -p, -s options are given then relevant properties from config file would be ignored;
Precedence of loding config is -p, -s > -c > -d > default
No option:
if "stubmatic" runs without any option then it builds configuration from config.json in current directory otherwise from current directory structure on default port 7777.
wiki : https://github.com/NaturalIntelligence/stubmatic
Report a bug : https://github.com/NaturalIntelligence/stubmatic/issues
Example:
------------------------
$ stubmatic init
$ stubmatic validate config.json
$ stubmatic -p 9999
$ stubmatic -d project-directory-path -c config.json
$ stubmatic -d project-directory-path
$ stubmatic -c config.json
$ stubmatic -v --debug --target http://remoteurl:8080
$ stubmatic --record directory/path --target https://some.url