Message: RuleDefinition

File: WebAPI/rules_1.proto

Description

Rule definition contains one of the specific rules. Only one specific rule can be specified. The complete definition is expected regardless if this is a new rule or an update of existing one.

Note: Overall serialized RuleDefinition message size is limited (100KB by default).

Used in

RuleListResult, SetRuleRequest

Fields

rule_id

Type: string

Description: Client ID of the rule. It must be unique for this client.

rule_tags

Type: string

Description: List of optional client rule tags. The number of tags is limited. If the limit is exceeded, the maximum allowed number of tags is provided in the error message. See RuleEventSubscription.rule_tags and RuleEventHistoryRequest.rule_tags fields

actions

Type: Action

Description: List of actions for rule execution.

order_event_rule

Type: OrderEventRule

Description: Order event rule definition.

condition_rule

Type: ConditionRule

Description: Condition rule definition.

enabled

Type: bool

Default: true

Description: True means the rule is in execution. To enable or disable the rule the client updates the rule with a corresponding values of this flag.

attributes

Type: shared_1.NamedValue

Description: List of custom rule attributes defined by client. Note that full list of attributes has to be specified on rule’s modification.

deleted

Type: bool

Description: If set to true the rule with given rule_id has been deleted.

expiration_time

Type: google.protobuf.Timestamp

Description: Rule expiration time. The rule is disabled on expiration. This is an optional field for condition rules with MarketVariable or StudySymbol. If this field is omitted, it is set to “now + 1 year”. Other rules don’t support this field.