you are not infected. hbsag -
Sice you have already cleared hbsag and developed the anti bodies hbsab, then it is almost 100% sure that you also have cleared hbeag by developing hbeab. From your blood test, it is most likely you were infected with hepB virus sometime in the past, but then luckily, your body cleared the infection. So, you have nothing to worry about this disease. You may check the quantity of your hbsab to see if it is above the protective level of 10IU. If it is below this level, may be you need to take hepB vaccination to boost your hbsab level.
you are lucky you have immunity already and you don't have hepatitis b. Are you vaccinated or it was a past exposure to the virus.