Skip to main content
Glama
GUIPETAV

canva-mcp-server

by GUIPETAV

canva-mcp-server

License: MIT Node

教育用のMCP(Model Context Protocol)サーバーで、AIエージェントを Canva Connect API に接続します。創造的なAIメディアに関する授業教材として作成され、MCPサーバーの構造を実際に示します。

機能

AIエージェント(Claude など)が呼び出せる3つのツールを公開します。

ツール

説明

canva_search_designs

Canvaアカウントの既存デザインをタイトルで検索する

canva_create_design

新しい空白のデザイン(ポスター、プレゼンテーション、Instagram投稿など)を作成する

canva_export_design

デザインをPNG、JPG、PDF、PPTX、GIF、MP4として書き出す

Related MCP server: mcp-toolbox

プロジェクト構成

canva-mcp-server/
├── package.json
├── tsconfig.json
├── src/
│   ├── index.ts              # ponto de entrada, registra as ferramentas
│   ├── constants.ts
│   ├── services/canva.ts     # cliente HTTP + tratamento de erros da API
│   └── tools/                # uma ferramenta por arquivo
│       ├── searchDesigns.ts
│       ├── createDesign.ts
│       └── exportDesign.ts

1. 依存関係をインストールする

cd canva-mcp-server
npm install

2. Canvaのアクセストークンを取得する

Canva Connect API は OAuth 2.0(Authorization Code + PKCE)を使用します。手順は次のとおりです。

  1. Canva Developer Portal にアクセスしてアプリを作成します(タイプは「Connect API integration」)。

  2. Client IDClient Secret を控えます。

  3. Redirect URI を設定します(ローカルテスト用には、http://127.0.0.1:3333/callback など)。

  4. 必要なスコープを最低限 design:content:read, design:content:write, design:meta:read, asset:read に設定します。

  5. Canva の OAuth フロー(ブラウザでの認可 → codeaccess_token と交換)に従います。公式ガイドは https://www.canva.dev/docs/connect/authentication/ にあります。授業では、Postman/Insomnia の内蔵 OAuth2 フローを使うか、Canva Developer Portal 内のサンプルスクリプトを使うのが最も簡単です。

  6. 取得した access_token を保存します(期限切れになるため、継続して使うにはリフレッシュトークンの実装が必要です。これは受講者向けの上級課題とします)。

3. 環境変数を設定する

export CANVA_ACCESS_TOKEN="seu_access_token_aqui"

(リポジトリには同じテンプレートの .env.example があります。必要なら .env ファイルを使用してください)

4. ビルドと実行

npm run build
npm start

自動リロード付きで開発する場合:

npm run dev

5. Claude Code / Claude Desktop に接続する

自分の mcp 設定(例: プロジェクトの .claude/settings.json または claude_desktop_config.json)に追加します:

{
  "mcpServers": {
    "canva": {
      "command": "node",
      "args": ["/caminho/absoluto/para/canva-mcp-server/dist/index.js"],
      "env": {
        "CANVA_ACCESS_TOKEN": "seu_access_token_aqui"
      }
    }
  }
}

6. MCP Inspector でテストする

npx @modelcontextprotocol/inspector node dist/index.js

これにより、ツールを手動で呼び出して結果を確認できるWebインターフェースが開きます。実際のエージェントに接続する前に授業でデモンストレーションするのに最適です。

受講者向け演習のアイデア

  • canva_list_brand_templates ツールを追加する(ブランドテンプレートを使用)。

  • アクセストークンの自動更新を実装する。

  • MCP のベストプラクティスガイドに従って、response_format(markdown か JSON か)のサポートを追加する。

  • トランスポートを stdio から Streamable HTTP に変更し、リモートサービスとして実行する。

ライセンス

MIT

Install Server
A
license - permissive license
A
quality
C
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Servers

  • A
    license
    Not graded
    quality
    D
    maintenance
    A comprehensive MCP server enabling LLMs to execute commands, manage files, interact with Figma, search the web, generate images, and more, extending their capabilities beyond text generation.
    Apache 2.0
  • A
    license
    Not graded
    quality
    D
    maintenance
    A Model Context Protocol (MCP) server for Canva integration. Connect Claude Code or any MCP-compatible AI client to your Canva account to search designs, generate AI designs, edit content, manage folders, and collaborate through comments.
    2
    MIT

View all related MCP servers

Related MCP Connectors

  • Connect AI agents to Flato's editable canvas runtime through a hosted MCP server.

  • Hosted MCP server connecting claude.ai, ChatGPT and other AI apps to your own computer

  • An MCP server that gives your AI access to the source code and docs of all public github repos

View all MCP Connectors

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/GUIPETAV/canva-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server