Transfer tokens

Transfer tokens on Ethereum Virtual Machine

Ethereum
Ethereum
Base
Base

Acts onchain

Sends a token from the socket to another address, native or ERC-20. The native token address sends ETH by value; any other address calls the token's transfer. To send the full balance, read the socket's balance of the token earlier in the plug and coil it in as the amount. Reach for it to pay out proceeds after a swap or withdrawal, to fund another account from a scheduled plug, or to move a balance read earlier in the transaction by coiling that exact amount.

Plug lets you combine onchain actions like this one into a single transaction, without writing a smart contract. Use in App opens a new plug with this action already in it.

Send Token

plug
evm
time
10actions
  1. 1·Take

    Take opens by declaring token as a caller parameter, naming the asset this run reads and sends at execution time.

  2. 2·Get token balance

    Using that token, the balance held by Your Wallet is read, capturing the holding on hand before any transfer.

  3. 3·Bubble

    Surfacing that measured balance as an output of this plug hands the pre-transfer holding back to the caller.

  4. 4·Get token balance

    Reading the token balance held by Your Wallet a second time captures the holding at this point in the flow.

  5. 5·Bubble

    That second balance reading is surfaced as an output of this plug, returning the figure to the caller.

  6. 6·Take

    Next, amount is declared as a caller parameter, sizing how much of the token the transfer moves.

  7. 7·Take

    Following that, recipient is declared as a caller parameter, naming the address that receives the token.

  8. 8·Take

    Also taken is frequency, a caller parameter supplying the interval the rate limit below uses.

  9. 9·Repeat

    Capping cadence, this rate limit permits at most one run every frequency, so the schedule advances no more than once per that interval.

  10. 10·Transfer tokens

    On each run, amount of the token is transferred to recipient, sending the asset from the socket to that address.

Take
Get balance of held by
Bubble
Get balance of held by
Bubble
Take
Take
Take
Repeat up to x every
Transfer to
  • Send Token

    plug
    evm
    time
  • Rebalance Holdings to Target

    plug
    values
    evm
  • Swap at Floor

    plug
    evm
    values
  • Swap

    plug
    values
    evm
  • Morpho Pendle Expiry Deleveraging

    pendle
    time
    boolean
  • Aave: Wind or Unwind Position

    plug
    boolean
    aave
  • Wind

    plug
    aave
    evm
  • Unwind

    plug
    aave
    evm

Posts · 4

More on Ethereum Virtual Machine · 11