Skip to content

Commit 44a63da

Browse files
committed
Add minimal example config file
1 parent 2347364 commit 44a63da

File tree

1 file changed

+113
-0
lines changed

1 file changed

+113
-0
lines changed

config/config.toml

Lines changed: 113 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
# Configuration for the JRPC API Websocket Server
2+
[pythd_api_server]
3+
# The address on which the websocket API server will listen on.
4+
listen_address = "127.0.0.1:8910"
5+
6+
# Configuration for the primary network this agent will publish data to. In most cases this should be a Pythnet endpoint.
7+
[primary_network]
8+
### Required fields ###
9+
10+
# HTTP(S) endpoint of the RPC node. Public RPC endpoints are usually rate-limited, so a private node should be used in most cases.
11+
rpc_url = "http://api.pythnet.pyth.network:8899"
12+
13+
# WS(S) endpoint of the RRC node. This is used to subscribe to account changes on the network.
14+
# This can be omitted when oracle.subscriber_enabled is set to false.
15+
wss_url = "ws://api.pythnet.pyth.network:8900"
16+
17+
# Path to the key store.
18+
key_store.root_path = "/path/to/keystore"
19+
20+
### Optional fields ###
21+
22+
# The interval with which to poll account information.
23+
# oracle.poll_interval_duration = "2m"
24+
25+
# Whether subscribing to account updates over websocket is enabled
26+
# oracle.subscriber_enabled = true
27+
28+
# Duration of the interval at which to refresh the cached network state (current slot and blockhash).
29+
# It is recommended to set this to slightly less than the network's block time,
30+
# as the slot fetched will be used as the time of the price update.
31+
# exporter.refresh_network_state_interval_duration = "200ms"
32+
33+
# Duration of the interval at which to publish updates
34+
# exporter.publish_interval_duration = "1s"
35+
36+
# Age after which a price update is considered stale and not published
37+
# exporter.staleness_threshold = "5s"
38+
39+
# Maximum size of a batch
40+
# exporter.max_batch_size = 12
41+
42+
# Maximum number of compute units requested by each update_price transaction
43+
# exporter.compute_unit_limit = 20000
44+
45+
# Price per compute unit offered for update_price transactions
46+
# exporter.compute_unit_price_micro_lamports =
47+
48+
# Duration of the interval with which to poll the status of transactions.
49+
# It is recommended to set this to a value close to exporter.publish_interval_duration
50+
# exporter.transaction_monitor.poll_interval_duration = "4s"
51+
52+
# Maximum number of recent transactions to monitor. When this number is exceeded,
53+
# the oldest transactions are no longer monitored. It is recommended to set this to
54+
# a value at least as large as (number of products published / number of products in a batch).
55+
# exporter.transaction_monitor.max_transactions = "100"
56+
57+
# Configuration for the optional secondary network this agent will publish data to. In most cases this should be a Solana endpoint.
58+
# [secondary_network]
59+
### Required fields ###
60+
61+
# HTTP(S) endpoint of the RPC node. The Solana public RPC endpoints are rate-limited, so a private node should be used.
62+
# rpc_url = "http://api.devnet.solana.com"
63+
64+
# WS(S) endpoint of the RRC node. This is used to subscribe to account changes on the network.
65+
# This can be omitted when oracle.subscriber_enabled is set to false.
66+
# wss_url = "ws://api.devnet.solana.com"
67+
68+
# Path to the key store.
69+
# key_store.root_path = "/path/to/keystore"
70+
71+
### Optional fields ###
72+
73+
# The interval with which to poll account information.
74+
# oracle.poll_interval_duration = "2m"
75+
76+
# Whether subscribing to account updates over websocket is enabled
77+
# oracle.subscriber_enabled = true
78+
79+
# Duration of the interval at which to refresh the cached network state (current slot and blockhash).
80+
# It is recommended to set this to slightly less than the network's block time,
81+
# as the slot fetched will be used as the time of the price update.
82+
# exporter.refresh_network_state_interval_duration = "200ms"
83+
84+
# Duration of the interval at which to publish updates
85+
# exporter.publish_interval_duration = "1s"
86+
87+
# Age after which a price update is considered stale and not published
88+
# exporter.staleness_threshold = "5s"
89+
90+
# Maximum size of a batch
91+
# exporter.max_batch_size = 12
92+
93+
# Maximum number of compute units requested by each update_price transaction
94+
# exporter.compute_unit_limit = 20000
95+
96+
# Price per compute unit offered for update_price transactions
97+
# exporter.compute_unit_price_micro_lamports =
98+
99+
# Duration of the interval with which to poll the status of transactions.
100+
# It is recommended to set this to a value close to exporter.publish_interval_duration
101+
# exporter.transaction_monitor.poll_interval_duration = "4s"
102+
103+
# Maximum number of recent transactions to monitor. When this number is exceeded,
104+
# the oldest transactions are no longer monitored. It is recommended to set this to
105+
# a value at least as large as (number of products published / number of products in a batch).
106+
# exporter.transaction_monitor.max_transactions = "100"
107+
108+
# Configuration for the JRPC API
109+
[pythd_adapter]
110+
# The duration of the interval at which `notify_price_sched` notifications will be sent.
111+
# Note that this doesn't affect the rate at which transactions are published:
112+
# this is soley a backwards-compatibility API feature.
113+
# notify_price_sched_interval_duration = "1s"

0 commit comments

Comments
 (0)