SnapLinker API

Programatically generate affiliate links for any merchant on the AvantLink network.

Free to use!

Link generation icon

Affiliate Links

Generate affiliate links with a simple HTTP request.

Search icon

Product Search

Search for products across multiple merchants and generate affiliate links automatically.

Tools icon

MCP Integration

Bring affiliate links to your AI using the Model Context Protocol.


Getting Started

Follow these simple steps to start using the SnapLinker API

1

Sign up for AvantLink

Log in to your AvantLink account or sign up to become an affiliate.

2

Install SnapLinker

Install SnapLinker from the AvantLink marketplace. This step is required even if you don't install the bookmarklet. It allows us to sync your merchant list with your AvantLink affiliate ID.

3

Find Your Affiliate ID

Make a note of your AvantLink affiliate ID. You can find it in the top right corner of the AvantLink dashboard.

Affiliate ID location
4

Start Making API Requests

Include your affiliate ID in all requests to the SnapLinker API. See examples below.


API Endpoints

Our RESTful API provides multiple ways to generate affiliate links

GET /avantlink/{YOUR_AVANTLINK_ID}

Generate Single Affiliate Link

Convert any product URL into a monetized affiliate link.

https://api.snaplinker.com/avantlink/{YOUR_AVANTLINK_ID}?url=http://www.example.com

Example Request:

https://api.snaplinker.com/avantlink/28861?url=https://www.competitivecyclist.com/

Example Response:


{
  "url": "https://www.avantlink.com/click.php?tt=app&ti=1019&mi=11465&pw=251821&url=https%3A%2F%2Fwww.competitivecyclist.com%2F"
}
          
POST /avantlinks/{YOUR_AVANTLINK_ID}

Generate Multiple Affiliate Links

Convert multiple URLs into monetized affiliate links with a single request.

https://api.snaplinker.com/avantlinks/{YOUR_AVANTLINK_ID}

Example Request:

POST https://api.snaplinker.com/avantlinks/28861
Content-Type: application/json

{
  "urls": [
    "https://www.competitivecyclist.com/",
    "https://www.backcountry.com/",
    "https://www.rei.com/"
  ]
}

Example Response:


{
  "urls": {
    "https://www.competitivecyclist.com/": "https://www.avantlink.com/click.php?tt=app&ti=1019&mi=11465&pw=251821&url=https%3A%2F%2Fwww.competitivecyclist.com%2F",
    "https://www.backcountry.com/": "https://www.avantlink.com/click.php?tt=app&ti=1019&mi=10421&pw=251821&url=https%3A%2F%2Fwww.backcountry.com%2F",
    "https://www.rei.com/": "https://www.avantlink.com/click.php?tt=app&ti=1019&mi=10248&pw=251821&url=https%3A%2F%2Fwww.rei.com%2F"
  }
}
          
GET avantlink/search/{YOUR_AVANTLINK_ID}

Search

Search all available products and return affiliate links

avantlink/search/{YOUR_AVANTLINK_ID}

Example Request:

https://snaplinker.com/avantlink/search?
POST /mcp/tools/execute

Model Context Protocol

AI-powered affiliate link management through the Model Context Protocol.

{"jsonrpc":"2.0","method":"tools/execute","params":{"id":"generate-affiliate-link","arguments":{"url":"...","avantlink_id":"..."}}}

Example Request:

{
  "jsonrpc": "2.0",
  "id": "1",
  "method": "tools/execute",
  "params": {
    "id": "generate-affiliate-link",
    "arguments": {
      "url": "https://www.competitivecyclist.com/",
      "avantlink_id": "28861"
    }
  }
}

Example Response:

{
  "jsonrpc": "2.0",
  "result": {
    "output": {
      "type": "object",
      "data": {
        "affiliateUrl": "https://www.avantlink.com/click.php?tt=app&ti=app_id&pw=28861&url=https%3A%2F%2Fwww.competitivecyclist.com%2F",
        "originalUrl": "https://www.competitivecyclist.com/"
      }
    }
  },
  "id": "1"
}

Simple Integration

Add just a few lines of code to your application to start generating affiliate links.

// JavaScript example - Single URL
fetch('https://snaplinker.com/avantlink/{YOUR_AFFILIATE_ID}?url=https://example.com/product')
  .then(response => response.json())
  .then(data => {
    console.log('Affiliate URL:', data.url);
  });
// JavaScript example - Multiple URLs
fetch('https://snaplinker.com/avantlinks/{YOUR_AFFILIATE_ID}', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    urls: [
      'https://example.com/product1',
      'https://example.com/product2',
      'https://otherstore.com/item'
    ]
  })
})
  .then(response => response.json())
  .then(data => {
    console.log('Affiliate URLs:', data.urls);
  });

Bulk Processing

Process multiple URLs in a single request with our bulk endpoint. Perfect for batch processing content or monetizing multiple links at once.

  • Efficient API Usage - Convert up to 100 URLs in a single request
  • Improved Performance - Reduce network overhead for multiple conversions
  • Simplified Integration - Easy JSON request/response format
  • Error Handling - Failed URLs will return the original URL

AI Powered

Use our Model Context Protocol integration to enable AI models to create affiliate links and search products directly. Perfect for content creation tools and AI assistants.

  • Generate Affiliate Links - Convert URLs to affiliate links
  • Product Search - Find products across multiple merchants
  • Context Management - Provide rich affiliate context to AI models
AI integration

Ready to Get Started?

Follow the steps above to get your AvantLink affiliate ID and start generating links today.