# CJ Affiliate API - Commission Junction Products & Feeds (`viralanalyzer/cj-affiliate-products`) Actor

Query CJ.com (Commission Junction) GraphQL API for affiliate products, 15k+ shopping product feeds, finance credit cards, travel experiences. You provide your own PAT + CID. Multi-vertical discovery.

- **URL**: https://apify.com/viralanalyzer/cj-affiliate-products.md
- **Developed by:** [viralanalyzer](https://apify.com/viralanalyzer) (community)
- **Categories:** Lead generation, E-commerce
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 item scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## 🛒 Amazon Brazil Intelligence — Products, Prices, Reviews & AI Analysis

> 🔗 [View on Apify Store](https://apify.com/viralanalyzer/amazon-brazil-intelligence) | 🇺🇸 English | [🇧🇷 Português](#português)

Scrape **Amazon.com.br products** with prices, ratings, reviews, seller data, and optional AI-powered market analysis. Search by keyword or provide direct product URLs. Extract detailed product information including Prime status, discounts, brand, categories, technical specifications, best seller rank, and customer reviews with sentiment analysis.

### ✨ Features

- **Product search** — Search any keyword on Amazon.com.br with pagination
- **Direct URL scraping** — Scrape specific product pages by ASIN or URL
- **Price intelligence** — Current price, original price, discount percentage, Prime status
- **Review extraction** — Customer reviews with ratings, dates, verified purchase badge, helpful votes
- **Product details** — Brand, categories, features, technical specifications, best seller rank
- **AI market analysis** — Optional Gemini-powered competitive analysis with pricing insights
- **Sorting & filtering** — Sort by relevance, price, rating, or newest; filter by price range and Prime
- **CAPTCHA handling** — Detects Amazon CAPTCHA pages and rotates sessions
- **Residential proxy** — Built-in proxy support with Brazil country targeting
- **Review sentiment** — Automatic sentiment classification (positive/mixed/negative) from review ratings

### 📥 Input

| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| `searchQuery` | string | Yes* | — | Product search term (e.g. "iPhone 15", "fone bluetooth") |
| `productUrls` | string[] | Yes* | `[]` | Direct Amazon.com.br product URLs to scrape |
| `category` | string | No | `""` | Amazon category filter |
| `maxProducts` | integer | No | 50 | Maximum number of products to scrape (1-500) |
| `includeReviews` | boolean | No | false | Scrape customer reviews for each product |
| `maxReviewsPerProduct` | integer | No | 10 | Maximum reviews per product (1-100) |
| `sortBy` | string | No | `"relevance"` | Sort: `relevance`, `price-asc`, `price-desc`, `rating`, `newest` |
| `minPrice` | number | No | 0 | Minimum price filter (R$) |
| `maxPrice` | number | No | 0 | Maximum price filter (R$, 0 = no limit) |
| `primeOnly` | boolean | No | false | Only return Prime-eligible products |
| `includeAiAnalysis` | boolean | No | false | AI-powered market analysis (requires GEMINI_API_KEY) |
| `proxyConfiguration` | object | No | Residential BR | Proxy settings for Amazon scraping |

*Either `searchQuery` or `productUrls` is required.

#### Input Example

```json
{
  "searchQuery": "fone bluetooth",
  "maxProducts": 50,
  "includeReviews": true,
  "maxReviewsPerProduct": 10,
  "sortBy": "relevance",
  "primeOnly": false
}
````

### 📤 Output

| Field | Type | Description |
|---|---|---|
| `id` | string | Internal unique ID |
| `asin` | string | Amazon Standard Identification Number |
| `title` | string | Product title |
| `url` | string | Product page URL |
| `price` | number | Current price in BRL |
| `originalPrice` | number | Original price before discount |
| `discount` | number | Discount percentage (0-100) |
| `currency` | string | Always `"BRL"` |
| `rating` | number | Average customer rating (0-5) |
| `reviewCount` | number | Total number of reviews |
| `mainImage` | string | Main product image URL |
| `images` | string\[] | All product image URLs (up to 8) |
| `isPrime` | boolean | Whether the product has Prime delivery |
| `seller` | string | Seller name |
| `brand` | string | Product brand |
| `categories` | string\[] | Product category breadcrumb |
| `features` | string\[] | Product feature bullet points (up to 10) |
| `description` | string | Product description (up to 1000 chars) |
| `techDetails` | object | Technical specifications key-value pairs |
| `availability` | string | Stock availability status |
| `isAvailable` | boolean | Whether the product is in stock |
| `delivery` | string | Delivery estimate text |
| `bestSellerRank` | number | Best seller rank in category |
| `isSponsored` | boolean | Whether the listing is sponsored |
| `coupon` | string | Available coupon text |
| `reviews` | object\[] | Customer reviews (if `includeReviews` is true) |
| `reviewSentiment` | string | Overall review sentiment: `positive`, `mixed`, or `negative` |
| `scrapedAt` | string | ISO 8601 scrape timestamp |

#### Output Example

```json
{
  "id": "amz_1709225400_abc123",
  "asin": "B0BTYCRJSS",
  "title": "soundcore P20i da Anker, Fone de Ouvido Bluetooth 5.3",
  "url": "https://www.amazon.com.br/dp/B0BTYCRJSS",
  "price": 166.19,
  "originalPrice": 219.99,
  "discount": 24,
  "currency": "BRL",
  "rating": 4.5,
  "reviewCount": 12847,
  "mainImage": "https://m.media-amazon.com/images/I/61example.jpg",
  "images": ["https://m.media-amazon.com/images/I/61example.jpg"],
  "isPrime": true,
  "seller": "Anker Official",
  "brand": "Anker",
  "categories": ["Eletrônicos", "Fones de Ouvido"],
  "features": ["Bluetooth 5.3 para conexão estável", "30 horas de reprodução"],
  "description": "Fone de ouvido sem fio com drivers de 10mm...",
  "techDetails": {"Peso": "52g", "Conectividade": "Bluetooth 5.3"},
  "availability": "Em estoque",
  "isAvailable": true,
  "delivery": "Entrega em 3-5 dias úteis",
  "bestSellerRank": 15,
  "isSponsored": false,
  "coupon": null,
  "reviewSentiment": "positive",
  "scrapedAt": "2026-03-06T12:00:00.000Z"
}
```

### 📋 Use Cases

- **E-commerce Intelligence** — Monitor competitor pricing on Amazon Brazil
- **Product Research** — Find bestsellers and trending products in the Brazilian market
- **Price Monitoring** — Track price changes over time with scheduled runs
- **Review Analysis** — Understand customer sentiment for any product category
- **Market Entry** — Research the Brazilian Amazon marketplace before launching products
- **Dropshipping Research** — Find high-demand, well-reviewed products
- **Brand Monitoring** — Track your brand's products, reviews, and competitive positioning
- **Competitive Analysis** — AI-powered market intelligence with pricing trends and recommendations

### ❓ FAQ

**Q: Do I need an Amazon account?**
A: No. The actor scrapes publicly available product data from Amazon.com.br without any authentication.

**Q: How does the AI analysis work?**
A: When `includeAiAnalysis` is enabled and a `GEMINI_API_KEY` environment variable is set, the actor sends a summary of scraped products to Google Gemini for pricing trend analysis, best value recommendations, and competitive insights.

**Q: Why do some products have no price?**
A: Some products may have unavailable pricing (e.g. "See price in cart" or out-of-stock items). The actor reports `null` for these fields rather than guessing.

**Q: Can I scrape specific product pages?**
A: Yes. Use `productUrls` with direct Amazon.com.br product URLs. The actor extracts the ASIN and fetches full product details.

**Q: Does it handle Amazon's anti-bot protection?**
A: The actor uses residential proxies (Brazil-targeted), session rotation, and CAPTCHA detection with automatic retry. For best results, use Apify residential proxy.

### 💰 Pricing

This actor uses **Pay Per Event (PPE)** pricing:

| Metric | Cost |
|--------|------|
| `product-scraped` | $0.06 per product |

**Example**: Scraping 1,000 products costs $60.00.

### 🔗 Related Actors

- [Website Change Monitor](https://apify.com/viralanalyzer/website-change-monitor) — Track price changes on any website
- [Google Maps BR Scraper](https://apify.com/viralanalyzer/google-maps-br-scraper) — Brazilian business data
- [CNPJ Enricher](https://apify.com/viralanalyzer/cnpj-enricher) — Brazilian company data enrichment
- [Reclame Aqui Scraper](https://apify.com/viralanalyzer/reclameaqui-scraper) — Consumer complaints & ratings

### 📝 Changelog

#### v1.0 (Current)

- Product search with pagination on Amazon.com.br
- Direct product URL scraping by ASIN
- Full product details: price, rating, reviews, brand, categories, features, specs
- Customer review extraction with sentiment analysis
- AI market analysis via Google Gemini
- Sorting (relevance, price, rating, newest) and filtering (price range, Prime)
- CAPTCHA detection with session rotation
- Residential proxy support (Brazil-targeted)
- PPE charging per product scraped

***

<a name="português"></a>

## 🛒 Amazon Brazil Intelligence — Produtos, Preços, Avaliações & Análise IA

> 🔗 [View on Apify Store](https://apify.com/viralanalyzer/amazon-brazil-intelligence) | [🇺🇸 English](#-amazon-brazil-intelligence--products-prices-reviews--ai-analysis) | 🇧🇷 Português

Extraia **produtos da Amazon.com.br** com preços, avaliações, dados de vendedores e análise de mercado opcional via IA. Busque por palavra-chave ou forneça URLs diretas de produtos. Extraia informações detalhadas incluindo status Prime, descontos, marca, categorias, especificações técnicas, ranking de mais vendidos e avaliações de clientes com análise de sentimento.

### ✨ Funcionalidades

- **Busca de produtos** — Pesquise qualquer palavra-chave na Amazon.com.br com paginação
- **Scraping por URL direta** — Extraia páginas de produtos específicos por ASIN ou URL
- **Inteligência de preços** — Preço atual, preço original, percentual de desconto, status Prime
- **Extração de avaliações** — Avaliações de clientes com notas, datas, selo de compra verificada, votos úteis
- **Detalhes do produto** — Marca, categorias, características, especificações técnicas, ranking de mais vendidos
- **Análise de mercado com IA** — Análise competitiva opcional via Gemini com insights de preços
- **Ordenação e filtros** — Ordene por relevância, preço, avaliação ou mais recente; filtre por faixa de preço e Prime
- **Tratamento de CAPTCHA** — Detecta páginas de CAPTCHA da Amazon e rotaciona sessões
- **Proxy residencial** — Suporte integrado a proxy com direcionamento para Brasil
- **Sentimento de avaliações** — Classificação automática de sentimento (positivo/misto/negativo) baseada nas notas

### 📥 Entrada

| Parâmetro | Tipo | Obrigatório | Padrão | Descrição |
|---|---|---|---|---|
| `searchQuery` | string | Sim\* | — | Termo de busca (ex: "iPhone 15", "fone bluetooth") |
| `productUrls` | string\[] | Sim\* | `[]` | URLs diretas de produtos da Amazon.com.br |
| `category` | string | Não | `""` | Filtro de categoria Amazon |
| `maxProducts` | inteiro | Não | 50 | Número máximo de produtos para extrair (1-500) |
| `includeReviews` | boolean | Não | false | Extrair avaliações de clientes |
| `maxReviewsPerProduct` | inteiro | Não | 10 | Máximo de avaliações por produto (1-100) |
| `sortBy` | string | Não | `"relevance"` | Ordenação: `relevance`, `price-asc`, `price-desc`, `rating`, `newest` |
| `minPrice` | número | Não | 0 | Filtro de preço mínimo (R$) |
| `maxPrice` | número | Não | 0 | Filtro de preço máximo (R$, 0 = sem limite) |
| `primeOnly` | boolean | Não | false | Apenas produtos com Prime |
| `includeAiAnalysis` | boolean | Não | false | Análise de mercado via IA (requer GEMINI\_API\_KEY) |
| `proxyConfiguration` | objeto | Não | Residencial BR | Configuração de proxy para scraping da Amazon |

\*`searchQuery` ou `productUrls` é obrigatório.

#### Exemplo de Entrada

```json
{
  "searchQuery": "fone bluetooth",
  "maxProducts": 50,
  "includeReviews": true,
  "maxReviewsPerProduct": 10,
  "sortBy": "relevance",
  "primeOnly": false
}
```

### 📤 Saída

| Campo | Tipo | Descrição |
|---|---|---|
| `id` | string | ID único interno |
| `asin` | string | Amazon Standard Identification Number |
| `title` | string | Título do produto |
| `url` | string | URL da página do produto |
| `price` | número | Preço atual em BRL |
| `originalPrice` | número | Preço original antes do desconto |
| `discount` | número | Percentual de desconto (0-100) |
| `currency` | string | Sempre `"BRL"` |
| `rating` | número | Avaliação média dos clientes (0-5) |
| `reviewCount` | número | Número total de avaliações |
| `mainImage` | string | URL da imagem principal do produto |
| `images` | string\[] | Todas as URLs de imagens do produto (até 8) |
| `isPrime` | boolean | Se o produto tem entrega Prime |
| `seller` | string | Nome do vendedor |
| `brand` | string | Marca do produto |
| `categories` | string\[] | Categorias do produto (breadcrumb) |
| `features` | string\[] | Características do produto em tópicos (até 10) |
| `description` | string | Descrição do produto (até 1000 caracteres) |
| `techDetails` | objeto | Especificações técnicas em pares chave-valor |
| `availability` | string | Status de disponibilidade em estoque |
| `isAvailable` | boolean | Se o produto está disponível |
| `delivery` | string | Texto de estimativa de entrega |
| `bestSellerRank` | número | Ranking de mais vendidos na categoria |
| `isSponsored` | boolean | Se o anúncio é patrocinado |
| `coupon` | string | Texto do cupom disponível |
| `reviews` | objeto\[] | Avaliações de clientes (se `includeReviews` estiver ativo) |
| `reviewSentiment` | string | Sentimento geral: `positive`, `mixed` ou `negative` |
| `scrapedAt` | string | Timestamp ISO 8601 da coleta |

#### Exemplo de Saída

```json
{
  "id": "amz_1709225400_abc123",
  "asin": "B0BTYCRJSS",
  "title": "soundcore P20i da Anker, Fone de Ouvido Bluetooth 5.3",
  "url": "https://www.amazon.com.br/dp/B0BTYCRJSS",
  "price": 166.19,
  "originalPrice": 219.99,
  "discount": 24,
  "currency": "BRL",
  "rating": 4.5,
  "reviewCount": 12847,
  "mainImage": "https://m.media-amazon.com/images/I/61example.jpg",
  "images": ["https://m.media-amazon.com/images/I/61example.jpg"],
  "isPrime": true,
  "seller": "Anker Official",
  "brand": "Anker",
  "categories": ["Eletrônicos", "Fones de Ouvido"],
  "features": ["Bluetooth 5.3 para conexão estável", "30 horas de reprodução"],
  "description": "Fone de ouvido sem fio com drivers de 10mm...",
  "techDetails": {"Peso": "52g", "Conectividade": "Bluetooth 5.3"},
  "availability": "Em estoque",
  "isAvailable": true,
  "delivery": "Entrega em 3-5 dias úteis",
  "bestSellerRank": 15,
  "isSponsored": false,
  "coupon": null,
  "reviewSentiment": "positive",
  "scrapedAt": "2026-03-06T12:00:00.000Z"
}
```

### 📋 Casos de Uso

- **Inteligência E-commerce** — Monitore preços de concorrentes na Amazon Brasil
- **Pesquisa de Produtos** — Encontre bestsellers e produtos em tendência no mercado brasileiro
- **Monitoramento de Preços** — Acompanhe mudanças de preços ao longo do tempo com execuções agendadas
- **Análise de Avaliações** — Entenda o sentimento dos clientes por categoria de produto
- **Entrada no Mercado** — Pesquise o marketplace da Amazon Brasil antes de lançar produtos
- **Pesquisa de Dropshipping** — Encontre produtos com alta demanda e boas avaliações
- **Monitoramento de Marca** — Acompanhe seus produtos, avaliações e posicionamento competitivo
- **Análise Competitiva** — Inteligência de mercado via IA com tendências de preços e recomendações

### ❓ Perguntas Frequentes

**P: Preciso de uma conta da Amazon?**
R: Não. O actor extrai dados de produtos disponíveis publicamente na Amazon.com.br sem nenhuma autenticação.

**P: Como funciona a análise com IA?**
R: Quando `includeAiAnalysis` está habilitado e a variável de ambiente `GEMINI_API_KEY` está configurada, o actor envia um resumo dos produtos extraídos para o Google Gemini para análise de tendências de preços, recomendações de melhor custo-benefício e insights competitivos.

**P: Por que alguns produtos não têm preço?**
R: Alguns produtos podem ter preço indisponível (ex: "Veja o preço no carrinho" ou itens fora de estoque). O actor reporta `null` nesses campos ao invés de adivinhar.

**P: Posso extrair páginas de produtos específicos?**
R: Sim. Use `productUrls` com URLs diretas de produtos da Amazon.com.br. O actor extrai o ASIN e busca os detalhes completos do produto.

**P: Ele lida com a proteção anti-bot da Amazon?**
R: O actor usa proxies residenciais (direcionados para Brasil), rotação de sessão e detecção de CAPTCHA com retry automático. Para melhores resultados, use o proxy residencial do Apify.

### 💰 Preços

Este actor usa precificação **Pay Per Event (PPE)**:

| Métrica | Custo |
|---------|-------|
| `product-scraped` | $0.05 por produto extraído |

**Exemplo**: Extrair 50 produtos custa $2.50.

### 🔗 Actors Relacionados

- [Website Change Monitor](https://apify.com/viralanalyzer/website-change-monitor) — Monitore mudanças de preço em qualquer site
- [Google Maps BR Scraper](https://apify.com/viralanalyzer/google-maps-br-scraper) — Dados de empresas brasileiras
- [CNPJ Enricher](https://apify.com/viralanalyzer/cnpj-enricher) — Enriquecimento de dados empresariais
- [Reclame Aqui Scraper](https://apify.com/viralanalyzer/reclameaqui-scraper) — Reclamações e avaliações de consumidores

### 📝 Changelog

#### v1.0 (Atual)

- Busca de produtos com paginação na Amazon.com.br
- Scraping de URLs diretas de produtos por ASIN
- Detalhes completos: preço, avaliação, reviews, marca, categorias, características, especificações
- Extração de avaliações de clientes com análise de sentimento
- Análise de mercado via Google Gemini
- Ordenação (relevância, preço, avaliação, mais recente) e filtros (faixa de preço, Prime)
- Detecção de CAPTCHA com rotação de sessão
- Suporte a proxy residencial (direcionado para Brasil)
- Cobrança PPE por produto extraído

# Actor input Schema

## `accessToken` (type: `string`):

Your CJ Personal Access Token from developers.cj.com. REQUIRED. Bearer auth used directly (no OAuth flow).

## `companyId` (type: `string`):

Your CJ Publisher CID (~7 digits, e.g. 7957587). Found at members.cj.com > Account Information. REQUIRED for ALL queries.

## `queryType` (type: `string`):

Which CJ GraphQL query to run

## `keywords` (type: `array`):

Search keywords. Applies to 'products', 'shoppingProducts', 'travelExperienceProducts'. Leave empty for non-product queries.

## `advertiserIds` (type: `array`):

Filter results to specific advertiser IDs. Get IDs from queryType=shoppingProductFeeds first.

## `maxResults` (type: `integer`):

Maximum items to return (CJ API limit per request: 1000)

## `offset` (type: `integer`):

Skip N items before returning results (for pagination)

## Actor input object example

```json
{
  "queryType": "shoppingProductFeeds",
  "keywords": [],
  "advertiserIds": [],
  "maxResults": 10,
  "offset": 0
}
```

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "maxResults": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("viralanalyzer/cj-affiliate-products").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "maxResults": 10 }

# Run the Actor and wait for it to finish
run = client.actor("viralanalyzer/cj-affiliate-products").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "maxResults": 10
}' |
apify call viralanalyzer/cj-affiliate-products --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=viralanalyzer/cj-affiliate-products",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "CJ Affiliate API - Commission Junction Products & Feeds",
        "description": "Query CJ.com (Commission Junction) GraphQL API for affiliate products, 15k+ shopping product feeds, finance credit cards, travel experiences. You provide your own PAT + CID. Multi-vertical discovery.",
        "version": "1.0",
        "x-build-id": "eZH1cpeMKxA9xzof4"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/viralanalyzer~cj-affiliate-products/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-viralanalyzer-cj-affiliate-products",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/viralanalyzer~cj-affiliate-products/runs": {
            "post": {
                "operationId": "runs-sync-viralanalyzer-cj-affiliate-products",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/viralanalyzer~cj-affiliate-products/run-sync": {
            "post": {
                "operationId": "run-sync-viralanalyzer-cj-affiliate-products",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "accessToken",
                    "companyId"
                ],
                "properties": {
                    "accessToken": {
                        "title": "Personal Access Token (PAT)",
                        "type": "string",
                        "description": "Your CJ Personal Access Token from developers.cj.com. REQUIRED. Bearer auth used directly (no OAuth flow)."
                    },
                    "companyId": {
                        "title": "Company ID (CID)",
                        "type": "string",
                        "description": "Your CJ Publisher CID (~7 digits, e.g. 7957587). Found at members.cj.com > Account Information. REQUIRED for ALL queries."
                    },
                    "queryType": {
                        "title": "Query Type",
                        "enum": [
                            "shoppingProductFeeds",
                            "productFeeds",
                            "products",
                            "shoppingProducts",
                            "financeCreditCardProducts",
                            "travelExperienceProducts"
                        ],
                        "type": "string",
                        "description": "Which CJ GraphQL query to run",
                        "default": "shoppingProductFeeds"
                    },
                    "keywords": {
                        "title": "Keywords (productSearch only)",
                        "type": "array",
                        "description": "Search keywords. Applies to 'products', 'shoppingProducts', 'travelExperienceProducts'. Leave empty for non-product queries.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "advertiserIds": {
                        "title": "Advertiser IDs (optional filter)",
                        "type": "array",
                        "description": "Filter results to specific advertiser IDs. Get IDs from queryType=shoppingProductFeeds first.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxResults": {
                        "title": "Max Results",
                        "minimum": 1,
                        "maximum": 1000,
                        "type": "integer",
                        "description": "Maximum items to return (CJ API limit per request: 1000)",
                        "default": 25
                    },
                    "offset": {
                        "title": "Offset (pagination)",
                        "minimum": 0,
                        "type": "integer",
                        "description": "Skip N items before returning results (for pagination)",
                        "default": 0
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
