Key handling

Wasit signs with keys you supply. It needs them to do its job, and it does the minimum with them.

  • Keys are read from environment variables. Never from a config file: wasit.config.json is committed and the loader refuses a secret in it. wasit run, the Action and the MCP server take keys from the environment only. The older commands wasit test, wasit mpp-charge and wasit mpp-channel also accept --payer-key and --commitment-key; a key on a command line stays in your shell history and is visible in the process list, so prefer the environment variable. The CLI loads a .env file from the folder it runs in into its environment, except wasit run in CI and with --mainnet (whose key comes from WASIT_MAINNET_PAYER_SECRET in the shell only) and wasit ci-report.
  • Keys are never accepted as MCP tool arguments. Every tool reads what it needs from the server's own environment, so an agent never handles a key and a key can never end up in a conversation transcript. A missing key returns an error naming the variable to set, not a prompt to supply one.
  • Keys are never logged, persisted, or transmitted anywhere except to the Stellar network as part of a signed transaction. Check output reports public keys and transaction hashes; it does not report secrets.
  • .env is gitignored. .env.example documents every variable by name with no values.

Use a dedicated testnet account with only as much balance as the run needs. Do not reuse a key that has any other purpose.