Generate AgentOS posters and videos from n8n
Use an n8n HTTP Request node to submit a template-based media job, wait for the actual result, and pass the finished asset to the next approved step.
On this page
Before you start1. Connect with a read-only request2. Prepare one durable job record3. Submit the job4. Wait for completion5. Deliver or hand offLimits and recoveryBefore you start
You need an eligible AgentOS account, a saved poster or video template, authorized assets, complete template inputs, and an n8n workspace. Rendering can use production resources, including speech generation for narrated video. Test with one approved item before adding a recurring trigger.
In AgentOS, open Settings → API key, then use Show API key and Copy. Store it in an n8n credential. Do not paste it into an AI prompt, an exported workflow, a spreadsheet, or client-side JavaScript. The current AgentOS UI provides one personal key per account, not separate keys for every automation.
1. Connect with a read-only request
Create a generic Bearer Auth credential in n8n using the AgentOS key. n8n supports this authentication type for its HTTP Request node. n8n credential guide
Configure the first HTTP Request:
Method: GET
URL: https://api.bsquarerealty.com/v1/workflow-api/media/templates
Authentication: Generic Credential Type → Bearer Auth
Query parameters:
medium = poster
limit = 20
Read the returned templates and use an actual templateId. If
nextCursor is present, pass it as cursor to read another page. For video
templates, set medium=video.
Fetch the selected template:
GET https://api.bsquarerealty.com/v1/workflow-api/media/templates/TEMPLATE_ID?medium=poster
The response includes body.inputSchema. Use it to build the inputs. There is no
universal address, price, or photos payload shared by every
template.
You can ask your connected AI assistant to prepare the mapping:
Read AgentOS template [TEMPLATE ID] for [poster/video]. Return its required input fields and a complete generation request using only these approved facts and assets: [FACTS AND ASSET REFERENCES]. Use the template's real input names. Mark missing required values instead of inventing them. Do not generate anything. Do not include credentials.
2. Prepare one durable job record
Store the source record ID, medium, template ID, complete inputs, and a requestKey. Use
a different key for a genuinely new output. Reuse the same key and unchanged payload when recovering
the same submission.
The request key must be 8–160 characters. A practical format is
campaign-SOURCE_ID-poster-v1. Your automation owns this naming convention; it is not a
special AgentOS parameter.
3. Submit the job
Add a POST HTTP Request with the same credential, Content-Type: application/json, and a
JSON body. This is the request structure; replace TEMPLATE_ID and populate
inputs from the selected template before sending:
{
"action": "start",
"medium": "poster",
"templateId": "TEMPLATE_ID",
"inputs": {},
"requestKey": "campaign-SOURCE_ID-poster-v1"
}
Endpoint:
POST https://api.bsquarerealty.com/v1/workflow-api/media/generate
For a video, use medium: "video", a video template, and that template's complete
inputs. outputFormat: "mp4" is a supported video option. Supplying a poster template
with medium: "video" does not convert it into a video.
For narrated videos, prepare and review the narration and photo order first. The optional
/media/narration-review endpoint accepts templateId and
inputs; it checks the declared storyboard without generating the video. It does not
write missing narration for you. The current API key routes do not expose the separate AI
narration-drafting tool.
4. Wait for completion
A 202 response means accepted. Save operation.operationId immediately; it
is not the template ID or the video workId.
Use a Wait node, then GET:
https://api.bsquarerealty.com/v1/workflow-api/media/operations/OPERATION_ID?medium=poster
Use the matching medium and inspect operation.status:
queuedorrunning: wait, then read the same operation again.-
succeeded: inspectoperation.artifactsand select animagefor a poster or avideofor an MP4. Do not accidentally select a thumbnail or subtitles file. failedorcanceled: stop and surface the error.-
unknown: reconcile the existing operation; do not create another job automatically.
Honor nextPollAfterMs when supplied. Otherwise, start with a modest interval such as 15
seconds, cap total polling time, and retain the operation ID for later recovery. Polling must not
call the generation endpoint again.
5. Deliver or hand off
Keep the operation ID and selected artifact metadata with the source record. Check the rendered
text, photo order, dimensions, and video audio before publishing. Generated assets can have an
expiresAt; keep a stable reference to the operation so fresh authorized links can be
retrieved.
If the next step is Buffer, copy the approved file to authorized storage with a stable public media URL before scheduling. Do not rely on an expiring AgentOS download URL remaining valid until publication.
Limits and recovery
The current API key contract shares a limit of 5 submissions per minute and 100 per 24 hours across
posters, videos, and workflow runs. Reads and reviews share 60 requests per minute. On
429, honor Retry-After. A network error after POST is an uncertain
submission: preserve the original key and payload; never generate a fresh key simply to try again.
The API key surface exposes template reads, final generation, operation reads, and published custom workflow runs. It does not expose template authoring, asset upload, arbitrary MLS search, or workflow publication. Prepare those resources in AgentOS or through the appropriate authorized MCP tools.
Verification: HTTP routes and schemas were checked against the November 9, 2026 source snapshot. No key was revealed and no paid render or n8n execution was performed for this guide. Verify the first read and one approved test job in your deployed account before enabling a schedule.
