Skip to main content
When a user sends a message that mentions a product, ChatAds extracts the keyword, scores purchase intent, and returns an affiliate link you can embed in the AI response.
Y
You
What are the best earbuds for commuting?
AI
AI Assistant

The Bose QuietComfort Ultra earbuds are great for commuting. They have solid noise cancellation and a comfortable fit. Battery life is around six hours, which is enough for most people.

Overview

Text search is the default mode (input_type: "text"). Send the AI’s response to ChatAds, and it will find product mentions, match them to affiliate offers, and return links you can insert back into the response before showing it to the user. No special parameters are needed — just pass the message field and ChatAds handles extraction and resolution automatically.
Currently ChatAds extracts 1 keyword per message, using a proprietary algorithm to determine the term most likely to convert.

How It Works

  1. Extract — ChatAds identifies product mentions in the text (e.g., “Bose QuietComfort Ultra earbuds”)
  2. Score — Each mention is scored for purchase intent and confidence using signals like brand detection, model patterns, and context
  3. Resolve — High-confidence mentions are matched to affiliate product listings
  4. Return — The API returns link_text (the exact phrase to hyperlink) and a url (the affiliate link)

Parameters

Only message is required — the defaults work well for most use cases. See the API Reference for the full list of parameters.
Average response time is 200ms, with general ranges of 50ms-500ms based on message complexity. You can use extraction and resolution modes to speed this up.

Response

{
  "data": {
    "status": "filled",
    "offers": [
      {
        "link_text": "Bose QuietComfort Ultra earbuds",
        "url": "https://amazon.com/dp/B0CD2FSRDD/?tag=yourtag-20",
        "product": {
          "title": "Bose QuietComfort Ultra Bluetooth Earbuds...",
          "stars": 3.8,
          "reviews": 9765
        }
      }
    ],
    "requested": 1,
    "returned": 1,
    "billed": true
  },
  "error": null,
  "meta": {
    "request_id": "bda67e29-a38a-47e0-b459-40a38475cf91"
  }
}
The link_text field tells you which phrase in the AI response to hyperlink. Replace it with a link to the url: Before:
The Bose QuietComfort Ultra earbuds are great for commuting.
After:
The Bose QuietComfort Ultra earbuds are great for commuting.
The link_text is an exact substring of the original message, so a simple string replace works in most cases.

Next Steps

Products in Images

Analyze product images for affiliate links

No Offers

Diagnose why the API returns no offers

API Reference

Full endpoint documentation