Skip to content

docs: add IDKit invite-code mode page#111

Draft
SeanROlszewski wants to merge 13 commits intomainfrom
docs/idkit-invite-code-mode
Draft

docs: add IDKit invite-code mode page#111
SeanROlszewski wants to merge 13 commits intomainfrom
docs/idkit-invite-code-mode

Conversation

@SeanROlszewski
Copy link
Copy Markdown
Contributor

@SeanROlszewski SeanROlszewski commented May 1, 2026

Documents invite-code mode (WDP-73 / idkit app-9428): the user enters a 6-character code in World App, which uses it as the entry point to in-app onboarding flows that fulfill the IDKit request.

  • New overview page world-id/idkit/invite-code.mdx — when to use, code format, lifecycle, multi-language example.
  • Per-SDK sections added to javascript.mdx, react.mdx, swift.mdx in the existing terse-bullet style.
  • Cross-link from integrate.mdx; sidebar entry between Integrate and Signatures.
  • Constraints flagged: iOS-only on the World App side, selfieCheckLegacy is the only supported preset today.

Documents the cross-device verification flow added in idkit APP-9428,
where the relying party shows a 6-character code the user types into
World App on a different device instead of scanning a QR.

- New page world-id/idkit/invite-code.mdx covering when to use the
  mode, the code format, lifecycle, and JS/React/Swift integration.
- Wired into IDKit nav between Integrate and Signatures.
- Cross-link from the standard Integrate page.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@SeanROlszewski SeanROlszewski marked this pull request as draft May 1, 2026 18:43
Comment thread world-id/idkit/invite-code.mdx Outdated

## When to use it

Use invite-code mode when the relying party (your app) and World App are reliably **on different devices** — for example, a desktop browser experience where the user has World App on their phone. Typing a 6-character code is more robust than asking the user to point a phone camera at their own laptop screen.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't the reason we built it, but is something we ensured worked. The reason to use this feature is to expedite onboarding users into the World Network. The app uses the code to show in-app flows that users complete as part of onboarding to respond to the IDKit request.

Comment thread world-id/idkit/invite-code.mdx Outdated
},
allow_legacy_proofs: true,
environment: "production",
}).preset(orbLegacy({ signal: "user-123" }));
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's put the selfie check preset here since that's the hero use case for this atm.

Comment thread world-id/idkit/invite-code.mdx Outdated

### Display the code

Show `code` prominently. A formatted display (`ABC-DEF` in a large, monospaced font) is easier to read aloud and harder to mistype than the unseparated form. The Next.js example app and iOS sample app in the IDKit repo both ship a reference UI you can crib from.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove comments on reading the code aloud.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"Crib from" is unprofessional - "can be referenced" is better, but we're also going to provide at least a react component so this shouldn't be really mentioned.

- Reframe "When to use it" to lead with the onboarding use case
  (the hero use case is letting World App run in-app onboarding
  flows so users can satisfy a credential they don't yet hold);
  cross-device is now described as a secondary fit.
- Switch JS/React/Swift examples and the migration diff to
  selfieCheckLegacy so the doc reflects the current hero preset.
- Remove the "easier to read aloud" line and the reference to the
  example apps under "Display the code" — a React component will
  ship for that surface.
- Update the cross-link in integrate.mdx to match the new framing.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Comment thread world-id/idkit/invite-code.mdx Outdated

## When to use it

Invite-code mode is built to **expedite onboarding users into the World Network**. When a user enters your app's invite code into World App, World App uses it to launch the in-app onboarding flows the user needs to complete in order to satisfy your IDKit request. This lets you request a credential the user does not yet hold — World App walks them through getting it, then returns the proof to your app.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a note that this is for iOS only

Trim the overview and move per-SDK details to the existing reference
pages so the structure matches how other IDKit features are documented.

- Tighten the lede; collapse "When to use it" to two paragraphs.
- Drop the Crockford / check-character internals — feature pages
  don't explain crypto details (signatures.mdx is the spec page).
- Drop the inline "Migrating from QR mode" section — migration
  content belongs on 4-0-migration.mdx.
- Replace the three Markdown API tables with a "SDK references"
  link list pointing into the per-language pages.
- Add a Warning callout about generating rp_context server-side.
- Show the RpContext(...) constructor in the Swift sample so it
  parallels JS/React.
- Add "Invite-code mode" sections to javascript.mdx, react.mdx, and
  swift.mdx using the existing terse-bullet style of those pages.
- Add IDKit.requestWithInviteCode and selfieCheckLegacy to the JS
  entry-points list.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Invite-code redemption is currently shipped only in World App for iOS;
Android users cannot redeem a code today. Surface the constraint as a
Note callout on the overview page and append it to the cross-link in
integrate.mdx so anyone evaluating the feature sees it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Comment thread world-id/idkit/invite-code.mdx Outdated
Comment thread world-id/idkit/invite-code.mdx Outdated
Invite-code mode displays a short 6-character code in your app that the user enters into World App. World App treats the code as an entry point to the in-app onboarding flows the user needs to complete in order to satisfy your IDKit request, then returns the proof.

<Note>
Invite-code mode requires World App on iOS.
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably worth a note that only selfie-check is supported atm. As we add the other credentials we can update the docs.

Invite-code mode currently only works with the selfie-check preset.
Add a Note alongside the iOS-only one so the constraint is visible
on the overview page; the docs will be updated as support is added
for other credentials.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Comment thread world-id/idkit/integrate.mdx Outdated
Comment thread world-id/idkit/invite-code.mdx Outdated
Comment thread world-id/idkit/invite-code.mdx Outdated
Comment thread world-id/idkit/invite-code.mdx Outdated
Without the blank lines, <CodeGroup> opens a CommonMark Type-7 HTML
block that swallows the inner code fences — backticks render as
literal text on github.com. Adding a blank line after the opening
tag and before the closing tag ends the HTML block, letting the
fences parse as Markdown. Mintlify renders the same either way.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- Drop title="React" and title="Swift" from the CodeGroup so
  GitHub renders the fences correctly (matches the JS fence).
- Add a paragraph after the CodeGroup explaining why
  allow_legacy_proofs: true is required (selfieCheckLegacy is a
  v3 preset), so a copy-paste user trying a non-legacy preset
  later isn't surprised.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant