ContentDrips API
Generate stunning social media graphics and carousels programmatically
Base URL: https://generate.contentdrips.com
Setup & Installation
Get started with the ContentDrips API in just a few steps.
Sign up for a ContentDrips Account
Visit ContentDrips to create your account. You'll need this to access templates and the API.
Go to ContentDripsCreate or Select a Template
Design your template using the ContentDrips editor or select one from the Template Gallery. Templates are the blueprints for your graphics.
Make sure to add editable layers (text, images) that you'll update via the API. Note down your Template ID for later.
Get Your API Key
Navigate to your API Management dashboard to retrieve your API key. This key is required for all API requests.
Go to API ManagementYour API key will look like:
cd_live_abc123xyz789_1234567890abcdefStore Your API Key Securely
Keep your API key secret. Add it to your environment variables:
# .env.local CONTENTDRIPS_API_KEY=cd_live_your_key_here
⚠️ Never commit API keys to version control. Use environment variables instead.
Make Your First API Request
Test the API with a simple request to generate your first graphic:
const apiKey = process.env.CONTENTDRIPS_API_KEY;
const templateId = 'YOUR_TEMPLATE_ID';
const response = await fetch("https://generate.contentdrips.com/render", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": `Bearer ${apiKey}`
},
body: JSON.stringify({
template_id: templateId,
output: "png",
content_update: [
{
type: "textbox",
label: "title",
value: "Your First Generated Graphic!",
fontSize: "48",
fontColor: "#2C3E50"
},
{
type: "shape",
label: "glitter",
fill: "#f00000",
opacity: 0.8
}
]
})
})
const data = await response.json();
console.log("Job ID:", data.job_id);Setup Tutorial Video
Watch this complete setup guide to get started:
Getting Started
The ContentDrips API provides asynchronous image and PDF generation from templates. The workflow is simple:
Submit Job
Submit your template with content updates
Get Job ID
Receive a unique job ID for tracking
Poll Status
Check status until processing completes
Download Result
Retrieve your generated files
Authentication
All endpoints require Bearer token authentication in the Authorization header.
Example Header
Authorization: Bearer YOUR_API_KEY_HEREContent-Type: All requests must include application/json
Endpoints
| Method | Endpoint | Description |
|---|---|---|
| POST | /render | Submit single graphic job |
| POST | /render?tool=carousel-maker | Submit carousel job |
| GET | /job/:jobId/status | Check job status |
| GET | /job/:jobId/result | Get completed result |
| GET | /queue/stats | Get queue statistics |
Single Graphics API
Generate individual graphics from templates with dynamic content updates.
1. Submit Job
POST /render
Submit your graphic request with template ID and content updates.
Request Example:
const response = await fetch("https://generate.contentdrips.com/render", {
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_TOKEN_HERE"
},
body: JSON.stringify({
template_id: "123456",
canvas_background: {
type: "fill",
color: "#f0f9ff"
},
output: "png",
content_update: [
{
type: "textbox",
label: "quote",
value: "Your inspiring quote goes here",
fontSize: "48",
fontColor: "#333333",
textboxMaxHeight: 300
},
{
type: "image",
label: "background",
value: "https://example.com/image.jpg",
opacity: 0.8
},
{
type: "shape",
label: "glitter",
fill: "#f00000",
opacity: 0.8
}
]
})
})
const data = await response.json()Success Response:
{
"job_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"status": "queued",
"message": "Job has been queued for processing",
"check_status_url": "/job/a1b2c3d4-e5f6-7890-abcd-ef1234567890/status"
}Single Image Request Parameters
| Property | Type | Required | Description |
|---|---|---|---|
| template_id | String | Yes | Template ID used for rendering |
| output | String | Yes | File format for the exported image |
| canvas_background | Object | No | Controls the background style of the canvas |
| content_update | Array<Object> | No | Updates content boxes, shapes, and images in the base template |
content_update Array<Object> Parameters
Array of objects that updates content boxes, shapes, and images in the base template
| Property | Type | Required | Description |
|---|---|---|---|
| type | String | Yes | Must be "textbox", "image", or "shape" |
| label | String | Yes | Matches template meta_labels |
| value | String | Yes | Text content or image url |
| fontSize | String/Number | No | Font size in pixels |
| fontColor | String | No | Color (CSS format) |
| textboxMaxHeight | String/Number | No | Max height or "auto" |
| fill | String | No | Fill of type "shape" |
| opacity | String/Number | No | Opacity of type "shape" |
2. Check Job Status
GET /job/:jobId/status
Completed
{
"job_id": "...",
"status": "completed",
"completedAt": "2024-01-15..."
}Failed
{
"job_id": "...",
"status": "failed",
"error": "Template not found"
}3. Get Job Result
GET /job/:jobId/result
Returns the generated PNG file (for single graphic) or PDF file URL:
{
"date": "2024-01-15T10:35:00.000Z",
"type": "normal",
"export_url": "https://bucket.s3.amazonaws.com/.../image.png"
}Returns array of file urls when carousel is in PNG format:
{
"date": "2024-01-15T10:35:00.000Z",
"type": "normal",
"export_url": ["https://bucket.s3.amazonaws.com/.../image1.png", "..."]
}Carousel API
Generate multi-slide carousels with intro slide, slides, and ending slide.
Submit Carousel Job
POST /render?tool=carousel-maker
Submit a carousel template with intro slide, content slides, and ending slide. Each slide uses an elements object to fill named template slots.
Request Example:
const response = await fetch(
"https://generate.contentdrips.com/render?tool=carousel-maker",
{
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_TOKEN_HERE"
},
body: JSON.stringify({
template_id: "126149",
output: "png",
carousel_content: {
intro_slide: {
elements: {
heading: {
type: "text",
value: "Three ways to grow your personal brand"
},
image: {
type: "image",
value: "https://images.unsplash.com/photo-1629019324504.jpg"
},
hashtags: {
type: "text",
value: "#personalbrand"
}
}
},
slides: [
{
elements: {
description: {
type: "text",
value: "Craft your unique identity and showcase your expertise"
},
image: {
type: "image",
value: "https://images.unsplash.com/photo-1769101230555.jpg"
}
}
},
{
elements: {
description: {
type: "text",
value: "Nurture authentic connections with your audience"
}
}
}
],
ending_slide: {
elements: {
heading: {
type: "text",
value: "Share your thoughts in comments below"
}
}
}
}
})
}
)Success Response — PNG Output:
{
"date": "2024-01-15T10:35:00.000Z",
"type": "carousel",
"export_url": [
"https://bucket.s3.amazonaws.com/.../frame-0.png",
"https://bucket.s3.amazonaws.com/.../frame-1.png"
]
}Success Response — PDF Output:
{
"date": "2024-01-15T10:35:00.000Z",
"type": "carousel",
"export_url": "https://your-bucket.s3.amazonaws.com/.../carousel-output.pdf"
}Carousel Request Parameters
| Property | Type | Required | Description |
|---|---|---|---|
| template_id | String | Yes | Template ID used for rendering |
| output | String | Yes | File format for exported carousel |
| canvas_background | Object | No | Controls the background style of the canvas |
| content_update | Array<Object> | No | Updates content boxes, shapes, and images in the base template |
| carousel_content | Object | No | Container for intro_slide, slides array, and ending_slide with named element slots |
| carousel | Object | No | Legacy format — flat heading/description/image fields per slide. Still supported. |
| ai_carousel | Object | No | Generate carousel copy (topic/blog/youtube/tiktok_reel) and render as carousel |
canvas_background Object Parameters
Controls the background style of the canvas
| Property | Type | Required | Description |
|---|---|---|---|
| type | String | Yes (object) | Describes how the background is rendered (e.g., "fill") |
| color | String | No | Background color in CSS format |
content_update Array<Object> Parameters
Array of objects that updates content boxes, shapes, and images in the base template
| Property | Type | Required | Description |
|---|---|---|---|
| type | String | Yes | Must be "textbox", "image", or "shape" |
| label | String | Yes | Matches template meta_labels |
| value | String | Yes | Text content or image url |
| fontSize | String/Number | No | Font size in pixels |
| fontColor | String | No | Color (CSS format) |
| textboxMaxHeight | String/Number | No | Max height or "auto" |
| fill | String | No | Fill of type "shape" |
| opacity | String/Number | No | Opacity of type "shape" |
carousel_content Object Parameters
carousel_content is a container for intro_slide, a slides array, and ending_slide. Each slide uses an elements object whose keys map to named slots in the template.
| Property | Type | Required | Description |
|---|---|---|---|
| intro_slide | Object | No | First slide of the carousel |
| intro_slide.elements | Object | No | Keyed element values for the intro slide (e.g. heading, description, image, hashtags) |
| slides | Array<Object> | No | List of content slides, each with their own elements object |
| slides[n].elements | Object | No | Keyed element values for each content slide |
| ending_slide | Object | No | Final slide of the carousel |
| ending_slide.elements | Object | No | Keyed element values for the ending slide |
Slide elements Object Parameters
Each slide contains an elements object. Keys are element names (e.g. heading, description, image, hashtags) matching the template's named slots.
| Property | Type | Required | Description |
|---|---|---|---|
| <element_name>.type | String | Yes | Element type — "text" for any text field, "image" for image fields |
| <element_name>.value | String | Yes | The value to fill in — text string for type "text", or a URL for type "image" |
carousel key (still supported)
The older carousel key is still accepted and continues to work. New integrations should use carousel_content.
Legacy Request Example:
const response = await fetch(
"https://generate.contentdrips.com/render?tool=carousel-maker",
{
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_TOKEN_HERE"
},
body: JSON.stringify({
template_id: "126149",
output: "png",
carousel: {
intro_slide: {
heading: {
text: "Three ways to grow your personal brand",
fontSize: "56",
fontColor: "#2C3E50"
}
},
slides: [
{
heading: {
text: "Feature 1",
fontSize: "48",
fontColor: "#3498DB"
}
}
],
ending_slide: {
heading: {
text: "Share your thoughts in comments below",
fontSize: "60",
fontColor: "#E74C3C"
}
}
}
})
}
)carousel Object Parameters (Legacy)
The legacy carousel key is still supported. Each slide accepts flat heading/description/image fields with optional style overrides.
| Property | Type | Required | Description |
|---|---|---|---|
| intro_slide | Object | No | First slide of the carousel |
| slides | Array<Object> | No | List of main slides |
| ending_slide | Object | No | Final slide of the carousel |
Legacy Slide Parameters
Flat field structure used with the carousel key. heading, description, and image are set directly on each slide object.
| Property | Type | Required | Description |
|---|---|---|---|
| heading.text | String | No | Main heading text for the slide |
| heading.fontSize | String/Number | No | Font size for heading |
| heading.fontColor | String | No | Color of the heading text (CSS format) |
| description.text | String | No | Secondary / body text for the slide |
| description.fontSize | String/Number | No | Font size for description text |
| description.fontColor | String | No | Font color for description text |
| image.url | String | No | Image URL for the slide |
| image.opacity | Number | No | Image opacity (0–1) |
| backgroundColor | String | No | Background color of the slide — overrides canvas background |
AI Carousel
Generate carousel copy automatically from a topic or URL and render it using the carousel-maker tool.
Generate + Render AI Carousel
POST /render?tool=carousel-maker
Request Example:
const response = await fetch(
"https://generate.contentdrips.com/render?tool=carousel-maker",
{
method: "POST",
headers: {
"Content-Type": "application/json",
"Authorization": "Bearer YOUR_TOKEN_HERE"
},
body: JSON.stringify({
template_id: "126149",
output: "png",
ai_carousel: {
method: "topic",
input: "How to price your freelance services"
}
})
}
)Supported methods
topic: free textblog: HTTPS blog URLyoutube: YouTube URLtiktok_reel: TikTok or Instagram Reel URL
Carousel Request Parameters
| Property | Type | Required | Description |
|---|---|---|---|
| template_id | String | Yes | Template ID used for rendering |
| output | String | Yes | File format for exported carousel |
| canvas_background | Object | No | Controls the background style of the canvas |
| content_update | Array<Object> | No | Updates content boxes, shapes, and images in the base template |
| carousel_content | Object | No | Container for intro_slide, slides array, and ending_slide with named element slots |
| carousel | Object | No | Legacy format — flat heading/description/image fields per slide. Still supported. |
| ai_carousel | Object | No | Generate carousel copy (topic/blog/youtube/tiktok_reel) and render as carousel |
ai_carousel Object Parameters
Generate carousel copy automatically and render as a carousel (use tool=carousel-maker)
| Property | Type | Required | Description |
|---|---|---|---|
| method | String | Yes | How to resolve input before generating slides: topic, blog, youtube, tiktok_reel |
| input | String | Yes | Topic text or HTTPS URL (depends on method) |
Response Codes
202
Accepted
Job queued successfully
400
Bad Request
Validation error in request
401
Unauthorized
Invalid or missing token
404
Not Found
Job or template not found
500
Server Error
Internal server error
Error Handling
All errors follow a consistent format:
{
"error": "Error Type",
"message": "Detailed error description"
}Template Not Found
Ensure template_id exists and belongs to your account
Invalid Content Labels
Content update labels must match template meta_labels exactly
Rate Limited
Check queue stats and retry after a brief delay
Best Practices
Polling Recommendations
Poll status every 5 seconds and set a maximum timeout of 5 minutes to avoid excessive API calls.
Template Labels
Content update labels must exactly match your template's meta_labels. Mismatches will result in a 400 error.
Output Formats: PNG vs PDF
PNG: best for social media and web; returns array of frame URLs. PDF: best for presentations and printing; returns single PDF URL.
How to Specify Output Format
In your API request, set the "output" parameter: "output": "png" or "output": "pdf".
Error Handling
Always check response status codes and store job IDs for debugging and reference.
Image URLs
Use publicly accessible image URLs. Ensure images are properly formatted and not behind authentication.