question

briannguyen avatar image
briannguyen asked clarkm answered

How can setup Token to getting deposits (MID) Permission?

Document Link: https://docs.clover.com/docs/funding-examples
clover01.jpg
So, How can I setup Token to get Deposit Permission?
(I ask the same question 4 months ago, but I didn't get the answer: https://community.clover.com/questions/57254/get-close-batch-unauthorized.html)
Please help me, thank you so much!

API Token
clover01.jpg (218.4 KiB)
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
clarkm avatar image
clarkm answered

If you ever used a DApp on Ethereum there’s a very high chance you have approved an ERC20 token to be used by a smart contract.

Approvals are first and foremost a technical solution: We first approve the contract for the token, then call the DApp like Tiktok video downloader contract which calls the transferFrom function.
Simply put: Contracts can’t know when a token is transferred to them. Instead, we give the contract the right to take the tokens by itself.

To deposit tokens on your favorite lending DApp you would first approve the DApp’s contract with the amount you want to deposit and then call the deposit function that will move your token to the DApp contract.

10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community