Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Calling contract with arguments documentation #472

Closed
guudc opened this issue Oct 11, 2023 · 3 comments
Closed

Calling contract with arguments documentation #472

guudc opened this issue Oct 11, 2023 · 3 comments

Comments

@guudc
Copy link

guudc commented Oct 11, 2023

The docs does not shows how to pass arguements to contracts method via the soroban js client.

It has only one scenario of a contract method call without arguments.

Could anyone assist me with how to pass arguements to a contract method via the soroban js client.

@Shaptic
Copy link
Contributor

Shaptic commented Dec 22, 2023

The parameters to stellar-sdk's Contract.call (as well as Operation.invokeContractFunction are individual ScVals. You can create these by hand (see the static methods in the XDR definition) or via helpers like nativeToScVal or ScInt.

@janewang janewang transferred this issue from stellar-deprecated/soroban-docs Apr 16, 2024
@janewang janewang added the help wanted Extra attention is needed label Apr 25, 2024
@janewang
Copy link
Contributor

@guudc Any interest in provide an update to the example to pass an arg to increment?

@briwylde08 briwylde08 removed the help wanted Extra attention is needed label Jan 7, 2025
@briwylde08
Copy link
Contributor

Note to link to JS docs from our docs

@github-project-automation github-project-automation bot moved this from Backlog to Done in Dev Docs Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

5 participants
@janewang @Shaptic @guudc @briwylde08 and others