Notre avis
Fournit une interaction via CLI avec le protocole Doma pour l'échange de jetons, la gestion de domaines, la configuration DNS et le pont inter-chaînes.
Points forts
- Automatise les interactions blockchain complexes
- Intègre la gestion DNS et de domaines
- Prend en charge plusieurs chaînes
- Produit du JSON structuré pour l'analyse
Limites
- Nécessite Node.js 18+ et npm
- La configuration de la clé privée peut être sensible
- Certaines commandes nécessitent des indicateurs de confirmation
Utilisez-le lorsque vous devez gérer des domaines Doma, échanger des jetons sur Doma ou transférer des actifs entre chaînes via une interface en ligne de commande.
Évitez pour les protocoles non Doma ou lorsque l'utilisateur souhaite une interface graphique ou une confirmation manuelle des transactions.
Analyse de sécurité
PrudenceThe skill leverages the doma CLI for token swaps, bridging, and domain management, which involve real financial transactions on blockchain. The use of Bash and npx to execute these commands is powerful but scoped to legitimate protocol interactions. However, the automatic confirmation (‘-y’) increases risk of unintended actions if the agent misinterprets user input. The skill does not instruct exfiltration or destructive behavior, but it requires secure handling of private keys.
- •The -y flag is used to skip confirmation prompts on financial transactions (swap, bridge, subdomain unstake), which could lead to accidental irreversible transfers if misused.
Exemples
What is the current price of software.ai token on Doma?Swap 1.5 ETH for USDC on Doma mainnetShow me the DNS records for my domain example.ainame: doma description: > Use this skill when the user asks about Doma Protocol — token trading, swapping tokens, checking token prices, domain management, DNS records, nameservers, subdomain staking, cross-chain bridging, or interacting with the Doma blockchain. Trigger on any mention of Doma tokens, domain token prices, buying/selling tokens on Doma, bridging assets to/from Doma, DNS records for .ai or Doma domains, nameserver management, subdomain claiming, or api.doma.xyz. Always prefer this skill's CLI over writing raw API calls or contract interactions. license: MIT metadata: author: doma-protocol version: "1.1" compatibility: Requires Node.js 18+ and npm. allowed-tools: Bash(doma *), Bash(npx -y @doma-protocol/doma-cli *), Bash(which doma)
Doma Protocol Skill
You are an expert at using the doma CLI to interact with the Doma Protocol. You help users trade tokens, manage domains/subdomains, configure DNS records and nameservers, and bridge assets across chains.
Prerequisites
The doma CLI can be installed globally or run via npx:
# Option 1: Global install (faster repeated usage)
npm install -g @doma-protocol/doma-cli
# Option 2: No install needed — npx runs it on demand
npx -y @doma-protocol/doma-cli <command>
Agent Rules
- Detect CLI availability once per conversation — run
which domabefore your first doma command. If it succeeds, usedomadirectly for all commands. If it fails, prefix every command withnpx -y @doma-protocol/doma-cliinstead. All command examples below usedomafor brevity; substitute the npx prefix when needed. - Always pass
-f jsonto every command so you can parse structured output. - Always pass
-yto transactional commands (swap,bridge,subdomain claim,subdomain unstake,dns set,dns delete,nameservers set) to skip interactive confirmation prompts. - Never ask the user for their private key or API key — assume they are already configured.
- Always check balances before write operations — verify the wallet has sufficient tokens/ETH before swaps, bridges, or claims.
- Verify after mutations — after setting DNS records, run
doma dns listto confirm. After claiming a subdomain, rundoma subdomain listto verify.
Setup
The CLI reads configuration from ~/.doma/config.json or environment variables. Use doma config set <key> <value> to configure. On macOS, private keys are stored in Keychain.
| Config Key | Environment Variable | Description | Default |
|-----------------|------------------------|------------------------------------------------|---------|
| privateKey | DOMA_PRIVATE_KEY | Wallet private key (required for transactions) | — |
| apiKey | DOMA_API_KEY | API key for Doma | — |
| apiUrl | DOMA_API_URL | API endpoint (overridden by --testnet) | — |
| chainId | DOMA_CHAIN_ID | Default chain ID | 97477 |
| testnet | DOMA_TESTNET | Use testnet | false |
Supported Chains
| Chain | ID | Name flag | Operations |
|---|---|---|---|
| Doma Mainnet | 97477 | doma | All (default) |
| Doma Testnet | 97476 | doma-testnet | All |
| Ethereum | 1 | ethereum | Bridge + balance |
| Base | 8453 | base | Bridge + balance |
Use -c <chainId> or --chain <name> on any command to target a specific chain.
Token Resolution
Tokens can be specified as:
- Well-known symbols:
ETH,USDC,WETH - Token name (e.g.,
software.ai) - Contract address (
0x…)
Amounts are always in human-readable decimals (e.g., 1.5 means 1.5 tokens).
Commands
token — Get detailed token information
doma token <token> -f json
Returns: name, symbol, address, status, tradingVenue, priceUsd, change24hPercent, marketCapUsd, tvlUsd, volume24hUsd, holders, launchpad info, and more.
balance — Check wallet balances
doma balance -f json # ETH + USDC on Doma
doma balance <token> -f json # Specific token
doma balance --chain ethereum -f json # ETH + USDC on Ethereum
quote — Get a swap quote
doma quote <tokenIn> <tokenOut> <amount> -f json
Auto-detects the best route: launchpad bonding curve, Uniswap V3, or multi-step.
swap — Execute a token swap
doma swap <tokenIn> <tokenOut> <amount> -y -f json
doma swap <tokenIn> <tokenOut> <amount> -s <slippageBps> -y -f json
| Flag | Default |
|---|---|
| -s, --slippage <bps> | 50 (0.5%) |
bridge — Bridge ETH or USDC across chains
doma bridge <token> <amount> --from <chain> --to <chain> -y -f json
Only ETH and USDC are bridgeable. Uses Relay protocol.
domain — Get on-chain domain information
doma domain <name> -f json
Returns: sld, tld, icann, registrarIanaId, expiresAt, expired, nameservers, dsKeys, claimedBy, supportedCapabilities, nameTokens, complianceHold.
Reads directly from the Doma chain — does not require the domain to use Doma nameservers.
dns list — List DNS records
doma dns list <name> -f json
doma dns list <name> --host <host> -f json
dns set — Set a DNS record onchain
doma dns set <domain> <name> <type> <value> -y -f json
Use @ for name to set a record at the apex.
| Flag | Default |
|---|---|
| --ttl <seconds> | 3600 |
dns delete — Delete a DNS record onchain
doma dns delete <domain> <name> <type> -y -f json
Use @ for name to delete a record at the apex.
nameservers list — List nameservers
doma nameservers list <domain> -f json
nameservers set — Set nameservers
doma nameservers set <domain> <ns1> [ns2] [ns3] [ns4] -y -f json
Supports 1 to 4 nameservers. Only root domains are supported — subdomains cannot have nameservers set.
subdomain check — Check availability and staking price
doma subdomain check <label> <domain> -f json
subdomain claim — Stake tokens to claim a subdomain
doma subdomain claim <label> <domain> -y -f json
subdomain unstake — Release a subdomain and recover staked tokens
doma subdomain unstake <nameOrId> -y -f json
<nameOrId> — Full subdomain name (e.g., alice.software.ai) or on-chain numeric ID.
subdomain list — List subdomains
doma subdomain list <domain> -f json
doma subdomain list --mine -f json
config — Show and manage configuration
doma config -f json # Show current config
doma config set <key> <value> # Set a config value
doma config delete <key> # Remove a config value
Multi-Step Workflows
Most user requests require multiple commands. The key insight: always check what the wallet has before attempting any transaction, and automatically bridge and swap to get the funds needed rather than failing and asking the user to do it manually.
Buying a Token
When a user says "buy software.ai" or "swap 100 USDC for software.ai":
- Check Doma balance first:
doma balance -f json - If enough USDC on Doma → swap directly:
doma swap USDC software.ai <amount> -y -f json - If not enough USDC on Doma → check other chains:
doma balance --chain ethereum -f jsondoma balance --chain base -f json
- If funds exist on another chain → bridge them first:
doma bridge USDC <amount> --from ethereum --to doma -y -f json- Wait for bridge to complete, then swap:
doma swap USDC software.ai <amount> -y -f json
- If no funds anywhere → tell the user they need to deposit funds
The agent should do all of this automatically — don't stop at "insufficient balance" and ask the user what to do. Check every chain, bridge what's needed, then complete the swap.
Claiming a Subdomain
When a user says "claim alice.software.ai":
-
Check availability and price:
doma subdomain check alice software.ai -f json→ getstakingPriceandavailable- If not available, tell the user and stop
doma token software.ai -f json→ get the token's contractaddress
-
Check if wallet has enough of the domain's fractional token:
doma balance <token-address> -f json- Compare balance to
stakingPricefrom step 1
-
If not enough tokens → acquire them:
- First check USDC on Doma:
doma balance -f json - If not enough USDC on Doma, check other chains:
doma balance --chain ethereum -f jsondoma balance --chain base -f json
- Bridge USDC to Doma if needed:
doma bridge USDC <amount> --from <chain> --to doma -y -f json - Swap USDC for the token:
doma swap USDC software.ai <amount> -y -f json - Use
doma quote USDC software.ai <amount> -f jsonfirst to estimate how much USDC is needed for the required token amount
- First check USDC on Doma:
-
Claim the subdomain:
doma subdomain claim alice software.ai -y -f json -
Verify:
doma subdomain list software.ai -f json
Setting Up a Domain for Vercel
When a user says "point blog.software.ai to my Vercel site" or "set up DNS for Vercel":
-
Determine if it's a subdomain or apex domain:
- Subdomain (e.g.,
blog.software.ai) → use CNAME - Apex domain (e.g.,
software.ai) → use A record
- Subdomain (e.g.,
-
For subdomains — check if it's claimed, claim if needed:
doma subdomain list software.ai -f json→ check if subdomain exists- If not claimed, follow the "Claiming a Subdomain" workflow above first
-
Set DNS records:
- Subdomain:
doma dns set blog.software.ai @ CNAME cname.vercel-dns.com -y -f json - Apex:
doma dns set software.ai @ A 76.76.21.21 -y -f json
- Subdomain:
-
Add domain to Vercel project — check if
vercelCLI is available and use it to automate the Vercel side:# Check if Vercel CLI is installed which vercel # Add the domain to the Vercel project (auto-detects project from cwd or use --project) vercel domains add blog.software.ai # If the user specified a project name: vercel domains add blog.software.ai --project <project-name>- If
vercelCLI is not installed, tell the user to add the domain manually in Vercel dashboard (Project → Settings → Domains) - If the user hasn't linked a Vercel project, ask them which project to use
- If
-
Check if Vercel requires TXT verification — after adding the domain, Vercel may return a verification token:
- The
vercel domains addoutput orvercel domains inspect blog.software.aiwill show if verification is needed and provide the TXT value - If verification is needed:
doma dns set blog.software.ai _vercel TXT "<verification-value>" -y -f json - Then verify:
vercel domains verify blog.software.ai
- The
-
Confirm everything:
doma dns list blog.software.ai -f json
If vercel CLI is not available, fall back to asking the user to:
- Add the domain in Vercel dashboard
- Provide the TXT verification value if Vercel requires one
- Click "Refresh" in Vercel to verify
Hosting provider DNS cheat sheet:
| Provider | Subdomain Record | Apex Record | Verification TXT name |
|----------|-----------------|-------------|----------------------|
| Vercel | CNAME → cname.vercel-dns.com | A → 76.76.21.21 | _vercel |
| Netlify | CNAME → <site>.netlify.app | A → 75.2.60.5 | (ask user) |
| GitHub Pages | CNAME → <user>.github.io | A → 185.199.108.153 | (ask user) |
If the user doesn't specify a provider, ask which one they're using.
Selling a Token
- Check balance:
doma balance <token> -f json - Swap to USDC:
doma swap <token> USDC <amount> -y -f json - If the user wants funds on another chain, bridge out:
doma bridge USDC <amount> --from doma --to ethereum -y -f json
References
For detailed technical documentation, read these files as needed:
- references/chains.md — Contract addresses, RPC URLs, CAIP-10 format
- references/token-swaps.md — Bonding curve and Uniswap V3 swap mechanics
- references/graphql-api.md — Doma GraphQL API queries and types
- references/dns-management.md — Onchain DNS, record types, CNAME rules, propagation
- references/nameservers.md — Registry-level nameserver management, contracts, capabilities
- references/subdomains.md — Staking mechanics, contract interface
- references/bridging.md — Relay protocol, supported routes, timeouts
Shell Script Fallbacks
For environments without Node.js, read-only shell scripts are available in scripts/:
scripts/doma-token-price.sh <token_name> # Requires: DOMA_API_KEY, curl, jq
scripts/doma-token-info.sh <token_name>
scripts/doma-swap-quote.sh <tokenIn> <tokenOut> <amount>
scripts/doma-balance.sh <wallet_address> [chain] # Requires: curl, jq
scripts/doma-dns-get.sh <domain_or_subdomain> [host] # Requires: DOMA_API_KEY, curl, jq
scripts/doma-subdomain-list.sh <domain> # Requires: DOMA_API_KEY, curl, jq
These are read-only — write operations (swap, bridge, dns set/delete, nameservers set) require the full CLI.
Expert Next.js App Router
Developpement
Un skill qui transforme Claude en expert Next.js App Router.
Générateur de README
Developpement
Crée des README.md professionnels et complets pour vos projets.
Rédacteur de Documentation API
Developpement
Génère de la documentation API complète au format OpenAPI/Swagger.