Connecting to the Minka Sandbox server
Introduction
The Minka Sandbox server provides a development and testing environment for building and testing ledger applications.
This environment is specifically designed for development purposes and should not be used for production deployments.
Prerequisites
Before connecting to the sandbox, ensure you have:
- Node.js 20.17 or later installed
- npm or yarn package manager
- A stable internet connection
Installation
Install the Minka Command Line Interface (CLI) using one of the following methods:
# Using npm
npm install -g @minka/cli
# Using yarn
yarn global add @minka/cli
The CLI requires Node.js 20.17 or later. For detailed system requirements and troubleshooting, see the CLI Reference documentation.
Connecting to the Minka Sandbox server
To connect to the Minka development environment, use the following command:
minka server connect https://ldg-stg.one/api/v2
After establishing the connection, you can use the Minka CLI to create and interact with ledgers.
Creating a Signer
In the Minka ecosystem, every server and ledger operation requires a signer. Signers are cryptographic identities that provide:
- Authentication: They identify the entity responsible for each ledger action
- Authorization: They enable fine-grained control over which operations each entity can perform

A signer consists of a cryptographic key pair:
- A private key for signing operations
- A corresponding public key for verifying signatures
Your private key should never be shared with anyone. Anyone with access to your private key can perform any action that your signer is authorized to do, including transferring balances.
To create a signer named ledger-creator
, execute the following command:
minka signer create
You can see the signer details, including the private key, using the following command:
minka signer show ledger-creator --secret
For comprehensive information about signers, including security best practices and technical implementation details, refer to the following documentation:
Security and Authorization
The Minka ledger system implements a multi-level security model with three distinct levels:
- Server level
- Ledger level
- Record level
Authorization Process
When checking whether a signer can perform an action, the system follows a two-stage authorization process:
-
Access Gate: The system performs a top-to-bottom check to verify if the
access
rule is granted to the signer. For example, if a signer attempts to perform an action on a specific record but doesn't have theaccess
rule on the ledger, the action is blocked. -
Action Authorization: If the signer passes the Access Gate for a particular level, the system collects all access rules from every level and applies an additive model: if ANY rule grants the requested action, the action is granted.
Sandbox Server Security Configuration
The Sandbox Server is configured with two default rules:
[
{
"action": "access"
},
{
"action": "create",
"record": "ledger"
}
]
These rules provide:
- Access Gate: Any signer has
access
to the server, fulfilling the base level requirement for performing actions - Action Authorization: Any signer can create a ledger
For a detailed explanation of authorization in Minka, see About Authorization documentation.