Note that this page has not been updated to reflect the current state of Beanstalk, but is left here as a reference.
The Token Support Facet handles permits for ERC-20 and ERC-721 tokens and transfers for ERC-721 and ERC-1155 tokens.
permitERC20
is a wrapper function for permit of ERC20Permit token.
token
IERC20Permit
Token to permit.
owner
address
Owner of the token.
spender
address
Address to permit to spend the token.
value
uint256
Token amount to permit.
deadline
uint256
Expiration of signature (Unix time)
v
uint8
Recovery ID.
r
bytes32
ECDSA signature output.
s
bytes32
ECDSA signature output.
Execute an ERC-721 token transfer.
token
IERC721
Token address of the ERC-721.
to
address
Address being transferred to.
id
uint256
ID of ERC-721 token to transfer.
Execute a permit for an ERC-721 token.
token
IERC4494
Token address to permit.
spender
address
Address to permit to spend the token.
tokenId
uint256
ID of token
to permit.
deadline
uint256
Expiration of signature (Unix time).
sig
bytes
Execute an ERC-1155 token transfer of a single ID.
token
IERC1155
Token address of the ERC-1155.
to
address
Address being transferred to.
id
uint256
ID of the ERC-1155 token.
value
uint256
Number of the ERC-1155 tokens at id
to transfer.
Execute an ERC-1155 token transfer of multiple IDs.
token
IERC1155
Token address of the ERC-1155.
to
address
Address being transferred to.
ids
uint256[]
Array of IDs of the ERC-155 token.
values
uint256[]
Array of amounts of ERC-1155s at id
to transfer.
None.
None.
A valid secp256k1
or signature from owner of the tokenId
.