Skip to content

getIsApprovedForAll

Returns the approval status of the spender for the owner's tokens.

Unlike fungible tokens, non-fungible tokens' allowance is not set on a per-token basis.

Usage

example.ts
import { mintclub } from 'mint.club-v2-sdk'
 
const isApproved = await mintclub.network('ethereum').nft('SYMBOL').getIsApprovedForAll({
	owner: '0x...',
	spender: '0x...'
})

Return Value

Promise<boolean>

Returns a promise that resolves to a boolean value indicating whether the spender is approved to spend the owner's tokens.

Parameters

owner

  • Type: '0x...${string}'

The address of the owner of the tokens. Usually the user's address.

import { mintclub } from 'mint.club-v2-sdk'
 
const isApproved = await mintclub.network('ethereum').nft('SYMBOL').getIsApprovedForAll({
	owner: '0x...', 
	spender: '0x...'
})

spender

  • Type: '0x...${string}'

The address of the spender of the tokens. Usually the contract that is allowed to spend the tokens on behalf of the owner.

import { mintclub } from 'mint.club-v2-sdk'
 
const isApproved = await mintclub.network('ethereum').nft('SYMBOL').getIsApprovedForAll({
	owner: '0x...', 
	spender: '0x...'
})