switchboard_utils/
protobufs.rs

1// @generated
2/// / Represnts a list of tasks to be performed by a switchboard oracle.
3#[allow(clippy::derive_partial_eq_without_eq)]
4#[derive(Clone, PartialEq, ::prost::Message)]
5pub struct OracleJob {
6    /// / The chain of tasks to perform for this OracleJob.
7    #[prost(message, repeated, tag = "1")]
8    pub tasks: ::prost::alloc::vec::Vec<oracle_job::Task>,
9}
10/// Nested message and enum types in `OracleJob`.
11pub mod oracle_job {
12    ///
13    /// The adapter will report the text body of a successful HTTP request to the
14    /// specified url, or return an error if the response status code is greater
15    /// than or equal to 400.
16    ///
17    /// _**Input**_: None
18    ///
19    /// _**Returns**_: String representation of the http response.
20    ///
21    /// _**Example**_: Basic HttpTask
22    ///
23    /// ```json
24    /// {"httpTask": {"url": "<https://mywebsite.org/path"}> }
25    /// ```
26    ///
27    /// _**Example**_: HttpTask example with headers
28    ///
29    /// ```json
30    /// { "httpTask": { "url": "<https://mywebsite.org/path",> "method": "METHOD_POST", "headers": [ { "key": "MY_HEADER_KEY", "value": "MY_HEADER_VALUE" } ], "body": "{\"MY_BODY_KEY\":\"MY_BODY_VALUE\"}" } }
31    /// ```
32    #[allow(clippy::derive_partial_eq_without_eq)]
33    #[derive(Clone, PartialEq, ::prost::Message)]
34    pub struct HttpTask {
35        /// / A string containing the URL to direct this HTTP request to.
36        #[prost(string, optional, tag = "1")]
37        pub url: ::core::option::Option<::prost::alloc::string::String>,
38        /// / The type of HTTP request to make.
39        #[prost(enumeration = "http_task::Method", optional, tag = "2")]
40        pub method: ::core::option::Option<i32>,
41        /// / A list of headers to add to this HttpTask.
42        #[prost(message, repeated, tag = "3")]
43        pub headers: ::prost::alloc::vec::Vec<http_task::Header>,
44        /// / A stringified body (if any) to add to this HttpTask.
45        #[prost(string, optional, tag = "4")]
46        pub body: ::core::option::Option<::prost::alloc::string::String>,
47    }
48    /// Nested message and enum types in `HttpTask`.
49    pub mod http_task {
50        /// / An object that represents a header to add to an HTTP request.
51        #[allow(clippy::derive_partial_eq_without_eq)]
52        #[derive(Clone, PartialEq, ::prost::Message)]
53        pub struct Header {
54            /// / A header key such as `Authorization` or `Content-Type`
55            #[prost(string, optional, tag = "1")]
56            pub key: ::core::option::Option<::prost::alloc::string::String>,
57            /// / A value for the given header key like `Basic MYAUTHKEY` or `application/json`
58            #[prost(string, optional, tag = "2")]
59            pub value: ::core::option::Option<::prost::alloc::string::String>,
60        }
61        /// / An enumeration representing the types of HTTP requests available to make.
62        #[derive(
63            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
64        )]
65        #[repr(i32)]
66        pub enum Method {
67            /// / Unset HTTP method will default to METHOD_GET
68            Unkown = 0,
69            /// / Perform an HTTP 'GET' request.
70            Get = 1,
71            /// / Perform an HTTP 'POST' request.
72            Post = 2,
73        }
74        impl Method {
75            /// String value of the enum field names used in the ProtoBuf definition.
76            ///
77            /// The values are not transformed in any way and thus are considered stable
78            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
79            pub fn as_str_name(&self) -> &'static str {
80                match self {
81                    Method::Unkown => "METHOD_UNKOWN",
82                    Method::Get => "METHOD_GET",
83                    Method::Post => "METHOD_POST",
84                }
85            }
86            /// Creates an enum from field names used in the ProtoBuf definition.
87            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
88                match value {
89                    "METHOD_UNKOWN" => Some(Self::Unkown),
90                    "METHOD_GET" => Some(Self::Get),
91                    "METHOD_POST" => Some(Self::Post),
92                    _ => None,
93                }
94            }
95        }
96    }
97    ///
98    /// The adapter walks the path specified and returns the value found at that result. If returning
99    /// JSON data from the HttpGet or HttpPost adapters, you must use this adapter to parse the response.
100    ///
101    /// _**Input**_: String representation of a JSON object.
102    ///
103    /// _**Returns**_: A numerical result.
104    ///
105    /// _**Example**_: Parses the price field from a JSON object
106    ///
107    /// ```json
108    /// {"jsonParse": {"path": "$.price"} }
109    /// ```
110    #[allow(clippy::derive_partial_eq_without_eq)]
111    #[derive(Clone, PartialEq, ::prost::Message)]
112    pub struct JsonParseTask {
113        /// / JSONPath formatted path to the element. <https://t.ly/uLtw>
114        /// / <https://www.npmjs.com/package/jsonpath-plus>
115        #[prost(string, optional, tag = "1")]
116        pub path: ::core::option::Option<::prost::alloc::string::String>,
117        /// / The technique that will be used to aggregate the results if walking the specified path returns multiple numerical results.
118        #[prost(
119            enumeration = "json_parse_task::AggregationMethod",
120            optional,
121            tag = "2"
122        )]
123        pub aggregation_method: ::core::option::Option<i32>,
124    }
125    /// Nested message and enum types in `JsonParseTask`.
126    pub mod json_parse_task {
127        /// / The methods of combining a list of numerical results.
128        #[derive(
129            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
130        )]
131        #[repr(i32)]
132        pub enum AggregationMethod {
133            None = 0,
134            /// / Grab the minimum value of the results.
135            Min = 1,
136            /// / Grab the maximum value of the results.
137            Max = 2,
138            /// / Sum up all of the results.
139            Sum = 3,
140            /// / Average all of the results.
141            Mean = 4,
142            /// / Grab the median of the results.
143            Median = 5,
144        }
145        impl AggregationMethod {
146            /// String value of the enum field names used in the ProtoBuf definition.
147            ///
148            /// The values are not transformed in any way and thus are considered stable
149            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
150            pub fn as_str_name(&self) -> &'static str {
151                match self {
152                    AggregationMethod::None => "NONE",
153                    AggregationMethod::Min => "MIN",
154                    AggregationMethod::Max => "MAX",
155                    AggregationMethod::Sum => "SUM",
156                    AggregationMethod::Mean => "MEAN",
157                    AggregationMethod::Median => "MEDIAN",
158                }
159            }
160            /// Creates an enum from field names used in the ProtoBuf definition.
161            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
162                match value {
163                    "NONE" => Some(Self::None),
164                    "MIN" => Some(Self::Min),
165                    "MAX" => Some(Self::Max),
166                    "SUM" => Some(Self::Sum),
167                    "MEAN" => Some(Self::Mean),
168                    "MEDIAN" => Some(Self::Median),
169                    _ => None,
170                }
171            }
172        }
173    }
174    ///
175    /// Returns the median (middle) of all the results returned by the provided subtasks and subjobs. Nested tasks must return a Number.
176    ///
177    /// _**Input**_: None
178    ///
179    /// _**Returns**_: A numerical result.
180    ///
181    /// _**Example**_: Returns the median numerical result of 3 tasks.
182    ///
183    /// ```json
184    /// {"medianTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
185    /// ```
186    ///
187    /// _**Example**_: Returns the median numerical result of 3 jobs.
188    ///
189    /// ```json
190    /// {"medianTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
191    /// ```
192    #[allow(clippy::derive_partial_eq_without_eq)]
193    #[derive(Clone, PartialEq, ::prost::Message)]
194    pub struct MedianTask {
195        /// / A list of subtasks to process and produce a list of result values.
196        #[prost(message, repeated, tag = "1")]
197        pub tasks: ::prost::alloc::vec::Vec<Task>,
198        /// / A list of subjobs to process and produce a list of result values.
199        #[prost(message, repeated, tag = "2")]
200        pub jobs: ::prost::alloc::vec::Vec<super::OracleJob>,
201        /// / The minimum number of values before a successful median can be yielded.
202        #[prost(int32, optional, tag = "3")]
203        pub min_successful_required: ::core::option::Option<i32>,
204    }
205    ///
206    /// Returns the mean (average) of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
207    ///
208    /// _**Input**_: None
209    ///
210    /// _**Returns**_: A numerical result.
211    ///
212    /// _**Example**_: Returns the mean numerical result of 3 tasks.
213    ///
214    /// ```json
215    /// {"meanTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
216    /// ```
217    ///
218    /// _**Example**_: Returns the mean numerical result of 3 jobs.
219    ///
220    /// ```json
221    /// {"meanTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
222    /// ```
223    #[allow(clippy::derive_partial_eq_without_eq)]
224    #[derive(Clone, PartialEq, ::prost::Message)]
225    pub struct MeanTask {
226        /// / A list of subtasks to process and produce a list of result values.
227        #[prost(message, repeated, tag = "1")]
228        pub tasks: ::prost::alloc::vec::Vec<Task>,
229        /// / A list of subjobs to process and produce a list of result values.
230        #[prost(message, repeated, tag = "2")]
231        pub jobs: ::prost::alloc::vec::Vec<super::OracleJob>,
232    }
233    ///
234    /// Returns the maximum value of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
235    ///
236    /// _**Input**_: None
237    ///
238    /// _**Returns**_: A numerical result.
239    ///
240    /// _**Example**_: Returns the maximum numerical result from 3 tasks.
241    ///
242    /// ```json
243    /// {"maxTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
244    /// ```
245    ///
246    /// _**Example**_: Returns the maximum numerical result from 3 jobs.
247    ///
248    /// ```json
249    /// {"maxTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
250    /// ```
251    #[allow(clippy::derive_partial_eq_without_eq)]
252    #[derive(Clone, PartialEq, ::prost::Message)]
253    pub struct MaxTask {
254        /// / A list of subtasks to process and produce a list of result values.
255        #[prost(message, repeated, tag = "1")]
256        pub tasks: ::prost::alloc::vec::Vec<Task>,
257        /// / A list of subjobs to process and produce a list of result values.
258        #[prost(message, repeated, tag = "2")]
259        pub jobs: ::prost::alloc::vec::Vec<super::OracleJob>,
260    }
261    ///
262    /// Returns the minimum value of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
263    ///
264    /// _**Input**_: None
265    ///
266    /// _**Returns**_: A numerical result.
267    ///
268    /// _**Example**_: Returns the minimum numerical result from 3 tasks.
269    ///
270    /// ```json
271    /// {"minTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
272    /// ```
273    ///
274    /// _**Example**_: Returns the minimum numerical result from 3 jobs.
275    ///
276    /// ```json
277    /// {"minTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
278    /// ```
279    #[allow(clippy::derive_partial_eq_without_eq)]
280    #[derive(Clone, PartialEq, ::prost::Message)]
281    pub struct MinTask {
282        /// / A list of subtasks to process and produce a list of result values.
283        #[prost(message, repeated, tag = "1")]
284        pub tasks: ::prost::alloc::vec::Vec<Task>,
285        /// / A list of subjobs to process and produce a list of result values.
286        #[prost(message, repeated, tag = "2")]
287        pub jobs: ::prost::alloc::vec::Vec<super::OracleJob>,
288    }
289    ///
290    /// Returns a specified value.
291    ///
292    /// _**Input**_: None
293    ///
294    /// _**Returns**_: A numerical result.
295    ///
296    /// _**Example**_: Returns the value 10
297    ///
298    /// ```json
299    /// {"valueTask": {"value": 10} }
300    /// ```
301    ///
302    /// _**Example**_: Returns the currentRound result of an aggregator
303    ///
304    /// ```json
305    /// {"valueTask": {"aggregatorPubkey": "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"} }
306    /// ```
307    ///
308    /// _**Example**_: Returns the value stored in a CacheTask variable
309    ///
310    /// ```json
311    /// {"valueTask": {"big": "${ONE}"} }
312    /// ```
313    #[allow(clippy::derive_partial_eq_without_eq)]
314    #[derive(Clone, PartialEq, ::prost::Message)]
315    pub struct ValueTask {
316        #[prost(oneof = "value_task::Value", tags = "1, 2, 3")]
317        pub value: ::core::option::Option<value_task::Value>,
318    }
319    /// Nested message and enum types in `ValueTask`.
320    pub mod value_task {
321        #[allow(clippy::derive_partial_eq_without_eq)]
322        #[derive(Clone, PartialEq, ::prost::Oneof)]
323        pub enum Value {
324            /// / The value that will be returned from this task.
325            #[prost(double, tag = "1")]
326            Value(f64),
327            /// / Specifies an aggregatorr to pull the value of.
328            #[prost(string, tag = "2")]
329            AggregatorPubkey(::prost::alloc::string::String),
330            /// / A stringified big.js. `Accepts variable expansion syntax.`
331            #[prost(string, tag = "3")]
332            Big(::prost::alloc::string::String),
333        }
334    }
335    ///
336    /// Opens and maintains a websocket for light speed data retrieval.
337    ///
338    /// _**Input**_: None
339    ///
340    /// _**Returns**_: String representation of the websocket subscription message.
341    ///
342    /// _**Example**_: Opens a coinbase websocket
343    ///
344    /// ```json
345    /// { "websocketTask": { "url": "wss://ws-feed.pro.coinbase.com", "subscription": "{\"type\":\"subscribe\",\"product_ids\":\[\"BTC-USD\"],\"channels\":[\"ticker\",{\"name\":\"ticker\",\"product_ids\":[\"BTC-USD\"]}\]}", "maxDataAgeSeconds": 15, "filter": "$[?(@.type == 'ticker' && @.product_id == 'BTC-USD')]" } }
346    /// ```
347    #[allow(clippy::derive_partial_eq_without_eq)]
348    #[derive(Clone, PartialEq, ::prost::Message)]
349    pub struct WebsocketTask {
350        /// / The websocket url.
351        #[prost(string, optional, tag = "1")]
352        pub url: ::core::option::Option<::prost::alloc::string::String>,
353        /// / The websocket message to notify of a new subscription.
354        #[prost(string, optional, tag = "2")]
355        pub subscription: ::core::option::Option<::prost::alloc::string::String>,
356        /// / Minimum amount of time required between when the horses are taking out.
357        #[prost(int32, optional, tag = "3")]
358        pub max_data_age_seconds: ::core::option::Option<i32>,
359        /// / Incoming message JSONPath filter.
360        /// / Example: "$[?(@.channel == 'ticker' && @.market == 'BTC/USD')]"
361        #[prost(string, optional, tag = "4")]
362        pub filter: ::core::option::Option<::prost::alloc::string::String>,
363    }
364    ///
365    /// This task will run the `attempt` on the subtasks in an effort to produce a valid numerical result. If `attempt`. fails to produce an acceptable result, `on_failure` subtasks will be run instead.
366    ///
367    /// _**Input**_: The current running numerical result output from a task.
368    ///
369    /// _**Returns**_: A numerical result, else run `on_failure` subtasks.
370    ///
371    /// _**Example**_: Returns the numerical result from the conditionalTask's subtasks, else `on_failure` returns the numerical result from its subtasks.
372    ///
373    /// ```json
374    /// {"conditionalTask":{"attempt":\[{"tasks":[{"jupiterSwapTask":{"inTokenAddress":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","outTokenAddress":"DUALa4FC2yREwZ59PHeu1un4wis36vHRv5hWVBmzykCJ"}}]}],"onFailure":[{"lpExchangeRateTask":{"orcaPoolAddress":"7yJ4gMRJhEoCR48aPE3EAWRmCoygakik81ZS1sajaTnE"}}\]}}
375    /// ```
376    #[allow(clippy::derive_partial_eq_without_eq)]
377    #[derive(Clone, PartialEq, ::prost::Message)]
378    pub struct ConditionalTask {
379        /// / A list of subtasks to process in an attempt to produce a valid numerical result.
380        #[prost(message, repeated, tag = "1")]
381        pub attempt: ::prost::alloc::vec::Vec<Task>,
382        /// / A list of subtasks that will be run if `attempt` subtasks are unable to produce an acceptable
383        /// / result.
384        #[prost(message, repeated, tag = "2")]
385        pub on_failure: ::prost::alloc::vec::Vec<Task>,
386    }
387    ///
388    /// This task will divide a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
389    ///
390    /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
391    ///
392    /// _**Returns**_: A numerical result.
393    ///
394    /// _**Example**_: Returns the numerical result by dividing by a job of subtasks.
395    ///
396    /// ```json
397    /// {"tasks":\[{"valueTask":{"value":100}},{"divideTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
398    /// ```
399    ///
400    /// _**Example**_: Returns the numerical result by dividing by an aggregator.
401    ///
402    /// ```json
403    /// {"tasks":\[{"valueTask":{"value":100}},{"divideTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
404    /// ```
405    ///
406    /// _**Example**_: Returns the numerical result by dividing by a big.
407    ///
408    /// ```json
409    /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"divideTask":{"big":"${TEN}"}}\]}
410    /// ```
411    #[allow(clippy::derive_partial_eq_without_eq)]
412    #[derive(Clone, PartialEq, ::prost::Message)]
413    pub struct DivideTask {
414        #[prost(oneof = "divide_task::Denominator", tags = "1, 2, 3, 4")]
415        pub denominator: ::core::option::Option<divide_task::Denominator>,
416    }
417    /// Nested message and enum types in `DivideTask`.
418    pub mod divide_task {
419        #[allow(clippy::derive_partial_eq_without_eq)]
420        #[derive(Clone, PartialEq, ::prost::Oneof)]
421        pub enum Denominator {
422            /// / Specifies a basic scalar denominator to divide by.
423            #[prost(double, tag = "1")]
424            Scalar(f64),
425            /// / Specifies another aggregator resut to divide by.
426            #[prost(string, tag = "2")]
427            AggregatorPubkey(::prost::alloc::string::String),
428            /// / A job whose result is computed before dividing our numerical input by that result.
429            #[prost(message, tag = "3")]
430            Job(super::super::OracleJob),
431            /// / A stringified big.js. `Accepts variable expansion syntax.`
432            #[prost(string, tag = "4")]
433            Big(::prost::alloc::string::String),
434        }
435    }
436    ///
437    /// This task will multiply a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
438    ///
439    /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
440    ///
441    /// _**Returns**_: A numerical result.
442    ///
443    /// _**Example**_: Returns the numerical result by multiplying by a job of subtasks.
444    ///
445    /// ```json
446    /// {"tasks":\[{"valueTask":{"value":100}},{"multiplyTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
447    /// ```
448    ///
449    /// _**Example**_: Returns the numerical result by multiplying by an aggregator.
450    ///
451    /// ```json
452    /// {"tasks":\[{"valueTask":{"value":100}},{"multiplyTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
453    /// ```
454    ///
455    /// _**Example**_: Returns the numerical result by multiplying by a big.
456    ///
457    /// ```json
458    /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"multiplyTask":{"big":"${TEN}"}}\]}
459    /// ```
460    #[allow(clippy::derive_partial_eq_without_eq)]
461    #[derive(Clone, PartialEq, ::prost::Message)]
462    pub struct MultiplyTask {
463        #[prost(oneof = "multiply_task::Multiple", tags = "1, 2, 3, 4")]
464        pub multiple: ::core::option::Option<multiply_task::Multiple>,
465    }
466    /// Nested message and enum types in `MultiplyTask`.
467    pub mod multiply_task {
468        #[allow(clippy::derive_partial_eq_without_eq)]
469        #[derive(Clone, PartialEq, ::prost::Oneof)]
470        pub enum Multiple {
471            /// / Specifies a scalar to multiply by.
472            #[prost(double, tag = "1")]
473            Scalar(f64),
474            /// / Specifies an aggregator to multiply by.
475            #[prost(string, tag = "2")]
476            AggregatorPubkey(::prost::alloc::string::String),
477            /// / A job whose result is computed before multiplying our numerical input by that result.
478            #[prost(message, tag = "3")]
479            Job(super::super::OracleJob),
480            /// / A stringified big.js. `Accepts variable expansion syntax.`
481            #[prost(string, tag = "4")]
482            Big(::prost::alloc::string::String),
483        }
484    }
485    ///
486    /// This task will add a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
487    ///
488    /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
489    ///
490    /// _**Returns**_: A numerical result.
491    ///
492    /// _**Example**_: Returns the numerical result by adding by a job of subtasks.
493    ///
494    /// ```json
495    /// {"tasks":\[{"valueTask":{"value":100}},{"addTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
496    /// ```
497    ///
498    /// _**Example**_: Returns the numerical result by multiplying by an aggregator.
499    ///
500    /// ```json
501    /// {"tasks":\[{"valueTask":{"value":100}},{"addTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
502    /// ```
503    ///
504    /// _**Example**_: Returns the numerical result by multiplying by a big.
505    ///
506    /// ```json
507    /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"addTask":{"big":"${TEN}"}}\]}
508    /// ```
509    #[allow(clippy::derive_partial_eq_without_eq)]
510    #[derive(Clone, PartialEq, ::prost::Message)]
511    pub struct AddTask {
512        #[prost(oneof = "add_task::Addition", tags = "1, 2, 3, 4")]
513        pub addition: ::core::option::Option<add_task::Addition>,
514    }
515    /// Nested message and enum types in `AddTask`.
516    pub mod add_task {
517        #[allow(clippy::derive_partial_eq_without_eq)]
518        #[derive(Clone, PartialEq, ::prost::Oneof)]
519        pub enum Addition {
520            /// / Specifies a scalar to add by.
521            #[prost(double, tag = "1")]
522            Scalar(f64),
523            /// / Specifies an aggregator to add by.
524            #[prost(string, tag = "2")]
525            AggregatorPubkey(::prost::alloc::string::String),
526            /// / A job whose result is computed before adding our numerical input by that result.
527            #[prost(message, tag = "3")]
528            Job(super::super::OracleJob),
529            /// / A stringified big.js. `Accepts variable expansion syntax.`
530            #[prost(string, tag = "4")]
531            Big(::prost::alloc::string::String),
532        }
533    }
534    ///
535    /// This task will subtract a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
536    ///
537    /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
538    ///
539    /// _**Returns**_: A numerical result.
540    ///
541    /// _**Example**_: Returns the numerical result by subtracting by a job of subtasks.
542    ///
543    /// ```json
544    /// {"tasks":\[{"valueTask":{"value":100}},{"subtractTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
545    /// ```
546    ///
547    /// _**Example**_: Returns the numerical result by multiplying by an aggregator.
548    ///
549    /// ```json
550    /// {"tasks":\[{"valueTask":{"value":100}},{"subtractTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
551    /// ```
552    ///
553    /// _**Example**_: Returns the numerical result by multiplying by a big.
554    ///
555    /// ```json
556    /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"subtractTask":{"big":"${TEN}"}}\]}
557    /// ```
558    #[allow(clippy::derive_partial_eq_without_eq)]
559    #[derive(Clone, PartialEq, ::prost::Message)]
560    pub struct SubtractTask {
561        #[prost(oneof = "subtract_task::Subtraction", tags = "1, 2, 3, 4")]
562        pub subtraction: ::core::option::Option<subtract_task::Subtraction>,
563    }
564    /// Nested message and enum types in `SubtractTask`.
565    pub mod subtract_task {
566        #[allow(clippy::derive_partial_eq_without_eq)]
567        #[derive(Clone, PartialEq, ::prost::Oneof)]
568        pub enum Subtraction {
569            /// / Specifies a scalar to subtract by.
570            #[prost(double, tag = "1")]
571            Scalar(f64),
572            /// / Specifies an aggregator to subtract by.
573            #[prost(string, tag = "2")]
574            AggregatorPubkey(::prost::alloc::string::String),
575            /// / A job whose result is computed before subtracting our numerical input by that result.
576            #[prost(message, tag = "3")]
577            Job(super::super::OracleJob),
578            /// / A stringified big.js. `Accepts variable expansion syntax.`
579            #[prost(string, tag = "4")]
580            Big(::prost::alloc::string::String),
581        }
582    }
583    ///
584    /// Fetch LP token price info from a number of supported exchanges.
585    ///
586    /// See our blog post on [Fair LP Token Oracles](/blog/2022/01/20/Fair-LP-Token-Oracles)
587    ///
588    /// *NOTE**: This is not the swap price but the price of the underlying LP token.
589    ///
590    /// _**Input**_: None
591    ///
592    /// _**Returns**_: The price of an LP token for a given AMM pool.
593    ///
594    /// _**Example**_: Fetch the Orca LP token price of the SOL/USDC pool
595    ///
596    /// ```json
597    /// { "lpTokenPriceTask": { "orcaPoolAddress": "APDFRM3HMr8CAGXwKHiu2f5ePSpaiEJhaURwhsRrUUt9" } }
598    /// ```
599    ///
600    /// _**Example**_: Fetch the fair price Orca LP token price of the SOL/USDC pool
601    ///
602    /// ```json
603    /// { "lpTokenPriceTask": { "orcaPoolAddress": "APDFRM3HMr8CAGXwKHiu2f5ePSpaiEJhaURwhsRrUUt9", "useFairPrice": true, "priceFeedAddresses": [ "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR", "BjUgj6YCnFBZ49wF54ddBVA9qu8TeqkFtkbqmZcee8uW" ] } }
604    /// ```
605    ///
606    /// _**Example**_: Fetch the fair price Raydium LP token price of the SOL/USDC pool
607    ///
608    /// ```json
609    /// { "lpTokenPriceTask": { "raydiumPoolAddress": "58oQChx4yWmvKdwLLZzBi4ChoCc2fqCUWBkwMihLYQo2", "useFairPrice": true,"priceFeedAddresses": ["GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR","BjUgj6YCnFBZ49wF54ddBVA9qu8TeqkFtkbqmZcee8uW" ] } }
610    /// ```
611    #[allow(clippy::derive_partial_eq_without_eq)]
612    #[derive(Clone, PartialEq, ::prost::Message)]
613    pub struct LpTokenPriceTask {
614        /// / A list of Switchboard aggregator accounts used to calculate the fair LP price. This ensures the price is based on the previous round to mitigate flash loan price manipulation.
615        #[prost(string, repeated, tag = "5")]
616        pub price_feed_addresses: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
617        /// / A list of OracleJobs to execute in order to yield the price feed jobs to use for the fair price formula.
618        #[prost(message, repeated, tag = "6")]
619        pub price_feed_jobs: ::prost::alloc::vec::Vec<super::OracleJob>,
620        /// / If enabled and price_feed_addresses provided, the oracle will calculate the fair LP price based on the liquidity pool reserves. See our blog post for more information: <https://switchboardxyz.medium.com/fair-lp-token-oracles-94a457c50239>
621        #[prost(bool, optional, tag = "7")]
622        pub use_fair_price: ::core::option::Option<bool>,
623        #[prost(oneof = "lp_token_price_task::PoolAddress", tags = "1, 2, 3, 4")]
624        pub pool_address: ::core::option::Option<lp_token_price_task::PoolAddress>,
625    }
626    /// Nested message and enum types in `LpTokenPriceTask`.
627    pub mod lp_token_price_task {
628        #[allow(clippy::derive_partial_eq_without_eq)]
629        #[derive(Clone, PartialEq, ::prost::Oneof)]
630        pub enum PoolAddress {
631            /// / Mercurial finance pool address. A full list can be found here: <https://github.com/mercurial-finance/stable-swap-n-pool-js>
632            #[prost(string, tag = "1")]
633            MercurialPoolAddress(::prost::alloc::string::String),
634            /// / Saber pool address. A full list can be found here: <https://github.com/saber-hq/saber-registry-dist>
635            #[prost(string, tag = "2")]
636            SaberPoolAddress(::prost::alloc::string::String),
637            /// / Orca pool address. A full list can be found here: <https://www.orca.so/pools>
638            #[prost(string, tag = "3")]
639            OrcaPoolAddress(::prost::alloc::string::String),
640            /// / The Raydium liquidity pool ammId. A full list can be found here: <https://sdk.raydium.io/liquidity/mainnet.json>
641            #[prost(string, tag = "4")]
642            RaydiumPoolAddress(::prost::alloc::string::String),
643        }
644    }
645    ///
646    /// Fetch the current swap price for a given liquidity pool
647    ///
648    /// _**Input**_: None
649    ///
650    /// _**Returns**_: The swap price for a given AMM pool.
651    ///
652    /// _**Example**_: Fetch the exchange rate from the Orca SOL/USDC pool
653    ///
654    /// ```json
655    /// { "lpExchangeRateTask": { "orcaPoolAddress": "APDFRM3HMr8CAGXwKHiu2f5ePSpaiEJhaURwhsRrUUt9" } }
656    /// ```
657    ///
658    /// _**Example**_: Fetch the exchange rate from the Raydium SOL/USDC pool
659    ///
660    /// ```json
661    /// { "lpExchangeRateTask": { "raydiumPoolAddress": "58oQChx4yWmvKdwLLZzBi4ChoCc2fqCUWBkwMihLYQo2" } }
662    /// ```
663    #[allow(clippy::derive_partial_eq_without_eq)]
664    #[derive(Clone, PartialEq, ::prost::Message)]
665    pub struct LpExchangeRateTask {
666        /// Used alongside mercurial_pool_address to specify the input token for a swap.
667        #[prost(string, optional, tag = "1")]
668        pub in_token_address: ::core::option::Option<::prost::alloc::string::String>,
669        /// Used alongside mercurial_pool_address to specify the output token for a swap.
670        #[prost(string, optional, tag = "2")]
671        pub out_token_address: ::core::option::Option<::prost::alloc::string::String>,
672        /// Amount of the input token to swap.
673        #[prost(uint64, optional, tag = "9")]
674        pub amount: ::core::option::Option<u64>,
675        #[prost(
676            oneof = "lp_exchange_rate_task::PoolAddress",
677            tags = "3, 4, 5, 6, 7, 8"
678        )]
679        pub pool_address: ::core::option::Option<lp_exchange_rate_task::PoolAddress>,
680    }
681    /// Nested message and enum types in `LpExchangeRateTask`.
682    pub mod lp_exchange_rate_task {
683        #[allow(clippy::derive_partial_eq_without_eq)]
684        #[derive(Clone, PartialEq, ::prost::Oneof)]
685        pub enum PoolAddress {
686            /// Mercurial finance pool address.
687            #[prost(string, tag = "3")]
688            MercurialPoolAddress(::prost::alloc::string::String),
689            /// Saber pool address.
690            #[prost(string, tag = "4")]
691            SaberPoolAddress(::prost::alloc::string::String),
692            /// **@deprecated** Use orcaPoolAddress
693            #[prost(string, tag = "5")]
694            OrcaPoolTokenMintAddress(::prost::alloc::string::String),
695            /// The Raydium liquidity pool ammId.
696            #[prost(string, tag = "6")]
697            RaydiumPoolAddress(::prost::alloc::string::String),
698            /// Pool address for an Orca LP pool or whirlpool.
699            #[prost(string, tag = "7")]
700            OrcaPoolAddress(::prost::alloc::string::String),
701            /// The Port reserve pubkey.
702            #[prost(string, tag = "8")]
703            PortReserveAddress(::prost::alloc::string::String),
704        }
705    }
706    /// / Find a pattern within a string of a previous task and extract a group number.
707    #[allow(clippy::derive_partial_eq_without_eq)]
708    #[derive(Clone, PartialEq, ::prost::Message)]
709    pub struct RegexExtractTask {
710        /// / Regex pattern to find.
711        #[prost(string, optional, tag = "1")]
712        pub pattern: ::core::option::Option<::prost::alloc::string::String>,
713        /// / Group number to extract.
714        #[prost(int32, optional, tag = "2")]
715        pub group_number: ::core::option::Option<i32>,
716    }
717    #[allow(clippy::derive_partial_eq_without_eq)]
718    #[derive(Clone, PartialEq, ::prost::Message)]
719    pub struct XStepPriceTask {
720        #[prost(oneof = "x_step_price_task::StepSource", tags = "1, 2")]
721        pub step_source: ::core::option::Option<x_step_price_task::StepSource>,
722    }
723    /// Nested message and enum types in `XStepPriceTask`.
724    pub mod x_step_price_task {
725        #[allow(clippy::derive_partial_eq_without_eq)]
726        #[derive(Clone, PartialEq, ::prost::Oneof)]
727        pub enum StepSource {
728            /// / median task containing the job definitions to fetch the STEP/USD price
729            #[prost(message, tag = "1")]
730            StepJob(super::MedianTask),
731            /// / existing aggregator pubkey for STEP/USD
732            #[prost(string, tag = "2")]
733            StepAggregatorPubkey(::prost::alloc::string::String),
734        }
735    }
736    ///
737    /// Takes a twap over a set period for a certain aggregator. Aggregators have an optional history buffer account storing the last N accepted results. The TwapTask will iterate over an aggregators history buffer and calculate the time weighted average of the samples within a given time period.
738    ///
739    /// _**Input**_: None
740    ///
741    /// _**Returns**_: The time weighted average of an aggregator over a given time period.
742    ///
743    /// _**Example**_: The 1hr Twap of the SOL/USD Aggregator, requiring at least 60 samples.
744    ///
745    /// ```json
746    /// { "twapTask": { "aggregatorPubkey": "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR", "period": 3600, "minSamples": 60, "weightByPropagationTime": true  } }
747    /// ```
748    #[allow(clippy::derive_partial_eq_without_eq)]
749    #[derive(Clone, PartialEq, ::prost::Message)]
750    pub struct TwapTask {
751        /// / The target aggregator for the TWAP.
752        #[prost(string, optional, tag = "1")]
753        pub aggregator_pubkey: ::core::option::Option<::prost::alloc::string::String>,
754        /// / Period, in seconds, the twap should account for
755        #[prost(int32, optional, tag = "2")]
756        pub period: ::core::option::Option<i32>,
757        /// / Weight samples by their propagation time
758        #[prost(bool, optional, tag = "3")]
759        pub weight_by_propagation_time: ::core::option::Option<bool>,
760        /// / Minimum number of samples in the history to calculate a valid result
761        #[prost(uint32, optional, tag = "4")]
762        pub min_samples: ::core::option::Option<u32>,
763        /// / Ending unix timestamp to collect values up to
764        #[prost(int32, optional, tag = "5")]
765        pub ending_unix_timestamp: ::core::option::Option<i32>,
766        /// / Execute the task to get the ending unix timestamp
767        #[prost(message, optional, tag = "6")]
768        pub ending_unix_timestamp_task: ::core::option::Option<CronParseTask>,
769    }
770    /// / Fetch the latest swap price on Serum's orderbook
771    #[allow(clippy::derive_partial_eq_without_eq)]
772    #[derive(Clone, PartialEq, ::prost::Message)]
773    pub struct SerumSwapTask {
774        /// / The serum pool to fetch swap price for
775        #[prost(string, optional, tag = "1")]
776        pub serum_pool_address: ::core::option::Option<::prost::alloc::string::String>,
777    }
778    ///
779    /// Round the current running result to an exponential power.
780    ///
781    /// _**Input**_: The current running numerical result.
782    ///
783    /// _**Returns**_: The input raised to an exponential power.
784    ///
785    /// _**Example**_: Raise 2 to the power of 3, 2^3
786    ///
787    /// ```json
788    /// {"tasks":\[{"valueTask":{"value":2}},{"powTask":{"scalar":3}}\]}
789    /// ```
790    #[allow(clippy::derive_partial_eq_without_eq)]
791    #[derive(Clone, PartialEq, ::prost::Message)]
792    pub struct PowTask {
793        #[prost(oneof = "pow_task::Exponent", tags = "1, 2, 3")]
794        pub exponent: ::core::option::Option<pow_task::Exponent>,
795    }
796    /// Nested message and enum types in `PowTask`.
797    pub mod pow_task {
798        #[allow(clippy::derive_partial_eq_without_eq)]
799        #[derive(Clone, PartialEq, ::prost::Oneof)]
800        pub enum Exponent {
801            /// / Take the working value to the exponent of value.
802            #[prost(double, tag = "1")]
803            Scalar(f64),
804            /// / Take the working value to the exponent of the aggregators value.
805            #[prost(string, tag = "2")]
806            AggregatorPubkey(::prost::alloc::string::String),
807            /// / A stringified big.js. `Accepts variable expansion syntax.`
808            #[prost(string, tag = "3")]
809            Big(::prost::alloc::string::String),
810        }
811    }
812    /// / Fetch the lending rates for various Solana protocols
813    #[allow(clippy::derive_partial_eq_without_eq)]
814    #[derive(Clone, PartialEq, ::prost::Message)]
815    pub struct LendingRateTask {
816        /// / 01, apricot, francium, jet, larix, mango, port, solend, tulip
817        #[prost(string, optional, tag = "1")]
818        pub protocol: ::core::option::Option<::prost::alloc::string::String>,
819        /// / A token mint address supported by the chosen protocol
820        #[prost(string, optional, tag = "2")]
821        pub asset_mint: ::core::option::Option<::prost::alloc::string::String>,
822        #[prost(enumeration = "lending_rate_task::Field", optional, tag = "3")]
823        pub field: ::core::option::Option<i32>,
824    }
825    /// Nested message and enum types in `LendingRateTask`.
826    pub mod lending_rate_task {
827        #[derive(
828            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
829        )]
830        #[repr(i32)]
831        pub enum Field {
832            /// / deposit lending rate
833            DepositRate = 0,
834            /// / borrow lending rate
835            BorrowRate = 1,
836        }
837        impl Field {
838            /// String value of the enum field names used in the ProtoBuf definition.
839            ///
840            /// The values are not transformed in any way and thus are considered stable
841            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
842            pub fn as_str_name(&self) -> &'static str {
843                match self {
844                    Field::DepositRate => "FIELD_DEPOSIT_RATE",
845                    Field::BorrowRate => "FIELD_BORROW_RATE",
846                }
847            }
848            /// Creates an enum from field names used in the ProtoBuf definition.
849            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
850                match value {
851                    "FIELD_DEPOSIT_RATE" => Some(Self::DepositRate),
852                    "FIELD_BORROW_RATE" => Some(Self::BorrowRate),
853                    _ => None,
854                }
855            }
856        }
857    }
858    /// / Fetch the current price for a Mango perpetual market
859    #[allow(clippy::derive_partial_eq_without_eq)]
860    #[derive(Clone, PartialEq, ::prost::Message)]
861    pub struct MangoPerpMarketTask {
862        /// / Mainnet address for a mango perpetual market. A full list can be found here: <https://github.com/blockworks-foundation/mango-client-v3/blob/main/src/ids.json>
863        #[prost(string, optional, tag = "1")]
864        pub perp_market_address: ::core::option::Option<::prost::alloc::string::String>,
865    }
866    ///
867    /// Fetch the simulated price for a swap on JupiterSwap.
868    ///
869    /// _**Input**_: None
870    ///
871    /// _**Returns**_: The swap price on Jupiter for a given input and output token mint address.
872    ///
873    /// _**Example**_: Fetch the JupiterSwap price for exchanging 1 SOL into USDC.
874    ///
875    /// ```json
876    /// { "jupiterSwapTask": { "inTokenAddress": "So11111111111111111111111111111111111111112", "outTokenAddress": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" } }
877    /// ```
878    ///
879    /// _**Example**_: Fetch the JupiterSwap price for exchanging 1000 SOL into USDC.
880    ///
881    /// ```json
882    /// { "jupiterSwapTask": { "inTokenAddress": "So11111111111111111111111111111111111111112", "outTokenAddress": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", "baseAmount": "1000" } }
883    /// ```
884    #[allow(clippy::derive_partial_eq_without_eq)]
885    #[derive(Clone, PartialEq, ::prost::Message)]
886    pub struct JupiterSwapTask {
887        /// / The input token address.
888        #[prost(string, optional, tag = "1")]
889        pub in_token_address: ::core::option::Option<::prost::alloc::string::String>,
890        /// / The output token address.
891        #[prost(string, optional, tag = "2")]
892        pub out_token_address: ::core::option::Option<::prost::alloc::string::String>,
893        /// / The allowable slippage on the swap in decimal form (e.g. 0.5 is 0.5% slippage)
894        #[prost(double, optional, tag = "9")]
895        pub slippage: ::core::option::Option<f64>,
896        #[prost(oneof = "jupiter_swap_task::RoutesFilters", tags = "4, 5")]
897        pub routes_filters: ::core::option::Option<jupiter_swap_task::RoutesFilters>,
898        #[prost(oneof = "jupiter_swap_task::SwapAmount", tags = "3, 6, 7, 8")]
899        pub swap_amount: ::core::option::Option<jupiter_swap_task::SwapAmount>,
900    }
901    /// Nested message and enum types in `JupiterSwapTask`.
902    pub mod jupiter_swap_task {
903        #[allow(clippy::derive_partial_eq_without_eq)]
904        #[derive(Clone, PartialEq, ::prost::Message)]
905        pub struct FilterList {
906            /// / A list of Jupiter AMM labels to allow or deny (e.g. 'Raydium', 'Orca')
907            #[prost(string, repeated, tag = "1")]
908            pub labels: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
909        }
910        #[allow(clippy::derive_partial_eq_without_eq)]
911        #[derive(Clone, PartialEq, ::prost::Oneof)]
912        pub enum RoutesFilters {
913            /// / A list of AMM markets to allow.
914            #[prost(message, tag = "4")]
915            AllowList(FilterList),
916            /// / A list of AMM markets to deny.
917            #[prost(message, tag = "5")]
918            DenyList(FilterList),
919        }
920        #[allow(clippy::derive_partial_eq_without_eq)]
921        #[derive(Clone, PartialEq, ::prost::Oneof)]
922        pub enum SwapAmount {
923            /// / The amount of `in_token_address` tokens to swap.
924            #[prost(double, tag = "3")]
925            BaseAmount(f64),
926            /// / The amount of `out_token_address` tokens to swap.
927            #[prost(double, tag = "6")]
928            QuoteAmount(f64),
929            /// / The amount of `in_token_address` tokens to swap.
930            #[prost(string, tag = "7")]
931            BaseAmountString(::prost::alloc::string::String),
932            /// / The amount of `out_token_address` tokens to swap.
933            #[prost(string, tag = "8")]
934            QuoteAmountString(::prost::alloc::string::String),
935        }
936    }
937    /// / Fetch the current price of a perpetual market.
938    #[allow(clippy::derive_partial_eq_without_eq)]
939    #[derive(Clone, PartialEq, ::prost::Message)]
940    pub struct PerpMarketTask {
941        #[prost(oneof = "perp_market_task::MarketAddress", tags = "1, 2, 3, 4")]
942        pub market_address: ::core::option::Option<perp_market_task::MarketAddress>,
943    }
944    /// Nested message and enum types in `PerpMarketTask`.
945    pub mod perp_market_task {
946        #[allow(clippy::derive_partial_eq_without_eq)]
947        #[derive(Clone, PartialEq, ::prost::Oneof)]
948        pub enum MarketAddress {
949            /// / Market address for a mango perpetual market. A full list can be found here: <https://github.com/blockworks-foundation/mango-client-v3/blob/main/src/ids.json>
950            #[prost(string, tag = "1")]
951            MangoMarketAddress(::prost::alloc::string::String),
952            /// / Market address for a drift perpetual market. A full list can be found here: <https://github.com/drift-labs/protocol-v1/blob/master/sdk/src/constants/markets.ts>
953            #[prost(string, tag = "2")]
954            DriftMarketAddress(::prost::alloc::string::String),
955            /// / Market address for a zeta perpetual market.
956            #[prost(string, tag = "3")]
957            ZetaMarketAddress(::prost::alloc::string::String),
958            /// / Market address for a 01 protocol perpetual market.
959            #[prost(string, tag = "4")]
960            ZoMarketAddress(::prost::alloc::string::String),
961        }
962    }
963    ///
964    /// Fetch the current price of a Solana oracle protocol.
965    ///
966    /// _**Input**_: None
967    ///
968    /// _**Returns**_: The current price of an on-chain oracle.
969    ///
970    /// _**Example**_: The Switchboard SOL/USD oracle price.
971    ///
972    /// ```json
973    /// { "oracleTask": { "switchboardAddress": "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR" } }
974    /// ```
975    ///
976    /// _**Example**_: The Pyth SOL/USD oracle price.
977    ///
978    /// ```json
979    /// { "oracleTask": { "pythAddress": "H6ARHf6YXhGYeQfUzQNGk6rDNnLBQKrenN712K4AQJEG" } }
980    /// ```
981    ///
982    /// _**Example**_: The Chainlink SOL/USD oracle price.
983    ///
984    /// ```json
985    /// { "oracleTask": { "chainlinkAddress": "CcPVS9bqyXbD9cLnTbhhHazLsrua8QMFUHTutPtjyDzq" } }
986    /// ```
987    #[allow(clippy::derive_partial_eq_without_eq)]
988    #[derive(Clone, PartialEq, ::prost::Message)]
989    pub struct OracleTask {
990        /// / Value (as a percentage) that the lower bound confidence interval is of the actual value.
991        /// / Confidence intervals that are larger that this treshold are rejected.
992        #[prost(double, optional, tag = "4")]
993        pub pyth_allowed_confidence_interval: ::core::option::Option<f64>,
994        #[prost(oneof = "oracle_task::AggregatorAddress", tags = "1, 2, 3")]
995        pub aggregator_address: ::core::option::Option<oracle_task::AggregatorAddress>,
996    }
997    /// Nested message and enum types in `OracleTask`.
998    pub mod oracle_task {
999        #[allow(clippy::derive_partial_eq_without_eq)]
1000        #[derive(Clone, PartialEq, ::prost::Oneof)]
1001        pub enum AggregatorAddress {
1002            /// / Mainnet address of a Switchboard V2 feed. Switchboard is decentralized and allows anyone to build their own feed. A small subset of feeds is available here: <https://switchboard.xyz/explorer>
1003            #[prost(string, tag = "1")]
1004            SwitchboardAddress(::prost::alloc::string::String),
1005            /// / Mainnet address for a Pyth feed. A full list can be found here: <https://pyth.network/price-feeds/>
1006            #[prost(string, tag = "2")]
1007            PythAddress(::prost::alloc::string::String),
1008            /// / Mainnet address for a Chainlink feed. A full list can be found here: <https://docs.chain.link/docs/solana/data-feeds-solana>
1009            #[prost(string, tag = "3")]
1010            ChainlinkAddress(::prost::alloc::string::String),
1011        }
1012    }
1013    /// / Load a parse an Anchor based solana account.
1014    #[allow(clippy::derive_partial_eq_without_eq)]
1015    #[derive(Clone, PartialEq, ::prost::Message)]
1016    pub struct AnchorFetchTask {
1017        /// / Owning program of the account to parse.
1018        #[prost(string, optional, tag = "1")]
1019        pub program_id: ::core::option::Option<::prost::alloc::string::String>,
1020        /// / The account to parse.
1021        #[prost(string, optional, tag = "2")]
1022        pub account_address: ::core::option::Option<::prost::alloc::string::String>,
1023    }
1024    /// / Fetch the current transactions per second.
1025    #[allow(clippy::derive_partial_eq_without_eq)]
1026    #[derive(Clone, PartialEq, ::prost::Message)]
1027    pub struct TpsTask {}
1028    /// / Fetch the JSON representation of an SPL Stake Pool account.
1029    #[allow(clippy::derive_partial_eq_without_eq)]
1030    #[derive(Clone, PartialEq, ::prost::Message)]
1031    pub struct SplStakePoolTask {
1032        /// / The pubkey of the SPL Stake Pool.
1033        #[prost(string, optional, tag = "1")]
1034        pub pubkey: ::core::option::Option<::prost::alloc::string::String>,
1035    }
1036    /// / Fetch the JSON representation of an SPL token mint.
1037    #[allow(clippy::derive_partial_eq_without_eq)]
1038    #[derive(Clone, PartialEq, ::prost::Message)]
1039    pub struct SplTokenParseTask {
1040        #[prost(oneof = "spl_token_parse_task::AccountAddress", tags = "1, 2")]
1041        pub account_address: ::core::option::Option<spl_token_parse_task::AccountAddress>,
1042    }
1043    /// Nested message and enum types in `SplTokenParseTask`.
1044    pub mod spl_token_parse_task {
1045        #[allow(clippy::derive_partial_eq_without_eq)]
1046        #[derive(Clone, PartialEq, ::prost::Oneof)]
1047        pub enum AccountAddress {
1048            /// / The publicKey of a token account to fetch the mintInfo for.
1049            #[prost(string, tag = "1")]
1050            TokenAccountAddress(::prost::alloc::string::String),
1051            /// / The publicKey of the token mint address.
1052            #[prost(string, tag = "2")]
1053            MintAddress(::prost::alloc::string::String),
1054        }
1055    }
1056    /// / Fetch the swap price from DefiKingdoms.
1057    #[allow(clippy::derive_partial_eq_without_eq)]
1058    #[derive(Clone, PartialEq, ::prost::Message)]
1059    pub struct DefiKingdomsTask {
1060        /// / The RPC provider to use for the swap.
1061        #[prost(string, optional, tag = "1")]
1062        pub provider: ::core::option::Option<::prost::alloc::string::String>,
1063        /// / The input token of the swap.
1064        #[prost(message, optional, tag = "2")]
1065        pub in_token: ::core::option::Option<defi_kingdoms_task::Token>,
1066        /// / The output token of the swap.
1067        #[prost(message, optional, tag = "3")]
1068        pub out_token: ::core::option::Option<defi_kingdoms_task::Token>,
1069    }
1070    /// Nested message and enum types in `DefiKingdomsTask`.
1071    pub mod defi_kingdoms_task {
1072        #[allow(clippy::derive_partial_eq_without_eq)]
1073        #[derive(Clone, PartialEq, ::prost::Message)]
1074        pub struct Token {
1075            /// / The address of the token.
1076            #[prost(string, optional, tag = "1")]
1077            pub address: ::core::option::Option<::prost::alloc::string::String>,
1078            /// / The number of decimal places for a token.
1079            #[prost(int32, optional, tag = "2")]
1080            pub decimals: ::core::option::Option<i32>,
1081        }
1082    }
1083    /// / Fetch the swap price from UniSwap.
1084    #[allow(clippy::derive_partial_eq_without_eq)]
1085    #[derive(Clone, PartialEq, ::prost::Message)]
1086    pub struct UniswapExchangeRateTask {
1087        /// / The input token address.
1088        #[prost(string, optional, tag = "1")]
1089        pub in_token_address: ::core::option::Option<::prost::alloc::string::String>,
1090        /// / The output token address.
1091        #[prost(string, optional, tag = "2")]
1092        pub out_token_address: ::core::option::Option<::prost::alloc::string::String>,
1093        /// / The amount of tokens to swap.
1094        #[prost(double, optional, tag = "3")]
1095        pub in_token_amount: ::core::option::Option<f64>,
1096        /// / The allowable slippage in percent for the swap.
1097        #[prost(double, optional, tag = "4")]
1098        pub slippage: ::core::option::Option<f64>,
1099        /// / The RPC provider to use for the swap.
1100        #[prost(string, optional, tag = "5")]
1101        pub provider: ::core::option::Option<::prost::alloc::string::String>,
1102    }
1103    /// / Fetch the swap price from SushiSwap.
1104    #[allow(clippy::derive_partial_eq_without_eq)]
1105    #[derive(Clone, PartialEq, ::prost::Message)]
1106    pub struct SushiswapExchangeRateTask {
1107        /// / The input token address.
1108        #[prost(string, optional, tag = "1")]
1109        pub in_token_address: ::core::option::Option<::prost::alloc::string::String>,
1110        /// / The output token address.
1111        #[prost(string, optional, tag = "2")]
1112        pub out_token_address: ::core::option::Option<::prost::alloc::string::String>,
1113        /// / The amount of tokens to swap.
1114        #[prost(double, optional, tag = "3")]
1115        pub in_token_amount: ::core::option::Option<f64>,
1116        /// / The allowable slippage in percent for the swap.
1117        #[prost(double, optional, tag = "4")]
1118        pub slippage: ::core::option::Option<f64>,
1119        /// / The RPC provider to use for the swap.
1120        #[prost(string, optional, tag = "5")]
1121        pub provider: ::core::option::Option<::prost::alloc::string::String>,
1122    }
1123    /// / Fetch the swap price from PancakeSwap.
1124    #[allow(clippy::derive_partial_eq_without_eq)]
1125    #[derive(Clone, PartialEq, ::prost::Message)]
1126    pub struct PancakeswapExchangeRateTask {
1127        /// / The input token address.
1128        #[prost(string, optional, tag = "1")]
1129        pub in_token_address: ::core::option::Option<::prost::alloc::string::String>,
1130        /// / The output token address.
1131        #[prost(string, optional, tag = "2")]
1132        pub out_token_address: ::core::option::Option<::prost::alloc::string::String>,
1133        /// / The amount of tokens to swap.
1134        #[prost(double, optional, tag = "3")]
1135        pub in_token_amount: ::core::option::Option<f64>,
1136        /// / The allowable slippage in percent for the swap.
1137        #[prost(double, optional, tag = "4")]
1138        pub slippage: ::core::option::Option<f64>,
1139        /// / The RPC provider to use for the swap.
1140        #[prost(string, optional, tag = "5")]
1141        pub provider: ::core::option::Option<::prost::alloc::string::String>,
1142    }
1143    ///
1144    /// Execute a job and store the result in a variable to reference later.
1145    ///
1146    /// _**Input**_: None
1147    ///
1148    /// _**Returns**_: The input
1149    ///
1150    /// _**Example**_: CacheTask storing ${ONE} = 1
1151    ///
1152    /// ```json
1153    /// { "cacheTask": { "cacheItems": [ { "variableName": "ONE", "job": { "tasks": [ { "valueTask": { "value": 1 } } ] } } ] } }
1154    /// ```
1155    #[allow(clippy::derive_partial_eq_without_eq)]
1156    #[derive(Clone, PartialEq, ::prost::Message)]
1157    pub struct CacheTask {
1158        /// / A list of cached variables to reference in the job with `${VARIABLE_NAME}`.
1159        #[prost(message, repeated, tag = "1")]
1160        pub cache_items: ::prost::alloc::vec::Vec<cache_task::CacheItem>,
1161    }
1162    /// Nested message and enum types in `CacheTask`.
1163    pub mod cache_task {
1164        #[allow(clippy::derive_partial_eq_without_eq)]
1165        #[derive(Clone, PartialEq, ::prost::Message)]
1166        pub struct CacheItem {
1167            /// / The name of the variable to store in cache to reference later with `${VARIABLE_NAME}`.
1168            #[prost(string, optional, tag = "1")]
1169            pub variable_name: ::core::option::Option<::prost::alloc::string::String>,
1170            /// / The OracleJob to execute to yield the value to store in cache.
1171            #[prost(message, optional, tag = "2")]
1172            pub job: ::core::option::Option<super::super::OracleJob>,
1173        }
1174    }
1175    /// / Return the difference between an oracle's clock and the current timestamp at `SYSVAR_CLOCK_PUBKEY`.
1176    #[allow(clippy::derive_partial_eq_without_eq)]
1177    #[derive(Clone, PartialEq, ::prost::Message)]
1178    pub struct SysclockOffsetTask {}
1179    #[allow(clippy::derive_partial_eq_without_eq)]
1180    #[derive(Clone, PartialEq, ::prost::Message)]
1181    pub struct MarinadeStateTask {}
1182    /// / Fetch the account data in a stringified buffer format.
1183    #[allow(clippy::derive_partial_eq_without_eq)]
1184    #[derive(Clone, PartialEq, ::prost::Message)]
1185    pub struct SolanaAccountDataFetchTask {
1186        /// / The on-chain account to fetch the account data from.
1187        #[prost(string, optional, tag = "1")]
1188        pub pubkey: ::core::option::Option<::prost::alloc::string::String>,
1189    }
1190    ///
1191    /// Return a timestamp from a crontab instruction.
1192    ///
1193    /// _**Input**_: None
1194    ///
1195    /// _**Returns**_: A timestamp
1196    ///
1197    /// _**Example**_: Return the unix timestamp for the on-chain SYSCLOCK
1198    ///
1199    /// ```json
1200    /// {"cronParseTask":{"cronPattern":"* * * * * *","clockOffset":0,"clock":"SYSCLOCK"}}
1201    /// ```
1202    ///
1203    /// _**Example**_: Return the unix timestamp for next friday at 5pm UTC
1204    ///
1205    /// ```json
1206    /// {"cronParseTask":{"cronPattern":"0 17 * * 5","clockOffset":0,"clock":0}}
1207    /// ```
1208    #[allow(clippy::derive_partial_eq_without_eq)]
1209    #[derive(Clone, PartialEq, ::prost::Message)]
1210    pub struct CronParseTask {
1211        /// / The cron pattern to parse.
1212        #[prost(string, optional, tag = "1")]
1213        pub cron_pattern: ::core::option::Option<::prost::alloc::string::String>,
1214        /// / The timestamp offset to calculate the next run.
1215        #[prost(int32, optional, tag = "2")]
1216        pub clock_offset: ::core::option::Option<i32>,
1217        /// / Use the TaskRunner's clock or the on-chain SYSCLOCK.
1218        #[prost(enumeration = "cron_parse_task::ClockType", optional, tag = "3")]
1219        pub clock: ::core::option::Option<i32>,
1220    }
1221    /// Nested message and enum types in `CronParseTask`.
1222    pub mod cron_parse_task {
1223        #[derive(
1224            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
1225        )]
1226        #[repr(i32)]
1227        pub enum ClockType {
1228            /// / Use the TaskRunners system clock for the current time.
1229            Oracle = 0,
1230            /// / Use the on-chain SYSCLOCK for the current time.
1231            Sysclock = 1,
1232        }
1233        impl ClockType {
1234            /// String value of the enum field names used in the ProtoBuf definition.
1235            ///
1236            /// The values are not transformed in any way and thus are considered stable
1237            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1238            pub fn as_str_name(&self) -> &'static str {
1239                match self {
1240                    ClockType::Oracle => "ORACLE",
1241                    ClockType::Sysclock => "SYSCLOCK",
1242                }
1243            }
1244            /// Creates an enum from field names used in the ProtoBuf definition.
1245            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1246                match value {
1247                    "ORACLE" => Some(Self::Oracle),
1248                    "SYSCLOCK" => Some(Self::Sysclock),
1249                    _ => None,
1250                }
1251            }
1252        }
1253    }
1254    /// / Return the deserialized value from a stringified buffer.
1255    #[allow(clippy::derive_partial_eq_without_eq)]
1256    #[derive(Clone, PartialEq, ::prost::Message)]
1257    pub struct BufferLayoutParseTask {
1258        /// / The buffer offset to start deserializing from.
1259        #[prost(uint32, optional, tag = "1")]
1260        pub offset: ::core::option::Option<u32>,
1261        /// / The endianness of the stored value.
1262        #[prost(enumeration = "buffer_layout_parse_task::Endian", optional, tag = "2")]
1263        pub endian: ::core::option::Option<i32>,
1264        /// / The type of value to deserialize.
1265        #[prost(
1266            enumeration = "buffer_layout_parse_task::BufferParseType",
1267            optional,
1268            tag = "3"
1269        )]
1270        pub r#type: ::core::option::Option<i32>,
1271    }
1272    /// Nested message and enum types in `BufferLayoutParseTask`.
1273    pub mod buffer_layout_parse_task {
1274        #[derive(
1275            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
1276        )]
1277        #[repr(i32)]
1278        pub enum Endian {
1279            /// Use little endian byte order.
1280            LittleEndian = 0,
1281            /// Use big endian byte order.
1282            BigEndian = 1,
1283        }
1284        impl Endian {
1285            /// String value of the enum field names used in the ProtoBuf definition.
1286            ///
1287            /// The values are not transformed in any way and thus are considered stable
1288            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1289            pub fn as_str_name(&self) -> &'static str {
1290                match self {
1291                    Endian::LittleEndian => "LITTLE_ENDIAN",
1292                    Endian::BigEndian => "BIG_ENDIAN",
1293                }
1294            }
1295            /// Creates an enum from field names used in the ProtoBuf definition.
1296            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1297                match value {
1298                    "LITTLE_ENDIAN" => Some(Self::LittleEndian),
1299                    "BIG_ENDIAN" => Some(Self::BigEndian),
1300                    _ => None,
1301                }
1302            }
1303        }
1304        #[derive(
1305            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
1306        )]
1307        #[repr(i32)]
1308        pub enum BufferParseType {
1309            /// / A public key.
1310            Pubkey = 1,
1311            /// / A boolean.
1312            Bool = 2,
1313            /// / An 8-bit unsigned value.
1314            U8 = 3,
1315            /// / An 8-bit signed value.
1316            I8 = 4,
1317            /// / A 16-bit unsigned value.
1318            U16 = 5,
1319            /// / A 16-bit signed value.
1320            I16 = 6,
1321            /// / A 32-bit unsigned value.
1322            U32 = 7,
1323            /// / A 32-bit signed value.
1324            I32 = 8,
1325            /// / A 32-bit IEEE floating point value.
1326            F32 = 9,
1327            /// / A 64-bit unsigned value.
1328            U64 = 10,
1329            /// / A 64-bit signed value.
1330            I64 = 11,
1331            /// / A 64-bit IEEE floating point value.
1332            F64 = 12,
1333            /// / A 128-bit unsigned value.
1334            U128 = 13,
1335            /// / A 128-bit signed value.
1336            I128 = 14,
1337        }
1338        impl BufferParseType {
1339            /// String value of the enum field names used in the ProtoBuf definition.
1340            ///
1341            /// The values are not transformed in any way and thus are considered stable
1342            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1343            pub fn as_str_name(&self) -> &'static str {
1344                match self {
1345                    BufferParseType::Pubkey => "pubkey",
1346                    BufferParseType::Bool => "bool",
1347                    BufferParseType::U8 => "u8",
1348                    BufferParseType::I8 => "i8",
1349                    BufferParseType::U16 => "u16",
1350                    BufferParseType::I16 => "i16",
1351                    BufferParseType::U32 => "u32",
1352                    BufferParseType::I32 => "i32",
1353                    BufferParseType::F32 => "f32",
1354                    BufferParseType::U64 => "u64",
1355                    BufferParseType::I64 => "i64",
1356                    BufferParseType::F64 => "f64",
1357                    BufferParseType::U128 => "u128",
1358                    BufferParseType::I128 => "i128",
1359                }
1360            }
1361            /// Creates an enum from field names used in the ProtoBuf definition.
1362            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1363                match value {
1364                    "pubkey" => Some(Self::Pubkey),
1365                    "bool" => Some(Self::Bool),
1366                    "u8" => Some(Self::U8),
1367                    "i8" => Some(Self::I8),
1368                    "u16" => Some(Self::U16),
1369                    "i16" => Some(Self::I16),
1370                    "u32" => Some(Self::U32),
1371                    "i32" => Some(Self::I32),
1372                    "f32" => Some(Self::F32),
1373                    "u64" => Some(Self::U64),
1374                    "i64" => Some(Self::I64),
1375                    "f64" => Some(Self::F64),
1376                    "u128" => Some(Self::U128),
1377                    "i128" => Some(Self::I128),
1378                    _ => None,
1379                }
1380            }
1381        }
1382    }
1383    #[allow(clippy::derive_partial_eq_without_eq)]
1384    #[derive(Clone, PartialEq, ::prost::Message)]
1385    pub struct HistoryFunctionTask {
1386        #[prost(enumeration = "history_function_task::Method", optional, tag = "1")]
1387        pub method: ::core::option::Option<i32>,
1388        #[prost(string, optional, tag = "2")]
1389        pub aggregator_address: ::core::option::Option<::prost::alloc::string::String>,
1390        #[prost(uint32, optional, tag = "3")]
1391        pub period: ::core::option::Option<u32>,
1392    }
1393    /// Nested message and enum types in `HistoryFunctionTask`.
1394    pub mod history_function_task {
1395        #[derive(
1396            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
1397        )]
1398        #[repr(i32)]
1399        pub enum Method {
1400            Min = 0,
1401            Max = 1,
1402        }
1403        impl Method {
1404            /// String value of the enum field names used in the ProtoBuf definition.
1405            ///
1406            /// The values are not transformed in any way and thus are considered stable
1407            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1408            pub fn as_str_name(&self) -> &'static str {
1409                match self {
1410                    Method::Min => "METHOD_MIN",
1411                    Method::Max => "METHOD_MAX",
1412                }
1413            }
1414            /// Creates an enum from field names used in the ProtoBuf definition.
1415            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1416                match value {
1417                    "METHOD_MIN" => Some(Self::Min),
1418                    "METHOD_MAX" => Some(Self::Max),
1419                    _ => None,
1420                }
1421            }
1422        }
1423    }
1424    #[allow(clippy::derive_partial_eq_without_eq)]
1425    #[derive(Clone, PartialEq, ::prost::Message)]
1426    pub struct VwapTask {
1427        #[prost(string, optional, tag = "1")]
1428        pub price_aggregator_address: ::core::option::Option<::prost::alloc::string::String>,
1429        #[prost(string, optional, tag = "2")]
1430        pub volume_aggregator_address: ::core::option::Option<::prost::alloc::string::String>,
1431        #[prost(uint32, optional, tag = "3")]
1432        pub period: ::core::option::Option<u32>,
1433    }
1434    #[allow(clippy::derive_partial_eq_without_eq)]
1435    #[derive(Clone, PartialEq, ::prost::Message)]
1436    pub struct EwmaTask {
1437        #[prost(string, optional, tag = "1")]
1438        pub aggregator_address: ::core::option::Option<::prost::alloc::string::String>,
1439        #[prost(int32, optional, tag = "2")]
1440        pub period: ::core::option::Option<i32>,
1441        #[prost(double, optional, tag = "3")]
1442        pub lambda: ::core::option::Option<f64>,
1443    }
1444    #[allow(clippy::derive_partial_eq_without_eq)]
1445    #[derive(Clone, PartialEq, ::prost::Message)]
1446    pub struct ComparisonTask {
1447        /// / The type of operator to use on the left (lhs) and right (rhs) operand.
1448        #[prost(enumeration = "comparison_task::Operation", optional, tag = "1")]
1449        pub op: ::core::option::Option<i32>,
1450        /// / The OracleJob to execute if the condition evaluates to true.
1451        #[prost(message, optional, tag = "6")]
1452        pub on_true: ::core::option::Option<super::OracleJob>,
1453        /// / The result to use if the condition evaluates to true. Can be set to a `${CACHE_KEY}`.
1454        #[prost(string, optional, tag = "7")]
1455        pub on_true_value: ::core::option::Option<::prost::alloc::string::String>,
1456        /// / The OracleJob to execute if the condition evaluates to false.
1457        #[prost(message, optional, tag = "8")]
1458        pub on_false: ::core::option::Option<super::OracleJob>,
1459        /// / The result to use if the condition evaluates to false. Can be set to a `${CACHE_KEY}`.
1460        #[prost(string, optional, tag = "9")]
1461        pub on_false_value: ::core::option::Option<::prost::alloc::string::String>,
1462        /// / The OracleJob to execute if the condition fails to evaluate.
1463        #[prost(message, optional, tag = "10")]
1464        pub on_failure: ::core::option::Option<super::OracleJob>,
1465        /// / The result to use if the condition fails to evaluate. Can be set to a `${CACHE_KEY}`.
1466        #[prost(string, optional, tag = "11")]
1467        pub on_failure_value: ::core::option::Option<::prost::alloc::string::String>,
1468        #[prost(oneof = "comparison_task::Lhs", tags = "2, 3")]
1469        pub lhs: ::core::option::Option<comparison_task::Lhs>,
1470        #[prost(oneof = "comparison_task::Rhs", tags = "4, 5")]
1471        pub rhs: ::core::option::Option<comparison_task::Rhs>,
1472    }
1473    /// Nested message and enum types in `ComparisonTask`.
1474    pub mod comparison_task {
1475        #[derive(
1476            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
1477        )]
1478        #[repr(i32)]
1479        pub enum Operation {
1480            /// / Use the equals to '==' operator.
1481            Eq = 0,
1482            /// / Use the greater than '>' operator.
1483            Gt = 1,
1484            /// / Use the less than '<' operator.
1485            Lt = 2,
1486        }
1487        impl Operation {
1488            /// String value of the enum field names used in the ProtoBuf definition.
1489            ///
1490            /// The values are not transformed in any way and thus are considered stable
1491            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1492            pub fn as_str_name(&self) -> &'static str {
1493                match self {
1494                    Operation::Eq => "OPERATION_EQ",
1495                    Operation::Gt => "OPERATION_GT",
1496                    Operation::Lt => "OPERATION_LT",
1497                }
1498            }
1499            /// Creates an enum from field names used in the ProtoBuf definition.
1500            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1501                match value {
1502                    "OPERATION_EQ" => Some(Self::Eq),
1503                    "OPERATION_GT" => Some(Self::Gt),
1504                    "OPERATION_LT" => Some(Self::Lt),
1505                    _ => None,
1506                }
1507            }
1508        }
1509        #[allow(clippy::derive_partial_eq_without_eq)]
1510        #[derive(Clone, PartialEq, ::prost::Oneof)]
1511        pub enum Lhs {
1512            /// / OracleJob where the executed result is equal to the left hand side operand.
1513            #[prost(message, tag = "2")]
1514            Lhs(super::super::OracleJob),
1515            /// / String or `${CACHE_KEY}` representing the left hand side operand.
1516            #[prost(string, tag = "3")]
1517            LhsValue(::prost::alloc::string::String),
1518        }
1519        #[allow(clippy::derive_partial_eq_without_eq)]
1520        #[derive(Clone, PartialEq, ::prost::Oneof)]
1521        pub enum Rhs {
1522            /// / OracleJob where the executed result is equal to the right hand side operand.
1523            #[prost(message, tag = "4")]
1524            Rhs(super::super::OracleJob),
1525            /// / String or `${CACHE_KEY}` representing the right hand side operand.
1526            #[prost(string, tag = "5")]
1527            RhsValue(::prost::alloc::string::String),
1528        }
1529    }
1530    ///
1531    /// Round the current running result to a set number of decimal places.
1532    ///
1533    /// _**Input**_: The current running numerical result.
1534    ///
1535    /// _**Returns**_: The running result rounded to a set number of decimal places.
1536    ///
1537    /// _**Example**_: Round down the running resul to 8 decimal places
1538    ///
1539    /// ```json
1540    /// { "roundTask": { "method": "METHOD_ROUND_DOWN", "decimals": 8 } }
1541    /// ```
1542    #[allow(clippy::derive_partial_eq_without_eq)]
1543    #[derive(Clone, PartialEq, ::prost::Message)]
1544    pub struct RoundTask {
1545        /// / The rounding method to use.
1546        #[prost(enumeration = "round_task::Method", optional, tag = "1")]
1547        pub method: ::core::option::Option<i32>,
1548        /// / The number of decimals to round to.
1549        #[prost(int32, optional, tag = "2")]
1550        pub decimals: ::core::option::Option<i32>,
1551    }
1552    /// Nested message and enum types in `RoundTask`.
1553    pub mod round_task {
1554        #[derive(
1555            Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration,
1556        )]
1557        #[repr(i32)]
1558        pub enum Method {
1559            /// / Round the result down.
1560            RoundUp = 0,
1561            /// / Round the result up.
1562            RoundDown = 1,
1563        }
1564        impl Method {
1565            /// String value of the enum field names used in the ProtoBuf definition.
1566            ///
1567            /// The values are not transformed in any way and thus are considered stable
1568            /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1569            pub fn as_str_name(&self) -> &'static str {
1570                match self {
1571                    Method::RoundUp => "METHOD_ROUND_UP",
1572                    Method::RoundDown => "METHOD_ROUND_DOWN",
1573                }
1574            }
1575            /// Creates an enum from field names used in the ProtoBuf definition.
1576            pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1577                match value {
1578                    "METHOD_ROUND_UP" => Some(Self::RoundUp),
1579                    "METHOD_ROUND_DOWN" => Some(Self::RoundDown),
1580                    _ => None,
1581                }
1582            }
1583        }
1584    }
1585    ///
1586    /// Bound the running result to an upper/lower bound. This is typically the last task in an OracleJob.
1587    ///
1588    /// _**Input**_: The current running numerical result.
1589    ///
1590    /// _**Returns**_: The running result bounded to an upper or lower bound if it exceeds a given threshold.
1591    ///
1592    /// _**Example**_: Bound the running result to a value between 0.90 and 1.10
1593    ///
1594    /// ```json
1595    /// { "boundTask": { "lowerBoundValue": "0.90","onExceedsLowerBoundValue": "0.90","upperBoundValue": "1.10","onExceedsUpperBoundValue": "1.10" } }
1596    /// ```
1597    #[allow(clippy::derive_partial_eq_without_eq)]
1598    #[derive(Clone, PartialEq, ::prost::Message)]
1599    pub struct BoundTask {
1600        /// / The OracleJob to execute for the lower bound value.
1601        #[prost(message, optional, tag = "1")]
1602        pub lower_bound: ::core::option::Option<super::OracleJob>,
1603        /// / The value to use for the lower bound. Can be set to a `${CACHE_KEY}`.
1604        #[prost(string, optional, tag = "2")]
1605        pub lower_bound_value: ::core::option::Option<::prost::alloc::string::String>,
1606        /// / The OracleJob to execute for the upper bound value.
1607        #[prost(message, optional, tag = "3")]
1608        pub upper_bound: ::core::option::Option<super::OracleJob>,
1609        /// / The value to use for the upper bound. Can be set to a `${CACHE_KEY}`.
1610        #[prost(string, optional, tag = "4")]
1611        pub upper_bound_value: ::core::option::Option<::prost::alloc::string::String>,
1612        /// / The OracleJob to execute if the upper bound is exceeded.
1613        #[prost(message, optional, tag = "5")]
1614        pub on_exceeds_upper_bound: ::core::option::Option<super::OracleJob>,
1615        /// / The value to use if the upper bound is exceeded. Can be set to a `${CACHE_KEY}`.
1616        #[prost(string, optional, tag = "6")]
1617        pub on_exceeds_upper_bound_value: ::core::option::Option<::prost::alloc::string::String>,
1618        /// / The OracleJob to execute if the lower bound is exceeded.
1619        #[prost(message, optional, tag = "7")]
1620        pub on_exceeds_lower_bound: ::core::option::Option<super::OracleJob>,
1621        /// / The value to use if the lower bound is exceeded. Can be set to a `${CACHE_KEY}`.
1622        #[prost(string, optional, tag = "8")]
1623        pub on_exceeds_lower_bound_value: ::core::option::Option<::prost::alloc::string::String>,
1624    }
1625    ///
1626    /// Represents a singular operation performed by an oracle to yield an eventual numerical result.
1627    #[allow(clippy::derive_partial_eq_without_eq)]
1628    #[derive(Clone, PartialEq, ::prost::Message)]
1629    pub struct Task {
1630        #[prost(
1631            oneof = "task::Task",
1632            tags = "1, 2, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46"
1633        )]
1634        pub task: ::core::option::Option<task::Task>,
1635    }
1636    /// Nested message and enum types in `Task`.
1637    pub mod task {
1638        #[allow(clippy::derive_partial_eq_without_eq)]
1639        #[derive(Clone, PartialEq, ::prost::Oneof)]
1640        pub enum Task {
1641            ///
1642            /// The adapter will report the text body of a successful HTTP request to the
1643            /// specified url, or return an error if the response status code is greater
1644            /// than or equal to 400.
1645            ///
1646            /// _**Input**_: None
1647            ///
1648            /// _**Returns**_: String representation of the http response.
1649            ///
1650            /// _**Example**_: Basic HttpTask
1651            ///
1652            /// ```json
1653            /// {"httpTask": {"url": "<https://mywebsite.org/path"}> }
1654            /// ```
1655            ///
1656            /// _**Example**_: HttpTask example with headers
1657            ///
1658            /// ```json
1659            /// { "httpTask": { "url": "<https://mywebsite.org/path",> "method": "METHOD_POST", "headers": [ { "key": "MY_HEADER_KEY", "value": "MY_HEADER_VALUE" } ], "body": "{\"MY_BODY_KEY\":\"MY_BODY_VALUE\"}" } }
1660            /// ```
1661            #[prost(message, tag = "1")]
1662            HttpTask(super::HttpTask),
1663            ///
1664            /// The adapter walks the path specified and returns the value found at that result. If returning
1665            /// JSON data from the HttpGet or HttpPost adapters, you must use this adapter to parse the response.
1666            ///
1667            /// _**Input**_: String representation of a JSON object.
1668            ///
1669            /// _**Returns**_: A numerical result.
1670            ///
1671            /// _**Example**_: Parses the price field from a JSON object
1672            ///
1673            /// ```json
1674            /// {"jsonParse": {"path": "$.price"} }
1675            /// ```
1676            #[prost(message, tag = "2")]
1677            JsonParseTask(super::JsonParseTask),
1678            ///
1679            /// Returns the median (middle) of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
1680            ///
1681            /// _**Input**_: None
1682            ///
1683            /// _**Returns**_: A numerical result.
1684            ///
1685            /// _**Example**_: Returns the median numerical result of 3 tasks.
1686            ///
1687            /// ```json
1688            /// {"medianTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
1689            /// ```
1690            ///
1691            /// _**Example**_: Returns the median numerical result of 3 jobs.
1692            ///
1693            /// ```json
1694            /// {"medianTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
1695            /// ```
1696            #[prost(message, tag = "4")]
1697            MedianTask(super::MedianTask),
1698            ///
1699            /// Returns the mean (average) of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
1700            ///
1701            /// _**Input**_: None
1702            ///
1703            /// _**Returns**_: A numerical result.
1704            ///
1705            /// _**Example**_: Returns the mean numerical result of 3 tasks.
1706            ///
1707            /// ```json
1708            /// {"meanTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
1709            /// ```
1710            ///
1711            /// _**Example**_: Returns the mean numerical result of 3 jobs.
1712            ///
1713            /// ```json
1714            /// {"meanTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
1715            /// ```
1716            #[prost(message, tag = "5")]
1717            MeanTask(super::MeanTask),
1718            ///
1719            /// Opens and maintains a websocket for light speed data retrieval.
1720            ///
1721            /// _**Input**_: None
1722            ///
1723            /// _**Returns**_: String representation of the websocket subscription message.
1724            ///
1725            /// _**Example**_: Opens a coinbase websocket
1726            ///
1727            /// ```json
1728            /// { "websocketTask": { "url": "wss://ws-feed.pro.coinbase.com", "subscription": "{\"type\":\"subscribe\",\"product_ids\":\[\"BTC-USD\"],\"channels\":[\"ticker\",{\"name\":\"ticker\",\"product_ids\":[\"BTC-USD\"]}\]}", "maxDataAgeSeconds": 15, "filter": "$[?(@.type == 'ticker' && @.product_id == 'BTC-USD')]" } }
1729            /// ```
1730            #[prost(message, tag = "6")]
1731            WebsocketTask(super::WebsocketTask),
1732            ///
1733            /// This task will divide a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
1734            ///
1735            /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
1736            ///
1737            /// _**Returns**_: A numerical result.
1738            ///
1739            /// _**Example**_: Returns the numerical result by dividing by a job of subtasks.
1740            ///
1741            /// ```json
1742            /// {"tasks":\[{"valueTask":{"value":100}},{"divideTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
1743            /// ```
1744            ///
1745            /// _**Example**_: Returns the numerical result by dividing by an aggregator.
1746            ///
1747            /// ```json
1748            /// {"tasks":\[{"valueTask":{"value":100}},{"divideTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
1749            /// ```
1750            ///
1751            /// _**Example**_: Returns the numerical result by dividing by a big.
1752            ///
1753            /// ```json
1754            /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"divideTask":{"big":"${TEN}"}}\]}
1755            /// ```
1756            #[prost(message, tag = "7")]
1757            DivideTask(super::DivideTask),
1758            ///
1759            /// This task will multiply a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
1760            ///
1761            /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
1762            ///
1763            /// _**Returns**_: A numerical result.
1764            ///
1765            /// _**Example**_: Returns the numerical result by multiplying by a job of subtasks.
1766            ///
1767            /// ```json
1768            /// {"tasks":\[{"valueTask":{"value":100}},{"multiplyTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
1769            /// ```
1770            ///
1771            /// _**Example**_: Returns the numerical result by multiplying by an aggregator.
1772            ///
1773            /// ```json
1774            /// {"tasks":\[{"valueTask":{"value":100}},{"multiplyTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
1775            /// ```
1776            ///
1777            /// _**Example**_: Returns the numerical result by multiplying by a big.
1778            ///
1779            /// ```json
1780            /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"multiplyTask":{"big":"${TEN}"}}\]}
1781            /// ```
1782            #[prost(message, tag = "8")]
1783            MultiplyTask(super::MultiplyTask),
1784            ///
1785            /// Fetch LP token price info from a number of supported exchanges.
1786            ///
1787            /// See our blog post on [Fair LP Token Oracles](/blog/2022/01/20/Fair-LP-Token-Oracles)
1788            ///
1789            /// *NOTE**: This is not the swap price but the price of the underlying LP token.
1790            ///
1791            /// _**Input**_: None
1792            ///
1793            /// _**Returns**_: The price of an LP token for a given AMM pool.
1794            ///
1795            /// _**Example**_: Fetch the Orca LP token price of the SOL/USDC pool
1796            ///
1797            /// ```json
1798            /// { "lpTokenPriceTask": { "orcaPoolAddress": "APDFRM3HMr8CAGXwKHiu2f5ePSpaiEJhaURwhsRrUUt9" } }
1799            /// ```
1800            ///
1801            /// _**Example**_: Fetch the fair price Orca LP token price of the SOL/USDC pool
1802            ///
1803            /// ```json
1804            /// { "lpTokenPriceTask": { "orcaPoolAddress": "APDFRM3HMr8CAGXwKHiu2f5ePSpaiEJhaURwhsRrUUt9", "useFairPrice": true, "priceFeedAddresses": [ "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR", "BjUgj6YCnFBZ49wF54ddBVA9qu8TeqkFtkbqmZcee8uW" ] } }
1805            /// ```
1806            ///
1807            /// _**Example**_: Fetch the fair price Raydium LP token price of the SOL/USDC pool
1808            ///
1809            /// ```json
1810            /// { "lpTokenPriceTask": { "raydiumPoolAddress": "58oQChx4yWmvKdwLLZzBi4ChoCc2fqCUWBkwMihLYQo2", "useFairPrice": true,"priceFeedAddresses": ["GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR","BjUgj6YCnFBZ49wF54ddBVA9qu8TeqkFtkbqmZcee8uW" ] } }
1811            /// ```
1812            #[prost(message, tag = "9")]
1813            LpTokenPriceTask(super::LpTokenPriceTask),
1814            ///
1815            /// Fetch the current swap price for a given liquidity pool
1816            ///
1817            /// _**Input**_: None
1818            ///
1819            /// _**Returns**_: The swap price for a given AMM pool.
1820            ///
1821            /// _**Example**_: Fetch the exchange rate from the Orca SOL/USDC pool
1822            ///
1823            /// ```json
1824            /// { "lpExchangeRateTask": { "orcaPoolAddress": "APDFRM3HMr8CAGXwKHiu2f5ePSpaiEJhaURwhsRrUUt9" } }
1825            /// ```
1826            ///
1827            /// _**Example**_: Fetch the exchange rate from the Raydium SOL/USDC pool
1828            ///
1829            /// ```json
1830            /// { "lpExchangeRateTask": { "raydiumPoolAddress": "58oQChx4yWmvKdwLLZzBi4ChoCc2fqCUWBkwMihLYQo2" } }
1831            /// ```
1832            #[prost(message, tag = "10")]
1833            LpExchangeRateTask(super::LpExchangeRateTask),
1834            ///
1835            /// This task will run the `attempt` on the subtasks in an effort to produce a valid numerical result. If `attempt`. fails to produce an acceptable result, `on_failure` subtasks will be run instead.
1836            ///
1837            /// _**Input**_: The current running numerical result output from a task.
1838            ///
1839            /// _**Returns**_: A numerical result, else run `on_failure` subtasks.
1840            ///
1841            /// _**Example**_: Returns the numerical result from the conditionalTask's subtasks, else `on_failure` returns the numerical result from its subtasks.
1842            ///
1843            /// ```json
1844            /// {"conditionalTask":{"attempt":\[{"tasks":[{"jupiterSwapTask":{"inTokenAddress":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","outTokenAddress":"DUALa4FC2yREwZ59PHeu1un4wis36vHRv5hWVBmzykCJ"}}]}],"onFailure":[{"lpExchangeRateTask":{"orcaPoolAddress":"7yJ4gMRJhEoCR48aPE3EAWRmCoygakik81ZS1sajaTnE"}}\]}}
1845            /// ```
1846            #[prost(message, tag = "11")]
1847            ConditionalTask(super::ConditionalTask),
1848            ///
1849            /// Returns a specified value.
1850            ///
1851            /// _**Input**_: None
1852            ///
1853            /// _**Returns**_: A numerical result.
1854            ///
1855            /// _**Example**_: Returns the value 10
1856            ///
1857            /// ```json
1858            /// {"valueTask": {"value": 10} }
1859            /// ```
1860            ///
1861            /// _**Example**_: Returns the currentRound result of an aggregator
1862            ///
1863            /// ```json
1864            /// {"valueTask": {"aggregatorPubkey": "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"} }
1865            /// ```
1866            ///
1867            /// _**Example**_: Returns the value stored in a CacheTask variable
1868            ///
1869            /// ```json
1870            /// {"valueTask": {"big": "${ONE}"} }
1871            /// ```
1872            #[prost(message, tag = "12")]
1873            ValueTask(super::ValueTask),
1874            ///
1875            /// Returns the maximum value of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
1876            ///
1877            /// _**Input**_: None
1878            ///
1879            /// _**Returns**_: A numerical result.
1880            ///
1881            /// _**Example**_: Returns the maximum numerical result from 3 tasks.
1882            ///
1883            /// ```json
1884            /// {"maxTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
1885            /// ```
1886            ///
1887            /// _**Example**_: Returns the minimum numerical result from 3 jobs.
1888            ///
1889            /// ```json
1890            /// {"maxTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
1891            /// ```
1892            #[prost(message, tag = "13")]
1893            MaxTask(super::MaxTask),
1894            #[prost(message, tag = "14")]
1895            RegexExtractTask(super::RegexExtractTask),
1896            #[prost(message, tag = "15")]
1897            XstepPriceTask(super::XStepPriceTask),
1898            ///
1899            /// This task will add a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
1900            ///
1901            /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
1902            ///
1903            /// _**Returns**_: A numerical result.
1904            ///
1905            /// _**Example**_: Returns the numerical result by adding by a job of subtasks.
1906            ///
1907            /// ```json
1908            /// {"tasks":\[{"valueTask":{"value":100}},{"addTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
1909            /// ```
1910            ///
1911            /// _**Example**_: Returns the numerical result by multiplying by an aggregator.
1912            ///
1913            /// ```json
1914            /// {"tasks":\[{"valueTask":{"value":100}},{"addTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
1915            /// ```
1916            ///
1917            /// _**Example**_: Returns the numerical result by multiplying by a big.
1918            ///
1919            /// ```json
1920            /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"addTask":{"big":"${TEN}"}}\]}
1921            /// ```
1922            #[prost(message, tag = "16")]
1923            AddTask(super::AddTask),
1924            ///
1925            /// This task will subtract a numerical input by a scalar value from a job of subtasks, an aggregator, or a big.
1926            ///
1927            /// _**Input**_: The current running numerical result output from a scalar value, an aggregator, a job of subtasks or a big.
1928            ///
1929            /// _**Returns**_: A numerical result.
1930            ///
1931            /// _**Example**_: Returns the numerical result by subtracting by a job of subtasks.
1932            ///
1933            /// ```json
1934            /// {"tasks":\[{"valueTask":{"value":100}},{"subtractTask":{"job":{"tasks":[{"valueTask":{"value":10}}]}}}\]}
1935            /// ```
1936            ///
1937            /// _**Example**_: Returns the numerical result by multiplying by an aggregator.
1938            ///
1939            /// ```json
1940            /// {"tasks":\[{"valueTask":{"value":100}},{"subtractTask":{"aggregatorPubkey":"GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR"}}\]}
1941            /// ```
1942            ///
1943            /// _**Example**_: Returns the numerical result by multiplying by a big.
1944            ///
1945            /// ```json
1946            /// {"tasks":\[{"cacheTask":{"cacheItems":[{"variableName":"TEN","job":{"tasks":[{"valueTask":{"value":10}}]}}]}},{"valueTask":{"value":100}},{"subtractTask":{"big":"${TEN}"}}\]}
1947            /// ```
1948            #[prost(message, tag = "17")]
1949            SubtractTask(super::SubtractTask),
1950            ///
1951            /// Takes a twap over a set period for a certain aggregator. Aggregators have an optional history buffer account storing the last N accepted results. The TwapTask will iterate over an aggregators history buffer and calculate the time weighted average of the samples within a given time period.
1952            ///
1953            /// _**Input**_: None
1954            ///
1955            /// _**Returns**_: The time weighted average of an aggregator over a given time period.
1956            ///
1957            /// _**Example**_: The 1hr Twap of the SOL/USD Aggregator, requiring at least 60 samples.
1958            ///
1959            /// ```json
1960            /// { "twapTask": { "aggregatorPubkey": "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR", "period": 3600, "minSamples": 60, "weightByPropagationTime": true  } }
1961            /// ```
1962            #[prost(message, tag = "18")]
1963            TwapTask(super::TwapTask),
1964            #[prost(message, tag = "19")]
1965            SerumSwapTask(super::SerumSwapTask),
1966            ///
1967            /// Round the current running result to an exponential power.
1968            ///
1969            /// _**Input**_: The current running numerical result.
1970            ///
1971            /// _**Returns**_: The input raised to an exponential power.
1972            ///
1973            /// _**Example**_: Raise 2 to the power of 3, 2^3
1974            ///
1975            /// ```json
1976            /// {"tasks":\[{"valueTask":{"value":2}},{"powTask":{"scalar":3}}\]}
1977            /// ```
1978            #[prost(message, tag = "20")]
1979            PowTask(super::PowTask),
1980            #[prost(message, tag = "21")]
1981            LendingRateTask(super::LendingRateTask),
1982            #[prost(message, tag = "22")]
1983            MangoPerpMarketTask(super::MangoPerpMarketTask),
1984            ///
1985            /// Fetch the simulated price for a swap on JupiterSwap.
1986            ///
1987            /// _**Input**_: None
1988            ///
1989            /// _**Returns**_: The swap price on Jupiter for a given input and output token mint address.
1990            ///
1991            /// _**Example**_: Fetch the JupiterSwap price for exchanging 1 SOL into USDC.
1992            ///
1993            /// ```json
1994            /// { "jupiterSwapTask": { "inTokenAddress": "So11111111111111111111111111111111111111112", "outTokenAddress": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v" } }
1995            /// ```
1996            ///
1997            /// _**Example**_: Fetch the JupiterSwap price for exchanging 1000 SOL into USDC.
1998            ///
1999            /// ```json
2000            /// { "jupiterSwapTask": { "inTokenAddress": "So11111111111111111111111111111111111111112", "outTokenAddress": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", "baseAmount": "1000" } }
2001            /// ```
2002            #[prost(message, tag = "23")]
2003            JupiterSwapTask(super::JupiterSwapTask),
2004            #[prost(message, tag = "24")]
2005            PerpMarketTask(super::PerpMarketTask),
2006            ///
2007            /// Fetch the current price of a Solana oracle protocol.
2008            ///
2009            /// _**Input**_: None
2010            ///
2011            /// _**Returns**_: The current price of an on-chain oracle.
2012            ///
2013            /// _**Example**_: The Switchboard SOL/USD oracle price.
2014            ///
2015            /// ```json
2016            /// { "oracleTask": { "switchboardAddress": "GvDMxPzN1sCj7L26YDK2HnMRXEQmQ2aemov8YBtPS7vR" } }
2017            /// ```
2018            ///
2019            /// _**Example**_: The Pyth SOL/USD oracle price.
2020            ///
2021            /// ```json
2022            /// { "oracleTask": { "pythAddress": "H6ARHf6YXhGYeQfUzQNGk6rDNnLBQKrenN712K4AQJEG" } }
2023            /// ```
2024            ///
2025            /// _**Example**_: The Chainlink SOL/USD oracle price.
2026            ///
2027            /// ```json
2028            /// { "oracleTask": { "chainlinkAddress": "CcPVS9bqyXbD9cLnTbhhHazLsrua8QMFUHTutPtjyDzq" } }
2029            /// ```
2030            #[prost(message, tag = "25")]
2031            OracleTask(super::OracleTask),
2032            #[prost(message, tag = "26")]
2033            AnchorFetchTask(super::AnchorFetchTask),
2034            #[prost(message, tag = "27")]
2035            DefiKingdomsTask(super::DefiKingdomsTask),
2036            #[prost(message, tag = "28")]
2037            TpsTask(super::TpsTask),
2038            #[prost(message, tag = "29")]
2039            SplStakePoolTask(super::SplStakePoolTask),
2040            #[prost(message, tag = "30")]
2041            SplTokenParseTask(super::SplTokenParseTask),
2042            #[prost(message, tag = "31")]
2043            UniswapExchangeRateTask(super::UniswapExchangeRateTask),
2044            #[prost(message, tag = "32")]
2045            SushiswapExchangeRateTask(super::SushiswapExchangeRateTask),
2046            #[prost(message, tag = "33")]
2047            PancakeswapExchangeRateTask(super::PancakeswapExchangeRateTask),
2048            ///
2049            /// Execute a job and store the result in a variable to reference later.
2050            ///
2051            /// _**Input**_: None
2052            ///
2053            /// _**Returns**_: The input
2054            ///
2055            /// _**Example**_: CacheTask storing ${ONE} = 1
2056            ///
2057            /// ```json
2058            /// { "cacheTask": { "cacheItems": [ { "variableName": "ONE", "job": { "tasks": [ { "valueTask": { "value": 1 } } ] } } ] } }
2059            /// ```
2060            #[prost(message, tag = "34")]
2061            CacheTask(super::CacheTask),
2062            #[prost(message, tag = "35")]
2063            SysclockOffsetTask(super::SysclockOffsetTask),
2064            #[prost(message, tag = "36")]
2065            MarinadeStateTask(super::MarinadeStateTask),
2066            #[prost(message, tag = "37")]
2067            SolanaAccountDataFetchTask(super::SolanaAccountDataFetchTask),
2068            #[prost(message, tag = "38")]
2069            BufferLayoutParseTask(super::BufferLayoutParseTask),
2070            ///
2071            /// Return a timestamp from a crontab instruction.
2072            ///
2073            /// _**Input**_: None
2074            ///
2075            /// _**Returns**_: A timestamp
2076            ///
2077            /// _**Example**_: Return the unix timestamp for the on-chain SYSCLOCK
2078            ///
2079            /// ```json
2080            /// {"cronParseTask":{"cronPattern":"* * * * * *","clockOffset":0,"clock":"SYSCLOCK"}}
2081            /// ```
2082            ///
2083            /// _**Example**_: Return the unix timestamp for next friday at 5pm UTC
2084            ///
2085            /// ```json
2086            /// {"cronParseTask":{"cronPattern":"0 17 * * 5","clockOffset":0,"clock":0}}
2087            /// ```
2088            #[prost(message, tag = "39")]
2089            CronParseTask(super::CronParseTask),
2090            ///
2091            /// Returns the minimum value of all the results returned by the provided subtasks and subjobs. Nested tasks or jobs must return a Number.
2092            ///
2093            /// _**Input**_: None
2094            ///
2095            /// _**Returns**_: A numerical result.
2096            ///
2097            /// _**Example**_: Returns the minimum numerical result from 3 tasks.
2098            ///
2099            /// ```json
2100            /// {"minTask": {"tasks": [{"valueTask": {"value": 10}},{"valueTask": {"value": 20}},{"valueTask": {"value": 30}}]}}
2101            /// ```
2102            ///
2103            /// _**Example**_: Returns the minimum numerical result from 3 jobs.
2104            ///
2105            /// ```json
2106            /// {"minTask": {"jobs": [{"tasks": [{"httpTask": {"url": "<https://www.binance.com/api/v3/ticker/price?symbol=SOLUSDT"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://www.binance.us/api/v3/ticker/price?symbol=SOLUSD"}},{"jsonParseTask":> {"path": "$.price"}}]},{"tasks": [{"httpTask": {"url": "<https://api-pub.bitfinex.com/v2/tickers?symbols=tSOLUSD"}},{"jsonParseTask":> {"path": "$\[0][7]"}}]}\]}}
2107            /// ```
2108            #[prost(message, tag = "40")]
2109            MinTask(super::MinTask),
2110            #[prost(message, tag = "41")]
2111            HistoryFunctionTask(super::HistoryFunctionTask),
2112            #[prost(message, tag = "42")]
2113            VwapTask(super::VwapTask),
2114            #[prost(message, tag = "43")]
2115            EwmaTask(super::EwmaTask),
2116            #[prost(message, tag = "44")]
2117            ComparisonTask(super::ComparisonTask),
2118            ///
2119            /// Round the current running result to a set number of decimal places.
2120            ///
2121            /// _**Input**_: The current running numerical result.
2122            ///
2123            /// _**Returns**_: The running result rounded to a set number of decimal places.
2124            ///
2125            /// _**Example**_: Round down the running resul to 8 decimal places
2126            ///
2127            /// ```json
2128            /// { "roundTask": { "method": "METHOD_ROUND_DOWN", "decimals": 8 } }
2129            /// ```
2130            #[prost(message, tag = "45")]
2131            RoundTask(super::RoundTask),
2132            ///
2133            /// Bound the running result to an upper/lower bound. This is typically the last task in an OracleJob.
2134            ///
2135            /// _**Input**_: The current running numerical result.
2136            ///
2137            /// _**Returns**_: The running result bounded to an upper or lower bound if it exceeds a given threshold.
2138            ///
2139            /// _**Example**_: Bound the running result to a value between 0.90 and 1.10
2140            ///
2141            /// ```json
2142            /// { "boundTask": { "lowerBoundValue": "0.90","onExceedsLowerBoundValue": "0.90","upperBoundValue": "1.10","onExceedsUpperBoundValue": "1.10" } }
2143            /// ```
2144            #[prost(message, tag = "46")]
2145            BoundTask(super::BoundTask),
2146        }
2147    }
2148}
2149// @@protoc_insertion_point(module)