Inspiration
Affiliate marketers often manage a single campaign across disconnected prompt documents, design tools, spreadsheets, link trackers, social publishing screens, and analytics dashboards. That creates duplicated work, inconsistent messaging, unclear ownership, and weak visibility into what actually converts.
AffiliateOS AI was created to make the offer the source of truth for the entire campaign lifecycle.
What it does
AffiliateOS AI is an authenticated affiliate marketing workspace that helps a user:
- Create or AI-autofill a structured affiliate offer
- Turn the offer into a campaign workspace
- Generate and version campaign content through reusable AI recipes
- Build complete AI-assisted email sequences with subject alternatives, preview text, CTA copy, editing, regeneration, version preservation, and export
- Create infographic content plans and render editable, deterministic SVG and PNG assets
- Prepare Pinterest creatives and publish through the Pinterest API when authorized
- Create tracked links and record public click events
- Run campaign experiments and variants
- Record conversions, commissions, revenue, and ROI
- Review campaign health and optimization recommendations based on stored performance data
How we built it
The application uses Next.js 15, React 19, TypeScript, Tailwind CSS, NextAuth, Prisma 6, SQLite, OpenAI-compatible provider adapters, Pinterest API v5, and server-side SVG/PNG rendering.
OpenAI workflows are organized through a shared AI Recipe and provider layer. Provider selection, platform credits, founder-unlimited access, and Bring Your Own AI credentials are resolved server-side. Personal API keys are encrypted with AES-256-GCM and are never returned after submission.
The Infographic Generator deliberately separates AI-assisted planning from deterministic visual rendering. This keeps important marketing text readable, editable, and exportable instead of relying on an image model to draw accurate text.
How Codex and GPT-5.6 accelerated the build
Codex with GPT-5.6 was used throughout the Build Week sprint to inspect the existing architecture, identify integration gaps, plan additive database changes, implement server routes and services, generate focused tests, improve production readiness, and document each milestone.
The most important Build Week phases were:
- Phase 20: Offline-safe development workflow and AI Offer Autofill Assistant
- Phase 21: Founder/superuser access, unlimited founder AI usage, BYOA unlock, and live AI testing readiness
- Phase 22: Secure personal API-key persistence, truthful AI capability states, a working AI Email Writer, and a working Infographic Generator MVP
Detailed implementation reports and testing evidence are available in the repository under docs/.
Challenges we ran into
One major issue was a misleading AI readiness state: the platform key could be configured and founder access could be active while saving a personal BYOA key still failed. The fix required tracing the complete request path, separating platform-provider status from personal credential status, adding a dedicated encrypted credential model, and testing save, replace, explicit connection test, and removal independently.
Another challenge was generating infographics with accurate text. Instead of asking an image model to render all copy, we created a structured content plan and a deterministic SVG/PNG renderer with templates, aspect ratios, brand colors, text wrapping, overflow handling, and immutable render versions.
Accomplishments that we're proud of
- A coherent offer-to-ROI workflow rather than a disconnected collection of AI tools
- Secure platform and BYOA provider modes with explicit credit behavior
- A practical AI Email Writer that preserves message versions during editing and regeneration
- A deterministic Infographic Generator with three templates, four formats, SVG/PNG export, and zero-credit rendering
- Real click, conversion, commission, and ROI attribution backed by stored data
- Production safety rules that prevent mock providers from silently impersonating live AI
- A detailed phase-by-phase engineering record showing where Codex influenced implementation and decisions
What we learned
A useful AI product needs more than prompt calls. It needs ownership rules, persistence, versioning, provider transparency, failure recovery, credit accounting, secure credential handling, and measurable outcomes. We also learned that deterministic rendering and AI planning complement each other well when accuracy matters.
What's next for AffiliateOS AI
Next steps include provider-generated optional illustrations, deeper campaign automation, third-party email delivery integrations, expanded analytics, reusable brand libraries, and more automated production verification.
Built With
- codex
- gpt-5.6
- next.js-15
- nextauth
- node.js
- openai-api
- pinterest-api-v5
- png
- prisma-6
- react-19
- sqlite
- svg
- tailwind-css
- typescript
Log in or sign up for Devpost to join the conversation.