PreparedBatchWrite
type PreparedBatchWrite<Schema> = object;Represents a BatchWrite command bound to a specific entity, ready to be included in a table-level TableBatchWrite command.
Type Parameters
Section titled “Type Parameters”Schema
Section titled “Schema”Schema extends ZodObject
The Zod schema type associated with the DynamoEntity.
Properties
Section titled “Properties”entity
Section titled “entity”entity: DynamoEntity<Schema>;Methods
Section titled “Methods”buildRequests()
Section titled “buildRequests()”buildRequests(skipValidation, abortSignal?): Promise<( | { PutRequest: { Item: Record<string, unknown>; };} | { DeleteRequest: { Key: DynamoKey; };})[]>;Parameters
Section titled “Parameters”skipValidation
Section titled “skipValidation”boolean
abortSignal?
Section titled “abortSignal?”AbortSignal
Returns
Section titled “Returns”Promise<(
| {
PutRequest: {
Item: Record<string, unknown>;
};
}
| {
DeleteRequest: {
Key: DynamoKey;
};
})[]>
matchUnprocessedDelete()
Section titled “matchUnprocessedDelete()”matchUnprocessedDelete(key): | Partial<EntitySchema<Schema>> | undefined;Parameters
Section titled “Parameters”Returns
Section titled “Returns”| Partial<EntitySchema<Schema>>
| undefined
matchUnprocessedPut()
Section titled “matchUnprocessedPut()”matchUnprocessedPut(item): | EntitySchema<Schema> | undefined;Parameters
Section titled “Parameters”Record<string, unknown>
Returns
Section titled “Returns”| EntitySchema<Schema>
| undefined