genlayer-cli
できること
このスキルは、genlayerコマンドラインツールを使って、インテリジェントコントラクトを展開し、やり取りする方法を説明します。ネットワークの切り替えやトランザクションの確認を含み、GenLayer Studioやテストネットで作業する開発者向けです。
使う場面
- ✓コマンドラインからGenLayerのコントラクトを展開したいとき。
- ✓ローカル、Studio、テストネットのGenLayerのネットワークを切り替える必要があるとき。
- ✓GenLayerのコントラクトへのトランザクションが失敗し、それを調べたいとき。
スキルのリンク
https://github.com/internet-court/internet-court-skill/blob/main/vendored/genlayer/genlayer-cli/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“GenLayerのコントラクトをBradburyテストネットに展開し、トランザクションの結果を確認したいです。”
毎週5つの新しいスキル。1分で読めます。
仕組み
エージェントはツールをインストールし、必要なネットワークを選んで、コントラクトを展開、呼び出し、確認するコマンドを実行します。このスキルは、カスタムのアドレスを入力するよりも、組み込みのネットワークを選ぶよう勧めています。組み込みの設定の方がチェーンの構成が正しく保たれるためです。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
GenLayer CLI
The genlayer CLI manages contract deployment, interaction, transaction inspection, and network configuration. Works with GenLayer Studio (local), studio.genlayer.com, and Testnet Bradbury.
Setup
npm install -g genlayer
Network Configuration
genlayer network set # Interactive selector
genlayer network set testnet-bradbury # Direct
genlayer network info # Show current network config
genlayer network list # List all networks
Networks: localnet, studionet, testnet-asimov, testnet-bradbury
Note: studionet is gasless — no tokens are required to deploy or interact with contracts. A 0 GEN balance is expected and does not prevent any operations.
Note: studionet is rate-limited per IP — 60 req/min, 1000 req/hr, 10000 req/day. Limits aren't permanent — batching many deploy/write calls trips -32429 / HTTP 429 and further requests are rejected until the window resets (next minute / hour / day cycle). -32028 signals the pending-queue cap — up to 32 in-flight txs per sender; a separate cap also applies per contract. Throttle batch scripts, wait for receipts between submissions, or use localnet for heavy batches.
Always use genlayer network set instead of --rpc for built-in networks. The --rpc flag bypasses the chain configuration (consensus contract ABI, isStudio flag, etc.) and will cause transaction polling failures. Only use --rpc for custom/private networks not in the built-in list.
Account Management
genlayer account # Show active account (address, balance, network)
genlayer account list # List all accounts
genlayer account create --name dev1 # Create new account
genlayer account use dev1 # Set active account
genlayer account unlock # Cache key in OS keychain (no password prompts)
genlayer account lock # Remove from keychain
# Import from private key or keystore
genlayer account import --name imported --private-key 0x...
genlayer account import --name imported --keystore ./keystore.json
# Send tokens
genlayer account send 0x123...abc 10gen
Amount formats: "10gen", "0.5gen", or raw wei "1000000000000000000"
Non-interactive usage (CI/CD, containers, agents)
account create, account import, and account send accept --password <password> to skip interactive prompts:
genlayer account create --name dev1 --password "mypassword"
genlayer account import --name imported --private-key 0x... --password "mypassword"
account unlock requires an OS keychain (macOS Keychain, GNOME Keyring, etc.) and will fail in headless containers. When the account is locked, commands that sign transactions (deploy, write, appeal, account send) will prompt for the keystore password. To automate these, pipe the password via stdin:
echo "mypassword" | genlayer deploy --contract contracts/my_contract.py --args "arg1"
Funding Accounts
New accounts start with 0 GEN. Funding requirements depend on the network:
StudioNet is gasless — accounts with 0 GEN can deploy and interact with contracts without any funding. A zero balance on StudioNet is expected and normal. Skip funding entirely when using StudioNet.
For testnets (Bradbury, Asimov), fund the account before deploying or writing.
Faucet: https://testnet-faucet.genlayer.foundation/
- Get your address:
genlayer account-> copy theaddressfield - Go to the faucet URL, paste the address, and claim 100 GEN (once per 24 hours)
- Verify:
genlayer accountshould show the updated balance
The faucet uses Cloudflare Turnstile and cannot be automated from CLI -- the user must claim manually in a browser. Works for both Testnet Bradbury and Testnet Asimov.
Contract Deployment
# Deploy a specific contract
genlayer deploy --contract contracts/my_contract.py
genlayer deploy --contract contracts/my_contract.py --args "arg1" 42
# Run all deploy scripts in deploy/ folder
genlayer deploy
Contract Interaction
Read (no transaction)
genlayer call <address> <method>
genlayer call 0x123...abc get_data --args "key1"
Write (sends transaction)
genlayer write <address> <method>
genlayer write 0x123...abc set_data --args "hello"
Inspect contract
genlayer schema <address
よくある質問
studionetに展開するのにトークンが必要ですか?
いいえ。studionetはガス代がかからないため、残高がゼロでも展開や呼び出しを妨げないとしています。
展開をまとめて行うと拒否されることがあるのはなぜですか?
Studionetは、IPアドレスごとに毎分、毎時、毎日のリクエスト数を制限するため、大量のまとめ実行は上限に達することがあります。このスキルは、速度を抑えるか、localnetを使うよう勧めています。
どのネットワークが使えますか?
localnet、studionet、testnet-asimov、testnet-bradburyです。
詳細
作者による元の説明
Use the GenLayer CLI to deploy, interact with, and debug intelligent contracts.
人気
- GitHubのスター
- 7.0k
- ランキング
- #13627
- ライセンス
- —
- 更新日
- 2026/10/26
コメント
- …
このリポジトリの他のスキル
internet-court
7.0kエージェントが、他のAIエージェントや有料サービスと安全に支払い、雇用、取引できるよう支援し、適切な専門ガイドを案内します。
genlayer-erc7710-connector
7.0kエージェントが、AIによるレビューの結果を権限の仕組みにつなぎ、悪いレビューがエージェントの権限を制限または取り消せるよう支援します。
genlayer-intelligent-contracts
7.0kエージェントが、別のエージェントが委任された範囲を守ったかを判定するAIの審査役について、ルール、証拠、出力を定義できるよう支援します。
x402-erc7710
7.0kエージェントが、リクエストごとにウェブサービスの支払いを行い、許可された予算の範囲内で継続的な支出を設定できるよう支援します。
似ているスキル
api-connector-builder
280kエージェントが既存のパターンに従って、新しいAPI連携を構築します。新しい方式を作らずに、もう一つ連携を追加したいときに使います。
api-design
280kエージェントがベストプラクティスに沿ってREST APIを設計できるようにします。APIの通信方法、エラーの表示方法、データの整理方法を決めるのに役立ちます。
backend-patterns
280kエージェントのサーバーサイドのアーキテクチャパターンとデータベースの最適化を支援します。サーバー上で動くコードを作成またはレビューするときに役立ちます。