IdentityInternalApi
Marks the statements only kuilt's own session protocol needs, and nothing else. It carries no stability promise for consumers.
The admission exchange signs and checks statements — a host's challenge, a joiner's proof — whose layouts are defined here so that the bytes signed and the bytes verified come from one place. The room code in :kuilt-session has to build and read them, and Kotlin's internal cannot cross a module boundary, so those declarations are public in the binary and gated here instead.
The raw DeviceKey.sign is gated here too, since it can sign those statements' bytes. An app signs with signApp. A DeviceKey implemented outside kuilt marks its sign override with this annotation too, not with @OptIn: the marker carries the gate to callers of the concrete type, where an @OptIn on the override would lift it for them.
An annotated declaration may change shape or disappear in any release, patch releases included. Opting in from outside kuilt's own modules means depending on that.
kotlin { compilerOptions { optIn.add("us.tractat.kuilt.identity.IdentityInternalApi") } }The opt-in level is ERROR, so using one of these without opting in does not compile. Java callers do not see opt-in requirements at all, so on the JVM this is a convention, not a fence.