This method updates/creates a user and an account and returns the user object representing that newly created user/account.
You can provide vanity referral codes and sharelinks in a user upsert. Make sure to check the tenant setting allowReferralCodeEditOnUserUpsert, if it is set to FALSE then referral codes added when upserting an existing user will be ignored. New sharelinks and referral codes will be set as primary for the upserted user. If a referral code is passed without an associated sharelink for that program, then one will be generated and vice versa for sharelinks.
Because this call creates a user, it requires either a write token or an API key.