Class EIP712
- Namespace
- Thirdweb
- Assembly
- Thirdweb.dll
Provides methods for generating and signing EIP712 compliant messages and transactions.
public static class EIP712
- Inheritance
-
EIP712
- Inherited Members
Methods
GenerateSignature_MinimalForwarder(string, string, BigInteger, string, Forwarder_ForwardRequest, IThirdwebWallet)
Generates a signature for a minimal forwarder request.
public static Task<string> GenerateSignature_MinimalForwarder(string domainName, string version, BigInteger chainId, string verifyingContract, Forwarder_ForwardRequest forwardRequest, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
forwardRequest
Forwarder_ForwardRequestThe forward request.
signer
IThirdwebWalletThe wallet signer.
Returns
GenerateSignature_SmartAccount(string, string, BigInteger, string, SignerPermissionRequest, IThirdwebWallet)
Generates a signature for a smart account permission request.
public static Task<string> GenerateSignature_SmartAccount(string domainName, string version, BigInteger chainId, string verifyingContract, SignerPermissionRequest signerPermissionRequest, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
signerPermissionRequest
SignerPermissionRequestThe signer permission request.
signer
IThirdwebWalletThe wallet signer.
Returns
GenerateSignature_SmartAccount_AccountMessage(string, string, BigInteger, string, byte[], IThirdwebWallet)
Generates a signature for a smart account message.
public static Task<string> GenerateSignature_SmartAccount_AccountMessage(string domainName, string version, BigInteger chainId, string verifyingContract, byte[] message, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
message
byte[]The message to sign.
signer
IThirdwebWalletThe wallet signer.
Returns
GenerateSignature_TokenERC1155(string, string, BigInteger, string, TokenERC1155_MintRequest, IThirdwebWallet)
Generates a signature for an ERC1155 token mint request.
public static Task<string> GenerateSignature_TokenERC1155(string domainName, string version, BigInteger chainId, string verifyingContract, TokenERC1155_MintRequest mintRequest, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
mintRequest
TokenERC1155_MintRequestThe mint request.
signer
IThirdwebWalletThe wallet signer.
Returns
GenerateSignature_TokenERC20(string, string, BigInteger, string, TokenERC20_MintRequest, IThirdwebWallet)
Generates a signature for an ERC20 token mint request.
public static Task<string> GenerateSignature_TokenERC20(string domainName, string version, BigInteger chainId, string verifyingContract, TokenERC20_MintRequest mintRequest, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
mintRequest
TokenERC20_MintRequestThe mint request.
signer
IThirdwebWalletThe wallet signer.
Returns
GenerateSignature_TokenERC721(string, string, BigInteger, string, TokenERC721_MintRequest, IThirdwebWallet)
Generates a signature for an ERC721 token mint request.
public static Task<string> GenerateSignature_TokenERC721(string domainName, string version, BigInteger chainId, string verifyingContract, TokenERC721_MintRequest mintRequest, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
mintRequest
TokenERC721_MintRequestThe mint request.
signer
IThirdwebWalletThe wallet signer.
Returns
GenerateSignature_ZkSyncTransaction(string, string, BigInteger, ZkSyncAATransaction, IThirdwebWallet)
Generates a signature for a zkSync transaction.
public static Task<string> GenerateSignature_ZkSyncTransaction(string domainName, string version, BigInteger chainId, ZkSyncAATransaction transaction, IThirdwebWallet signer)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
transaction
ZkSyncAATransactionThe zkSync transaction.
signer
IThirdwebWalletThe wallet signer.
Returns
GetTypedDefinition_MinimalForwarder(string, string, BigInteger, string)
Gets the typed data definition for a minimal forwarder request.
public static TypedData<Domain> GetTypedDefinition_MinimalForwarder(string domainName, string version, BigInteger chainId, string verifyingContract)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
Returns
- TypedData<Domain>
The typed data definition.
GetTypedDefinition_SmartAccount(string, string, BigInteger, string)
Gets the typed data definition for a smart account permission request.
public static TypedData<Domain> GetTypedDefinition_SmartAccount(string domainName, string version, BigInteger chainId, string verifyingContract)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
Returns
- TypedData<Domain>
The typed data definition.
GetTypedDefinition_SmartAccount_AccountMessage(string, string, BigInteger, string)
Gets the typed data definition for a smart account message.
public static TypedData<Domain> GetTypedDefinition_SmartAccount_AccountMessage(string domainName, string version, BigInteger chainId, string verifyingContract)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
Returns
- TypedData<Domain>
The typed data definition.
GetTypedDefinition_TokenERC1155(string, string, BigInteger, string)
Gets the typed data definition for a TokenERC1155 mint request.
public static TypedData<Domain> GetTypedDefinition_TokenERC1155(string domainName, string version, BigInteger chainId, string verifyingContract)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
Returns
- TypedData<Domain>
The typed data definition.
GetTypedDefinition_TokenERC20(string, string, BigInteger, string)
Gets the typed data definition for a TokenERC20 mint request.
public static TypedData<Domain> GetTypedDefinition_TokenERC20(string domainName, string version, BigInteger chainId, string verifyingContract)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
Returns
- TypedData<Domain>
The typed data definition.
GetTypedDefinition_TokenERC721(string, string, BigInteger, string)
Gets the typed data definition for a TokenERC721 mint request.
public static TypedData<Domain> GetTypedDefinition_TokenERC721(string domainName, string version, BigInteger chainId, string verifyingContract)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
verifyingContract
stringThe verifying contract.
Returns
- TypedData<Domain>
The typed data definition.
GetTypedDefinition_ZkSyncTransaction(string, string, BigInteger)
Gets the typed data definition for a zkSync transaction.
public static TypedData<DomainWithNameVersionAndChainId> GetTypedDefinition_ZkSyncTransaction(string domainName, string version, BigInteger chainId)
Parameters
domainName
stringThe domain name.
version
stringThe version.
chainId
BigIntegerThe chain ID.
Returns
- TypedData<DomainWithNameVersionAndChainId>
The typed data definition.