You can also filter out this information for a specific user by passing on the user_address, dates with the from and to parameters, type of users with user_type and spefific conversions with their ids.
import { Fuul } from ('@fuul/sdk');awaitFuul.getPointsLeaderboard({ user_address:'0x12345', from:newDate('2021-01-01'), to:newDate('2022-01-01'), user_type:'all',// all, affiliate or end_user conversions:'1,2,3'});
You can retrieve the tier and the volume information of users by adding them on the fields parameter as follows:
import { Fuul } from ('@fuul/sdk');awaitFuul.getPointsLeaderboard(fields: 'tier,referred_volume');
The referred_volume parameter will be returned in USD values.
Points for a specific address per conversion
To get all points for an address use the getUserPointsByConversion method.
import { Fuul } from ('@fuul/sdk');awaitFuul.getUserPointsByConversion({ user_address:'0x12345' });
You can also filter out dates as follows:
import { Fuul } from ('@fuul/sdk');awaitFuul.getUserPointsByConversion({ user_address:'0x12345', from:newDate('2021-01-01'), to:newDate('2022-01-01'),});
A simple response for retrieving this information would be the following: