Type alias RecordsWriteRequest

RecordsWriteRequest: {
    data: unknown;
    message?: Omit<Partial<DwnMessageParams[DwnInterface.RecordsWrite]>, "signer">;
    store?: boolean;
}

Defines a request to write (create) a record to a Decentralized Web Node (DWN).

This request type allows specifying the data for the new or updated record, along with any additional message parameters required for the write operation, and an optional flag to indicate whether the record should be immediately stored.

Type declaration

  • data: unknown

    The data payload for the record, which can be of any type.

  • Optional message?: Omit<Partial<DwnMessageParams[DwnInterface.RecordsWrite]>, "signer">

    Optional additional parameters for the record write operation.

  • Optional store?: boolean

    Optional flag indicating whether the record should be immediately stored. If true, the record is persisted in the DWN as part of the write operation. If false, the record is created, signed, and returned but not persisted.

Param: data

Param: message

, excluding the signer.

Param: store