Make a canvas public
Create a public share link for a canvas. Anyone with the link can view the canvas.
By default, the request blocks until a thumbnail has been generated so the share URL
will unfurl properly when shared on social media or messaging platforms.
Set wait_for_thumbnail: false to return immediately.
Authorization
bearerAuth API key from Settings > Developer > REST API. Format: moda_live_...
In: header
Path Parameters
UUID of the canvas to make public.
uuidRequest Body
application/json
Permission level for the share link. 'view' allows anyone with the link to view the canvas. 'view_remix' (default) allows anyone to view and create a remix copy of the canvas.
"view_remix""view" | "view_remix"If true (default), the request blocks until the canvas thumbnail has been generated. This ensures the share URL will unfurl properly with a preview image when shared on social media or messaging platforms. If false, returns immediately after making the canvas public (thumbnail generation runs in the background).
trueMaximum seconds to wait for thumbnail generation when wait_for_thumbnail=true. If the timeout is reached, the response is returned with thumbnail_ready=false. Min 1, max 120. Ignored when wait_for_thumbnail=false.
301 <= value <= 120Response Body
application/json
application/json
curl -X POST "https://api.moda.app/v1/canvases/497f6eca-6276-4993-bfeb-53cbbbba6f08/share" \ -H "Content-Type: application/json" \ -d '{}'{
"share_url": "http://example.com",
"share_token": "string",
"public_enabled": true,
"permission": "view",
"thumbnail_ready": true
}{
"error": {
"type": "invalid_request",
"code": "file_not_found",
"message": "Canvas cvs_abc123 not found",
"doc_url": "https://docs.moda.app/errors/file_not_found",
"request_id": "019d8996-16b3-73ee-841a-5bc5038eb972",
"causes": [
{
"type": "invalid_request",
"code": "file_not_found",
"message": "Canvas cvs_abc123 not found",
"doc_url": "https://docs.moda.app/errors/file_not_found",
"request_id": "019d8996-16b3-73ee-841a-5bc5038eb972",
"causes": [],
"details": {},
"retry_after_ms": 0
}
],
"details": {},
"retry_after_ms": 0
}
}