Skip to content

getAddressForFid

Returns the first verified address for a given Farcaster user's fid if available, falling back to their account custodyAddress if requested, otherwise returning null.

Usage

example.ts
import { getAddressForFid } from "frames.js"
 
const address = await getAddressForFid({
	fid: 1214,
	options: { fallbackToCustodyAddress: true }
});
console.log(address) // 0xdAa83039ACA9a33b2e54bb2acC9f9c3A99357618