Use whatever format you want. Sharing a link is more convenient, but where you can't leave it, you can use a referral code. In both cases, the invited player will become your referral.