@ceramic-sdk/events v0.2.1 • Docs
Ceramic SDK / @ceramic-sdk/events / encodeEventToCAR
encodeEventToCAR(
codec,event):CAR
Encodes an unsigned event into a CAR using the provided codec.
• codec: Codec<unknown, unknown, unknown>
The codec used to encode the event.
• event: unknown
The unsigned event to encode.
CAR
A CAR object representing the unsigned event.
Encodes the event as the root of the CAR file using the specified codec.