Skip to main content

Embedded views

What this page is — putting a Papers screen inside a partner's website in an iframe, and the two credentials that make that safe.

What it is for — so a partner's users can create, review or sign a Papers document without leaving the partner's site.

The problem it solves — sending people to another website to sign one document loses a share of them at the hand-off.

Route: /embed/papers/<view> framed on the partner's site · Permission: Papers module limits, defaults, integrations and signature-provider toggles. to mint, list and revoke tokens


1. What it is​

An embed token is a signed credential that says this partner site may frame this view of Papers. The frame is chromeless, with no Orbit navigation, so it sits inside the partner's page as if it belonged there.

ViewLabel in the mint dialogWhat the visitor doesWhat authorises the document
generateGenerate documentCreates a document from a published type by filling in its fieldsThe embed token — the document lands as a draft
statusCheck submission statusLooks up something they submittedTheir reference plus the email they used
reviewReview & respondThe deal room — read, comment, suggest, send back, acceptThe per-document portal token they were emailed
signSignThe signing ceremonyThe signer's own signing link token
The embed token authorises framing, never document access

An embed token sits in the HTML of a public website, so it identifies a site, never a person. For review and sign, document access comes from the second credential in the query. For status, it comes from the reference and email pair. An integration that assumes the embed token opens documents either leaks or does not work.


2. Why you would use it​

  • Users finish what they start. Sending a customer away to another site to sign loses a share of them. Keeping the step in the partner's product keeps them.
  • Partners generate documents without your staff. A franchise site can create a correctly structured agreement straight from your published type, with its real fields and validation.
  • No second implementation to drift. review and sign reuse the portal and ceremony, so there is no separate rule deciding who may read a document inside an iframe.
  • Tokens can be switched off. Every token is registered, so a partner relationship that ends can be cut off the same day.

3. Step by step​

  1. Open Settings → Papers → Embeddable views (settings page).
  2. Mint a token: choose the view, the allowed origins, optionally a project, the expiry, and for generate a maximum uses quota.
  3. Copy the iframe snippet now. The token value is never stored, so it cannot be shown again.
  4. Give the snippet to the partner. For review and sign, the partner appends the portal or signing token of the specific document to the frame URL.
  5. Watch the token's events list to see its use, and revoke it when the relationship ends.

4. Field reference​

FieldRequiredRule — exact messages
ViewYes"view must be one of: generate, status, review, sign"
Allowed origins (frame ancestors)YesEmpty: "frame_ancestors is required — the partner origins allowed to embed this view". Each entry must be an origin or host: https://partner.example, partner.example, or *.partner.example for every subdomain. No path, query or credentials
Expires in (days)NoDefault 30, maximum 180 — "expires_days must be at most 180"
Maximum usesNoCaps how many documents the token may create. Blank or 0 means no cap
ProjectNoRestricts generate to one project's types

How the origin rule is enforced​

LayerWhat it does
APIEvery public embed call checks the caller's Origin or Referer against the list. A mismatch is refused: "this origin is not on the token's frame-ancestors allowlist" (403)
BrowserWhen the API host serves the embed shell, it sends a per-token frame-ancestors security header, so the browser itself refuses other sites

If your deployment serves the embed page from the static frontend rather than the API host, only the API check applies. The static host cannot vary its security header per partner.

Public rate limits​

CallPer minute
Token check30
Context, type schema, branding60
Create document, status lookup20

5. Choosing the view​

You want the partner to…UseWatch out for
Let their users start an application or agreementgenerateSet maximum uses so a leaked snippet cannot flood you with drafts
Let applicants follow progressstatusThe applicant must keep their reference and email
Negotiate inside their productreviewPortal tokens still expire (30 days by default)
Collect signatures inside their productsignCode verification still applies unless the request uses magic link only

6. Worked example​

Gatiro's reseller, Northwind Partners, wants its customers to request a Reseller order form and sign it without leaving portal.northwind.example.

  1. The Gatiro admin mints a generate token.
    • Allowed origins: https://portal.northwind.example.
    • Expiry: 90 days. Maximum uses: 200.
  2. Northwind places the iframe on their New order page. A customer fills in the form, and a draft order form appears in Gatiro's project, attributed to the embed token.
  3. The admin mints a second token for sign, with the same origin and 90 days.
  4. Once Gatiro finalizes the order and sends it for signature, Northwind frames the signing view with the signer's own link token. The customer signs inside Northwind's portal.
  5. A test from staging.northwind.example is refused with the allowlist message. The admin adds *.northwind.example to a new token rather than loosening the production one.
  6. When the reseller agreement ends, both tokens are revoked. Their frames stop working immediately.

7. The admin contract​

What must be configuredOtherwise
A published type for generateNothing can be generated
Allowed origins exactly matching the partner's scheme and hostFrames are refused
The API public URL and built frontend path set in deploymentBrowser-level framing protection is not sent; only the API check protects you
Documents finalized and sent for signature for signThere is no signing token to frame
Someone keeps the snippet at mint timeMint again — it is shown once

8. Downstream​

  • Documents created through generate enter the normal lifecycle as drafts, with the same numbering, approvals and AI behaviour as any other document.
  • Every token call is logged in the token's events list.
  • Branding shown inside the frame comes from the organisation's Papers branding.

9. Don't confuse this with…​

Customer portalYour own signed-in site, not a frame in someone else's
Share linksA page you send, not a component in a page
API keysServer-to-server access. Embed tokens are browser credentials for one view

10. Troubleshooting​

SymptomCause
The frame is blank or refusedThe host page's origin is not on the token's list (check https and www)
review or sign loads but shows no documentThe portal or signing token is missing from the frame URL (§1)
status finds nothingThe reference and email do not match what was submitted
It stopped workingExpired, revoked, or the maximum-uses quota is exhausted
Mint refusedOrigins empty or malformed, or expiry above 180 days