feat(cli): wire invoke and account commands to native flows - #54
Merged
P3az3 merged 1 commit intoJul 28, 2026
Merged
Conversation
…neX#34) - handle_invoke: replace stub with full stellar contract invoke shell-out - resolves CONTRACT_ID from env var, SOROBAN_CONTRACT_ID, or .milestonex_contract_id - resolves source from SOROBAN_SOURCE or STELLAR_SECRET_KEY - validates JSON args via serde_json before passing to stellar-cli - prints friendly usage with canonical campaign contract method list - handle_account: upgrade deprecation from warning line to prominent banner box - account create → transparently delegates to keypair generate-master - account fund → transparently delegates to keypair fund - docs/deployment.md: update CLI status table - invoke:⚠️ Stub → ✅ Implemented with env var instructions - account rows: reflect 'deprecation banner' and 'Transparently delegates' - README.md: remove invoke from stub list, update quick-start Step 4 Closes MillestoneX#34
Contributor
|
@peterexcel494-oss resolve conflicts |
Contributor
Author
|
@P3az3 Please kindly review |
1 similar comment
Contributor
Author
|
@P3az3 Please kindly review |
Contributor
Author
|
@P3az3 Please kindly review........ |
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.
Summary
Closes #34
Wires up the two remaining CLI stubs identified in issue #34 so they call into native Stellar/Soroban tooling instead of printing "NOT yet implemented" banners.
What changed
milestonex-cli invoke <method> [args...]— was a stub, now fully wiredstellar contract invokewith the correct flags.CONTRACT_IDenv var →SOROBAN_CONTRACT_ID→.milestonex_contract_idfile written bymake deploy-testnet.SOROBAN_SOURCE→STELLAR_SECRET_KEY.SOROBAN_NETWORK(default:testnet).serde_jsonto validate JSON args before passing to stellar-cli; warns if an arg looks like malformed JSON.milestonex-campaignanalytics methods (version,get_dashboard_metrics,get_campaign_report,get_platform_summary, etc.).milestonex-cli account— upgraded deprecation + transparent delegationaccount create→ transparently delegates tokeypair generate-master(with banner).account fund <addr> <xlm>→ transparently delegates tokeypair fund(with banner).keypairnamespace.docs/deployment.mdCLI status tableinvoke <method>account/account create/account fundREADME.mdinvokefrom the list of stubs.milestonex-cli invoke versionandmilestonex-cli invoke get_dashboard_metrics 1directly.invokeas a stub command.Acceptance criteria (issue #34)
invokeworks againstCampaignContract::versionandCampaignContract::get_dashboard_metrics(wired tostellar contract invokewhich targets the canonical campaign contract).account create|fundaliases transparently tokeypair generate-master|fundwith deprecation warning.docs/deployment.md+print_available_commands()inmain.rs).Affected files
crates/tools/src/main.rsdocs/deployment.mdREADME.mdDependencies
Depends on the
serde_jsoncrate, which was already present incrates/tools/Cargo.toml. No new dependencies added.Closes #34