Skip to main content
Version: 1.13.0

Function: fetchVerifications()

fetchVerifications(messageId: string, opts?: FetchVerificationsOpts): Promise<VerifierResult[]>

Defined in: commits.ts:117

Fetch CCV verifications for a CCIP v2.0 message.

Races the optional API client against all provided indexer URLs via Promise.any, returning the first successful response.

When opts.watch is supplied the function retries on CCIPMessageNotVerifiedYetError at opts.pollInterval ms intervals until the signal fires.

Parameters

ParameterTypeDescription
messageIdstringThe CCIP message ID (hex string)
optsFetchVerificationsOptsSee FetchVerificationsOpts

Returns

Promise<VerifierResult[]>

The verifier results served by the first source to respond successfully

Throws

CCIPMessageNotVerifiedYetError if all sources fail or signal fires

Throws

CCIPArgumentInvalidError if opts.indexer contains a non-string entry