AI
Pass

How to Build an AI Product Listing Writer with AI Pass SDK

How to Build an AI Product Listing Writer with AI Pass SDK

E-commerce sellers need listing copy constantly. In this tutorial, you'll build an AI tool that generates product titles, descriptions, and bullet points optimized for specific marketplaces. You earn 50% commission on every API call.

What You'll Build

A web app where users:

  1. Enter product details (name, features, audience)
  2. Select a marketplace (Amazon, Etsy, eBay)
  3. Get a complete listing with title, description, and bullet points

Step 1: Create Your AI Pass Account

  1. Go to aipass.one and sign up
  2. Verify your email (required for payouts)
  3. Open the Developer Dashboard

Step 2: Create an OAuth2 Client

  1. In the Developer Dashboard, go to OAuth2 Clients
  2. Click Create Client
  3. Copy your Client ID (looks like client_XXXX...)

Step 3: Build the App

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>AI Product Listing Writer</title>
  <link href="https://aipass.one/aipass-ui.css" rel="stylesheet">
  <style>
    body { font-family: sans-serif; max-width: 700px; margin: 40px auto; padding: 20px; }
    input, textarea, select, button { display: block; width: 100%; margin: 8px 0; padding: 10px; font-size: 15px; box-sizing: border-box; }
    textarea { height: 80px; }
    #output { margin-top: 20px; padding: 20px; background: #f8f9fa; border-radius: 8px; white-space: pre-wrap; display: none; }
  </style>
</head>
<body>
  <h1>📦 AI Product Listing Writer</h1>
  <input id="name" placeholder="Product name (e.g. Bamboo Cutting Board)">
  <textarea id="features" placeholder="Key features (e.g. eco-friendly, 14x10 inches, juice groove)"></textarea>
  <input id="audience" placeholder="Target audience (e.g. home cooks, meal preppers)">
  <select id="platform">
    <option value="Amazon">Amazon</option>
    <option value="Etsy">Etsy</option>
    <option value="eBay">eBay</option>
    <option value="Shopify">Shopify</option>
    <option value="general">General</option>
  </select>
  <button onclick="generate()">Generate Listing</button>
  <div id="output"></div>

  <script src="https://aipass.one/aipass-sdk.js"></script>
  <script>
    AiPass.initialize({
      clientId: 'YOUR_CLIENT_ID',
      requireLogin: true,
      darkMode: true
    });

    async function generate() {
      const name = document.getElementById('name').value;
      const features = document.getElementById('features').value;
      const audience = document.getElementById('audience').value;
      const platform = document.getElementById('platform').value;
      const output = document.getElementById('output');
      output.style.display = 'block';
      output.textContent = 'Generating listing...';

      try {
        const r = await AiPass.generateCompletion({
          model: 'gpt-5-mini',
          temperature: 1,
          max_tokens: 16000,
          messages: [
            { role: 'system', content: `You are an expert e-commerce copywriter. Write a ${platform}-optimized product listing. Include: 1) SEO title 2) Product description (2-3 paragraphs) 3) 5 bullet points 4) Suggested search keywords. Format with clear headers.` },
            { role: 'user', content: `Product: ${name}\nFeatures: ${features}\nTarget audience: ${audience}\nPlatform: ${platform}` }
          ]
        });
        output.textContent = r.choices[0].message.content;
      } catch (e) {
        output.textContent = 'Error: ' + e.message;
      }
    }
  </script>
</body>
</html>

Step 4: Deploy

Option A: Self-host anywhere — GitHub Pages, Netlify, Vercel, your server. SDK handles auth and billing.

Option B: Publish on AI Pass — dedicated page with </> embed button.

Key Details

  • temperature: 1 and max_tokens: 16000 — required for GPT-5 models via SDK
  • r.choices[0].message.content — the generated listing text
  • Users get $1 free credit on signup, then pay as you go
  • You earn 50% commission on every API call

Links