Documentation
Everything you need to integrate EverAd into your app, website, or ad stack.
Getting Started
EverAd is an AI-powered ad optimization platform. Create a campaign, generate variations, embed them on your site, and let the algorithm find the best performers automatically.
Quick Start (5 minutes)
Embed Guide
Add EverAd to any website with a single line of code. The embed automatically serves the best-performing variation, tracks impressions, and records clicks.
HTML Embed (iframe)
html<iframe src="https://everad.vercel.app/api/embed?campaignId=YOUR_CAMPAIGN_ID" width="300" height="250" frameBorder="0" style="border: none; border-radius: 12px;" ></iframe>
React Component
tsxfunction EverAd({ campaignId }: { campaignId: string }) { return ( <iframe src={`https://everad.vercel.app/api/embed?campaignId=${campaignId}`} width={300} height={250} style={{ border: 'none', borderRadius: 12 }} /> ); }
Customization Options
campaignIdstringrequiredYour campaign IDwidthnumberAd width in pixels (default: 300)heightnumberAd height in pixels (default: 250)themestring'light' or 'dark' (default: dark)API Reference
All API endpoints require authentication via session cookie (Google SSO) unless noted. The serve and track endpoints are public.
Campaigns
/api/campaigns/api/campaigns/api/campaigns/:id/api/campaigns/:id/api/campaigns/:idVariations
/api/variations/api/variations/:id/api/variations/:idServe (Public)
/api/serveThis is the core endpoint that powers ad serving. It runs real-time optimization, picks a winner, increments impressions, and returns the ad creative.
bashcurl "https://everad.vercel.app/api/serve?campaign_id=YOUR_ID" # With debug info curl "https://everad.vercel.app/api/serve?campaign_id=YOUR_ID&debug=true" # Simulate company enrichment curl "https://everad.vercel.app/api/serve?campaign_id=YOUR_ID&debug=true&company=bestbuy.com"
Response Format
json{ "variationId": "uuid", "campaignId": "uuid", "headline": "Your Best Ad Yet", "description": "AI-optimized copy that converts.", "ctaText": "Get Started", "productUrl": "https://yoursite.com", "imageUrl": "https://storage.supabase.co/..." }
Track Clicks (Public)
/api/trackbashcurl -X POST "https://everad.vercel.app/api/track" \ -H "Content-Type: application/json" \ -d '{"variationId": "YOUR_VARIATION_ID"}'
Optimize
/api/optimizeKills bottom 5 performers, generates 5 new variations via AI, marks the top performer as winner, and logs the optimization round.
Generate More
/api/campaigns/:id/generateWebhooks
EverAd uses Stripe webhooks to keep billing in sync. Configure your webhook endpoint in the Stripe Dashboard.
Webhook URL
texthttps://everad.vercel.app/api/stripe/webhook
Events Handled
checkout.session.completedUser completes payment → plan upgraded in DBcustomer.subscription.updatedPlan changed → DB synced to new plancustomer.subscription.deletedSubscription canceled → downgraded to freeinvoice.payment_failedPayment failed → logged for follow-upOptimization Algorithm
EverAd uses adaptive optimization, powered by Bayesian optimization. It's proven to converge faster than traditional A/B testing while minimizing regret (wasted impressions on bad variants).
How It Works
textFor each variation: alpha = clicks + 1 beta = (impressions - clicks) + 1 sample = random draw from Beta(alpha, beta) Serve the variation with the highest sampled score. This naturally balances: - Exploration: new variations get tested - Exploitation: proven winners get more traffic
When to Run Optimization
Click "Optimize" on your campaign to trigger a cycle. This kills the bottom 5 performers, generates 5 fresh variations via AI, and starts the next round. We recommend running optimization after every 500-1000 impressions.
Compliance API
/api/compliance/check/api/compliance/check-publicbashcurl -X POST "https://everad.vercel.app/api/compliance/check-public" \ -H "Content-Type: application/json" \ -d '{ "headline": "FREE MONEY NOW!!!", "description": "Click here to get rich quick with no effort", "ctaText": "GET RICH", "platforms": ["google", "meta"] }'
Response
json{ "score": "F", "issues": [ { "platform": "google", "rule": "Excessive capitalization", "severity": "error", "message": "Headline uses all caps which violates Google Ads policy", "fix": "Use normal capitalization: 'Free Money Now'" } ], "fixedVersion": { "headline": "Smart Investment Opportunities", "description": "Discover proven strategies to grow your wealth responsibly.", "ctaText": "Learn More" } }
Competitor API
/api/competitors/analyze/api/competitors/analyze-publicbashcurl -X POST "https://everad.vercel.app/api/competitors/analyze-public" \ -H "Content-Type: application/json" \ -d '{"url": "https://competitor.com"}'
Response
json{ "competitor": { "name": "CompetitorCo", "product": "Email marketing platform", "valueProps": ["Easy automation", "500+ templates"], "pricing": "$29/mo starter", "weaknesses": ["No AI optimization", "Limited analytics"], "audience": "Small business marketers" }, "counterAds": [ { "headline": "Smarter Than Templates", "description": "Why use 500 templates when AI writes the perfect ad every time?", "ctaText": "Try AI Ads Free", "angle": "technology-superiority" } ] }
Visitor Enrichment
Every ad serve request automatically extracts visitor signals. On the Scale plan, referrer domains are enriched via Apollo.io to provide company-level data.
Free Signals (All Plans)
Device type, OS, browser, language, traffic source, referrer URL, day/time, weekend detection, UTM parameters.
Apollo.io Enrichment (Scale Plan)
Company name, industry, employee count, annual revenue, HQ location, LinkedIn URL. Data is cached for 24 hours to minimize API usage.
Testing Enrichment
Use the ?company=domain.com parameter on the serve endpoint to simulate enrichment from any company:
bashcurl "https://everad.vercel.app/api/serve?campaign_id=YOUR_ID&debug=true&company=shopify.com"
Billing & Plans
| Feature | Free | Starter $99 | Growth $299 | Scale $799 |
|---|---|---|---|---|
| Campaigns | 1 | 10 | ∞ | ∞ |
| Variations | 10 | ∞ | ∞ | ∞ |
| AI Generation | ||||
| Smart Optimization | ||||
| Embed Code | ||||
| Analytics | Basic | Full | Full | |
| Per-Segment Optimization | ||||
| Apollo.io Enrichment | ||||
| White-label | ||||
| API Access |
Billing is handled via Stripe. Upgrade, downgrade, or cancel anytime from the billing page.
Ready to Get Started?
Start optimizing your ads in 5 minutes. No credit card required.
Start Free Trial →