Hi all, hope someone can help. I need to increase sales somehow.

I have a friend who is willing to be a commission-only sales rep for me. So, one idea I have had is to assign a simple code, for example "RAY10" that my friend (called Ray) can give to people, in the hopes of driving traffic & leading to sales.

The code RAY10 would achieve two things, offer the customer a 10% discount off their first order and also assign that customer to Ray, so any orders going forward, Ray would receive a commission on every order that customer places.

Does something like this already exist ? I think this is known as 'Affiliate Marketing'... ... ... ?
Can be commercial or free, i don't care, so long as it works and is easy to use.

I am sure y'all can tell I'm clueless about this subject. Thanks in advance, Isabella.