Fetch attribute status and PII consent data for a wallet address, to determine if attributes need to be claimed or privacy needs to be consented.
Parameters
SDK Configuration
See API Onboard Status for more information about the underlying API endpoint.
Example
importtype { API } from'@quadrata/sdk/types';import { fetchOnboardStatus, parseOnboardStatus, QuadrataAttribute, QuadrataEnvironment, QuadrataNetwork, QuadrataPrivacyConsent} from'@quadrata/sdk/api';typeResponseType=API.Service.FetchOnboardStatus.Response;typeParsedResponseType=API.Service.FetchOnboardStatus.ParsedResponse;constresponse:ResponseType=awaitfetchOnboardStatus( { apiAccessToken:'jwt token from createAccessToken',// optional, if provided in config attributes: [QuadrataAttribute.AML,QuadrataAttribute.DID, ],// optional, if provided in config as network chainId:QuadrataNetwork.MAINNET,// optional, unless you are checking for accrediation re-attestation offeringId:'123',// optional, if provided in config privacyScopes: [QuadrataPrivacyConsent.EMAIL,QuadrataPrivacyConsent.DATE_OF_BIRTH, ], walletAddress:'0x123', options: {// optional fetch options cache:'no-cache' } }, {// optional, if provided in above params attributes: [QuadrataAttribute.AML,QuadrataAttribute.DID ],// required environment:QuadrataEnvironment.PRODUCTION,// optional, if provided in above params network:QuadrataNetwork.MAINNET,// optional, if provided in above params privacyScopes: [QuadrataPrivacyConsent.EMAIL,QuadrataPrivacyConsent.DATE_OF_BIRTH, ], });/* parse the response */constisBypassMint=false; // or trueconststatus:ParsedResponseType=parseOnboardStatus(response, isBypassMint);// status.attributesToClaim// status.isConsentNeeded// status.isInReview