getNextChallengeEpoch
getNextChallengeEpoch(
client,options):Promise<bigint>
Defined in: packages/synapse-core/src/pdp-verifier/get-next-challenge-epoch.ts:61
Get next challenge epoch
Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
client | Client<Transport, Chain> | The client to use to get the active pieces. |
options | OptionsType | getNextChallengeEpoch.OptionsType |
Returns
Section titled “Returns”Promise<bigint>
The next challenge epoch for the data set getNextChallengeEpoch.OutputType
Example
Section titled “Example”import { getNextChallengeEpoch } from '@filoz/synapse-core/pdp-verifier'import { calibration } from '@filoz/synapse-core/chains'import { createPublicClient, http } from 'viem'
const client = createPublicClient({ chain: calibration, transport: http(),})
const nextChallengeEpoch = await getNextChallengeEpoch(client, { dataSetId: 1n,})