BTC Alert Template Switch
This component allows you to read in data from the previous component and perform actions based on a set of conditions.
- Property: This is the incoming property you will use for the comparison. In the case of this template, we are getting the USD price of BTC from CoinCap's Get Asset Details, and we reference it by entering "data.priceUsd".
- Conditions: This is a complex field that allows you to choose one or more condition(s) to perform next actions on. Each condition creates a new output element on the component. The first output element will fire when the first condition is met, the second output element will fire when the second condition is met, etc. Conditions can overlap if you choose.
Options for Conditions
- Basic operators: Typical logical operators include >, <, >=, <=, == (equal to), !== (not equal to)
- String only operators: Starts with, ends with, and regex. When given a string, match on the beginning or end of a string, or match based on a given regex. Read more about Regex here.
- Index Of: Returns the position in the incoming data (array or string, for example) of the first occurrence of the given value
- Data Type
- Options: Number, String Boolean
- Enter the value to match in the condition.