Skip to content

Commit 246d154

Browse files
NEOxplusclaude
andcommitted
feat: rewrite llms.txt as teaching doc, add templates page, enhance columns
- Rewrite llms.txt from endpoint list to system-prompt-style teaching document with mental model, creation card payloads, workflows (modeled after Remotion) - Expand llms-full.txt with templates, column types/roles, asset folders, common workflows, integrations section - Add reference/templates.mdx: List, Get, Clone endpoints with examples - Update reference/columns.mdx: add Column Types & Roles tables - Update guides/quickstart.mdx: add "Fast Path: Clone a Template" at top - Update index.mdx: add template clone as first next step - Add Templates to sidebar in astro.config.mjs Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 2c35668 commit 246d154

7 files changed

Lines changed: 572 additions & 84 deletions

File tree

‎astro.config.mjs‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ export default defineConfig({
4545
{ label: 'Overview', slug: 'reference/overview' },
4646
{ label: 'Discovery', slug: 'reference/discovery' },
4747
{ label: 'API Keys', slug: 'reference/api-keys' },
48+
{ label: 'Templates', slug: 'reference/templates' },
4849
{ label: 'Auto Content Engine', slug: 'reference/sheets' },
4950
{ label: 'Rows', slug: 'reference/rows' },
5051
{ label: 'Columns', slug: 'reference/columns' },

‎public/llms-full.txt‎

Lines changed: 160 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,23 @@ DELETE /v1/persisted_tokens/{id}/revoke
5454

5555
DELETE /v1/persisted_tokens/revoke_all
5656

57+
## Templates
58+
59+
Templates are pre-configured engines synced from a curated library. Cloning a template is the fastest way to create a production-ready engine with the right columns.
60+
61+
GET /v1/templates/projects?page={page}
62+
→ [{id, slug, title, name, description, cover, tutorial_url, tags: [], recent_generated_contents: [{id, type, thumbnail_url}]}]
63+
20 per page.
64+
65+
GET /v1/templates/projects/{slug}
66+
slug can be a URL slug, UUID, or numeric ID.
67+
→ {id, slug, title, name, description, cover, tutorial_url, tags: [], ...}
68+
69+
POST /v1/templates/spreadsheets/{slug}/clone
70+
Body: {agent_id}
71+
Clones the template into the specified agent's workspace. Returns the new engine.
72+
→ Full engine object with columns, rows, cells
73+
5774
## Auto Content Engine
5875

5976
POST /v1/autocontentengine?agent_id={id}
@@ -89,6 +106,20 @@ POST /v1/autocontentengine/{id}/columns/{col_id}/duplicate?agent_id={id}
89106
PATCH /v1/autocontentengine/{id}/columns/update_positions?agent_id={id}
90107
PUT /v1/autocontentengine/{id}/columns/mass_update?agent_id={id}
91108

109+
## Column Types & Roles
110+
111+
Types: text, image, video, audio
112+
113+
Roles:
114+
- ingredient — User-editable input columns (ONLY these can be created/updated/deleted by users)
115+
- video — Generated video layer column (system)
116+
- final_video — Final composite video column (system)
117+
- stats — Statistics/metadata column (system)
118+
- global_variable_name — Variable name (system)
119+
- global_variable_value — Variable value (system)
120+
121+
Default template columns: TEXT 1 (text/ingredient), TEXT 2 (text/ingredient), PROMPT (text/ingredient), VIDEO (video/video), FINAL VIDEO (video/final_video), STATS (stats/stats)
122+
92123
## Cells
93124

94125
GET /v1/autocontentengine/{id}/cells/{cell_id}?agent_id={id}
@@ -110,6 +141,17 @@ DELETE /v1/autocontentengine/{id}/cells/{cell_id}/layers/{layer_id}?agent_id={id
110141
POST .../layers/{layer_id}/duplicate?agent_id={id}
111142
PUT .../layers/update_positions?agent_id={id}
112143

144+
## Global Variables
145+
146+
GET /v1/autocontentengine/{id}/global_variables?agent_id={id}
147+
→ Key-value pairs used for template substitution in prompts and content
148+
149+
POST /v1/autocontentengine/{id}/import_global_variables?agent_id={id}
150+
(multipart/form-data with XLSX file)
151+
152+
GET /v1/autocontentengine/global_variables_template
153+
→ XLSX template download
154+
113155
## Generations
114156

115157
POST /v1/autocontentengine/{id}/cells/{cell_id}/generate?agent_id={id}
@@ -128,51 +170,86 @@ POST /v1/generations/{id}/continue → credits re-charged
128170

129171
## Creation Card Types
130172

131-
Each cell in a content engine has a creation card type that determines what kind of content it generates:
173+
Each cell in a content engine has a creation card type that determines what kind of content it generates.
132174

133175
### Text
134-
Models: Gemini, OpenAI
135-
Inputs: text (supports AI generation), variables
136-
137-
### Image from text
138-
Models: Gemini, Gemini Pro, Midjourney
139-
Inputs: prompt (AI text + variables), aspect ratio (1:1, 9:16, 16:9)
140-
141-
### Video from text
142-
Models: Veo 3, Veo 3 Fast, Veo 3.1, Veo 3.1 Fast, Sora 2, Kling 1.6, Seedance Pro, Seedance Pro 1.5
143-
Inputs: prompt, negative prompt, ratio, duration, variables
144-
145-
### Video from image
146-
Models: Kling 2.1, Kling 2.6, Veo 3, Veo 3 Fast, Veo 3.1, Veo 3.1 Fast, Sora 2, Seedance Lite, Seedance Pro, Seedance Pro 1.5
147-
Inputs: image, image tail (optional), prompt, negative prompt, ratio, duration
148-
149-
### Video from ingredients
150-
Models: Pika, Kling 1.6, Seedance Lite, Veo 3.1, Veo 3.1 Fast
151-
Inputs: prompt (with asset selector), ratio, duration
152-
153-
### Speech from text
154-
Voice methods: My Voices, Design Voice, Clone Voice
155-
Inputs: voice selection, script, enhance voice, language, gender
176+
generation_type: "text"
177+
Models: gemini_2_0_flash, gemini_2_5_pro, gpt_4o, gpt_4o_mini, o3_mini, o4_mini, claude_sonnet_4
178+
data: {prompt, model, variables: {key: value}}
179+
Inputs: prompt text (supports AI generation with {{variable}} substitution), model selection
180+
Output: text string in cell value
181+
182+
### Image from Text
183+
generation_type: "image_from_text"
184+
Models: gemini_image, gemini_pro_image, midjourney
185+
data: {prompt, model, aspect_ratio, variables: {key: value}}
186+
Aspect ratios: 1:1, 9:16, 16:9, 4:3, 3:4
187+
Inputs: prompt (AI text + variable substitution), aspect ratio
188+
Output: image content resource
189+
190+
### Video from Text
191+
generation_type: "video_from_text"
192+
Models: veo_3, veo_3_fast, veo_3_1, veo_3_1_fast, sora_2, kling_1_6, seedance_pro, seedance_pro_1_5
193+
data: {prompt, negative_prompt?, model, aspect_ratio, duration, variables: {key: value}}
194+
Aspect ratios: 1:1, 9:16, 16:9
195+
Durations: 5s, 10s (model-dependent)
196+
Inputs: prompt, optional negative prompt, ratio, duration, variables
197+
Output: video content resource
198+
199+
### Video from Image
200+
generation_type: "video_from_image"
201+
Models: kling_2_1, kling_2_6, veo_3, veo_3_fast, veo_3_1, veo_3_1_fast, sora_2, seedance_lite, seedance_pro, seedance_pro_1_5
202+
data: {prompt, negative_prompt?, model, image_resource_id, image_tail_resource_id?, aspect_ratio, duration}
203+
Aspect ratios: 1:1, 9:16, 16:9
204+
Durations: 5s, 10s (model-dependent)
205+
Inputs: source image (content resource ID), optional tail image, prompt, negative prompt, ratio, duration
206+
Output: video content resource
207+
208+
### Video from Ingredients
209+
generation_type: "video_from_ingredients"
210+
Models: pika, kling_1_6, seedance_lite, veo_3_1, veo_3_1_fast
211+
data: {prompt, model, asset_resource_ids: [], aspect_ratio, duration}
212+
Aspect ratios: 1:1, 9:16, 16:9
213+
Durations: 5s, 10s (model-dependent)
214+
Inputs: prompt with asset selector (multiple content resource IDs), ratio, duration
215+
Output: video content resource
216+
217+
### Speech from Text
218+
generation_type: "speech_from_text"
219+
Voice methods: my_voices (saved voices), design_voice (create from parameters), clone_voice (clone from audio)
220+
data: {script, voice_method, voice_id?, language?, gender?, enhance_voice?, speed?}
221+
For my_voices: {script, voice_method: "my_voices", voice_id}
222+
For design_voice: {script, voice_method: "design_voice", language, gender, enhance_voice: true/false}
223+
For clone_voice: {script, voice_method: "clone_voice", audio_resource_id}
224+
Inputs: voice selection, script text, enhancement toggle, language, gender
225+
Output: audio content resource
156226

157227
### Lipsync
158-
Models: sync.so, gen
159-
Inputs: video, audio, lipsync model
228+
generation_type: "lipsync"
229+
Models: sync_so, gen
230+
data: {model, video_resource_id, audio_resource_id}
231+
Inputs: source video (content resource ID), source audio (content resource ID), lipsync model
232+
Output: video content resource with synced lip movements
160233

161234
### Captions
162-
Models: Gemini
163-
Inputs: audio/video
235+
generation_type: "captions"
236+
Models: gemini
237+
data: {model, source_resource_id}
238+
Inputs: audio or video content resource ID
239+
Output: caption/subtitle data
164240

165241
### Media
166-
Upload: image or video file
167-
168-
## Global Variables
169-
170-
GET /v1/autocontentengine/{id}/global_variables?agent_id={id}
171-
POST /v1/autocontentengine/{id}/import_global_variables?agent_id={id}
172-
(multipart/form-data with XLSX file)
173-
174-
GET /v1/autocontentengine/global_variables_template
175-
→ XLSX template download
242+
generation_type: "media"
243+
Upload: image or video file directly to a cell
244+
data: {content_resource_id}
245+
Inputs: content resource ID from a prior upload
246+
Output: media attached to cell
247+
248+
### Render Final Video
249+
generation_type: "render"
250+
POST /v1/autocontentengine/{id}/cells/{cell_id}/render?agent_id={id}
251+
Composites all layers (video, audio, captions, lipsync) into a final video.
252+
Output: final video content resource in the final_video column cell
176253

177254
## Automation
178255

@@ -274,6 +351,8 @@ GET /v1/asset_libraries?agent_id={id}&folder_id={id}&asset_type={image,video,aud
274351
Unified view of files and folders. Polymorphic response — items have "type": "AssetFolder" or "ContentResource".
275352
→ [{id, type: "AssetFolder", name} | {id, type: "ContentResource", url, thumbnail_url, file_name, content_type}]
276353

354+
## Asset Folders
355+
277356
POST /v1/asset_folders?agent_id={id}
278357
Body: {asset_folder: {name, parent_id?}}
279358
→ {asset_folder_id}
@@ -289,6 +368,8 @@ Deletes folder and all contents (subfolders and files).
289368
→ 200 (empty body)
290369
Errors: 403 forbidden, 404 not_found, 422 folder_removal_failed
291370

371+
## Direct Upload
372+
292373
POST /v1/direct_upload
293374
Get a pre-signed S3 URL for large file uploads. Workflow: (1) call this, (2) PUT file to returned URL with headers, (3) use signed_id as content_resource[file].
294375
Body: {blob: {filename, byte_size (max 1GB), checksum (base64 MD5), content_type, metadata?}}
@@ -302,7 +383,49 @@ Errors: 422 invalid_content_type, 422 file_size_exceeded, 422 direct_upload_fail
302383

303384
Common codes:
304385
- 401 unauthorized — invalid API key
386+
- 403 forbidden — insufficient permissions for this resource
305387
- 404 not_found — resource doesn't exist
306388
- 422 usable_gen_credit_required — no active credits
307389
- 422 agent_not_found — invalid agent_id
308390
- 422 insufficient_credits_for_job — not enough credits
391+
- 422 validation_error — invalid request body or parameters
392+
393+
## Common Workflows
394+
395+
### Create a TikTok Video (End to End)
396+
1. GET /v1/templates/projects → pick a video template
397+
2. POST /v1/templates/spreadsheets/{slug}/clone → {agent_id} → get engine
398+
3. GET /v1/autocontentengine/{id}?agent_id={id} → see columns and cells
399+
4. PATCH /v1/autocontentengine/{id}/cells/{text_cell_id}?agent_id={id} → set script
400+
5. POST /v1/autocontentengine/{id}/cells/{video_cell_id}/generate?agent_id={id} → generate video
401+
6. GET /v1/generations/{gen_id} → poll until completed
402+
7. POST /v1/autocontentengine/{id}/cells/{audio_cell_id}/generate → generate speech
403+
8. POST /v1/autocontentengine/{id}/cells/{lipsync_cell_id}/generate → lipsync
404+
9. POST /v1/autocontentengine/{id}/cells/{final_cell_id}/render → render final video
405+
406+
### Generate Batch Images
407+
1. POST /v1/autocontentengine?agent_id={id} → create engine
408+
2. POST /v1/autocontentengine/{id}/columns?agent_id={id} → add image column
409+
3. POST /v1/autocontentengine/{id}/rows?agent_id={id} → add rows
410+
4. POST .../cells/{cell_id}/generate → generate in each cell
411+
5. GET /v1/generations/{id} → poll each generation
412+
413+
### Upload and Use a Large Asset
414+
1. POST /v1/direct_upload → get pre-signed S3 URL
415+
2. PUT file to the returned URL with Content-Type and Content-MD5 headers
416+
3. POST /v1/content_resources?agent_id={id} with signed_id as content_resource[file]
417+
4. Use the returned content_resource.id in generation data (e.g., image_resource_id, audio_resource_id)
418+
419+
### Set Up Automation Webhook
420+
1. PATCH /v1/agents/{agent_id}/automation_config → set webhook_url and callback_url
421+
2. POST /v1/agents/{agent_id}/automation_config/test_webhook → verify delivery
422+
3. POST /v1/agents/{agent_id}/automation_config/test_callback → verify callback
423+
4. Generations will now POST status updates to your webhook_url
424+
425+
## Integrations
426+
427+
MCP Server: npx @poweredbygen/autocontentengine-mcp-server@latest (env: GEN_API_KEY)
428+
TypeScript SDK: npm install @poweredbygen/autocontentengine-sdk
429+
n8n: HTTP Request node with X-API-Key header
430+
OpenAPI Spec: https://api.gen.pro/openapi.yaml
431+
Full Docs: https://api.gen.pro

0 commit comments

Comments
 (0)