Repository navigation
Add stellar token transfer-from command - #2743
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
No unresolved review issues were identified.
Review effort: Lite
Findings: None
What changed in this PR
Adds stellar token transfer-from for SEP-41 delegated token transfers using allowances.
Changes:
- Implements spender-signed transfers with account, contract, and alias resolution.
- Registers the command and structured JSON errors.
- Adds documentation and integration tests.
| File | Description |
|---|---|
FULL_HELP_DOCS.md |
Documents the new command. |
cmd/soroban-cli/src/commands/token/transfer_from.rs |
Implements delegated transfers. |
cmd/soroban-cli/src/commands/token/mod.rs |
Registers the command and errors. |
cmd/soroban-cli/src/cli.rs |
Enables JSON error formatting. |
cmd/crates/soroban-test/tests/it/integration/token/transfer_from.rs |
Adds integration coverage. |
cmd/crates/soroban-test/tests/it/integration/token/mod.rs |
Registers integration tests. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
fnando
added this pull request to stack #2745
September 22, 2026 17:03
fnando
force-pushed
the
token-transfer-from
branch
from
September 22, 2026 17:12
310c5e1 to
5bcf7ad
Compare
leighmcculloch
approved these changes
Sep 22, 2026
fnando
force-pushed
the
token-transfer-from
branch
from
September 22, 2026 23:25
5bcf7ad to
30e6aae
Compare
fnando
force-pushed
the
token-transfer-from
branch
from
September 22, 2026 23:27
30e6aae to
ff7c374
Compare
4 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a new
stellar token transfer-fromsubcommand, implementing SEP-41'stransfer_from(spender, from, to, amount). A spender who holds an allowance (granted viatoken approve) can move tokens out of an owner's balance to a destination. The spender signs and authorizes;--fromis the owner whose funds move and--tois the recipient. Both accept aG…/M…account, aC…contract, or an alias.Why
stellar tokencovered 7 of SEP-41's 10 interface functions, but nottransfer_from, so delegated transfers via an allowance weren't possible from the CLI.Known limitations
Muxed (
M…) source accounts are rejected up front for--spender, matchingtoken transfer/approve, since the invoke pipeline can't yet source a transaction from a muxed account (#2645).