Using OpenClaw?See our one-click integration →

Agent Integration Guide

40+ templates across 10 categories. Two modes: Prompt (AI picks template) and Direct Render (you pick template + fill slots).

Two Modes

Prompt Mode

Describe what you need. AI handles the rest.

Direct Render

Full control. Your agent picks template + fills content. Precise and fast. Recommended.

Standard Slots

Every template accepts these universal slots. Use consistent names across all templates for automation (CSV imports, batch generation).

SlotTypeExample
headingstring"Summer Sale 2026"
subheadingstring"Up to 50% off everything"
badge_textstring"LIMITED"
cta_textstring"Shop Now"
photo_urlURL"https://..."
accent_colorhex"#EF4444"

Category-Specific Slots

E-commerce: price, original_price, discount, stars, rating

Real estate: address, price, feature1, feature2, feature3

Content/media: author, episode, duration, quote_text, show_name

Certificates: recipient_name, signer_title, description

Slot Aliases

The renderer auto-resolves these alternative names, so both conventions work:

title, hero_text, headline -> heading

subtitle, description -> subheading

badge, label, tag -> badge_text

cta, button, button_text -> cta_text

imageUrl, image, photo -> photo_url

accentColor, color, accent -> accent_color

Recommended Agent Workflow

1.

User asks for an image. Agent calls GET /api/v1/templates?category=food&style=photo

2.

Agent reviews template names/descriptions and picks the best match

3.

Agent calls POST /api/v1/generate with templateId and filled slots

4.

Returns image URL to user

Template Categories

Browse templates by category using GET /api/v1/templates?category=... or see all categories at GET /api/v1/templates/categories

Social

Posts, stories, carousels

?category=social

Marketing

Sales, promos, CTAs

?category=marketing

Business

Reports, pitches, corporate

?category=business

Food

Restaurants, recipes, menus

?category=food

Lifestyle

Fashion, beauty, fitness, travel, real estate

?category=lifestyle

Events

Weddings, concerts, festivals, holidays

?category=events

Education

Courses, certifications, tutorials

?category=education

Tech

SaaS, APIs, launches, OG images

?category=tech

Creative

Podcasts, music, gaming, blogs

?category=creative

Infographic

Flowcharts, processes, checklists, comparisons, timelines

?category=infographic

Infographic Decision Tree

When the user wants an infographic, pick the right template based on intent. All infographic templates use Direct Render. No photo needed.

User IntentTemplate
A process/how-to/guide with stepsflowchart
A workflow/pipeline with 4+ stagesprocess-horizontal
A checklist/requirements/to-dochecklist
A comparison/vs/pros-conscomparison-vs
A timeline/roadmap/historytimeline-vertical

OpenAI Function Definition

{
  "name": "generate_infographic",
  "description": "Generate an infographic image (flowchart, checklist, comparison, or timeline)",
  "parameters": {
    "type": "object",
    "properties": {
      "templateId": {
        "type": "string",
        "enum": ["flowchart", "process-horizontal", "checklist", "comparison-vs", "timeline-vertical"]
      },
      "slots": {
        "type": "object",
        "description": "Template-specific content and color slots"
      },
      "size": {
        "type": "string",
        "enum": ["1080x1080", "1200x628", "1080x1920", "1200x1200", "1280x720"],
        "default": "1080x1080"
      },
      "logoUrl": {
        "type": "string",
        "description": "HTTPS URL to a logo image. PNG with transparent background recommended. Placed as overlay on the generated image."
      },
      "logoPosition": {
        "type": "string",
        "enum": ["top-left", "top-right", "bottom-left", "bottom-right"],
        "description": "Where to place the logo on the image. Default: bottom-left."
      }
    },
    "required": ["templateId", "slots"]
  }
}

Quick Start — Direct Render

Step 1: Browse templates by category

GET https://api.rendrkit.dev/api/v1/templates?category=food

// Or browse all categories:
GET https://api.rendrkit.dev/api/v1/templates/categories

// Filter by style:
GET https://api.rendrkit.dev/api/v1/templates?category=food&style=photo

// Search:
GET https://api.rendrkit.dev/api/v1/templates?search=restaurant

Step 2: Pick a template and fill slots

POST https://api.rendrkit.dev/api/v1/generate
Authorization: Bearer YOUR_API_KEY
Content-Type: application/json

{
  "templateId": "dish-spotlight",
  "slots": {
    "heading": "Truffle Risotto",
    "subheading": "Creamy arborio rice with black truffle shavings",
    "badge_text": "CHEF'S SPECIAL",
    "price": "$28",
    "accent_color": "#D4A574"
  }
}

Step 3: Get your image

{
  "id": "abc-123",
  "url": "https://storage.rendrkit.dev/images/abc-123.png",
  "width": 1080,
  "height": 1080,
  "templateId": "dish-spotlight"
}

Best Practices for High-Quality Images

1. Use Direct Render (recommended)

Direct render gives you full control and the best quality. Your agent picks the template and fills every slot.

Quality comparison:

Prompt mode (GPT picks): avg 5-6/10 — GPT may miss slots or pick wrong template

Direct render (agent picks): avg 7-9/10 — every slot filled, right template chosen

2. Always Fill These Slots

SlotImpactExample
headingRequired"Grand Opening" (2-4 words, punchy)
subheadingKey detail"Authentic Italian dining in the heart of downtown"
badge_textContext"NEW", "SALE", "HIRING", "LIVE"
detailsSpecificity"March 15, 2026 · Portland, OR · 5-11pm"
photoQueryVisual match"italian restaurant warm interior" (1-3 words, visual noun)
cta_textOptional"Reserve Now" — only add when user needs a button

3. Choose the Right Template Type

Photo templates — for real-world subjects (food, places, people, products)

Gradient templates — for abstract concepts (announcements, stats, tech, quotes)

4. Photo Query Tips

Good: "coffee shop interior", "yoga beach sunrise", "red sneakers white background"

Bad: "beautiful amazing professional", "high quality stunning", "modern vibes"

The query searches Unsplash — think like you're searching for a stock photo.

5. Template Selection Workflow

1. GET /api/v1/templates?category=food → browse food templates
2. Pick "dish-spotlight" → check its slots
3. POST /generate with templateId + all slots filled
4. Return image to user

Quick Start per Template

Copy-paste these curl commands to generate images instantly. Replace YOUR_API_KEY with your key.

tweet-card — Social Post Screenshot

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"templateId":"tweet-card","slots":{"avatar_letter":"A","display_name":"Alex Rivera","handle":"@alexr","tweet_text":"Just shipped the biggest update of the year.","likes":"2.4K","retweets":"312","accent_color":"#1D9BF0"}}'

gradient-hero — Tech / SaaS Announcement

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"templateId":"gradient-hero","slots":{"heading":"The Future is Now","subheading":"AI-powered analytics that understand your business","badge_text":"NOW IN BETA","accent_color":"#8B5CF6","cta_text":"Join Waitlist"}}'

magazine-cover — Photo + Text Overlay

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"templateId":"magazine-cover","slots":{"heading":"Taste Tuscany","subheading":"Handmade pasta and wood-fired pizza","badge_text":"GRAND OPENING","accent_color":"#D4A574","cta_text":"Reserve a Table"}}'

flash-sale — Urgent Promo

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"templateId":"flash-sale","slots":{"badge_text":"FLASH SALE","heading":"24 Hours Only","discount":"70% OFF","accent_color":"#FF3B30","subheading":"Our biggest discount ever","cta_text":"Grab the Deal"}}'

dish-spotlight — Featured Dish

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"templateId":"dish-spotlight","slots":{"heading":"Truffle Risotto","subheading":"Creamy arborio rice with black truffle shavings","badge_text":"CHEF\'S SPECIAL","price":"$28","accent_color":"#D4A574"}}'

Common Mistakes

Using prompt mode for everything

Prompt mode is a fallback. Direct render with the right template always produces better results.

Generic headings

"Quality Service" — boring. "Taste Tuscany" — memorable.

Skipping photoQuery

Photo templates without a photo query fall back to gradient — losing the photo entirely.

Too-long headings

"Welcome to Our Amazing Grand Opening Celebration" — overflow. "Grand Opening" — clean.

Abstract photo queries

"professional modern lifestyle" — random stock photo. "italian restaurant interior warm" — perfect match.

Custom Fonts

Pass a Google Fonts name to use custom typography in generated images. Falls back to the template's default font if the name is invalid.

Via request body (highest priority)

{ "templateId": "gradient-hero", "slots": {...}, "font": "Poppins" }

Via brand object

{ "templateId": "...", "slots": {...}, "brand": { "font": "Montserrat", "colors": ["#FF0000"] } }

Via Brand Kit

Set font when creating or updating a brand kit. All images using that brand kit will use the custom font automatically.

Supported: any Google Fonts name (e.g. "Poppins", "Playfair Display", "Roboto", "Montserrat").

Logo Overlay

Add your brand logo to any generated image. Pass it as a top-level parameter (not inside slots).

ParameterTypeDescription
logoUrlHTTPS URLLogo image URL. PNG with transparency recommended.
logoPositionstring"top-left" | "top-right" | "bottom-left" (default) | "bottom-right"

Example

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "templateId": "dark-overlay",
    "size": "1080x1080",
    "logoUrl": "https://example.com/logo.png",
    "logoPosition": "bottom-left",
    "slots": {
      "heading": "Summer Collection",
      "subheading": "New arrivals now available",
      "cta_text": "Shop Now"
    }
  }'
Note: logoUrl must be HTTPS. For best results, use a PNG with transparent background. Logo is automatically sized proportional to the image and placed at the specified corner. You can also store logos in a Brand Kit for automatic application.

A/B Variants

Generate 2-3 color variations of the same design for A/B testing. Each variant uses a different accent color (hue-shifted) while keeping the same content. Each variant counts as 1 image toward your quota.

curl -X POST https://api.rendrkit.dev/api/v1/generate \
  -H "Authorization: Bearer rk_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{
    "templateId": "flash-sale",
    "slots": {
      "heading": "Summer Sale",
      "subheading": "50% off everything",
      "cta_text": "Shop Now",
      "accent_color": "#DC2626"
    },
    "variants": 3
  }'

Returns an array of images, each with a variant number:

{
  "images": [
    { "id": "...", "url": "...", "variant": 1 },
    { "id": "...", "url": "...", "variant": 2 },
    { "id": "...", "url": "...", "variant": 3 }
  ]
}
Plan limits: Free = 1 (no variants), Starter = up to 2, Pro/Business = up to 3. When variants: 1 (default), response is a single image object (unchanged).

Photo Guidelines

Provide HTTPS URL via imageUrl field — bypasses stock photo search

Resolution: 1080px+ wide recommended (image is displayed at 1080x1080)

Aspect ratio: Any — CSS background-size: cover handles cropping

Subject placement: Center your subject — edges may be cropped

No imageUrl? Use photoQuery in slots — searches Unsplash/Pexels automatically

photoQuery tips: Keep it 2-3 words, concrete visual nouns (e.g. "coffee shop interior", not "cozy atmosphere")

Content Tips for 9/10 Quality

Headings: 2-5 words max. Think Apple keynote, not blog post.

Subheadings: One line, specific benefit. No buzzwords.

Badge: 1-2 words uppercase. GRAND OPENING, 50% OFF, NEW, LIVE.

CTA: Action verb + object. "Reserve a Table", "Start Free Trial", "Get Tickets".

accent_color: Match brand or mood. Rich, saturated colors work best.

Fill ALL optional slots — each filled slot adds visual completeness.

OpenAI Function Calling

list_templates

{
  "name": "list_templates",
  "description": "Browse available image templates by category. Call this first to find the right template.",
  "parameters": {
    "type": "object",
    "properties": {
      "category": {
        "type": "string",
        "enum": ["social", "marketing", "business", "food", "lifestyle", "events", "education", "tech", "creative"],
        "description": "Filter by category"
      },
      "style": {
        "type": "string",
        "description": "Filter by style tag: photo, gradient, dark, light, minimal, bold, elegant, neon"
      }
    }
  }
}

generate_image

{
  "name": "generate_image",
  "description": "Generate a professional image using RendrKit. First call list_templates to find the right template, then generate.",
  "parameters": {
    "type": "object",
    "properties": {
      "templateId": {
        "type": "string",
        "description": "Template ID from list_templates. Use direct render for best results."
      },
      "slots": {
        "type": "object",
        "description": "Template content slots. Key slots: heading (required, 2-4 words), subheading (one sentence), badge_text (1-2 word label like NEW/SALE), details (date/location/price), photoQuery (1-3 word Unsplash search), cta_text (only if user wants a button). Check GET /templates for template-specific slots.",
        "additionalProperties": { "type": "string" }
      },
      "prompt": {
        "type": "string",
        "description": "Fallback: describe the image and AI picks the template. Less control than direct render."
      },
      "imageUrl": {
        "type": "string",
        "description": "Optional: your own photo URL to use as background"
      },
      "size": {
        "type": "string",
        "enum": ["1080x1080", "1200x628", "1080x1920", "1200x1200"],
        "description": "Image dimensions. Default: 1080x1080"
      },
      "logoUrl": {
        "type": "string",
        "description": "HTTPS URL to a logo image. PNG with transparent background recommended. Placed as overlay on the generated image."
      },
      "logoPosition": {
        "type": "string",
        "enum": ["top-left", "top-right", "bottom-left", "bottom-right"],
        "description": "Where to place the logo on the image. Default: bottom-left."
      }
    }
  }
}

Full Examples

Restaurant Grand Opening

{
  "templateId": "magazine-cover",
  "slots": {
    "heading": "Taste Tuscany",
    "subheading": "Handmade pasta, wood-fired pizza, local wines",
    "badge_text": "GRAND OPENING",
    "accent_color": "#D4A574"
  },
  "imageUrl": "https://example.com/restaurant-interior.jpg"
}

Year in Review Stats

{
  "templateId": "stats-banner",
  "slots": {
    "heading": "2025 In Review",
    "subheading": "A record-breaking year",
    "stat1_number": "10M+",
    "stat1_label": "Users Served",
    "stat2_number": "99.9%",
    "stat2_label": "Uptime",
    "stat3_number": "150+",
    "stat3_label": "Countries",
    "accent_color": "#3B82F6"
  }
}

SaaS Product Launch

{
  "templateId": "gradient-hero",
  "slots": {
    "heading": "Ship Faster",
    "subheading": "The deployment platform that gets out of your way",
    "badge_text": "NOW IN BETA",
    "accent_color": "#8B5CF6",
    "cta_text": "Start Free"
  }
}

Big Announcement

{
  "templateId": "announcement",
  "slots": {
    "bg_word": "NEW",
    "badge_text": "JUST LAUNCHED",
    "heading": "Version 3.0 is Here",
    "subheading": "Completely redesigned with 50+ new features",
    "cta_text": "See What's New",
    "accent_color": "#3B82F6"
  }
}

Team Member Spotlight

{
  "templateId": "profile-card",
  "slots": {
    "name": "Alex Rivera",
    "role": "Head of Product",
    "bio": "Building products that people love. Previously at Stripe and Figma.",
    "link1_text": "LinkedIn",
    "link2_text": "Twitter",
    "accent_color": "#3B82F6"
  },
  "imageUrl": "https://example.com/headshot.jpg"
}

Rate Limits & Pricing

Free: 50 images/month

Starter ($19/mo): 500 images/month

Pro ($49/mo): 2,000 images/month

Business ($149/mo): 10,000 images/month