estimateTaxAndRoyaltyFee

This mutation is called to get the tax and royalty fees for the NFT.

Sample mutation

mutation estimateTaxAndRoyaltyFee(
  $orderId: UUID1, 
  $orgId: UUID1!, 
  $nftTokenId: UUID1,
  $price: Float, 
  $currencyID: UUID1, 
  $estimateType: TaxEstimateType!, 
  $country: String, 
  $postalCode: String, 
  $currency: CurrencyCodeFiat
) {
  estimateTaxAndRoyaltyFee(
    orgId: $orgId
    orderId: $orderId
    nftTokenId: $nftTokenId
    price: $price
    estimateType: $estimateType
    country: $country
    postalCode: $postalCode
    currencyID: $currencyID
    currency: $currency
  ) {
    taxPercentage
    royaltyFee
    platformFee
    taxResponse {
      cryptoTaxPrice
      cryptoTotalPrice
      USDUnitprice
      taxPercentage
    }
  }
}

Sample variable

{
  "orgId": "8fb128bd-f55d-4bcc-8b6c-0beb684e4d4e",
  "nftTokenId": "97f7664d-92a6-4090-ae1d-cbd19a1342f0",
  "price": 1,
  "estimateType": "ListForSale"
}

Sample response

{
  "data": {
    "estimateTaxAndRoyaltyFee": {
      "taxPercentage": 0,
      "royaltyFee": 0,
      "platformFee": 2.5,
      "taxResponse": {
        "cryptoTaxPrice": 0,
        "cryptoTotalPrice": 1,
        "USDUnitprice": 1566.18,
        "taxPercentage": 0
      }
    }
  }
}

Arguments

NameTypeDescriptionRequired
orgIdUUIDThe organztion idYes
orderIdUUIDThe NFT listed or offered order id.No
nftTokenIdUUIDNft token idNo
priceFloatThe price for tax calculationYes
estimateTypeEnumThe estimate type such as ListForSale,BuyNow,MakeOffer,AcceptOffer.Yes
countryStringThe user country code .No
postalCodeStringPostal code of the userNo
currencyIdUUIDif the currency id it will fetch the currency and initiate the transaction else it from the backend picks the default payment currency.No
currencyEnumFiat currency units like USD or EUR.No

Fields

NameTypeDescription
taxPercentageFloatTax percentage of fixed price.
royaltyFeeFloatRoyalty fee of previous owners.
platformFeeFloatPlatform fee of the marketplace.
taxResponseObjectAn object that contains the TaxResponse such as fees.

Example

Load the estimated tax and royalty fee of the NFT.