encodeGrant
encodeGrant<
G>(grant):Uint8Array
Defined in: wrap.ts:160
Pack the grant to deliver or store it
{ 0: v, 1: node, 2: owner (20 bytes), 3: keyspace (16 bytes), 4: epk (65 bytes), 5: iv (12 bytes), 6: ct (48 bytes), * text: informational }Fields with text keys carry anything informational added to the grant, such as a piece’s CID. These informational keys are not authenticated.
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
G extends Grant |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
grant | G |