network marketing


I have a drupal webpage setup.

I want to add the ability to have a unilevel network marketing to it.  how can this be achieved with drupal?  i am sure there are modules out there already that can do something.

so i would need:

ability to allow new members to sell to clients who will become new members to resell to others (i guess some sort of tree showing who was recruited by whom?)  and some way of them signing up under that original member or recruiter.

commission they will receive based on their level of recruitment in the tree, of course based on sales.

ability to allow sales on the front end of the website to customers, and they should have to put in which member they are buying from (so that member gets paid commission for that sale)  so no public direct sales without putting a members id or code or name or something.

ability to set amount of recruits in a tree line a member can recruit.  so how many levels of payouts in the members tree.

i am not sure if someone has some other ideas that i am missing?

thank you

Drupal version: