- name
- linkdrop-agent-cli
- description
- Create and redeem Linkdrop claim links from the command line with strict JSON output on Base, Polygon, Arbitrum, Optimism, and Avalanche.
- version
- 1.0.0
- metadata
- openclaw
- requires
- env
- bins
- primaryEnv
- PRIVATE_KEY
- homepage
- https://github.com/seichris/linkdrop-sdk-cli
When to use
- You need to create a funded Linkdrop claim link from a local wallet.
- You need to redeem a Linkdrop claim link to a destination address.
- You need stdout to be exactly one JSON object for automation.
Files in this skill
linkdrop-agent.jsis the strict JSON CLI entrypoint.agentdrop-core.jscontains the Linkdrop and chain logic used by the CLI..env.exampleshows the supported runtime configuration.
Setup
- Run
npm install. - Set secrets in your shell or
.env:
- Required: PRIVATE_KEY, LINKDROP_API_KEY - Recommended for Base: RPC_URL_BASE - Optional fallback: RPC_URL
- Keep secrets out of git history.
Supported chains
basedefaultpolygonarbitrumoptimismavalanche
Send a claimable transfer
- Native token on Base:
- node linkdrop-agent.js send --amount 0.01 --token native --chain base
- ERC20 on Polygon:
- node linkdrop-agent.js send --amount 5 --token 0xTokenAddress --chain polygon
- Read these JSON fields from stdout:
- claimUrl - transferId - depositTx
Claim a transfer
- Run:
- node linkdrop-agent.js claim --url "https://..." --to 0xRecipient --chain base
- Read
redeemTxfrom stdout.
JSON contract
- Success returns
{ ok: true, ... }. - Failure returns
{ ok: false, error: { code, name, message, details? } }. - The CLI writes one JSON object to stdout per invocation.
Troubleshooting
Missing PRIVATE_KEY: set a 32-byte hex private key with0xprefix.Missing LINKDROP_API_KEY: set a valid Linkdrop API key with thezpka_prefix.No RPC URL available: setRPC_URL_BASEfor Base or the matchingRPC_URL_<CHAIN>.Unsupported chain: use one of the supported chain names above.