getForeignCall(Retrieves the result of a foreign call from the rules engine component contract.config
,rulesEngineForeignCallContract
,policyId
,foreignCallId
):Promise
<Maybe
<ForeignCallOnChain
>>
Parameter | Type | Description |
---|---|---|
config | Config | The configuration object containing network and wallet information. |
rulesEngineForeignCallContract | object | The contract instance containing the address and ABI for interaction. |
rulesEngineForeignCallContract.abi | (object | object | object )[] | - |
rulesEngineForeignCallContract.address | `0x${string}` | - |
policyId | number | The ID of the policy associated with the foreign call. |
foreignCallId | number | The ID of the foreign call to retrieve. |
Promise
<Maybe
<ForeignCallOnChain
>>
A promise that resolves to the result of the foreign call, or null
if an error occurs.