The DynaPictures connector lets your AI agent act in each user's DynaPictures account. Each user connects their own DynaPictures access token once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 17 tools.
- Tools
- 17
- What they doRead · write · destructive
- 6 · 7 · 46 read7 write4 destructive
- Users sign in with
- Access token
Setup
Install the SDK
Terminal window npm install @scalekit-sdk/node dotenvTerminal window pip install scalekit-sdk-python python-dotenvSet your credentials
Add your Scalekit credentials to your
.envfile. Find values in app.scalekit.com > Developers > API Credentials..env SCALEKIT_ENVIRONMENT_URL=<your-environment-url>SCALEKIT_CLIENT_ID=<your-client-id>SCALEKIT_CLIENT_SECRET=<your-client-secret>Create the DynaPictures connection
In AgentKit > Connections, create a DynaPictures connection. The name you give it is the
connection_nameyour code passes. See Configure connections.Authorize a user and make your first call
quickstart.mts import { ScalekitClient } from '@scalekit-sdk/node'import 'dotenv/config'import { createInterface } from 'node:readline/promises'const scalekit = new ScalekitClient(process.env.SCALEKIT_ENVIRONMENT_URL,process.env.SCALEKIT_CLIENT_ID,process.env.SCALEKIT_CLIENT_SECRET,)const actions = scalekit.actionsconst connector = 'dynapictures'const identifier = 'user_123'// Generate an authorization link for the userconst { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })console.log('Authorize DynaPictures:', link)const rl = createInterface({ input: process.stdin, output: process.stdout })await rl.question('Press Enter after authorizing...')rl.close()// Make your first callconst result = await actions.executeTool({connector,identifier,toolName: 'dynapictures_templates_list',toolInput: {},})console.log(result)Terminal window npx tsx quickstart.mtsquickstart.py import osfrom scalekit import ScalekitClientfrom dotenv import load_dotenvload_dotenv()scalekit_client = ScalekitClient(env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),client_id=os.getenv("SCALEKIT_CLIENT_ID"),client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),)actions = scalekit_client.actionsconnection_name = "dynapictures"identifier = "user_123"# Generate an authorization link for the userlink_response = actions.get_authorization_link(connection_name=connection_name,identifier=identifier,)print("Authorize DynaPictures:", link_response.link)input("Press Enter after authorizing...")# Make your first callresult = actions.execute_tool(tool_input={},tool_name="dynapictures_templates_list",connection_name=connection_name,identifier=identifier,)print(result)Terminal window python quickstart.pyEach user opens the link once and enters their DynaPictures credentials there. See Authorize a user for the full flow and statuses.
Tools
Pass the exact name toexecute_tooldynapictures_ai_image_job_getGet the status and result of an AI image generation job.Read-onlyGet AI Image Job
Get the status and result of an AI image generation job. Returns jobUid, status (queued, running, done or error), resultUrl when done, creditsCharged, creditsRemaining and error when it failed. Poll this after dynapictures_ai_image_generate. Download the resultUrl image if you need to keep it.
Inputs
job_uidstringrequired- jobUid returned by dynapictures_ai_image_generate. Example: aBcD1234eFgH5678iJkL9012.
dynapictures_media_asset_getGet one media library asset.Read-onlyGet Media Asset
Get one media library asset. Returns id, folder, mimeType, filename, size, url, thumbnailUrl, dateCreated and dateUpdated. Use dynapictures_media_assets_list to find asset IDs.
Inputs
asset_idstringrequired- ID of the asset. Example: 5a12844966.
workspace_idstringrequired- ID of the workspace, from dynapictures_workspaces_list. Example: 8eb9e4869b.
dynapictures_media_assets_listList the images and folders in a workspace's media library, 30 per page.Read-onlyList Media Assets
List the images and folders in a workspace's media library, 30 per page. Returns page, totalPages and results with id, folder, mimeType, filename, size, url, thumbnailUrl, dateCreated and dateUpdated. Use asset URLs as imageUrl values in dynapictures_image_generate.
Inputs
workspace_idstringrequired- ID of the workspace, from dynapictures_workspaces_list. Example: 8eb9e4869b.
pageinteger- Page number, starting at 1. Example: 1.
dynapictures_template_getGet one design template with its layers.Read-onlyGet Template
Get one design template with its layers. Returns id, name, thumbnail, dateCreated, dateUpdated and layers with type, name, width and height. Use this to see which layer names to customize in dynapictures_image_generate.
Inputs
template_idstringrequired- ID of the design template, shown in the top-left corner of the template page or returned by dynapictures_templates_list. Example: debcaw6f99.
dynapictures_templates_listList the design templates that are ready for API use (the Sync to Zapier option is on).Read-onlyList Templates
List the design templates that are ready for API use (the Sync to Zapier option is on). Returns templates with id, name, thumbnail, dateCreated, dateUpdated and layers (type, name, width, height). Use this to find template IDs and layer names before dynapictures_image_generate. Use dynapictures_template_get for one template.
Inputs
This tool takes no inputs.
dynapictures_workspaces_listList the workspaces the API key's user is a member of.Read-onlyList Workspaces
List the workspaces the API key's user is a member of. Returns workspaces with id, name, dateCreated and dateUpdated. Use this to find a workspace ID for the media library tools.
Inputs
This tool takes no inputs.
dynapictures_ai_image_generateStart an AI image generation job from a text prompt, optionally editing a source photo or using named reference images.WriteStart AI Image Generation
Start an AI image generation job from a text prompt, optionally editing a source photo or using named reference images. Returns jobUid and status queued (HTTP 202). Poll dynapictures_ai_image_job_get with the jobUid until status is done. Uses AI credits that depend on the model; a 4xx means the job was not queued.
Inputs
model_idstringrequired- AI model to use, for example gemini-3.1-flash-image (Nano Banana), nano-banana-pro, gpt-image-1-mini, gpt-image-2-low, gpt-image-2-med or flux-2-pro. See https://dynapictures.com/docs/ for the list and credit costs. Example: gemini-3.1-flash-image.
promptstringrequired- Text prompt describing the image. Reference images by [name] tokens. Example: A photorealistic cup of coffee on a wooden table, soft morning light.
ratiostring- Aspect ratio. Default 1:1; supported ratios vary by model. Example: 16:9.one of
1:13:22:316:99:164:33:4 reference_imagesarray- Named reference images, each with a name (used as [name] in the prompt) and a public url. At most 6 input images in total including source_image. Example: [{"name": "logo", "url": "https://example.com/logo.png"}]
source_imagestring- URL of a photo to edit (image-to-image). Leave empty for text-to-image. Editing models only. Example: https://example.com/product.jpg.
dynapictures_image_generateGenerate an image from a DynaPictures design template, replacing text, images and styling in its layers.WriteGenerate Image
Generate an image from a DynaPictures design template, replacing text, images and styling in its layers. Returns id, templateId, imageUrl, thumbnailUrl, retinaThumbnailUrl, metadata, width and height. Use this for single-page templates. Use dynapictures_multipage_images_generate for multi-page templates, dynapictures_pdf_generate for a PDF and dynapictures_templates_list to find template IDs and layer names. Each image uses one credit.
Inputs
template_idstringrequired- ID of the design template, shown in the top-left corner of the template page or returned by dynapictures_templates_list. Example: debcaw6f99.
formatstring- Image file format. Default is the template's format. Example: png.one of
pngjpegwebpavif metadatastring- Custom text stored with the generated image and returned in the response and webhooks. Example: Post for @acme on Monday.
paramsarray- Layers to customize. Each layer object names the layer to change (name, as shown in the template's settings panel) and its new values: text and color for text layers; imageUrl plus optional imagePosition, imageAlignH and imageAlignV for image layers; and styling such as backgroundColor, borderColor, borderWidth, borderRadius and opacity. Example: [{"name": "title", "text": "Summer Sale", "color": "#333"}, {"name": "image1", "imageUrl": "https://example.com/photo.jpg"}]
dynapictures_multipage_images_generateGenerate one image per page from a multi-page DynaPictures design template, customizing each page's layers.WriteGenerate Multipage Images
Generate one image per page from a multi-page DynaPictures design template, customizing each page's layers. Returns templateId, templateName and pages, each with id, imageUrl, thumbnailUrl, width, height and pageIndex. Use this for carousels and multi-page designs. Use dynapictures_pdf_generate to get one PDF instead. Each page uses one credit.
Inputs
pagesarrayrequired- Pages to customize. Each page has its zero-based index and a layers array. Each layer object names the layer to change (name, as shown in the template's settings panel) and its new values: text and color for text layers; imageUrl plus optional imagePosition, imageAlignH and imageAlignV for image layers; and styling such as backgroundColor, borderColor, borderWidth, borderRadius and opacity. Example: [{"index": 0, "layers": [{"name": "text1", "text": "Page one title"}]}, {"index": 1, "layers": [{"name": "image4", "imageUrl": "https://example.com/photo.jpg...
template_idstringrequired- ID of the design template, shown in the top-left corner of the template page or returned by dynapictures_templates_list. Example: debcaw6f99.
formatstring- Image file format for every page. Example: jpeg.one of
pngjpegwebpavif metadatastring- Custom text stored with the generated images. Example: Carousel for campaign 42.
dynapictures_pdf_generateGenerate a single PDF from a multi-page DynaPictures design template, customizing each page's layers.WriteGenerate PDF
Generate a single PDF from a multi-page DynaPictures design template, customizing each page's layers. Returns id, templateId, templateName, pdfUrl (also imageUrl), thumbnailUrl, metadata, width and height. Use this for brochures, certificates and other multi-page documents. Use dynapictures_multipage_images_generate for separate images. Each page uses one credit.
Inputs
pagesarrayrequired- Pages to customize. Each page has its zero-based index and a layers array. Each layer object names the layer to change (name, as shown in the template's settings panel) and its new values: text and color for text layers; imageUrl plus optional imagePosition, imageAlignH and imageAlignV for image layers; and styling such as backgroundColor, borderColor, borderWidth, borderRadius and opacity. Example: [{"index": 0, "layers": [{"name": "text1", "text": "Page one title"}]}, {"index": 1, "layers": [{"name": "image4", "imageUrl": "https://example.com/photo.jpg...
template_idstringrequired- ID of the design template, shown in the top-left corner of the template page or returned by dynapictures_templates_list. Example: debcaw6f99.
metadatastring- Custom text stored with the generated PDF. Example: Certificate for Jane Doe.
dynapictures_webhook_subscribeSubscribe a URL to receive a notification each time a new image is generated from a template.WriteSubscribe Webhook
Subscribe a URL to receive a notification each time a new image is generated from a template. Returns the subscription with targetUrl, eventType, templateId, id and dateCreated. Use dynapictures_webhook_unsubscribe with the same values to stop it.
Inputs
target_urlstringrequired- URL of your endpoint that receives the new-image notifications. Example: https://example.com/webhooks/dynapictures.
template_idstringrequired- ID of the design template whose new images trigger the webhook. Example: 000d61e4f7.
dynapictures_workspace_createCreate a new workspace, for example one per client.WriteCreate Workspace
Create a new workspace, for example one per client. Returns the workspace with id, name, dateCreated and dateUpdated. Only account admins can create workspaces.
Inputs
namestringrequired- Name of the new workspace. Example: Banners for client 22.
dynapictures_workspace_updateRename a workspace.WriteRename Workspace
Rename a workspace. Returns the workspace with id, name, dateCreated and dateUpdated. Only account admins can modify workspaces.
- Idempotent
Inputs
namestringrequired- New name of the workspace. Example: Banners for client 1234.
workspace_idstringrequired- ID of the workspace to rename, from dynapictures_workspaces_list. Example: 74b5b2c96a.
dynapictures_image_deleteDelete a previously generated image from DynaPictures' servers.DestructiveDelete Generated Image
Delete a previously generated image from DynaPictures' servers. Returns 200 with no body. Take the two path parts from the image URL: for https://edge.dynapictures.com/ff01d10f8d/9be4738250.png the folder is ff01d10f8d and the file is 9be4738250.png.
- Idempotent
Inputs
image_filestringrequired- File name of the generated image, the last segment of its URL including the extension. Example: 9be4738250.png.
image_folderstringrequired- First path segment of the generated image URL after the host. Example: ff01d10f8d.
dynapictures_media_asset_deletePermanently delete an image or folder from a workspace's media library.DestructiveDelete Media Asset
Permanently delete an image or folder from a workspace's media library. Returns the deleted asset's fields. Use dynapictures_media_assets_list to find asset IDs.
- Idempotent
Inputs
asset_idstringrequired- ID of the asset to delete. Example: 5a12844966.
workspace_idstringrequired- ID of the workspace, from dynapictures_workspaces_list. Example: 8eb9e4869b.
dynapictures_webhook_unsubscribeRemove a new-image webhook subscription.DestructiveUnsubscribe Webhook
Remove a new-image webhook subscription. Returns error false and a message. Send the same target URL and template ID used in dynapictures_webhook_subscribe.
- Idempotent
Inputs
target_urlstringrequired- URL of your endpoint that receives the new-image notifications. Example: https://example.com/webhooks/dynapictures.
template_idstringrequired- ID of the design template whose new images trigger the webhook. Example: 000d61e4f7.
dynapictures_workspace_deletePermanently delete a workspace with all its templates, media library files and generated images.DestructiveDelete Workspace
Permanently delete a workspace with all its templates, media library files and generated images. Returns the deleted workspace's id, name, dateCreated and dateUpdated. This cannot be undone. Needs workspace admin permission.
- Idempotent
Inputs
workspace_idstringrequired- ID of the workspace to delete, from dynapictures_workspaces_list. Example: 74b5b2c96a.
No tools match.