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

[Doc] How to send a token? For example USDC #20725

Closed
mahnunchik opened this issue Dec 23, 2024 · 5 comments · Fixed by #20779
Closed

[Doc] How to send a token? For example USDC #20725

mahnunchik opened this issue Dec 23, 2024 · 5 comments · Fixed by #20779
Assignees
Labels
doc-issue Issue submitted using the Doc issue template

Comments

@mahnunchik
Copy link

Ok, the documentation describes how to send a native coin. But I did not find documentation on how to send a token, for example, USDC.

I chose USDC as an example token because faucet is working well https://faucet.circle.com/

Once again, it looks like the wallet implementation is making an unnecessary merge
https://github.com/MystenLabs/sui/blob/main/apps/wallet/src/ui/app/pages/home/transfer-coin/utils/transaction.ts#L49-L60

I think it would be a good idea to add an example of simple and logical action to the documentation, like sending a token.

@mahnunchik mahnunchik added the doc-issue Issue submitted using the Doc issue template label Dec 23, 2024
@MystenLabs MystenLabs deleted a comment Dec 23, 2024
@stefan-mysten
Copy link
Contributor

Thanks, we'll try to add another example.

@rigwild
Copy link

rigwild commented Jan 5, 2025

It would be good to also have a Move smart contract example for tokens like USDC. The current Forge/Sword tutorial could be extended to create a shop selling swords for SUI or USDC.

@stefan-mysten
Copy link
Contributor

stefan-mysten commented Jan 6, 2025

@rigwild that's a good idea. We have this for now, but definitely something in the examples folder would help.

@mahnunchik this could help with how to transfer USDC: https://docs.sui.io/guides/developer/stablecoins#token-sending-logic

@mahnunchik
Copy link
Author

@stefan-mysten Thank you! It remains unclear what to do if there are not enough tokens in coins[0] object.

@stefan-mysten
Copy link
Contributor

@mahnunchik I am not sure I follow. If there are no coins, then you cannot transfer any object. Perhaps I am misunderstanding something. Happy to try to help if you have a more concrete example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc-issue Issue submitted using the Doc issue template
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants
@mahnunchik @rigwild @ronny-mysten @stefan-mysten and others