Use Canvas content with MCP
Use Glean's MCP tools to bring existing Canvas content into another AI app and save changes back to the same item in Glean. Each successful edit creates a new version while keeping the Library URL unchanged.
Canvas content is available through MCP tools. It isn't listed as an MCP resource through resources/list. The tool names use artifact for content saved from Canvas to Library.
Prerequisites
- Connect your host to a Glean MCP server.
- Confirm that the server exposes
searchandread_document(the default Glean MCP server includes both tools). - For edit access, ask your admin to add the Artifacts toolset to the server, which includes
create_artifact,edit_artifact, andshare_artifact. - Confirm that you can view the Canvas content and have edit access if you plan to change it.
Admins and MCP Server Moderators can add the toolset when they create or edit an MCP server.
Read Canvas content
Use the Library URL when you know which Canvas item you need:
- Open the content in Canvas or Library and click Share → Copy link. The URL ends with
/library/{artifact-id}. - Give the URL to your MCP host and ask it to use Glean to read the content.
- Continue your task in the host. The host uses
read_documentto retrieve the latest version as context.
For example:
Use Glean to read this Canvas content and use it as context for my next request:
https://app.glean.com/library/{artifact-id}
If you don't have the URL, ask the host to use search to find the item by title, creator, or topic, then use read_document on the result. Content shared by link without search visibility won't appear in search, so provide its Library URL directly.
Edit Canvas content
Have the host read the latest version before it makes a change. The artifact ID required by edit_artifact is the final segment of the Library URL.
For example:
Use Glean to read https://app.glean.com/library/{artifact-id}.
Update the executive summary to include the launch date, keep all other sections unchanged,
and save the update to the same Canvas content.
The host calls read_document, makes the requested change, and passes the artifact ID and updated content to edit_artifact. The edit creates a new version at the same Library URL.
edit_artifact supports documents, email drafts, messages, interactive artifacts (HTML), meeting notes, images, spreadsheets, and slides.
For documents and other text-based content, edit_artifact replaces the full body. Read the current version first and tell the host to preserve everything outside the requested change.
If another edit is saved after the host reads the item, edit_artifact rejects the update. Ask the host to read the latest version and retry.
Permissions and sharing
Your MCP connection uses your Glean identity and permissions:
searchandread_documentreturn only content that you can viewedit_artifactrequires edit access, not view accesscreate_artifactsaves new content to your Library, with you as the ownershare_artifactgrants view access when sharing is enabled for your organization
An MCP host can't use these tools to bypass Canvas permissions. Sharing through MCP also requires Chat Sharing to be enabled.