rules

Protocol buffer definition for rules

sift/rules/v1/rules.proto

AnnotationActionConfiguration

FieldTypeLabelDescription
tag_idsstringrepeated
annotation_typesift.annotations.v1.AnnotationType
assigned_to_user_idstringoptional

BatchGetRuleVersionsRequest

FieldTypeLabelDescription
rule_version_idsstringrepeated

BatchGetRuleVersionsResponse

FieldTypeLabelDescription
rulesRulerepeated

BatchGetRulesRequest

BatchGetRulesRequest is used to retrieve rules by rule_ids or client_keys. If both are provided, both will be used to retrieve rules.

FieldTypeLabelDescription
rule_idsstringrepeated
client_keysstringrepeated

BatchGetRulesResponse

FieldTypeLabelDescription
rulesRulerepeated

BatchUpdateRulesRequest

FieldTypeLabelDescription
rulesUpdateRuleRequestrepeatedrules are limited 1000 rules at a time

BatchUpdateRulesResponse

FieldTypeLabelDescription
successbool
rules_created_countint32
rules_updated_countint32

CalculatedChannelConfig

FieldTypeLabelDescription
channel_referencesCalculatedChannelConfig.ChannelReferencesEntryrepeated
expressionstring

CalculatedChannelConfig.ChannelReferencesEntry

FieldTypeLabelDescription
keystring
valueChannelReference

ChannelReference

FieldTypeLabelDescription
namestring
componentstring

ContextualChannels

FieldTypeLabelDescription
channelsChannelReferencerepeated

CreateRuleRequest

FieldTypeLabelDescription
updateUpdateRuleRequest

CreateRuleResponse

FieldTypeLabelDescription
rule_idstring

DeleteRuleRequest

DeleteRuleRequest is used to delete a rule by rule_id or client_key. If both are provided, only rule_id will be used.

FieldTypeLabelDescription
rule_idstring
client_keystring

DeleteRuleResponse

DryRunAnnotation

FieldTypeLabelDescription
condition_idstring
namestring
start_timegoogle.protobuf.Timestamp
end_timegoogle.protobuf.Timestamp
condition_version_idstring

EvaluateRulesRequest

Deprecated - use RuleEvaluationService instead.

FieldTypeLabelDescription
rule_idsstringrepeated
annotation_optionsEvaluatedAnnotationOptions
run_idstring
time_rangeTimeRangeQuery
dry_runbool

EvaluateRulesResponse

Deprecated - use RuleEvaluationService instead.

FieldTypeLabelDescription
created_annotation_countint32
dry_run_annotationsDryRunAnnotationrepeatedIf dry_run is true, this will be populated with the annotations that would be created
job_idstringoptionaljob_id and report_id will be set if the job has an extended run time and is being processed asynchronously.
report_idstringoptional

EvaluatedAnnotationOptions

FieldTypeLabelDescription
tag_idsstringrepeated

GetRuleRequest

GetRuleRequest is used to retrieve a rule by rule_id or client_key. If both are provided, only rule_id will be used.

FieldTypeLabelDescription
rule_idstring
client_keystring

GetRuleResponse

FieldTypeLabelDescription
ruleRule

GetRuleVersionRequest

FieldTypeLabelDescription
rule_version_idstring

GetRuleVersionResponse

FieldTypeLabelDescription
ruleRule

JsonRulesRequest

FieldTypeLabelDescription
asset_idstring
rules_jsonstring
organization_idstring

JsonRulesResponse

FieldTypeLabelDescription
successbool
total_rules_countint32
rules_created_countint32
rules_updated_countint32
rules_deleted_countint32
error_messagesstringoptional

LastValueThreshold

ListRuleVersionsRequest

FieldTypeLabelDescription
rule_idstring
page_sizeuint32The maximum number of Rule Versions to return. The service may return fewer than this value. If unspecified, at most 50 Rule Versions will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.
page_tokenstringA page token, received from a previous ListRuleVersions call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to ListRuleVersions must match the call that provided the page token.
filterstringA Common Expression Language (CEL) filter string. Available fields to filter by are rule_version_id, user_notes, and change_message. For further information about how to use CELs, please refer to this guide. Optional.

ListRuleVersionsResponse

FieldTypeLabelDescription
rule_versionsRuleVersionrepeated
next_page_tokenstring

NotificationActionConfiguration

FieldTypeLabelDescription
recipient_user_idsstringrepeated

Rule

FieldTypeLabelDescription
rule_idstring
asset_idstringDeprecated.
namestring
descriptionstring
is_enabledbool
created_dategoogle.protobuf.Timestamp
modified_dategoogle.protobuf.Timestamp
created_by_user_idstring
modified_by_user_idstring
organization_idstring
conditionsRuleConditionrepeated
rule_versionRuleVersion
client_keystringclient_key is a client provided identifier for the rule. It is immutable after rule creation.
asset_configurationRuleAssetConfiguration
contextual_channelsContextualChannels

RuleAction

FieldTypeLabelDescription
rule_action_idstring
rule_condition_idstring
action_typeActionKind
configurationRuleActionConfiguration
created_dategoogle.protobuf.Timestamp
modified_dategoogle.protobuf.Timestamp
created_by_user_idstring
modified_by_user_idstring
rule_action_version_idstring

RuleActionConfiguration

FieldTypeLabelDescription
notificationNotificationActionConfiguration
annotationAnnotationActionConfiguration

RuleAssetConfiguration

FieldTypeLabelDescription
asset_idsstringrepeated
tag_idsstringrepeated

RuleCondition

FieldTypeLabelDescription
rule_condition_idstring
rule_idstring
expressionRuleConditionExpression
created_dategoogle.protobuf.Timestamp
modified_dategoogle.protobuf.Timestamp
created_by_user_idstring
modified_by_user_idstring
actionsRuleActionrepeated
rule_condition_version_idstring

RuleConditionExpression

FieldTypeLabelDescription
single_channel_comparisonSingleChannelComparisonExpressionDeprecated.
calculated_channelCalculatedChannelConfig

RuleVersion

FieldTypeLabelDescription
rule_idstring
rule_version_idstring
versionstring
created_dategoogle.protobuf.Timestamp
created_by_user_idstring
version_notesstring
generated_change_messagestring

SearchRulesRequest

FieldTypeLabelDescription
limituint32optionalMax number of rules to return (returns all if omitted).
offsetuint32Only applies if limit provided.
orderSearchOrderoptionalOrder to sort results by (defaults to ascending).
name_matchesstring
case_sensitivebool
regexpbool
order_bystringoptional
rule_idsstringrepeatedIf provided, only returns rules with the given ids
asset_idsstringrepeatedIf provided, only returns rules with the given asset ids

SearchRulesResponse

FieldTypeLabelDescription
countuint32
rulesRulerepeatedConditions are not included in the search response. The latest version of the rule is returned.

SingleChannelComparisonExpression

Deprecated - use CalculatedChannelConfig.

FieldTypeLabelDescription
channel_componentstring
channel_namestring
comparatorConditionComparator
doubledouble
stringstring
last_valueLastValueThreshold

TimeRangeQuery

FieldTypeLabelDescription
start_timegoogle.protobuf.Timestamp
end_timegoogle.protobuf.Timestamp

UpdateActionRequest

FieldTypeLabelDescription
rule_action_idstringoptional
action_typeActionKind
configurationRuleActionConfiguration

UpdateConditionRequest

FieldTypeLabelDescription
rule_condition_idstringoptional
expressionRuleConditionExpression
actionsUpdateActionRequestrepeated

UpdateHumanFriendlyRulesRequest

Deprecated - use UpdateJsonRulesRequest.

FieldTypeLabelDescription
asset_idstring
rules_jsonstring
organization_idstring

UpdateHumanFriendlyRulesResponse

Deprecated - use UpdateJsonRulesResponse.

FieldTypeLabelDescription
successbool
rules_countint32
messagesstring

UpdateJsonRulesRequest

FieldTypeLabelDescription
requestJsonRulesRequest

UpdateJsonRulesResponse

FieldTypeLabelDescription
responseJsonRulesResponse

UpdateRuleRequest

UpdateRuleRequest is used to create or update a rule. If the rule_id or client_key is provided, the rule will be updated. If not, a new rule will be created.

FieldTypeLabelDescription
rule_idstringoptional
namestring
descriptionstring
asset_idstringDeprecated. Deprecated - use asset_configuration instead.
is_enabledbool
conditionsUpdateConditionRequestrepeated
organization_idstring
version_notesstring
client_keystringoptional
asset_configurationRuleAssetConfiguration
contextual_channelsContextualChannels

UpdateRuleResponse

FieldTypeLabelDescription
rule_idstring

ValidateJsonRulesRequest

FieldTypeLabelDescription
requestJsonRulesRequest

ValidateJsonRulesResponse

FieldTypeLabelDescription
responseJsonRulesResponse

ViewHumanFriendlyRulesRequest

Deprecated - use ViewJsonRulesRequest.

FieldTypeLabelDescription
asset_idstring

ViewHumanFriendlyRulesResponse

Deprecated - use ViewJsonRulesResponse.

FieldTypeLabelDescription
rules_jsonstring

ViewJsonRulesRequest

FieldTypeLabelDescription
asset_idstring

ViewJsonRulesResponse

FieldTypeLabelDescription
rules_jsonstring

ActionKind

NameNumberDescription
ACTION_KIND_UNSPECIFIED0
NOTIFICATION1
ANNOTATION2

ConditionComparator

NameNumberDescription
CONDITION_COMPARATOR_UNSPECIFIED0
LESS_THAN1
LESS_THAN_OR_EQUAL2
GREATER_THAN3
GREATER_THAN_OR_EQUAL4
EQUAL5
NOT_EQUAL6

SearchOrder

NameNumberDescription
SEARCH_ORDER_UNSPECIFIED0
SEARCH_ORDER_ASC1
SEARCH_ORDER_DESC2

RuleService

Method NameRequest TypeResponse TypeDescription
SearchRulesSearchRulesRequestSearchRulesResponseQueries rules based on provided search parameters.
GetRuleGetRuleRequestGetRuleResponseRetrieves the latest version of a rule.
BatchGetRulesBatchGetRulesRequestBatchGetRulesResponseRetrieve multiple rules.
CreateRuleCreateRuleRequestCreateRuleResponseCreates a rule.
UpdateRuleUpdateRuleRequestUpdateRuleResponseUpdates an existing rule.
BatchUpdateRulesBatchUpdateRulesRequestBatchUpdateRulesResponseUpdates existing rules or creates rules that do not exist.
DeleteRuleDeleteRuleRequestDeleteRuleResponseDeletes a rule
EvaluateRulesEvaluateRulesRequestEvaluateRulesResponseDeprecated - use RuleEvaluationService instead.
ViewHumanFriendlyRulesViewHumanFriendlyRulesRequestViewHumanFriendlyRulesResponseDeprecated - use ViewJsonRules instead. Retrieve a JSON object containing all of the rules for a given asset.
ViewJsonRulesViewJsonRulesRequestViewJsonRulesResponseRetrieve a JSON object containing all of the rules for a given asset.
UpdateHumanFriendlyRulesUpdateHumanFriendlyRulesRequestUpdateHumanFriendlyRulesResponseDeprecated - use UpdateJsonRules instead. Batch update rules given the rules_json which is a JSON list of rules.
ValidateJsonRulesValidateJsonRulesRequestValidateJsonRulesResponseValidate a batch update for rules given the rules_json which is a JSON list of rules. This is a dry-run operation.
UpdateJsonRulesUpdateJsonRulesRequestUpdateJsonRulesResponseBatch update rules given the rules_json which is a JSON list of rules.
ListRuleVersionsListRuleVersionsRequestListRuleVersionsResponseRetrieves a list of rule versions for the given rule.
GetRuleVersionGetRuleVersionRequestGetRuleVersionResponseRetrieves a specific version of a rule.
BatchGetRuleVersionsBatchGetRuleVersionsRequestBatchGetRuleVersionsResponseRetrieves multiple rules by rule versions.

On this page