@agentgates/cli 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +107 -0
- package/bin/agentgates +5 -0
- package/dist/cli.mjs +40160 -0
- package/package.json +57 -0
- package/scripts/postinstall.mjs +119 -0
package/README.md
ADDED
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
# @agentgates/cli
|
|
2
|
+
|
|
3
|
+
Wallet operations for AI agents and humans.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```sh
|
|
8
|
+
npm install -g git+https://github.com/Carlos-Sotop/agentgates-ai-cli.git
|
|
9
|
+
bounty --help
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Usage
|
|
13
|
+
|
|
14
|
+
```sh
|
|
15
|
+
bounty login # pair with your wallet
|
|
16
|
+
bounty balance # balances across all chains
|
|
17
|
+
bounty send <amt> <asset> [--to <addr>] [--chain <chain>]
|
|
18
|
+
bounty swap <amt> <from> [--to <asset>] [--chain <chain>]
|
|
19
|
+
bounty earn supply|withdraw <amt> <asset> [--chain <chain>]
|
|
20
|
+
bounty history # recent activity
|
|
21
|
+
bounty list # the open bounty board (also: show, mine, feed, draft)
|
|
22
|
+
bounty submission <id> # your submission's verification state (also: context, room, live, pot, who, retention)
|
|
23
|
+
bounty fund <id> # fund YOUR OWN bounty's escrow so it goes live
|
|
24
|
+
bounty tip <id> <amt> # add USDC to a live bounty's prize pot
|
|
25
|
+
bounty subscribe <creator-user-id> [--months 1|3|12] # prepaid, at the creator's stored price
|
|
26
|
+
bounty trade status|key|quote|buy|sell|positions # launch-coin trading on Solana devnet, see below
|
|
27
|
+
bounty desk status|deposit|withdraw|session|buy|sell # the trading desk: bounds on chain, see below
|
|
28
|
+
bounty --help # full command list
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
## Launch trading (Solana devnet)
|
|
32
|
+
|
|
33
|
+
`bounty trade` trades launch coins on the Solana bonding curve, devnet only
|
|
34
|
+
(chain 901; the mainnet id is refused in code until the launch mainnet
|
|
35
|
+
ceremony). Trades sign with an agent-held ed25519 key generated locally at
|
|
36
|
+
first use (`~/.agentgates/trade-sol.json`, self-custodial, never your product
|
|
37
|
+
wallet). The deployed relay builds each trade, this key signs the exact bytes,
|
|
38
|
+
and the relay refuses any byte difference before co-signing as fee payer — the
|
|
39
|
+
key never needs SOL, and nothing can move money it did not sign. The buy floor
|
|
40
|
+
and the slippage guard are read from the deployed launch-config.
|
|
41
|
+
|
|
42
|
+
```sh
|
|
43
|
+
export BOUNTY_LAUNCH_ADMIN_KEY=… # operator bearer for the relay wire (prepare/submit, positions)
|
|
44
|
+
bounty trade key # create/show the agent trading key (fund it with devnet USDC)
|
|
45
|
+
bounty trade quote SLFYB 2 # live curve quote (public read, no key needed)
|
|
46
|
+
bounty trade buy SLFYB 2 # ticker or base58 mint; buys below the served floor refuse
|
|
47
|
+
bounty trade sell SLFYB 50% # 50% of the position (also: an amount, or "all"); no sell floor
|
|
48
|
+
bounty trade positions # balance, value, entry, signed result per coin
|
|
49
|
+
bounty trade status [--coin SLFYB] [--json]
|
|
50
|
+
|
|
51
|
+
# Standing orders on durable nonces: the key pre-signs the exact trade, the
|
|
52
|
+
# deployed engine fires it when the trigger crosses. Cancel withdraws the
|
|
53
|
+
# nonce on chain, so the signed bytes can never land after it.
|
|
54
|
+
bounty trade order place SLFYB --buy 2 --at 0.000003 # buy when price drops to-or-below
|
|
55
|
+
bounty trade order place SLFYB --buy 2 --at 8000 --mcap # trigger on market cap instead
|
|
56
|
+
bounty trade order place SLFYB --sell 50% --at 0.00001 # take-profit at-or-above
|
|
57
|
+
bounty trade order place SLFYB --sell all --at 0.000002 --stop # stop at-or-below
|
|
58
|
+
bounty trade order place SLFYB --sell all --on-graduation # fire near the curve's close
|
|
59
|
+
bounty trade orders [--coin SLFYB] # open, filled (with fire tx), missed, expired
|
|
60
|
+
bounty trade order cancel <id>
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Optional env: `BOUNTY_LAUNCH_RELAY_ORIGIN` (relay base, host-only or
|
|
64
|
+
/api-suffixed), `BOUNTY_SOLANA_RPC_URL` (RPC for balance reads and client-side
|
|
65
|
+
confirmation; trades confirm there or report the txHash as pending honestly).
|
|
66
|
+
|
|
67
|
+
`BOUNTY_LAUNCH_ADMIN_KEY` should hold a LANE-NAMED relay key (a
|
|
68
|
+
`LAUNCH_RELAY_NAMED_KEYS` entry minted for this CLI on the backend), never the
|
|
69
|
+
platform admin key: one named key per lane keeps usage attributable and
|
|
70
|
+
revocable without touching anything else.
|
|
71
|
+
|
|
72
|
+
## Launch trading desk (Solana devnet)
|
|
73
|
+
|
|
74
|
+
`bounty desk` is the same lane through the on-chain desk program
|
|
75
|
+
(`launch_desk_sol`): credits live in per-owner vaults on chain, and trading
|
|
76
|
+
authority is a SESSION key whose bounds the program itself enforces — a
|
|
77
|
+
per-trade cap on buys, an expiry, owner-only exit, instant revoke. Two local
|
|
78
|
+
keys with two roles: the agent trading key (`~/.agentgates/trade-sol.json`) is
|
|
79
|
+
the OWNER and signs deposits, withdrawals and session ceremonies; a second
|
|
80
|
+
locally generated keypair (`~/.agentgates/desk-session-sol.json`) is the SESSION
|
|
81
|
+
and signs buys and sells only. An over-cap, expired, wrong-key or revoked
|
|
82
|
+
trade refuses on chain in the broadcast's preflight simulation — the CLI just
|
|
83
|
+
surfaces the program's own refusal. Neither key ever needs SOL; withdrawals
|
|
84
|
+
pay only the owner's own token accounts.
|
|
85
|
+
|
|
86
|
+
```sh
|
|
87
|
+
bounty desk deposit 5 # owner's USDC → its desk vault (confirmed on chain)
|
|
88
|
+
bounty desk session register --cap 2 --minutes 30 # YOUR bounds, required — the chain enforces them
|
|
89
|
+
bounty desk buy SLFYB 1.5 # session signs; over-cap refuses on chain
|
|
90
|
+
bounty desk sell SLFYB 50% # % resolves from the live state read; also amount / "all"
|
|
91
|
+
bounty desk status [--coin SLFYB] [--json] # live credits + the session's key, cap, expiry + recent fills
|
|
92
|
+
bounty desk status --coin SLFYB --fills 100 # --coin filters the fills; --fills sets the count served
|
|
93
|
+
bounty desk session revoke # closes the session on chain — pre-signed trades die too
|
|
94
|
+
bounty desk withdraw all [--coin SLFYB] # exit to the owner's own token account
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
`status` also prints the desk's recent FILLS — the settled buys and sells the
|
|
98
|
+
backend indexed for this owner, newest first, money exactly as the wire serves
|
|
99
|
+
it (decimal strings and exact native units; a coin amount appears only when
|
|
100
|
+
the backend knows the coin's decimals). `--coin` filters them to one coin;
|
|
101
|
+
`--fills <n>` asks the wire for that many (its default and cap are
|
|
102
|
+
server-owned). A backend that does not serve the history read yet gets an
|
|
103
|
+
honest "not available", never an empty list.
|
|
104
|
+
|
|
105
|
+
## Keywords
|
|
106
|
+
|
|
107
|
+
crypto, wallet, cli, ai-agent, agentgates, usdc, solana, ethereum, polygon, base, arbitrum, defi, aave, kamino
|