Marmot-TS
    Preparing search index...

    Function createInviteIntent

    • Builds a commit session intent that adds a user from their KeyPackage event and delivers a Welcome to them after the commit acks.

      Validates that the event is a KeyPackage (kind 30443), passes the trust boundary (SEC-01: signature; WIRE-02: d/i/mls_protocol_version cardinality; WIRE-01: Lifetime cap/current), that the embedded credential identity matches the event author, and that the mls_proposals tag exactly matches the leaf's advertised proposals — with GREASE included (MDK and current marmot-ts) or with GREASE removed from both sides (older marmot-ts) — before constructing the Add proposal. Pair the result with GroupSession.send / GroupsManager.send; GroupsManager.invite wraps this helper and resolves actorPubkey from the signer.

      Parameters

      Returns {
          actorPubkey: string;
          expectedParent?: string;
          extraProposals?: CommitProposalInputs;
          kind: "commit";
          proposalRefs?: string[];
          signal?: AbortSignal;
          welcomeRecipients?: WelcomeRecipient[];
      }

      • actorPubkey: string
      • OptionalexpectedParent?: string

        Canonical session.parentToken captured before fallible image work. Required for image commits.

      • OptionalextraProposals?: CommitProposalInputs
      • kind: "commit"
      • OptionalproposalRefs?: string[]
      • Optionalsignal?: AbortSignal

        Abort queued work or preparation before publication; confirmed work remains final.

      • OptionalwelcomeRecipients?: WelcomeRecipient[]

      Error if the event is not a KeyPackage kind, fails signature verification, has invalid required-tag cardinality, has an over-long or not-current Lifetime, the credential identity does not match the event author, or the mls_proposals tag is absent, malformed, or does not match the leaf's advertised proposals (with or without GREASE).