@thirdfy/agent-cli 0.2.60 → 0.2.61

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/CHANGELOG.md CHANGED
@@ -4,6 +4,12 @@ All notable changes to `@thirdfy/agent-cli` are documented here. The format is b
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.2.61] - 2026-09-06
8
+
9
+ ### Fixed
10
+
11
+ - `resolveTokenInForFunding` no longer uses `tokenAddress` for `withdraw_earn_position` and `claim_earn_rewards`. Those actions receive the asset; the wallet does not need to already hold it. Earn deposits still fund from `tokenAddress`. Pairs with `thirdfy-mcp` **0.0.109**.
12
+
7
13
  ## [0.2.60] - 2026-09-05
8
14
 
9
15
  ### Changed
package/README.md CHANGED
@@ -40,10 +40,10 @@ Run without global install:
40
40
  npx @thirdfy/agent-cli --help
41
41
  ```
42
42
 
43
- ## What's new in v0.2.60
43
+ ## What's new in v0.2.61
44
44
 
45
- - basedbid buy and sell are live on Base, Ethereum, and Robinhood Chain.
46
- - Buy spends native ETH on the target chain. `tokenAddress` is the listing, not the funding token.
45
+ - Vault withdraw and claim no longer treat the received asset as the funding token.
46
+ - A fully deployed earn position can exit even when the wallet holds none of that asset.
47
47
  - See [CHANGELOG.md](./CHANGELOG.md) and GitHub Releases for older versions.
48
48
 
49
49
  ## Quick start
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thirdfy/agent-cli",
3
- "version": "0.2.60",
3
+ "version": "0.2.61",
4
4
  "description": "Thirdfy Agent CLI for onboarding, governance preflight, execute-intent, and status polling.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -11,12 +11,22 @@ const NATIVE_ETH_SPEND_ACTIONS = new Set([
11
11
  'basedbid_create_board',
12
12
  ]);
13
13
 
14
+ /**
15
+ * Position exits receive `tokenAddress` from the protocol instead of spending it from the wallet.
16
+ * A vault withdraw funded entirely by vault shares would otherwise block on a zero wallet balance.
17
+ */
18
+ const POSITION_EXIT_ACTIONS = new Set([
19
+ 'withdraw_earn_position',
20
+ 'claim_earn_rewards',
21
+ ]);
22
+
14
23
  export function resolveTokenInForFunding(params, action) {
15
24
  if (!params || typeof params !== 'object') return '';
16
25
  const explicit = String(params.tokenIn || '').trim();
17
26
  if (explicit) return explicit;
18
27
  const actionId = normalizeActionKey(action);
19
28
  if (NATIVE_ETH_SPEND_ACTIONS.has(actionId)) return '';
29
+ if (POSITION_EXIT_ACTIONS.has(actionId)) return '';
20
30
  if (params.amountEth != null && String(params.amountEth).trim() !== '') return '';
21
31
  return String(params.tokenAddress || params.token || '').trim();
22
32
  }