ApiCoreInterfaces
Interface: Channel
Defined in: packages/core/src/identity/channel.ts:74
Both sides' sealed channel. Each direction has its own key, and each message
is bound to its type and to its place in its direction (seq, from 0).
Methods
derive()
derive(label, length): Promise<Uint8Array<ArrayBufferLike>>;Defined in: packages/core/src/identity/channel.ts:80
Bytes only this exchange gives, under label with the transcript appended: pairing's short code
Parameters
| Parameter | Type |
|---|---|
label | string |
length | number |
Returns
Promise<Uint8Array<ArrayBufferLike>>
open()
open(type, sealed): Promise<Uint8Array<ArrayBufferLike> | null>;Defined in: packages/core/src/identity/channel.ts:78
Opens the other side's next message; null for anything else, which leaves the count where it was
Parameters
| Parameter | Type |
|---|---|
type | string |
sealed | unknown |
Returns
Promise<Uint8Array<ArrayBufferLike> | null>
seal()
seal(type, plaintext): Promise<string>;Defined in: packages/core/src/identity/channel.ts:76
Seals this side's next message: base64url of an envelope
Parameters
| Parameter | Type |
|---|---|
type | string |
plaintext | Uint8Array |
Returns
Promise<string>