Get Started in Minutes
Follow these simple steps to integrate ReferralAny and start your affiliate program.
Create Your Account
Register as a merchant to get started
Visit the registration page and sign up as a merchant. You'll need to provide:
Create Your Program
Set up your affiliate program details
After logging in, navigate to Dashboard → Programs and click "Create Program".
Get Your API Key
Retrieve your credentials for integration
Navigate to Dashboard → Settings to find your API key. You'll need this for tracking conversions.
Install the SDK
Add tracking to your website
Add our tracking script to your website's <head> section:
<script src="https://www.referralany.com/sdk.js"></script>
<script>
ReferralAny.init({
apiKey: 'YOUR_API_KEY',
baseUrl: 'https://www.referralany.com',
debug: false // Set to true for console logging
});
</script>How It Works
Track Conversions
Record successful sales and sign-ups
JavaScript SDK
Track conversions when a purchase is made:
// Call this after a successful purchase
ReferralAny.trackConversion({
orderId: 'ORDER_123', // Required: unique order ID
amount: 99.99, // Required: order amount
currency: 'USD', // Optional: currency code
customerEmail: 'user@example.com' // Optional: for attribution
}, function(err, result) {
if (err) console.error('Tracking failed:', err);
else console.log('Conversion tracked:', result);
});REST API
Send conversion data directly from your server:
POST https://www.referralany.com/api/conversions
Content-Type: application/json
X-API-Key: YOUR_API_KEY
{
"externalId": "ORDER_123",
"amount": 99.99,
"currency": "USD",
"referralCode": "ABC123",
"customerEmail": "customer@example.com"
}Use X-API-Key header for authentication. Get your API key from Dashboard → Settings.
Stripe Integration
Pass the referral code to Stripe Checkout:
// When creating Stripe Checkout Session
const session = await stripe.checkout.sessions.create({
mode: 'payment',
line_items: [...],
success_url: 'https://yoursite.com/success',
// Pass referral code for attribution
client_reference_id: referralCode,
metadata: {
referralCode: referralCode
}
});Then set up webhook in Dashboard → Settings → Integrations.
Invite Affiliates
Grow your affiliate network
There are several ways to invite affiliates to your program:
Share Registration Link
Share your unique program link from Dashboard → Programs:
https://referralany.com/join/YOUR_PROGRAM_IDEmail Invitation
Go to Dashboard → Affiliates → "Invite Affiliate" and enter their email.
Public Applications
Enable public applications in settings. Affiliates apply and you approve them.
You're All Set!
Your affiliate program is ready to go. Need help with anything?