Images
When creating a content extension, one of the available options for the Content type field is Images. If you select this option, the extension can import image files, such as photos or illustrations, into Canva.
Examples
These are some examples of apps with content extensions that support images:
To find more examples, see canva.com/apps.
Supported image types
This section describes the types of images a content extension can import into Canva.
GIF
You can't import GIFs into Canva as images. You can only import them as embeds or videos.
JPG / JPEG
- Under 25 MB in size
- Not more than 100 million total pixels (width × height)
PNG
- Under 25 MB in size
- Not more than 100 million total pixels (width × height)
HEIC
- Under 25 MB in size
- Not more than 100 million total pixels (width × height)
SVG
- Under 10 MB in size
- Saved with an SVG Profile of "SVG 1.1"
The following elements are stripped from SVG images:
script
metadata
style
Additional considerations
- Cross-Origin Resource Sharing (CORS) can interfere with the importing of images. To learn more, see CORS.
- For guidelines on choosing the layout that's most appropriate for your content type, see Choose the best layout.
Example
const axios = require("axios");const express = require("express");const app = express();app.use(express.json());app.use(express.static("public"));app.post("/content/resources/find", async (request, response) => {// Get a list of imagesconst { data } = await axios.get("https://picsum.photos/v2/list");// Create an array of resourcesconst resources = data.map((resource) => {return {type: "IMAGE",id: resource.id, // This ID should always refer to the same piece of medianame: resource.author || resource.id,thumbnail: {url: resource.download_url,},url: resource.download_url,contentType: "image/jpeg",};});// Respond with the resourcesresponse.send({type: "SUCCESS",resources,});});app.listen(process.env.PORT || 3000);
javascript