π Part of the Overworked Metaverse ecosystem
Foundational token infrastructure for virtual economies πΌβ¨
This repository contains the ICRC-1 ledger deployment infrastructure for the CRY Token - the native cryptocurrency of the Overworked Metaverse.
The CRY Token powers a revolutionary virtual world where users earn real value through:
- πΌ Job Marketplace - Get paid in CRY for completing virtual tasks
- π Education Hubs - Earn tokens while learning new skills
- ποΈ Museums & Culture - Monetize cultural experiences and content creation
- π’ Virtual Offices - Facilitate real business operations in the metaverse
- ποΈ Marketplace - Trade virtual assets and services
π Note: The main token logic and smart contracts are implemented in the Overworked Metaverse backend. This repository focuses solely on ledger deployment and configuration.
- ICRC-1 Ledger Deployment - Standard-compliant token ledger
- ICP Ledger Integration - Local development with ICP compatibility
- NNS Setup - Network Nervous System for testing environments
- One-command deployment - Automated setup scripts
- Environment management - Configurable for different networks
- Account management - Automated minter and controller setup
- ICRC-1 compatible for seamless integration
- ICRC-2 support for advanced token operations
- Cross-ledger compatibility with other IC tokens
graph TB
A[οΏ½οΈ CRY Token Ledger Repo] --> B[π ICRC-1 Ledger]
A --> C[π ICP Ledger - Local]
A --> D[π§ Deployment Scripts]
B --> E[π Overworked Backend]
C --> E
E --> F[πΌ Job System]
E --> G[π Education Hub]
E --> H[ποΈ Museums]
E --> I[π’ Virtual Offices]
style A fill:#e1f5fe
style B fill:#e8f5e8
style C fill:#e8f5e8
style E fill:#f3e5f5
- dfx
>= 0.27.0 - WSL2 (for Windows users)
- Git
# Clone the repository
git clone https://github.com/Unchainers/CRY-Token.git
cd CRY-Token
# Install dfx if not already installed
sh -ci "$(curl -fsSL https://sdk.dfinity.org/install.sh)"
# Setup environment variables
cp .bash.env.template .bash.env
# Edit .bash.env with your configuration# Start local replica
dfx start --background
# Deploy with temporary accounts (development only)
./deploy_ledger.bash --temp-acc
# Deploy with specific owners
./deploy_ledger.bash --set-owners <ICP_OWNER> <CRY_OWNER>
# Deploy using current identity
./deploy_ledger.bash --with-redeem| Option | Description | Usage |
|---|---|---|
--temp-acc |
π§ͺ Create temporary test accounts | Development only |
--set-owners |
π₯ Set specific owner principals | --set-owners <icp> <cry> |
--with-redeem |
π Use current identity as owner | Single command setup |
After successful deployment, you'll have:
- Purpose: Main CRY token ledger
- Standard: ICRC-1/ICRC-2 compliant
- Functions: Transfer, balance queries, allowances
- Integration: Used by Overworked backend
- Purpose: Local ICP simulation for testing
- Standard: ICP ledger compatible
- Functions: ICP transfers and balance management
- Usage: Development and testing only
| Parameter | Value | Description |
|---|---|---|
| Symbol | CRY |
Token ticker symbol |
| Name | CRY Token |
Full token name |
| Decimals | 8 |
Precision (like Bitcoin) |
| Supply | 1,000,000 |
Initial pre-minted tokens |
| Transfer Fee | 0 |
No fees for basic transfers |
The ledger deployed by this repository is consumed by the main Overworked Metaverse backend for:
- πͺ Token Vending Machine - ICP to CRY exchange
- π P2P Token Swaps - User-to-user trading
- πΌ Job Payments - Automated salary distribution
- π Education Rewards - Learning incentives
- ποΈ Marketplace Transactions - Virtual asset trading
After deployment, these variables are available for the main project:
# Auto-generated in .env file
CANISTER_ID_ICRC1_LEDGER_CANISTER=<ledger-canister-id>
CANISTER_ID_ICP_LEDGER_CANISTER=<icp-canister-id>
DFX_NETWORK=local# Check deployed canister IDs
dfx canister id icrc1_ledger_canister
dfx canister id icp_ledger_canister# Use the balance checker utility
./wheretoken.bash
# Or manually query
dfx canister call icrc1_ledger_canister icrc1_balance_of '(record { owner = principal "user-principal-here" })'// In Overworked backend - reference the deployed ledger
let cryLedger : ICRC1.Service = actor("canister-id-from-env");
// Use the ledger for transfers
let result = await cryLedger.icrc1_transfer({
to = { owner = userPrincipal; subaccount = null };
amount = rewardAmount;
fee = null;
memo = null;
created_at_time = null;
});CRY-Token/
βββ π README.md # This file
βββ βοΈ dfx.json # DFX configuration for ledgers
βββ π§ deploy_ledger.bash # Main deployment script
βββ π .bash.env.template # Environment template
βββ π .bash.env # Your environment config
βββ ποΈ src/
β βββ π declarations/ # Generated type definitions
βββ π setup.txt # Troubleshooting guide
βββ π wheretoken.bash # Balance checking utility
βββ π *.log # Deployment logs
# Run the balance checker
./wheretoken.bash# Check total supply
dfx canister call icrc1_ledger_canister icrc1_total_supply
# Check token metadata
dfx canister call icrc1_ledger_canister icrc1_metadata# Check deployment logs
tail -f nns_install.log
tail -f bishop.log# Use local replica
export DFX_NETWORK=local
./deploy_ledger.bash --temp-acc- Never use
--temp-accfor mainnet deployment - Keep your principal keys secure
- Use proper identity management for production
- Deploy ledger infrastructure (this repo)
- Copy canister IDs to main project
- Integrate with Overworked backend
- Test end-to-end functionality
Common issues and solutions are documented in setup.txt
We welcome contributions to the CRY Token ledger infrastructure!
- π΄ Fork the repository
- πΏ Create a feature branch (
git checkout -b feature/ledger-improvement) - βοΈ Commit your changes (
git commit -m 'Improve ledger deployment') - π€ Push to the branch (
git push origin feature/ledger-improvement) - οΏ½ Open a Pull Request
- Follow bash scripting best practices
- Test deployment scripts thoroughly
- Document environment variable changes
- Use meaningful commit messages
- π Issues: GitHub Issues
- π¬ Discussions: GitHub Discussions
- π Main Project: Overworked Metaverse
- ποΈ Internet Computer Foundation - For the incredible ICP infrastructure
- π§ DFINITY - For the ICRC standards and development tools
- π IC Community - For continuous support and feedback