This section describes BLOC-service starting process with correct arguments enabling access to the BLOC-service JSON RPC API.
To configure BLOC-service RPC Wallet you can use both command line and config file. Config file allows you to configure your settings only once and use --config option further.
Almost all of the command line options can be defined through the configuration file. If a parameter is defined in the config and was also indicated in the command line, two behaviors are possible:
- If the parameter accepts one value only (e.g., --bind-address), the command line value will be used, since it has a higher priority
- If the parameter accepts several values, then command line and configuration file values will be merged
- If some of the options are not defined in the config, the default values will be applied
Notes:
- Config files, where used, now use JSON formatted files instead of INI
- Config files will be automatically upgraded to JSON and overwritten on first use
- Config file's path is relative to current working directory, not server root.
- Options --container-file and --container-password should ALWAYS be set (in either command line or config file mode).
- --container-file and --log-file options are relative to --server-root. server-root default is the current working directory.
To start using BLOC-service you must first create a new wallet by generating a container. Container file is the only file that stores all data required to run your service. It contains user addresses and private keys required to operate them. Make sure to backup this file regularly.
You can also restore a wallet using private keys with the --view-key and --spend-key argument or using a 25 words phrase --mnemonic-seed.
A complete guide is available on this page of how to restore your wallet with BLOC-service.
Once you have generated your wallet you can now connect BLOC-service to a local or remote BLOCd Daemon. You can do this using the --daemon-address and --daemon-port arguments.
We are going to describe on this page how to generate your own config file, and start BLOC-service using it:
You are now ready to use the bloc-service JSON RPC API to create addresses for your users, accept, send transactions and much more. Detailed description for every BLOC-service RPC Wallet API method can be found as follow: