Configuration Format

Explains the format of the configuration

The Smartcontract Configurations are stored in the Seascape CDN. The root domain of the Seascape CDN is:

Each configuration is the JSON file stored in the following path:<project name>/<env>/config.json

  • <project name> - name of the project. Its recommended to keep it as the github repository of the smartcontracts without the -smartcontracts suffix.

  • <env> - whether the project is right now in the development mode, production mode or in the beta mode.

The recommended <env> variables are: beta, development, production.


The config.json format is:

    "network id": {
        "type": [
                "name": "Greeter",
                "address": "0x5bDed8f6BdAE766C361EDaE25c5DC966BCaF8f43",
                "abi": "",
                "owner": "0x5bDed8f6BdAE766C361EDaE25c5DC966BCaF8f43",
                "verifier": "0x5bDed8f6BdAE766C361EDaE25c5DC966BCaF8f43",
                "txid": "0xdcdac24321b46c296619628ccbb3354713e846ad56075c8eedf688530a6e0797",
                "fund": "0x5bDed8f6BdAE766C361EDaE25c5DC966BCaF8f43"
  • "network id" - chain id. For example for Ethereum Mainnet, it would be "1". The configuration is grouped into the smartcontracts by network id.

  • "type" - smartcontract type, each network id compoed from the smartcontract types. Each smartcontract repository would contain multiple smartcontracts. The smartcontract type is the classification of the smartcontracts. For example for MoonscapeGame smartcontracts would categorize the smartcontracts into "game", "erc20", "beta" and "nfts" types.

  • "smartcontract-config" - the object containing the smartcontract information. The "type" is the list of the "smartcontract-config".

Smartcontract config parameters:

  • "name" - required. The name of the smartcontract. Its adviced to take from the Smartcontract name itself. For example the "erc20" type token of the is called "MscpToken.sol", thus the name of the smartcontract would be "MscpToken".

  • "address" - required. The address of the smartcontract deployed on the network.

  • "abi" - required. The link to the ABI file of the smartcontract.

  • "owner" - optional. Who owns the smartcontract. Useful in development of the admin dashboards using the Smartcontract Config.

  • "verifier" - optional. The account that generates the proof the backend. Its adviced to include if smartcontract has any call of the ecrecover method. This property is used by the "Proof of Server" feature of the Seascape SDK.

  • "fund" - optional. Optionally if the smartcontract has to keep the funds or take the funds from outcoming account.

  • "txid" - optional. The transaction has of the smartcontract deployment. Its usefule for verification.

Last updated