Skip to content

feat: update mainnet fastUSD defaultToken tokenId#105

Merged
KcatMa merged 2 commits into
developfrom
feat/cli-mainnet-default-usdc
May 26, 2026
Merged

feat: update mainnet fastUSD defaultToken tokenId#105
KcatMa merged 2 commits into
developfrom
feat/cli-mainnet-default-usdc

Conversation

@KcatMa

@KcatMa KcatMa commented May 25, 2026

Copy link
Copy Markdown
Contributor

Summary

Update the bundled mainnet defaultToken tokenId. The user-facing symbol stays fastUSD; only the underlying on-Fast tokenId changes.

  • symbol: "fastUSD" (unchanged from main)
  • tokenId: 0x125b60bb2e805336f0934077d4f9fdb36f45bec9ded8d7b0e637516cc43a86eb0xc655a12330da6af361d281b197996d2bc135aaed3b66278e729c2222291e9130

Behavior change: CLI commands that resolve the network's default token without an explicit --token flag (e.g. fast send, fast info balance) and any --token fastUSD invocations on mainnet now operate against the new tokenId. The dedicated fast fund fastusd command is unaffected. Testnet default (testUSDC) is unchanged.

Scope

  • packages/fast-sdk/src/networks/mainnet.ts — production default tokenId swap (+ line-wrap to fit biome's max width)
  • packages/fast-sdk/src/networks/types.ts — JSDoc untouched in net (briefly flipped to USDC then back to fastUSD)
  • app/cli/src/services/token-resolver.ts — comment lightly updated
  • app/cli/tests/schemas/networks.test.tstokenId regex assertion updated to /^0xc655a123/; symbol assertion stays fastUSD
  • .changeset/mainnet-fastusd-tokenid.md — patch bump for @fastxyz/sdk and @fastxyz/cli

Test fixtures (app/cli/tests/fixtures/networks.ts) intentionally keep fastUSD as their fictional default — they exercise resolver/lookup code paths and are decoupled from production config. No other tests need updates.

History on this branch

Two commits:

  1. 55a1712 — original change: swapped both symbol and tokenId (fastUSDUSDC, 0x125b...0xc655...).
  2. 37e62af — reversed the symbol back to fastUSD while keeping the new tokenId.

Net effect vs main is the single-line tokenId update described above.

Test plan

  • pnpm --filter @fastxyz/sdk build — passes
  • pnpm --filter @fastxyz/sdk test — green
  • pnpm --filter @fastxyz/cli build — passes
  • pnpm --filter @fastxyz/cli test — 54 passing
  • Manual: pnpm cli --network mainnet send fast1abc 10 (dry-run) — resolves to fastUSD against the new tokenId
  • Manual: pnpm cli --network mainnet send fast1abc 10 --token fastUSD — same result as implicit default

KcatMa added 2 commits May 25, 2026 18:25
Swap the bundled mainnet defaultToken from fastUSD (0x125b...86eb) to
USDC (0xc655...9130).

Behavior change for any CLI command that resolves the network's default
token without an explicit --token (e.g. `fast send`, `fast info balance`):
on mainnet they now default to USDC. Scripts relying on the implicit
fastUSD default must add `--token fastUSD` explicitly. The dedicated
`fast fund fastusd` command is unaffected. Testnet (testUSDC) unchanged.

Test fixtures intentionally keep fastUSD as their fictional default —
they exercise the resolver/lookup code paths and are decoupled from
production config.
Reverse the symbol change in the previous commit on this branch while
keeping the new tokenId. The bundled mainnet defaultToken is now:

  symbol  = "fastUSD"   (unchanged from main)
  tokenId = 0xc655...9130 (the value introduced by the prior commit)

Net effect vs main: only the tokenId of the mainnet defaultToken is
updated; the symbol that users type with --token fastUSD stays the same.
Testnet default (testUSDC) is unchanged.
@KcatMa KcatMa requested review from kaichii and xc93 May 26, 2026 14:01
@KcatMa KcatMa changed the title feat: change mainnet default token from fastUSD to USDC feat: update mainnet fastUSD defaultToken tokenId May 26, 2026

@xc93 xc93 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@KcatMa KcatMa merged commit 663cbfe into develop May 26, 2026
2 checks passed
@KcatMa KcatMa deleted the feat/cli-mainnet-default-usdc branch May 26, 2026 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants