Adds farcaster signer for a given user. Helpful if you want to cover the gas fee for a user.
import { addSignerFor } from "thirdweb/extensions/farcaster";import { sendTransaction } from "thirdweb"; const transaction = addSignerFor({ client, appAccount, userAccount, signerPublicKey,}); await sendTransaction({ transaction, account });
function addSignerFor( options: AddSignerForParams,): PreparedTransaction<[], AbiFunction, PrepareTransactionOptions>;
The options for adding the signer.
let options: Prettify< { chain?: Chain; client: ThirdwebClient; disableCache?: boolean; signerPublicKey: Hex; } & ( | { appAccount: Account } | { appAccountAddress: Address; deadline: bigint; signedKeyRequestMetadata: Hex; } ) & ( | { userAccount: Account } | { addSignature: Hex; deadline: bigint; userAddress: Address } )>;
let returnType: PreparedTransaction< [], AbiFunction, PrepareTransactionOptions>;
A prepared transaction object to add the signer to the account.