Add function to get total tokens for an SP