Mitone
Sign in
Interactive Drama

Sharing, QR Codes and Embedding

Copy a work's watch link and password, download its QR code, embed it with the embed code or player SDK, choose which sites may embed it, and see where oEmbed and WeChat sharing stand.

Sign-in requiredVerified on v0.36.23

Once a work is online, you can send viewers its watch link or QR code, or embed the player in your own website. Sharing and embedding don't use credits.

Before you start

  • The work is published and online; see Publish Check and Publish Settings. If it was published but isn't online now, you can still copy the link, QR code and embed code, but viewers can't open them.
  • A private work's access password is shown only to people with publishing rights: the creator for personal projects, a team admin for team projects.

Open the share panel

The Share tab of the publish center: watch link, QR code, embed code and SDK code

  • Open the Share tab in the editor's Publish center.
  • Or click Share in the project card menu in the project center. Only projects that have been published have this item.

If the work hasn't been published, the panel shows Not published yet; if it's published but not online, it shows Current status: … and The link, QR code and embed code work once the work is online.

  • The Watch link is the address of the work's public watch page; click Copy link to copy it.
  • For a private work, click Copy link and password to copy the link and the access password as two lines you can send straight to viewers.
  • Viewers who open the link see the start page first and click Start watching; for a private work they enter the access password first. For the viewer side, see The Viewer Experience.

QR code

The QR code in the panel encodes the watch link and is generated locally in your browser. Click Download QR code to save it as a PNG image for posters or printed materials.

To try a draft on your phone before publishing, use Preview on phone in the editor's More menu; no publishing is needed. See Preview on a phone.

Share poster

Once the work is online, the panel has a Share poster: it combines the share cover, the work's title, a QR code to watch and the AI generated label into one image, made and downloaded on your device.

Under Share poster, pick a size: 9:16 or 1:1, plus 16:9 for landscape works.

Click Download poster to save it as a PNG image.

  • The QR code on the poster opens the watch link with the share source ?ch=share; viewers who come from the poster count under Channel share in the data center's Source. See Space data.
  • Posters for private works don't include the access password.
  • There's no poster until the work is online; if making one fails, you see Couldn't create the poster. Try again.

Embed code

The Embed code is an iframe snippet; paste it into a web page to play the work there. The embed page shows only the player. Click Copy embed code to copy it. It looks like this:

<iframe src="<site address>/embed/idrama/<work ID>"
        style="width:100%;max-width:360px;aspect-ratio:9 / 16;border:0"
        allow="autoplay; fullscreen; picture-in-picture; web-share; clipboard-write" allowfullscreen
        referrerpolicy="strict-origin-when-cross-origin"></iframe>
  • The maximum width and aspect ratio follow the work's aspect ratio; adjust them as needed.
  • <work ID> can also be a series ID: playback starts from episode 1 and continues to the next episode in the same frame. See Series.
  • If your page has a content security policy, allow loading Mitone's player page and SDK script.

Player SDK

To control playback or receive story events from your page, use the player SDK instead. Click Copy SDK code to copy it:

<script src="<site address>/sdk/idrama-player.v1.js" async></script>
<mitone-idrama work="<work ID>"></mitone-idrama>

Attributes of the <mitone-idrama> tag:

AttributeDescription
workThe work or series ID; required
langInterface language, zh-CN or en-US; defaults to the browser language
autoplayStarts playing once loaded; if the browser blocks autoplay with sound, a click-to-play prompt is shown
controlscontrols="false" hides the player controls; it can only hide controls turned on in the work's settings, not add any
titleAccessible title of the player frame

From your page's script, call the tag's methods to control playback: ready(), play(), pause(), seek(positionMs), choose(output), setMuted(muted), restart() and getState(). All methods return a Promise and reject with an error carrying an error code when they fail.

The player dispatches events named idrama:<event name>. Common ones:

EventWhen
idrama:readyThe player is ready, with the work's title and aspect ratio
idrama:statechangeThe playback state changes, for example playing, paused, waiting for the viewer, ended
idrama:nodeenterA story node starts
idrama:interactionThe viewer makes a choice or completes an interaction
idrama:variablechangeA variable changes; only variables set to Expose in the variables panel are included, see Create and manage variables
idrama:endingAn ending is reached
idrama:seriesnextA series moves on to the next episode
idrama:errorThe work doesn't exist, is offline, doesn't allow embedding, or playback failed

Example: log the ending's name on your page when the viewer reaches an ending.

<script>
  const player = document.querySelector("mitone-idrama");
  player.addEventListener("idrama:ending", (event) => console.log(event.detail.name));
</script>
  • Commands from your page can't bypass the work's interaction rules: they can only choose options currently shown, and only seek within what has already played.
  • Events never include the viewer's identity or contact details.
  • idrama:ready also carries features: fullscreen says whether the embed can go full screen, and orientation whether it can lock the screen orientation, so your page can adjust its layout. Keep fullscreen in the embed code's allow; otherwise landscape works can only fill the page or play in pseudo-landscape. See Landscape Works.

Embedding settings

Whether embedding is allowed is set in the access settings of Settings (under Advanced). Click Save access settings and it takes effect right away, without publishing again:

  • Embedding: Allowed by default. Set it to Off and other sites embedding the work show Embedding is turned off; the Share tab also shows Embedding is off for this work; turn it back on in the access settings of the publish settings.
  • While embedding is allowed, you can list the sites allowed to embed it, for example https://partner.example.com; press Enter to add each one, up to 20. Leave it empty for any site. Once you list sites, other sites embedding it show This site isn't authorized. Sites are checked against the origin the browser reports, so keep the referrerpolicy attribute in the embed code.

oEmbed

Websites and content systems that support oEmbed can create the embed automatically from a work's watch link or a series page link. Public watch pages include an oEmbed discovery link, and you can also request <site address>/api/oembed?url=<watch link>&format=json directly. Private works, works that don't exist and works with embedding turned off have no oEmbed.

WeChat sharing

Not yet availableWeChat share cards and open tags are not available on this platform yet. Share the link or QR code instead.

When a viewer taps Share in a work inside WeChat, the player shows Tap "···" at the top right to share this work. The shared link doesn't carry the work's share card (share title, description and cover).

Partially availableCompatibility on phones and inside WeChat is still being verified; some devices may behave differently.

Check the result

  • Open the copied watch link in another browser and you see the start page; a private work opens after you enter the password.
  • Put the embed code on a test page and you see the embed page with just the player; with a site list set, pages not on the list show This site isn't authorized.

Limits and FAQ

  • Once a work is offline, expired, at its play limit or taken down, the link, QR code and embeds stop working.
  • The watch page itself can't be put in an iframe; use the Embed code or the SDK to embed.
  • Commands from your page can't skip interactions or change variables.

Was this page helpful?