getPolicy(
config
,rulesEnginePolicyContract
,rulesEngineRulesContract
,rulesEngineComponentContract
,policyId
):Promise
<string
>
Retrieves the full policy, including rules, trackers, and foreign calls, as a JSON string.
Parameter | Type | Description |
---|---|---|
config | Config | - |
rulesEnginePolicyContract | object | The contract instance for interacting with the Rules Engine Policy. |
rulesEnginePolicyContract.abi | (object | object )[] | - |
rulesEnginePolicyContract.address | `0x${string}` | - |
rulesEngineRulesContract | object | The contract instance for interacting with the Rules Engine Rules. |
rulesEngineRulesContract.abi | (object | object | object )[] | - |
rulesEngineRulesContract.address | `0x${string}` | - |
rulesEngineComponentContract | object | The contract instance for interacting with the Rules Engine Component. |
rulesEngineComponentContract.abi | (object | object | object )[] | - |
rulesEngineComponentContract.address | `0x${string}` | - |
policyId | number | The ID of the policy to retrieve. |
Promise
<string
>
A JSON string representing the full policy.
getPolicy(
config
,rulesEnginePolicyContract
,rulesEngineRulesContract
,rulesEngineComponentContract
,policyId
):Promise
<string
>
Retrieves the full policy, including rules, trackers, and foreign calls, as a JSON string.
Parameter | Type | Description |
---|---|---|
config | Config | - |
rulesEnginePolicyContract | object | The contract instance for interacting with the Rules Engine Policy. |
rulesEnginePolicyContract.abi | (object | object )[] | - |
rulesEnginePolicyContract.address | `0x${string}` | - |
rulesEngineRulesContract | object | The contract instance for interacting with the Rules Engine Rules. |
rulesEngineRulesContract.abi | (object | object | object )[] | - |
rulesEngineRulesContract.address | `0x${string}` | - |
rulesEngineComponentContract | object | The contract instance for interacting with the Rules Engine Component. |
rulesEngineComponentContract.abi | (object | object | object )[] | - |
rulesEngineComponentContract.address | `0x${string}` | - |
policyId | number | The ID of the policy to retrieve. |
Promise
<string
>
A JSON string representing the full policy.