Learn how to send USDC or execute a contract from a user-controlled wallet with social logins or email authentication
This guide outlines how to initiate a currency transfer or execute a contract
from a previously created user-controlled wallet with social logins or email
authentication. To create a wallet, see
Create Your First Wallet with Social Logins
or
Create Your First Wallet with Email.If you’re building with the Signing API, you must
manage the transaction broadcasting and indexing with your blockchain
infrastructure.
Using id which you just copied, send a GET request to the
/wallet/{id}/balances endpoint to check your wallet’s token balance.
From the response, copy and store the tokenId that you intend to transfer.
To create a transaction that executes a smart contract:
Include walletId and contractAddress in a POST request to the
/user/transactions/contractExecution endpoint.
From the response, copy challengeId and enter it in the sample app.
If you do not have a wallet to use as a destination for the transfer, you can
create another user-controlled wallet or send funds to any other blockchain
wallet such as Metamask.
To authorize a transfer on the sample app’s confirmation UI, ensure you have
obtained an active user token and encryption key.
From the Execute Challenge screen in the sample app, paste the Challenge ID
that you copied from the previous step and select Execute.
The sample app displays a confirmation UI that contains transaction details
for the user to confirm. You can customize confirmation UIs. For more, see
Confirmation UIs .
As the transfer transaction’s state changes and ultimately completes, Circle
sends webhook notifications to a
subscriber endpoint. For a list of all
possible states, see
Asynchronous States and Statuses.The following code sample shows an example of a webhook notification for a
transfer.