Skip to content

addPiecesWithMetadataCapture

addPiecesWithMetadataCapture(dataSetId, txHash, captureCallback, options): HttpHandler

Defined in: packages/synapse-core/src/mocks/pdp.ts:327

Creates a handler that captures piece metadata from addPieces requests

ParameterTypeDescription
dataSetIdbigintData set ID to match
txHash`0x${string}`Transaction hash to return in Location header
captureCallback(metadata) => voidCallback to store captured metadata
optionsPDPMockOptionsAdditional options

HttpHandler