canva-automation

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Canva Automation via Rube MCP

通过Rube MCP实现Canva自动化

Automate Canva design operations through Composio's Canva toolkit via Rube MCP.
通过Composio的Canva工具包,借助Rube MCP自动化Canva设计操作。

Prerequisites

前提条件

  • Rube MCP must be connected (RUBE_SEARCH_TOOLS available)
  • Active Canva connection via
    RUBE_MANAGE_CONNECTIONS
    with toolkit
    canva
  • Always call
    RUBE_SEARCH_TOOLS
    first to get current tool schemas
  • 必须已连接Rube MCP(需提供RUBE_SEARCH_TOOLS)
  • 通过
    RUBE_MANAGE_CONNECTIONS
    并使用工具包
    canva
    建立有效的Canva连接
  • 请始终先调用
    RUBE_SEARCH_TOOLS
    以获取最新的工具模式

Setup

设置步骤

Get Rube MCP: Add
https://rube.app/mcp
as an MCP server in your client configuration. No API keys needed — just add the endpoint and it works.
  1. Verify Rube MCP is available by confirming
    RUBE_SEARCH_TOOLS
    responds
  2. Call
    RUBE_MANAGE_CONNECTIONS
    with toolkit
    canva
  3. If connection is not ACTIVE, follow the returned auth link to complete Canva OAuth
  4. Confirm connection status shows ACTIVE before running any workflows
获取Rube MCP:在客户端配置中添加
https://rube.app/mcp
作为MCP服务器。无需API密钥 —— 只需添加端点即可使用。
  1. 通过确认
    RUBE_SEARCH_TOOLS
    能正常响应,验证Rube MCP是否可用
  2. 使用工具包
    canva
    调用
    RUBE_MANAGE_CONNECTIONS
  3. 如果连接状态未处于ACTIVE,请按照返回的授权链接完成Canva OAuth认证
  4. 在运行任何工作流之前,确认连接状态显示为ACTIVE

Core Workflows

核心工作流

1. List and Browse Designs

1. 列出与浏览设计

When to use: User wants to find existing designs or browse their Canva library
Tool sequence:
  1. CANVA_LIST_USER_DESIGNS
    - List all designs with optional filters [Required]
Key parameters:
  • query
    : Search term to filter designs by name
  • continuation
    : Pagination token from previous response
  • ownership
    : Filter by 'owned', 'shared', or 'any'
  • sort_by
    : Sort field (e.g., 'modified_at', 'title')
Pitfalls:
  • Results are paginated; follow
    continuation
    token until absent
  • Deleted designs may still appear briefly; check design status
  • Search is substring-based, not fuzzy matching
适用场景:用户想要查找现有设计或浏览其Canva素材库
工具执行顺序:
  1. CANVA_LIST_USER_DESIGNS
    - 列出所有设计,可选择添加筛选条件 [必填]
关键参数:
  • query
    : 用于按名称筛选设计的搜索词
  • continuation
    : 来自上一次响应的分页令牌
  • ownership
    : 按“owned(自有)”、“shared(共享)”或“any(全部)”筛选
  • sort_by
    : 排序字段(例如:'modified_at'、'title')
注意事项:
  • 结果是分页的;需持续使用
    continuation
    令牌直到其不存在
  • 已删除的设计可能仍会短暂显示;请检查设计状态
  • 搜索是基于子字符串的,而非模糊匹配

2. Create and Design

2. 创建与设计

When to use: User wants to create a new Canva design from scratch or from a template
Tool sequence:
  1. CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
    - Browse available brand templates [Optional]
  2. CANVA_CREATE_CANVA_DESIGN_WITH_OPTIONAL_ASSET
    - Create a new design [Required]
Key parameters:
  • design_type
    : Type of design (e.g., 'Presentation', 'Poster', 'SocialMedia')
  • title
    : Name for the new design
  • asset_id
    : Optional asset to include in the design
  • width
    /
    height
    : Custom dimensions in pixels
Pitfalls:
  • Design type must match Canva's predefined types exactly
  • Custom dimensions have minimum and maximum limits
  • Asset must be uploaded first via CANVA_CREATE_ASSET_UPLOAD_JOB before referencing
适用场景:用户想要从零开始或基于模板创建新的Canva设计
工具执行顺序:
  1. CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
    - 浏览可用的品牌模板 [可选]
  2. CANVA_CREATE_CANVA_DESIGN_WITH_OPTIONAL_ASSET
    - 创建新设计 [必填]
关键参数:
  • design_type
    : 设计类型(例如:'Presentation'、'Poster'、'SocialMedia')
  • title
    : 新设计的名称
  • asset_id
    : 可选,要包含在设计中的资产ID
  • width
    /
    height
    : 自定义尺寸(像素)
注意事项:
  • 设计类型必须与Canva预定义的类型完全匹配
  • 自定义尺寸有最小和最大限制
  • 资产必须先通过
    CANVA_CREATE_ASSET_UPLOAD_JOB
    上传后才能引用

3. Upload Assets

3. 上传资产

When to use: User wants to upload images or files to Canva for use in designs
Tool sequence:
  1. CANVA_CREATE_ASSET_UPLOAD_JOB
    - Initiate the asset upload [Required]
  2. CANVA_FETCH_ASSET_UPLOAD_JOB_STATUS
    - Poll until upload completes [Required]
Key parameters:
  • name
    : Display name for the asset
  • url
    : Public URL of the file to upload (for URL-based uploads)
  • job_id
    : Upload job ID returned from step 1 (for status polling)
Pitfalls:
  • Upload is asynchronous; you MUST poll the job status until it completes
  • Supported formats include PNG, JPG, SVG, MP4, GIF
  • File size limits apply; large files may take longer to process
  • The
    job_id
    from CREATE returns the ID needed for status polling
  • Status values: 'in_progress', 'success', 'failed'
适用场景:用户想要将图片或文件上传到Canva以用于设计
工具执行顺序:
  1. CANVA_CREATE_ASSET_UPLOAD_JOB
    - 启动资产上传 [必填]
  2. CANVA_FETCH_ASSET_UPLOAD_JOB_STATUS
    - 轮询直到上传完成 [必填]
关键参数:
  • name
    : 资产的显示名称
  • url
    : 要上传的文件的公共URL(基于URL的上传)
  • job_id
    : 步骤1返回的上传任务ID(用于状态轮询)
注意事项:
  • 上传是异步的;必须轮询任务状态直到完成
  • 支持的格式包括PNG、JPG、SVG、MP4、GIF
  • 存在文件大小限制;大文件可能需要更长处理时间
  • CREATE
    操作返回的
    job_id
    是状态轮询所需的ID
  • 状态值:'in_progress'、'success'、'failed'

4. Export Designs

4. 导出设计

When to use: User wants to download or export a Canva design as PDF, PNG, or other format
Tool sequence:
  1. CANVA_LIST_USER_DESIGNS
    - Find the design to export [Prerequisite]
  2. CANVA_CREATE_CANVA_DESIGN_EXPORT_JOB
    - Start the export process [Required]
  3. CANVA_GET_DESIGN_EXPORT_JOB_RESULT
    - Poll until export completes and get download URL [Required]
Key parameters:
  • design_id
    : ID of the design to export
  • format
    : Export format ('pdf', 'png', 'jpg', 'svg', 'mp4', 'gif', 'pptx')
  • pages
    : Specific page numbers to export (array)
  • quality
    : Export quality ('regular', 'high')
  • job_id
    : Export job ID for polling status
Pitfalls:
  • Export is asynchronous; you MUST poll the job result until it completes
  • Download URLs from completed exports expire after a limited time
  • Large designs with many pages take longer to export
  • Not all formats support all design types (e.g., MP4 only for animations)
  • Poll interval: wait 2-3 seconds between status checks
适用场景:用户想要将Canva设计下载或导出为PDF、PNG或其他格式
工具执行顺序:
  1. CANVA_LIST_USER_DESIGNS
    - 找到要导出的设计 [前提步骤]
  2. CANVA_CREATE_CANVA_DESIGN_EXPORT_JOB
    - 启动导出流程 [必填]
  3. CANVA_GET_DESIGN_EXPORT_JOB_RESULT
    - 轮询直到导出完成并获取下载URL [必填]
关键参数:
  • design_id
    : 要导出的设计ID
  • format
    : 导出格式('pdf'、'png'、'jpg'、'svg'、'mp4'、'gif'、'pptx')
  • pages
    : 要导出的特定页码(数组)
  • quality
    : 导出质量('regular'、'high')
  • job_id
    : 用于轮询状态的导出任务ID
注意事项:
  • 导出是异步的;必须轮询任务结果直到完成
  • 完成导出后获得的下载URL会在一段时间后过期
  • 包含多个页面的大型设计导出时间更长
  • 并非所有格式都支持所有设计类型(例如:MP4仅适用于动画设计)
  • 轮询间隔:状态检查之间等待2-3秒

5. Organize with Folders

5. 使用文件夹整理

When to use: User wants to create folders or organize designs into folders
Tool sequence:
  1. CANVA_POST_FOLDERS
    - Create a new folder [Required]
  2. CANVA_MOVE_ITEM_TO_SPECIFIED_FOLDER
    - Move designs into folders [Optional]
Key parameters:
  • name
    : Folder name
  • parent_folder_id
    : Parent folder for nested organization
  • item_id
    : ID of the design or asset to move
  • folder_id
    : Target folder ID
Pitfalls:
  • Folder names must be unique within the same parent folder
  • Moving items between folders updates their location immediately
  • Root-level folders have no parent_folder_id
适用场景:用户想要创建文件夹或将设计整理到文件夹中
工具执行顺序:
  1. CANVA_POST_FOLDERS
    - 创建新文件夹 [必填]
  2. CANVA_MOVE_ITEM_TO_SPECIFIED_FOLDER
    - 将设计移动到文件夹中 [可选]
关键参数:
  • name
    : 文件夹名称
  • parent_folder_id
    : 用于嵌套整理的父文件夹ID
  • item_id
    : 要移动的设计或资产ID
  • folder_id
    : 目标文件夹ID
注意事项:
  • 同一父文件夹下的文件夹名称必须唯一
  • 在文件夹之间移动项目会立即更新其位置
  • 根级文件夹没有
    parent_folder_id

6. Autofill from Brand Templates

6. 从品牌模板自动填充

When to use: User wants to generate designs by filling brand template placeholders with data
Tool sequence:
  1. CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
    - List available brand templates [Required]
  2. CANVA_INITIATE_CANVA_DESIGN_AUTOFILL_JOB
    - Start autofill with data [Required]
Key parameters:
  • brand_template_id
    : ID of the brand template to use
  • title
    : Title for the generated design
  • data
    : Key-value mapping of placeholder names to replacement values
Pitfalls:
  • Template placeholders must match exactly (case-sensitive)
  • Autofill is asynchronous; poll for completion
  • Only brand templates support autofill, not regular designs
  • Data values must match the expected type for each placeholder (text, image URL)
适用场景:用户想要通过用数据填充品牌模板占位符来生成设计
工具执行顺序:
  1. CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
    - 列出可用的品牌模板 [必填]
  2. CANVA_INITIATE_CANVA_DESIGN_AUTOFILL_JOB
    - 使用数据启动自动填充 [必填]
关键参数:
  • brand_template_id
    : 要使用的品牌模板ID
  • title
    : 生成的设计的标题
  • data
    : 占位符名称与替换值的键值对映射
注意事项:
  • 模板占位符必须完全匹配(区分大小写)
  • 自动填充是异步的;需轮询直到完成
  • 只有品牌模板支持自动填充,普通设计不支持
  • 数据值必须与每个占位符的预期类型匹配(文本、图片URL)

Common Patterns

常见模式

Async Job Pattern

异步任务模式

Many Canva operations are asynchronous:
1. Initiate job (upload, export, autofill) -> get job_id
2. Poll status endpoint with job_id every 2-3 seconds
3. Check for 'success' or 'failed' status
4. On success, extract result (asset_id, download_url, design_id)
许多Canva操作是异步的:
1. Initiate job (upload, export, autofill) -> get job_id
2. Poll status endpoint with job_id every 2-3 seconds
3. Check for 'success' or 'failed' status
4. On success, extract result (asset_id, download_url, design_id)

ID Resolution

ID解析

Design name -> Design ID:
1. Call CANVA_LIST_USER_DESIGNS with query=design_name
2. Find matching design in results
3. Extract id field
Brand template name -> Template ID:
1. Call CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
2. Find template by name
3. Extract brand_template_id
设计名称 -> 设计ID:
1. Call CANVA_LIST_USER_DESIGNS with query=design_name
2. Find matching design in results
3. Extract id field
品牌模板名称 -> 模板ID:
1. Call CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
2. Find template by name
3. Extract brand_template_id

Pagination

分页

  • Check response for
    continuation
    token
  • Pass token in next request's
    continuation
    parameter
  • Continue until
    continuation
    is absent or empty
  • 检查响应中是否存在
    continuation
    令牌
  • 将令牌传入下一次请求的
    continuation
    参数
  • 持续直到
    continuation
    不存在或为空

Known Pitfalls

已知注意事项

Async Operations:
  • Uploads, exports, and autofills are all asynchronous
  • Always poll job status; do not assume immediate completion
  • Download URLs from exports expire; use them promptly
Asset Management:
  • Assets must be uploaded before they can be used in designs
  • Upload job must reach 'success' status before the asset_id is valid
  • Supported formats vary; check Canva documentation for current limits
Rate Limits:
  • Canva API has rate limits per endpoint
  • Implement exponential backoff for bulk operations
  • Batch operations where possible to reduce API calls
Response Parsing:
  • Response data may be nested under
    data
    key
  • Job status responses include different fields based on completion state
  • Parse defensively with fallbacks for optional fields
异步操作:
  • 上传、导出和自动填充均为异步操作
  • 始终轮询任务状态;不要假设会立即完成
  • 导出获得的下载URL会过期;请及时使用
资产管理:
  • 资产必须先上传才能在设计中使用
  • 上传任务必须达到'success'状态后,asset_id才有效
  • 支持的格式会有所不同;请查看Canva文档了解当前限制
速率限制:
  • Canva API对每个端点都有速率限制
  • 对批量操作实现指数退避策略
  • 尽可能批量处理以减少API调用次数
响应解析:
  • 响应数据可能嵌套在
    data
    键下
  • 任务状态响应会根据完成状态包含不同的字段
  • 带回退机制地解析可选字段

Quick Reference

快速参考

TaskTool SlugKey Params
List designsCANVA_LIST_USER_DESIGNSquery, continuation
Create designCANVA_CREATE_CANVA_DESIGN_WITH_OPTIONAL_ASSETdesign_type, title
Upload assetCANVA_CREATE_ASSET_UPLOAD_JOBname, url
Check uploadCANVA_FETCH_ASSET_UPLOAD_JOB_STATUSjob_id
Export designCANVA_CREATE_CANVA_DESIGN_EXPORT_JOBdesign_id, format
Get exportCANVA_GET_DESIGN_EXPORT_JOB_RESULTjob_id
Create folderCANVA_POST_FOLDERSname, parent_folder_id
Move to folderCANVA_MOVE_ITEM_TO_SPECIFIED_FOLDERitem_id, folder_id
List templatesCANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST(none)
Autofill templateCANVA_INITIATE_CANVA_DESIGN_AUTOFILL_JOBbrand_template_id, data
任务工具标识关键参数
列出设计CANVA_LIST_USER_DESIGNSquery, continuation
创建设计CANVA_CREATE_CANVA_DESIGN_WITH_OPTIONAL_ASSETdesign_type, title
上传资产CANVA_CREATE_ASSET_UPLOAD_JOBname, url
检查上传状态CANVA_FETCH_ASSET_UPLOAD_JOB_STATUSjob_id
导出设计CANVA_CREATE_CANVA_DESIGN_EXPORT_JOBdesign_id, format
获取导出结果CANVA_GET_DESIGN_EXPORT_JOB_RESULTjob_id
创建文件夹CANVA_POST_FOLDERSname, parent_folder_id
移动至文件夹CANVA_MOVE_ITEM_TO_SPECIFIED_FOLDERitem_id, folder_id
列出模板CANVA_ACCESS_USER_SPECIFIC_BRAND_TEMPLATES_LIST
模板自动填充CANVA_INITIATE_CANVA_DESIGN_AUTOFILL_JOBbrand_template_id, data