Skip to main content
Version: 1.10.3

Function: getRequiredCCVs()

getRequiredCCVs(opts: EstimateReceiveExecutionOpts): Promise<GetRequiredCCVsResult>

Defined in: gas.ts:327

Resolve the CCVs the destination will require for a candidate message, and whether its finality is accepted, via the OffRamp's getCCVsForMessage view (a read; no send). Resolves the onRamp/offRamp from routerOrRamp like estimateReceiveExecution, maps token amounts to their destination counterparts, then queries the resolver. A disallowed finality throws CCIPFinalityNotAllowedError.

The set is sender-scoped: pass the real sender. It is informative only — comparing it against the source-engaged set is left to the caller, since source and destination CCVs are distinct per-chain contracts with no on-chain address link.

Parameters

ParameterTypeDescription
optsEstimateReceiveExecutionOptsEstimateReceiveExecutionOpts (source, dest, routerOrRamp, message)

Returns

Promise<GetRequiredCCVsResult>

{ requiredCCVs, optionalCCVs, optionalThreshold }.