Monitoring

Options to monitor on chain reports and extra features

Network ID

NETWORK_ID=369

Set this variable inside the .env file to match the network you're monitoring. DVM uses this variable for settings, but you still need to double check the endpoints.yaml file.

Confidence Threshold

Use -a or --account-name to specify a chained account to use for disputing:

cli -a <your account name without quotes>

Alert All NewReports

Use -av to get an alert for all NewReport events (regardless of whether they are disputable or not):

cli -av

Wait Between Checks

If you leave it as default, your DVM will scan the chain every few seconds for new reports.

Use the -w (wait) option to set how often DVM will check for new reports:

cli -w 120

Configuring QueryIDs and Thresholds to Monitor.

Monitored Feeds and their Thresholds are defined in the disputer-config.yaml file.

Generate queryIDs here: https://go.fetchoracle.com/#/generate-query-id

By default, the Auto-Disputer will monitor the PLS/USD feed with a threshold percentage of 10%. In the default disputer-config.yaml in disputable-values-monitor/disputer-config.yaml this is represented as:

# AutoDisputer configuration file
feeds:
  - query_id: "0x83245f6a6a2f6458558a706270fbcc35ac3a81917602c1313d3bfa998dcc2d4b"
    threshold:
      type: Percentage
      amount: 0.1 # 10%

Where 0x83245f6a6a2f6458558a706270fbcc35ac3a81917602c1313d3bfa998dcc2d4b represents the queryId of the PLS/USD feed on Fetch Oracle.

It's recommended to monitor two 'simple' queries at once per DVM instance, although more is also possible.

To change the query being monitored, simply add the new QueryID in the query_id field, using quotes.

To change the percentage threshold to dispute or send alerts, change the amount field where:

0.1 = 10%

1 = 100%

For example, to monitor a second query in the form of a newQueryId, follow the same pattern while respecting the file indentation, like so:

- query_id: "0x83245f6a6a2f6458558a706270fbcc35ac3a81917602c1313d3bfa998dcc2d4b"
    threshold:
      type: Percentage
      amount: 0.1 # 10%
 - query_id: "newQueryID"
    threshold:
      type: Percentage
      amount: 0.75 # 75%

Token Balance Alerts

Reporters

Inside telliot-feeds folder there's a .env file which contains variables for DVM.

You can set REPORTERS= with the addresses of reporters to monitor their FETCH and PLS balance on chain. If these balances thresholds are met, DVM will send an alert to your Discord channel.

Instructions are present in the file, just remember to separate wallet addresses in REPORTERS= with a comma and to match the thresholds values with the same number of reporters.

For example, if you have 3 wallets, you need 3 thresholds, one for each wallet, in their respective order:

REPORTERS= "0x1...,0x2...,0x3" Threshold values= "100,150,200"

Above, wallet 0x1 will trigger with 100, wallet 2 with 150 and wallet 3 with 200.

Disputer

You can also monitor FETCH and PLS balances for the disputer wallet selected for disputing (when starting DVM with the -d option). Set the thresholds for the tokens and it will send an alert when they're met.

Stale Reporters

You can set a threshold, in seconds, to get notified if the reporters in REPORTERS= have not submitted

NO_REPORTING_THRESHOLD="43200, 43200"

The length and order or values should match REPORTERS=

Stale queryIDs

You can set queryIDs to be monitored for stale submissions. If a queryID doesn't receive a submission in a X amount of seconds, you'll receive an alert.

#QueryIDs to monitor when was the last time they were reported, separated by commas.
#use "0x00000000000000000000000000000000000000000000000000000000000000000" as default if not using it.

QUERY_IDS="0x00000000000000000000000000000000000000000000000000000000000000000,0x00000000000000000000000000000000000000000000000000000000000000000"

#Thresholds, separated by commas, to send alerts if no report is submitted within threshold for queryIDs above.
#Must follow the length and order of QUERY_IDS=.

QUERYID_LAST_REPORT_THRESHOLD="43200, 43200" #Value in seconds. 43200 is for a 12h check.

Generate queryIDs here: https://go.fetchoracle.com/#/generate-query-id

Last updated