From ae19c6c08f650898e1f5744b483f3b5b46ae6b72 Mon Sep 17 00:00:00 2001 From: Benjamin Nguyen Date: Mon, 9 Sep 2024 16:18:28 -0700 Subject: [PATCH] python(feature): update protos --- python/lib/sift/assets/v1/assets_pb2.py | 45 ++-- python/lib/sift/assets/v1/assets_pb2.pyi | 51 +++- python/lib/sift/assets/v1/assets_pb2_grpc.py | 33 +++ python/lib/sift/assets/v1/assets_pb2_grpc.pyi | 17 ++ .../sift/remote_files/v1/remote_files_pb2.py | 76 +++--- .../sift/remote_files/v1/remote_files_pb2.pyi | 9 +- python/lib/sift/report_templates/__init__.py | 0 .../lib/sift/report_templates/v1/__init__.py | 0 .../v1/report_templates_pb2.py | 113 ++++++++ .../v1/report_templates_pb2.pyi | 253 ++++++++++++++++++ .../v1/report_templates_pb2_grpc.py | 101 +++++++ .../v1/report_templates_pb2_grpc.pyi | 64 +++++ python/lib/sift/rules/v1/rules_pb2.py | 234 ++++++++-------- python/lib/sift/rules/v1/rules_pb2.pyi | 40 ++- python/lib/sift/users/v2/users_pb2.py | 20 +- python/lib/sift/users/v2/users_pb2.pyi | 64 +++++ python/lib/sift/users/v2/users_pb2_grpc.py | 34 +++ python/lib/sift/users/v2/users_pb2_grpc.pyi | 20 ++ 18 files changed, 995 insertions(+), 179 deletions(-) create mode 100644 python/lib/sift/report_templates/__init__.py create mode 100644 python/lib/sift/report_templates/v1/__init__.py create mode 100644 python/lib/sift/report_templates/v1/report_templates_pb2.py create mode 100644 python/lib/sift/report_templates/v1/report_templates_pb2.pyi create mode 100644 python/lib/sift/report_templates/v1/report_templates_pb2_grpc.py create mode 100644 python/lib/sift/report_templates/v1/report_templates_pb2_grpc.pyi diff --git a/python/lib/sift/assets/v1/assets_pb2.py b/python/lib/sift/assets/v1/assets_pb2.py index 65be3f08..4df67bc4 100644 --- a/python/lib/sift/assets/v1/assets_pb2.py +++ b/python/lib/sift/assets/v1/assets_pb2.py @@ -14,11 +14,12 @@ from google.api import annotations_pb2 as google_dot_api_dot_annotations__pb2 from google.api import field_behavior_pb2 as google_dot_api_dot_field__behavior__pb2 +from google.protobuf import field_mask_pb2 as google_dot_protobuf_dot_field__mask__pb2 from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__pb2 from protoc_gen_openapiv2.options import annotations_pb2 as protoc__gen__openapiv2_dot_options_dot_annotations__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1bsift/assets/v1/assets.proto\x12\x0esift.assets.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\xde\x02\n\x05\x41sset\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\x17\n\x04name\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x04name\x12,\n\x0forganization_id\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12\x42\n\x0c\x63reated_date\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x44\n\rmodified_date\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\"v\n\x11ListAssetsRequest\x12 \n\tpage_size\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x1b\n\x06\x66ilter\x18\x03 \x01(\tB\x03\xe0\x41\x01R\x06\x66ilter\"k\n\x12ListAssetsResponse\x12-\n\x06\x61ssets\x18\x01 \x03(\x0b\x32\x15.sift.assets.v1.AssetR\x06\x61ssets\x12&\n\x0fnext_page_token\x18\x05 \x01(\tR\rnextPageToken\"4\n\x12\x44\x65leteAssetRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\"\x15\n\x13\x44\x65leteAssetResponse\"1\n\x0fGetAssetRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\"?\n\x10GetAssetResponse\x12+\n\x05\x61sset\x18\x01 \x01(\x0b\x32\x15.sift.assets.v1.AssetR\x05\x61sset2\xe7\x04\n\x0c\x41ssetService\x12\x9c\x01\n\x0b\x44\x65leteAsset\x12\".sift.assets.v1.DeleteAssetRequest\x1a#.sift.assets.v1.DeleteAssetResponse\"D\x92\x41 \x12\x0b\x44\x65leteAsset\x1a\x11\x44\x65letes an asset.\x82\xd3\xe4\x93\x02\x1b*\x19/api/v1/assets/{asset_id}\x12\x92\x01\n\x08GetAsset\x12\x1f.sift.assets.v1.GetAssetRequest\x1a .sift.assets.v1.GetAssetResponse\"C\x92\x41\x1f\x12\x08GetAsset\x1a\x13Retrieves an asset.\x82\xd3\xe4\x93\x02\x1b\x12\x19/api/v1/assets/{asset_id}\x12\xa6\x01\n\nListAssets\x12!.sift.assets.v1.ListAssetsRequest\x1a\".sift.assets.v1.ListAssetsResponse\"Q\x92\x41\x38\x12\nListAssets\x1a*Retrieves assets using an optional filter.\x82\xd3\xe4\x93\x02\x10\x12\x0e/api/v1/assets\x1az\x92\x41w\x12\x44Service to programmatically interact with [assets](/glossary#asset).\x1a/\n Read more about what assets are.\x12\x0b/data-modelB\x8f\x01\n\x12\x63om.sift.assets.v1B\x0b\x41ssetsProtoP\x01\xa2\x02\x03SAX\xaa\x02\x0eSift.Assets.V1\xca\x02\x0eSift\\Assets\\V1\xe2\x02\x1aSift\\Assets\\V1\\GPBMetadata\xea\x02\x10Sift::Assets::V1\x92\x41\x11\x12\x0f\n\rAsset Serviceb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1bsift/assets/v1/assets.proto\x12\x0esift.assets.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\xf7\x02\n\x05\x41sset\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\x17\n\x04name\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x04name\x12,\n\x0forganization_id\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12\x42\n\x0c\x63reated_date\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x44\n\rmodified_date\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x17\n\x04tags\x18\t \x03(\tB\x03\xe0\x41\x02R\x04tags\"v\n\x11ListAssetsRequest\x12 \n\tpage_size\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x1b\n\x06\x66ilter\x18\x03 \x01(\tB\x03\xe0\x41\x01R\x06\x66ilter\"k\n\x12ListAssetsResponse\x12-\n\x06\x61ssets\x18\x01 \x03(\x0b\x32\x15.sift.assets.v1.AssetR\x06\x61ssets\x12&\n\x0fnext_page_token\x18\x05 \x01(\tR\rnextPageToken\"4\n\x12\x44\x65leteAssetRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\"\x15\n\x13\x44\x65leteAssetResponse\"1\n\x0fGetAssetRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\"?\n\x10GetAssetResponse\x12+\n\x05\x61sset\x18\x01 \x01(\x0b\x32\x15.sift.assets.v1.AssetR\x05\x61sset\"\x83\x01\n\x12UpdateAssetRequest\x12+\n\x05\x61sset\x18\x01 \x01(\x0b\x32\x15.sift.assets.v1.AssetR\x05\x61sset\x12@\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02R\nupdateMask\"B\n\x13UpdateAssetResponse\x12+\n\x05\x61sset\x18\x01 \x01(\x0b\x32\x15.sift.assets.v1.AssetR\x05\x61sset2\x87\x06\n\x0c\x41ssetService\x12\x9c\x01\n\x0b\x44\x65leteAsset\x12\".sift.assets.v1.DeleteAssetRequest\x1a#.sift.assets.v1.DeleteAssetResponse\"D\x92\x41 \x12\x0b\x44\x65leteAsset\x1a\x11\x44\x65letes an asset.\x82\xd3\xe4\x93\x02\x1b*\x19/api/v1/assets/{asset_id}\x12\x92\x01\n\x08GetAsset\x12\x1f.sift.assets.v1.GetAssetRequest\x1a .sift.assets.v1.GetAssetResponse\"C\x92\x41\x1f\x12\x08GetAsset\x1a\x13Retrieves an asset.\x82\xd3\xe4\x93\x02\x1b\x12\x19/api/v1/assets/{asset_id}\x12\xa6\x01\n\nListAssets\x12!.sift.assets.v1.ListAssetsRequest\x1a\".sift.assets.v1.ListAssetsResponse\"Q\x92\x41\x38\x12\nListAssets\x1a*Retrieves assets using an optional filter.\x82\xd3\xe4\x93\x02\x10\x12\x0e/api/v1/assets\x12\x9d\x01\n\x0bUpdateAsset\x12\".sift.assets.v1.UpdateAssetRequest\x1a#.sift.assets.v1.UpdateAssetResponse\"E\x92\x41)\x12\x0bUpdateAsset\x1a\x1aUpdate fields on an asset.\x82\xd3\xe4\x93\x02\x13\x32\x0e/api/v1/assets:\x01*\x1az\x92\x41w\x12\x44Service to programmatically interact with [assets](/glossary#asset).\x1a/\n Read more about what assets are.\x12\x0b/data-modelB\x8f\x01\n\x12\x63om.sift.assets.v1B\x0b\x41ssetsProtoP\x01\xa2\x02\x03SAX\xaa\x02\x0eSift.Assets.V1\xca\x02\x0eSift\\Assets\\V1\xe2\x02\x1aSift\\Assets\\V1\\GPBMetadata\xea\x02\x10Sift::Assets::V1\x92\x41\x11\x12\x0f\n\rAsset Serviceb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -40,6 +41,8 @@ _globals['_ASSET'].fields_by_name['modified_date']._serialized_options = b'\340A\002' _globals['_ASSET'].fields_by_name['modified_by_user_id']._loaded_options = None _globals['_ASSET'].fields_by_name['modified_by_user_id']._serialized_options = b'\340A\002' + _globals['_ASSET'].fields_by_name['tags']._loaded_options = None + _globals['_ASSET'].fields_by_name['tags']._serialized_options = b'\340A\002' _globals['_LISTASSETSREQUEST'].fields_by_name['page_size']._loaded_options = None _globals['_LISTASSETSREQUEST'].fields_by_name['page_size']._serialized_options = b'\340A\001' _globals['_LISTASSETSREQUEST'].fields_by_name['page_token']._loaded_options = None @@ -50,6 +53,8 @@ _globals['_DELETEASSETREQUEST'].fields_by_name['asset_id']._serialized_options = b'\340A\002' _globals['_GETASSETREQUEST'].fields_by_name['asset_id']._loaded_options = None _globals['_GETASSETREQUEST'].fields_by_name['asset_id']._serialized_options = b'\340A\002' + _globals['_UPDATEASSETREQUEST'].fields_by_name['update_mask']._loaded_options = None + _globals['_UPDATEASSETREQUEST'].fields_by_name['update_mask']._serialized_options = b'\340A\002' _globals['_ASSETSERVICE']._loaded_options = None _globals['_ASSETSERVICE']._serialized_options = b'\222Aw\022DService to programmatically interact with [assets](/glossary#asset).\032/\n Read more about what assets are.\022\013/data-model' _globals['_ASSETSERVICE'].methods_by_name['DeleteAsset']._loaded_options = None @@ -58,20 +63,26 @@ _globals['_ASSETSERVICE'].methods_by_name['GetAsset']._serialized_options = b'\222A\037\022\010GetAsset\032\023Retrieves an asset.\202\323\344\223\002\033\022\031/api/v1/assets/{asset_id}' _globals['_ASSETSERVICE'].methods_by_name['ListAssets']._loaded_options = None _globals['_ASSETSERVICE'].methods_by_name['ListAssets']._serialized_options = b'\222A8\022\nListAssets\032*Retrieves assets using an optional filter.\202\323\344\223\002\020\022\016/api/v1/assets' - _globals['_ASSET']._serialized_start=192 - _globals['_ASSET']._serialized_end=542 - _globals['_LISTASSETSREQUEST']._serialized_start=544 - _globals['_LISTASSETSREQUEST']._serialized_end=662 - _globals['_LISTASSETSRESPONSE']._serialized_start=664 - _globals['_LISTASSETSRESPONSE']._serialized_end=771 - _globals['_DELETEASSETREQUEST']._serialized_start=773 - _globals['_DELETEASSETREQUEST']._serialized_end=825 - _globals['_DELETEASSETRESPONSE']._serialized_start=827 - _globals['_DELETEASSETRESPONSE']._serialized_end=848 - _globals['_GETASSETREQUEST']._serialized_start=850 - _globals['_GETASSETREQUEST']._serialized_end=899 - _globals['_GETASSETRESPONSE']._serialized_start=901 - _globals['_GETASSETRESPONSE']._serialized_end=964 - _globals['_ASSETSERVICE']._serialized_start=967 - _globals['_ASSETSERVICE']._serialized_end=1582 + _globals['_ASSETSERVICE'].methods_by_name['UpdateAsset']._loaded_options = None + _globals['_ASSETSERVICE'].methods_by_name['UpdateAsset']._serialized_options = b'\222A)\022\013UpdateAsset\032\032Update fields on an asset.\202\323\344\223\002\0232\016/api/v1/assets:\001*' + _globals['_ASSET']._serialized_start=226 + _globals['_ASSET']._serialized_end=601 + _globals['_LISTASSETSREQUEST']._serialized_start=603 + _globals['_LISTASSETSREQUEST']._serialized_end=721 + _globals['_LISTASSETSRESPONSE']._serialized_start=723 + _globals['_LISTASSETSRESPONSE']._serialized_end=830 + _globals['_DELETEASSETREQUEST']._serialized_start=832 + _globals['_DELETEASSETREQUEST']._serialized_end=884 + _globals['_DELETEASSETRESPONSE']._serialized_start=886 + _globals['_DELETEASSETRESPONSE']._serialized_end=907 + _globals['_GETASSETREQUEST']._serialized_start=909 + _globals['_GETASSETREQUEST']._serialized_end=958 + _globals['_GETASSETRESPONSE']._serialized_start=960 + _globals['_GETASSETRESPONSE']._serialized_end=1023 + _globals['_UPDATEASSETREQUEST']._serialized_start=1026 + _globals['_UPDATEASSETREQUEST']._serialized_end=1157 + _globals['_UPDATEASSETRESPONSE']._serialized_start=1159 + _globals['_UPDATEASSETRESPONSE']._serialized_end=1225 + _globals['_ASSETSERVICE']._serialized_start=1228 + _globals['_ASSETSERVICE']._serialized_end=2003 # @@protoc_insertion_point(module_scope) diff --git a/python/lib/sift/assets/v1/assets_pb2.pyi b/python/lib/sift/assets/v1/assets_pb2.pyi index 0897e02f..bba629ff 100644 --- a/python/lib/sift/assets/v1/assets_pb2.pyi +++ b/python/lib/sift/assets/v1/assets_pb2.pyi @@ -6,6 +6,7 @@ isort:skip_file import builtins import collections.abc import google.protobuf.descriptor +import google.protobuf.field_mask_pb2 import google.protobuf.internal.containers import google.protobuf.message import google.protobuf.timestamp_pb2 @@ -24,6 +25,7 @@ class Asset(google.protobuf.message.Message): CREATED_BY_USER_ID_FIELD_NUMBER: builtins.int MODIFIED_DATE_FIELD_NUMBER: builtins.int MODIFIED_BY_USER_ID_FIELD_NUMBER: builtins.int + TAGS_FIELD_NUMBER: builtins.int asset_id: builtins.str name: builtins.str organization_id: builtins.str @@ -33,6 +35,8 @@ class Asset(google.protobuf.message.Message): def created_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ... @property def modified_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ... + @property + def tags(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... def __init__( self, *, @@ -43,9 +47,10 @@ class Asset(google.protobuf.message.Message): created_by_user_id: builtins.str = ..., modified_date: google.protobuf.timestamp_pb2.Timestamp | None = ..., modified_by_user_id: builtins.str = ..., + tags: collections.abc.Iterable[builtins.str] | None = ..., ) -> None: ... def HasField(self, field_name: typing.Literal["created_date", b"created_date", "modified_date", b"modified_date"]) -> builtins.bool: ... - def ClearField(self, field_name: typing.Literal["asset_id", b"asset_id", "created_by_user_id", b"created_by_user_id", "created_date", b"created_date", "modified_by_user_id", b"modified_by_user_id", "modified_date", b"modified_date", "name", b"name", "organization_id", b"organization_id"]) -> None: ... + def ClearField(self, field_name: typing.Literal["asset_id", b"asset_id", "created_by_user_id", b"created_by_user_id", "created_date", b"created_date", "modified_by_user_id", b"modified_by_user_id", "modified_date", b"modified_date", "name", b"name", "organization_id", b"organization_id", "tags", b"tags"]) -> None: ... global___Asset = Asset @@ -173,3 +178,47 @@ class GetAssetResponse(google.protobuf.message.Message): def ClearField(self, field_name: typing.Literal["asset", b"asset"]) -> None: ... global___GetAssetResponse = GetAssetResponse + +@typing.final +class UpdateAssetRequest(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + ASSET_FIELD_NUMBER: builtins.int + UPDATE_MASK_FIELD_NUMBER: builtins.int + @property + def asset(self) -> global___Asset: + """The asset to update. The asset's `asset_id` field is used to identify asset run to update + and is required. + """ + + @property + def update_mask(self) -> google.protobuf.field_mask_pb2.FieldMask: + """The list of fields to be updated. Currently, the only field available to be updated is `tags`.""" + + def __init__( + self, + *, + asset: global___Asset | None = ..., + update_mask: google.protobuf.field_mask_pb2.FieldMask | None = ..., + ) -> None: ... + def HasField(self, field_name: typing.Literal["asset", b"asset", "update_mask", b"update_mask"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["asset", b"asset", "update_mask", b"update_mask"]) -> None: ... + +global___UpdateAssetRequest = UpdateAssetRequest + +@typing.final +class UpdateAssetResponse(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + ASSET_FIELD_NUMBER: builtins.int + @property + def asset(self) -> global___Asset: ... + def __init__( + self, + *, + asset: global___Asset | None = ..., + ) -> None: ... + def HasField(self, field_name: typing.Literal["asset", b"asset"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["asset", b"asset"]) -> None: ... + +global___UpdateAssetResponse = UpdateAssetResponse diff --git a/python/lib/sift/assets/v1/assets_pb2_grpc.py b/python/lib/sift/assets/v1/assets_pb2_grpc.py index 60fb1e05..24f0bb0a 100644 --- a/python/lib/sift/assets/v1/assets_pb2_grpc.py +++ b/python/lib/sift/assets/v1/assets_pb2_grpc.py @@ -29,6 +29,11 @@ def __init__(self, channel): request_serializer=sift_dot_assets_dot_v1_dot_assets__pb2.ListAssetsRequest.SerializeToString, response_deserializer=sift_dot_assets_dot_v1_dot_assets__pb2.ListAssetsResponse.FromString, ) + self.UpdateAsset = channel.unary_unary( + '/sift.assets.v1.AssetService/UpdateAsset', + request_serializer=sift_dot_assets_dot_v1_dot_assets__pb2.UpdateAssetRequest.SerializeToString, + response_deserializer=sift_dot_assets_dot_v1_dot_assets__pb2.UpdateAssetResponse.FromString, + ) class AssetServiceServicer(object): @@ -55,6 +60,12 @@ def ListAssets(self, request, context): context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') + def UpdateAsset(self, request, context): + """Missing associated documentation comment in .proto file.""" + context.set_code(grpc.StatusCode.UNIMPLEMENTED) + context.set_details('Method not implemented!') + raise NotImplementedError('Method not implemented!') + def add_AssetServiceServicer_to_server(servicer, server): rpc_method_handlers = { @@ -73,6 +84,11 @@ def add_AssetServiceServicer_to_server(servicer, server): request_deserializer=sift_dot_assets_dot_v1_dot_assets__pb2.ListAssetsRequest.FromString, response_serializer=sift_dot_assets_dot_v1_dot_assets__pb2.ListAssetsResponse.SerializeToString, ), + 'UpdateAsset': grpc.unary_unary_rpc_method_handler( + servicer.UpdateAsset, + request_deserializer=sift_dot_assets_dot_v1_dot_assets__pb2.UpdateAssetRequest.FromString, + response_serializer=sift_dot_assets_dot_v1_dot_assets__pb2.UpdateAssetResponse.SerializeToString, + ), } generic_handler = grpc.method_handlers_generic_handler( 'sift.assets.v1.AssetService', rpc_method_handlers) @@ -133,3 +149,20 @@ def ListAssets(request, sift_dot_assets_dot_v1_dot_assets__pb2.ListAssetsResponse.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata) + + @staticmethod + def UpdateAsset(request, + target, + options=(), + channel_credentials=None, + call_credentials=None, + insecure=False, + compression=None, + wait_for_ready=None, + timeout=None, + metadata=None): + return grpc.experimental.unary_unary(request, target, '/sift.assets.v1.AssetService/UpdateAsset', + sift_dot_assets_dot_v1_dot_assets__pb2.UpdateAssetRequest.SerializeToString, + sift_dot_assets_dot_v1_dot_assets__pb2.UpdateAssetResponse.FromString, + options, channel_credentials, + insecure, call_credentials, compression, wait_for_ready, timeout, metadata) diff --git a/python/lib/sift/assets/v1/assets_pb2_grpc.pyi b/python/lib/sift/assets/v1/assets_pb2_grpc.pyi index e006975f..d3638aed 100644 --- a/python/lib/sift/assets/v1/assets_pb2_grpc.pyi +++ b/python/lib/sift/assets/v1/assets_pb2_grpc.pyi @@ -37,6 +37,11 @@ class AssetServiceStub: ] """Retrieves assets using an optional filter.""" + UpdateAsset: grpc.UnaryUnaryMultiCallable[ + sift.assets.v1.assets_pb2.UpdateAssetRequest, + sift.assets.v1.assets_pb2.UpdateAssetResponse, + ] + class AssetServiceAsyncStub: DeleteAsset: grpc.aio.UnaryUnaryMultiCallable[ sift.assets.v1.assets_pb2.DeleteAssetRequest, @@ -56,6 +61,11 @@ class AssetServiceAsyncStub: ] """Retrieves assets using an optional filter.""" + UpdateAsset: grpc.aio.UnaryUnaryMultiCallable[ + sift.assets.v1.assets_pb2.UpdateAssetRequest, + sift.assets.v1.assets_pb2.UpdateAssetResponse, + ] + class AssetServiceServicer(metaclass=abc.ABCMeta): @abc.abstractmethod def DeleteAsset( @@ -81,4 +91,11 @@ class AssetServiceServicer(metaclass=abc.ABCMeta): ) -> typing.Union[sift.assets.v1.assets_pb2.ListAssetsResponse, collections.abc.Awaitable[sift.assets.v1.assets_pb2.ListAssetsResponse]]: """Retrieves assets using an optional filter.""" + @abc.abstractmethod + def UpdateAsset( + self, + request: sift.assets.v1.assets_pb2.UpdateAssetRequest, + context: _ServicerContext, + ) -> typing.Union[sift.assets.v1.assets_pb2.UpdateAssetResponse, collections.abc.Awaitable[sift.assets.v1.assets_pb2.UpdateAssetResponse]]: ... + def add_AssetServiceServicer_to_server(servicer: AssetServiceServicer, server: typing.Union[grpc.Server, grpc.aio.Server]) -> None: ... diff --git a/python/lib/sift/remote_files/v1/remote_files_pb2.py b/python/lib/sift/remote_files/v1/remote_files_pb2.py index 0d4361fb..0e4a180e 100644 --- a/python/lib/sift/remote_files/v1/remote_files_pb2.py +++ b/python/lib/sift/remote_files/v1/remote_files_pb2.py @@ -19,7 +19,7 @@ from protoc_gen_openapiv2.options import annotations_pb2 as protoc__gen__openapiv2_dot_options_dot_annotations__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\'sift/remote_files/v1/remote_files.proto\x12\x14sift.remote_files.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\xfb\x06\n\nRemoteFile\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\x12,\n\x0forganization_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12 \n\tentity_id\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x08\x65ntityId\x12\x46\n\x0b\x65ntity_type\x18\x04 \x01(\x0e\x32 .sift.remote_files.v1.EntityTypeB\x03\xe0\x41\x02R\nentityType\x12 \n\tfile_name\x18\x05 \x01(\tB\x03\xe0\x41\x02R\x08\x66ileName\x12)\n\x0e\x66ile_mime_type\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0c\x66ileMimeType\x12\x37\n\x15\x66ile_content_encoding\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x13\x66ileContentEncoding\x12$\n\x0bstorage_key\x18\x08 \x01(\tB\x03\xe0\x41\x02R\nstorageKey\x12 \n\tfile_size\x18\t \x01(\x04\x42\x03\xe0\x41\x02R\x08\x66ileSize\x12*\n\x0b\x64\x65scription\x18\n \x01(\tB\x03\xe0\x41\x01H\x01R\x0b\x64\x65scription\x88\x01\x01\x12Q\n\x0evideo_metadata\x18\x0b \x01(\x0b\x32#.sift.remote_files.v1.VideoMetadataB\x03\xe0\x41\x01H\x00R\rvideoMetadata\x12Q\n\x0eimage_metadata\x18\x0c \x01(\x0b\x32#.sift.remote_files.v1.ImageMetadataB\x03\xe0\x41\x01H\x00R\rimageMetadata\x12\x30\n\x12\x63reated_by_user_id\x18\r \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x0e \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x42\n\x0c\x63reated_date\x18\x0f \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x10 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDateB\n\n\x08metadataB\x0e\n\x0c_description\"w\n\rVideoMetadata\x12\x1b\n\x06height\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x06height\x12\x19\n\x05width\x18\x02 \x01(\rB\x03\xe0\x41\x01R\x05width\x12.\n\x10\x64uration_seconds\x18\x03 \x01(\x02\x42\x03\xe0\x41\x01R\x0f\x64urationSeconds\"G\n\rImageMetadata\x12\x1b\n\x06height\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x06height\x12\x19\n\x05width\x18\x02 \x01(\rB\x03\xe0\x41\x01R\x05width\"A\n\x14GetRemoteFileRequest\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\"_\n\x15GetRemoteFileResponse\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\"\xa9\x01\n\x16ListRemoteFilesRequest\x12 \n\tpage_size\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x1b\n\x06\x66ilter\x18\x03 \x01(\tB\x03\xe0\x41\x01R\x06\x66ilter\x12,\n\x0forganization_id\x18\x04 \x01(\tB\x03\xe0\x41\x01R\x0eorganizationId\"\x86\x01\n\x17ListRemoteFilesResponse\x12\x43\n\x0cremote_files\x18\x01 \x03(\x0b\x32 .sift.remote_files.v1.RemoteFileR\x0bremoteFiles\x12&\n\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken\"\x82\x05\n\x17\x43reateRemoteFileRequest\x12 \n\tfile_name\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x08\x66ileName\x12 \n\tentity_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x08\x65ntityId\x12\x46\n\x0b\x65ntity_type\x18\x03 \x01(\x0e\x32 .sift.remote_files.v1.EntityTypeB\x03\xe0\x41\x02R\nentityType\x12)\n\x0e\x66ile_mime_type\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x0c\x66ileMimeType\x12\x37\n\x15\x66ile_content_encoding\x18\x05 \x01(\tB\x03\xe0\x41\x02R\x13\x66ileContentEncoding\x12 \n\tfile_size\x18\x06 \x01(\x04\x42\x03\xe0\x41\x02R\x08\x66ileSize\x12*\n\x0b\x64\x65scription\x18\x07 \x01(\tB\x03\xe0\x41\x01H\x01R\x0b\x64\x65scription\x88\x01\x01\x12,\n\x0forganization_id\x18\x08 \x01(\tB\x03\xe0\x41\x01R\x0eorganizationId\x12Q\n\x0evideo_metadata\x18\t \x01(\x0b\x32#.sift.remote_files.v1.VideoMetadataB\x03\xe0\x41\x01H\x00R\rvideoMetadata\x12Q\n\x0eimage_metadata\x18\n \x01(\x0b\x32#.sift.remote_files.v1.ImageMetadataB\x03\xe0\x41\x01H\x00R\rimageMetadata\x12)\n\x0b\x63ustom_uuid\x18\x0b \x01(\tB\x03\xe0\x41\x01H\x02R\ncustomUuid\x88\x01\x01\x42\n\n\x08metadataB\x0e\n\x0c_descriptionB\x0e\n\x0c_custom_uuid\"b\n\x18\x43reateRemoteFileResponse\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\"D\n\x17\x44\x65leteRemoteFileRequest\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\"\x1a\n\x18\x44\x65leteRemoteFileResponse\"G\n\x1d\x42\x61tchDeleteRemoteFilesRequest\x12&\n\x0fremote_file_ids\x18\x01 \x03(\tR\rremoteFileIds\" \n\x1e\x42\x61tchDeleteRemoteFilesResponse\"\xa3\x01\n\x17UpdateRemoteFileRequest\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\x12@\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02R\nupdateMask\"b\n\x18UpdateRemoteFileResponse\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\"L\n\x1fGetRemoteFileDownloadUrlRequest\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\"J\n GetRemoteFileDownloadUrlResponse\x12&\n\x0c\x64ownload_url\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0b\x64ownloadUrl*\x91\x01\n\nEntityType\x12\x1b\n\x17\x45NTITY_TYPE_UNSPECIFIED\x10\x00\x12\x13\n\x0f\x45NTITY_TYPE_RUN\x10\x01\x12\x1a\n\x16\x45NTITY_TYPE_ANNOTATION\x10\x02\x12\x15\n\x11\x45NTITY_TYPE_ASSET\x10\x03\x12\x1e\n\x1a\x45NTITY_TYPE_ANNOTATION_LOG\x10\x04\x32\xbf\x0c\n\x11RemoteFileService\x12\xc2\x01\n\rGetRemoteFile\x12*.sift.remote_files.v1.GetRemoteFileRequest\x1a+.sift.remote_files.v1.GetRemoteFileResponse\"X\x92\x41(\x12\rGetRemoteFile\x1a\x17Retrieve a remote file.\x82\xd3\xe4\x93\x02\'\x12%/api/v1/remote-files/{remote_file_id}\x12\xbe\x01\n\x10\x43reateRemoteFile\x12-.sift.remote_files.v1.CreateRemoteFileRequest\x1a..sift.remote_files.v1.CreateRemoteFileResponse\"K\x92\x41)\x12\x10\x43reateRemoteFile\x1a\x15\x43reate a remote file.\x82\xd3\xe4\x93\x02\x19\"\x14/api/v1/remote-files:\x01*\x12\xb4\x01\n\x0fListRemoteFiles\x12,.sift.remote_files.v1.ListRemoteFilesRequest\x1a-.sift.remote_files.v1.ListRemoteFilesResponse\"D\x92\x41%\x12\x0fListRemoteFiles\x1a\x12List remote files.\x82\xd3\xe4\x93\x02\x16\x12\x14/api/v1/remote-files\x12\x84\x02\n\x10UpdateRemoteFile\x12-.sift.remote_files.v1.UpdateRemoteFileRequest\x1a..sift.remote_files.v1.UpdateRemoteFileResponse\"\x90\x01\x92\x41n\x12\x10UpdateRemoteFile\x1aZUpdates an existing remote file using using the list of fields specified in `update_mask`.\x82\xd3\xe4\x93\x02\x19\x32\x14/api/v1/remote-files:\x01*\x12\xcc\x01\n\x10\x44\x65leteRemoteFile\x12-.sift.remote_files.v1.DeleteRemoteFileRequest\x1a..sift.remote_files.v1.DeleteRemoteFileResponse\"Y\x92\x41)\x12\x10\x44\x65leteRemoteFile\x1a\x15\x44\x65lete a remote file.\x82\xd3\xe4\x93\x02\'*%/api/v1/remote-files/{remote_file_id}\x12\x8f\x02\n\x16\x42\x61tchDeleteRemoteFiles\x12\x33.sift.remote_files.v1.BatchDeleteRemoteFilesRequest\x1a\x34.sift.remote_files.v1.BatchDeleteRemoteFilesResponse\"\x89\x01\x92\x41[\x12\x16\x42\x61tchDeleteRemoteFiles\x1a\x41\x42\x61tch delete remote files. Each batch is limited to 1000 records.\x82\xd3\xe4\x93\x02%\" /api/v1/remote-files:batchDelete:\x01*\x12\x84\x02\n\x18GetRemoteFileDownloadUrl\x12\x35.sift.remote_files.v1.GetRemoteFileDownloadUrlRequest\x1a\x36.sift.remote_files.v1.GetRemoteFileDownloadUrlResponse\"y\x92\x41<\x12\x10GetRemoteFileUrl\x1a(Gets a download URL for the remote file.\x82\xd3\xe4\x93\x02\x34\x12\x32/api/v1/remote-files/{remote_file_id}/download-urlB\xb3\x01\n\x18\x63om.sift.remote_files.v1B\x10RemoteFilesProtoP\x01\xa2\x02\x03SRX\xaa\x02\x13Sift.RemoteFiles.V1\xca\x02\x13Sift\\RemoteFiles\\V1\xe2\x02\x1fSift\\RemoteFiles\\V1\\GPBMetadata\xea\x02\x15Sift::RemoteFiles::V1\x92\x41\x16\x12\x14\n\x12RemoteFile serviceb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\'sift/remote_files/v1/remote_files.proto\x12\x14sift.remote_files.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a google/protobuf/field_mask.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\xfb\x06\n\nRemoteFile\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\x12,\n\x0forganization_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12 \n\tentity_id\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x08\x65ntityId\x12\x46\n\x0b\x65ntity_type\x18\x04 \x01(\x0e\x32 .sift.remote_files.v1.EntityTypeB\x03\xe0\x41\x02R\nentityType\x12 \n\tfile_name\x18\x05 \x01(\tB\x03\xe0\x41\x02R\x08\x66ileName\x12)\n\x0e\x66ile_mime_type\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0c\x66ileMimeType\x12\x37\n\x15\x66ile_content_encoding\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x13\x66ileContentEncoding\x12$\n\x0bstorage_key\x18\x08 \x01(\tB\x03\xe0\x41\x02R\nstorageKey\x12 \n\tfile_size\x18\t \x01(\x04\x42\x03\xe0\x41\x02R\x08\x66ileSize\x12*\n\x0b\x64\x65scription\x18\n \x01(\tB\x03\xe0\x41\x01H\x01R\x0b\x64\x65scription\x88\x01\x01\x12Q\n\x0evideo_metadata\x18\x0b \x01(\x0b\x32#.sift.remote_files.v1.VideoMetadataB\x03\xe0\x41\x01H\x00R\rvideoMetadata\x12Q\n\x0eimage_metadata\x18\x0c \x01(\x0b\x32#.sift.remote_files.v1.ImageMetadataB\x03\xe0\x41\x01H\x00R\rimageMetadata\x12\x30\n\x12\x63reated_by_user_id\x18\r \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x0e \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x42\n\x0c\x63reated_date\x18\x0f \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x10 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDateB\n\n\x08metadataB\x0e\n\x0c_description\"\xb6\x01\n\rVideoMetadata\x12\x1b\n\x06height\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x06height\x12\x19\n\x05width\x18\x02 \x01(\rB\x03\xe0\x41\x01R\x05width\x12.\n\x10\x64uration_seconds\x18\x03 \x01(\x02\x42\x03\xe0\x41\x01R\x0f\x64urationSeconds\x12=\n\ttimestamp\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x01R\ttimestamp\"G\n\rImageMetadata\x12\x1b\n\x06height\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x06height\x12\x19\n\x05width\x18\x02 \x01(\rB\x03\xe0\x41\x01R\x05width\"A\n\x14GetRemoteFileRequest\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\"_\n\x15GetRemoteFileResponse\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\"\xa9\x01\n\x16ListRemoteFilesRequest\x12 \n\tpage_size\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x1b\n\x06\x66ilter\x18\x03 \x01(\tB\x03\xe0\x41\x01R\x06\x66ilter\x12,\n\x0forganization_id\x18\x04 \x01(\tB\x03\xe0\x41\x01R\x0eorganizationId\"\x86\x01\n\x17ListRemoteFilesResponse\x12\x43\n\x0cremote_files\x18\x01 \x03(\x0b\x32 .sift.remote_files.v1.RemoteFileR\x0bremoteFiles\x12&\n\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken\"\x82\x05\n\x17\x43reateRemoteFileRequest\x12 \n\tfile_name\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x08\x66ileName\x12 \n\tentity_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x08\x65ntityId\x12\x46\n\x0b\x65ntity_type\x18\x03 \x01(\x0e\x32 .sift.remote_files.v1.EntityTypeB\x03\xe0\x41\x02R\nentityType\x12)\n\x0e\x66ile_mime_type\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x0c\x66ileMimeType\x12\x37\n\x15\x66ile_content_encoding\x18\x05 \x01(\tB\x03\xe0\x41\x02R\x13\x66ileContentEncoding\x12 \n\tfile_size\x18\x06 \x01(\x04\x42\x03\xe0\x41\x02R\x08\x66ileSize\x12*\n\x0b\x64\x65scription\x18\x07 \x01(\tB\x03\xe0\x41\x01H\x01R\x0b\x64\x65scription\x88\x01\x01\x12,\n\x0forganization_id\x18\x08 \x01(\tB\x03\xe0\x41\x01R\x0eorganizationId\x12Q\n\x0evideo_metadata\x18\t \x01(\x0b\x32#.sift.remote_files.v1.VideoMetadataB\x03\xe0\x41\x01H\x00R\rvideoMetadata\x12Q\n\x0eimage_metadata\x18\n \x01(\x0b\x32#.sift.remote_files.v1.ImageMetadataB\x03\xe0\x41\x01H\x00R\rimageMetadata\x12)\n\x0b\x63ustom_uuid\x18\x0b \x01(\tB\x03\xe0\x41\x01H\x02R\ncustomUuid\x88\x01\x01\x42\n\n\x08metadataB\x0e\n\x0c_descriptionB\x0e\n\x0c_custom_uuid\"b\n\x18\x43reateRemoteFileResponse\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\"D\n\x17\x44\x65leteRemoteFileRequest\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\"\x1a\n\x18\x44\x65leteRemoteFileResponse\"G\n\x1d\x42\x61tchDeleteRemoteFilesRequest\x12&\n\x0fremote_file_ids\x18\x01 \x03(\tR\rremoteFileIds\" \n\x1e\x42\x61tchDeleteRemoteFilesResponse\"\xa3\x01\n\x17UpdateRemoteFileRequest\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\x12@\n\x0bupdate_mask\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.FieldMaskB\x03\xe0\x41\x02R\nupdateMask\"b\n\x18UpdateRemoteFileResponse\x12\x46\n\x0bremote_file\x18\x01 \x01(\x0b\x32 .sift.remote_files.v1.RemoteFileB\x03\xe0\x41\x02R\nremoteFile\"L\n\x1fGetRemoteFileDownloadUrlRequest\x12)\n\x0eremote_file_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cremoteFileId\"J\n GetRemoteFileDownloadUrlResponse\x12&\n\x0c\x64ownload_url\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0b\x64ownloadUrl*\x91\x01\n\nEntityType\x12\x1b\n\x17\x45NTITY_TYPE_UNSPECIFIED\x10\x00\x12\x13\n\x0f\x45NTITY_TYPE_RUN\x10\x01\x12\x1a\n\x16\x45NTITY_TYPE_ANNOTATION\x10\x02\x12\x15\n\x11\x45NTITY_TYPE_ASSET\x10\x03\x12\x1e\n\x1a\x45NTITY_TYPE_ANNOTATION_LOG\x10\x04\x32\xbf\x0c\n\x11RemoteFileService\x12\xc2\x01\n\rGetRemoteFile\x12*.sift.remote_files.v1.GetRemoteFileRequest\x1a+.sift.remote_files.v1.GetRemoteFileResponse\"X\x92\x41(\x12\rGetRemoteFile\x1a\x17Retrieve a remote file.\x82\xd3\xe4\x93\x02\'\x12%/api/v1/remote-files/{remote_file_id}\x12\xbe\x01\n\x10\x43reateRemoteFile\x12-.sift.remote_files.v1.CreateRemoteFileRequest\x1a..sift.remote_files.v1.CreateRemoteFileResponse\"K\x92\x41)\x12\x10\x43reateRemoteFile\x1a\x15\x43reate a remote file.\x82\xd3\xe4\x93\x02\x19\"\x14/api/v1/remote-files:\x01*\x12\xb4\x01\n\x0fListRemoteFiles\x12,.sift.remote_files.v1.ListRemoteFilesRequest\x1a-.sift.remote_files.v1.ListRemoteFilesResponse\"D\x92\x41%\x12\x0fListRemoteFiles\x1a\x12List remote files.\x82\xd3\xe4\x93\x02\x16\x12\x14/api/v1/remote-files\x12\x84\x02\n\x10UpdateRemoteFile\x12-.sift.remote_files.v1.UpdateRemoteFileRequest\x1a..sift.remote_files.v1.UpdateRemoteFileResponse\"\x90\x01\x92\x41n\x12\x10UpdateRemoteFile\x1aZUpdates an existing remote file using using the list of fields specified in `update_mask`.\x82\xd3\xe4\x93\x02\x19\x32\x14/api/v1/remote-files:\x01*\x12\xcc\x01\n\x10\x44\x65leteRemoteFile\x12-.sift.remote_files.v1.DeleteRemoteFileRequest\x1a..sift.remote_files.v1.DeleteRemoteFileResponse\"Y\x92\x41)\x12\x10\x44\x65leteRemoteFile\x1a\x15\x44\x65lete a remote file.\x82\xd3\xe4\x93\x02\'*%/api/v1/remote-files/{remote_file_id}\x12\x8f\x02\n\x16\x42\x61tchDeleteRemoteFiles\x12\x33.sift.remote_files.v1.BatchDeleteRemoteFilesRequest\x1a\x34.sift.remote_files.v1.BatchDeleteRemoteFilesResponse\"\x89\x01\x92\x41[\x12\x16\x42\x61tchDeleteRemoteFiles\x1a\x41\x42\x61tch delete remote files. Each batch is limited to 1000 records.\x82\xd3\xe4\x93\x02%\" /api/v1/remote-files:batchDelete:\x01*\x12\x84\x02\n\x18GetRemoteFileDownloadUrl\x12\x35.sift.remote_files.v1.GetRemoteFileDownloadUrlRequest\x1a\x36.sift.remote_files.v1.GetRemoteFileDownloadUrlResponse\"y\x92\x41<\x12\x10GetRemoteFileUrl\x1a(Gets a download URL for the remote file.\x82\xd3\xe4\x93\x02\x34\x12\x32/api/v1/remote-files/{remote_file_id}/download-urlB\xb3\x01\n\x18\x63om.sift.remote_files.v1B\x10RemoteFilesProtoP\x01\xa2\x02\x03SRX\xaa\x02\x13Sift.RemoteFiles.V1\xca\x02\x13Sift\\RemoteFiles\\V1\xe2\x02\x1fSift\\RemoteFiles\\V1\\GPBMetadata\xea\x02\x15Sift::RemoteFiles::V1\x92\x41\x16\x12\x14\n\x12RemoteFile serviceb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -65,6 +65,8 @@ _globals['_VIDEOMETADATA'].fields_by_name['width']._serialized_options = b'\340A\001' _globals['_VIDEOMETADATA'].fields_by_name['duration_seconds']._loaded_options = None _globals['_VIDEOMETADATA'].fields_by_name['duration_seconds']._serialized_options = b'\340A\001' + _globals['_VIDEOMETADATA'].fields_by_name['timestamp']._loaded_options = None + _globals['_VIDEOMETADATA'].fields_by_name['timestamp']._serialized_options = b'\340A\001' _globals['_IMAGEMETADATA'].fields_by_name['height']._loaded_options = None _globals['_IMAGEMETADATA'].fields_by_name['height']._serialized_options = b'\340A\001' _globals['_IMAGEMETADATA'].fields_by_name['width']._loaded_options = None @@ -131,42 +133,42 @@ _globals['_REMOTEFILESERVICE'].methods_by_name['BatchDeleteRemoteFiles']._serialized_options = b'\222A[\022\026BatchDeleteRemoteFiles\032ABatch delete remote files. Each batch is limited to 1000 records.\202\323\344\223\002%\" /api/v1/remote-files:batchDelete:\001*' _globals['_REMOTEFILESERVICE'].methods_by_name['GetRemoteFileDownloadUrl']._loaded_options = None _globals['_REMOTEFILESERVICE'].methods_by_name['GetRemoteFileDownloadUrl']._serialized_options = b'\222A<\022\020GetRemoteFileUrl\032(Gets a download URL for the remote file.\202\323\344\223\0024\0222/api/v1/remote-files/{remote_file_id}/download-url' - _globals['_ENTITYTYPE']._serialized_start=3175 - _globals['_ENTITYTYPE']._serialized_end=3320 + _globals['_ENTITYTYPE']._serialized_start=3239 + _globals['_ENTITYTYPE']._serialized_end=3384 _globals['_REMOTEFILE']._serialized_start=244 _globals['_REMOTEFILE']._serialized_end=1135 - _globals['_VIDEOMETADATA']._serialized_start=1137 - _globals['_VIDEOMETADATA']._serialized_end=1256 - _globals['_IMAGEMETADATA']._serialized_start=1258 - _globals['_IMAGEMETADATA']._serialized_end=1329 - _globals['_GETREMOTEFILEREQUEST']._serialized_start=1331 - _globals['_GETREMOTEFILEREQUEST']._serialized_end=1396 - _globals['_GETREMOTEFILERESPONSE']._serialized_start=1398 - _globals['_GETREMOTEFILERESPONSE']._serialized_end=1493 - _globals['_LISTREMOTEFILESREQUEST']._serialized_start=1496 - _globals['_LISTREMOTEFILESREQUEST']._serialized_end=1665 - _globals['_LISTREMOTEFILESRESPONSE']._serialized_start=1668 - _globals['_LISTREMOTEFILESRESPONSE']._serialized_end=1802 - _globals['_CREATEREMOTEFILEREQUEST']._serialized_start=1805 - _globals['_CREATEREMOTEFILEREQUEST']._serialized_end=2447 - _globals['_CREATEREMOTEFILERESPONSE']._serialized_start=2449 - _globals['_CREATEREMOTEFILERESPONSE']._serialized_end=2547 - _globals['_DELETEREMOTEFILEREQUEST']._serialized_start=2549 - _globals['_DELETEREMOTEFILEREQUEST']._serialized_end=2617 - _globals['_DELETEREMOTEFILERESPONSE']._serialized_start=2619 - _globals['_DELETEREMOTEFILERESPONSE']._serialized_end=2645 - _globals['_BATCHDELETEREMOTEFILESREQUEST']._serialized_start=2647 - _globals['_BATCHDELETEREMOTEFILESREQUEST']._serialized_end=2718 - _globals['_BATCHDELETEREMOTEFILESRESPONSE']._serialized_start=2720 - _globals['_BATCHDELETEREMOTEFILESRESPONSE']._serialized_end=2752 - _globals['_UPDATEREMOTEFILEREQUEST']._serialized_start=2755 - _globals['_UPDATEREMOTEFILEREQUEST']._serialized_end=2918 - _globals['_UPDATEREMOTEFILERESPONSE']._serialized_start=2920 - _globals['_UPDATEREMOTEFILERESPONSE']._serialized_end=3018 - _globals['_GETREMOTEFILEDOWNLOADURLREQUEST']._serialized_start=3020 - _globals['_GETREMOTEFILEDOWNLOADURLREQUEST']._serialized_end=3096 - _globals['_GETREMOTEFILEDOWNLOADURLRESPONSE']._serialized_start=3098 - _globals['_GETREMOTEFILEDOWNLOADURLRESPONSE']._serialized_end=3172 - _globals['_REMOTEFILESERVICE']._serialized_start=3323 - _globals['_REMOTEFILESERVICE']._serialized_end=4922 + _globals['_VIDEOMETADATA']._serialized_start=1138 + _globals['_VIDEOMETADATA']._serialized_end=1320 + _globals['_IMAGEMETADATA']._serialized_start=1322 + _globals['_IMAGEMETADATA']._serialized_end=1393 + _globals['_GETREMOTEFILEREQUEST']._serialized_start=1395 + _globals['_GETREMOTEFILEREQUEST']._serialized_end=1460 + _globals['_GETREMOTEFILERESPONSE']._serialized_start=1462 + _globals['_GETREMOTEFILERESPONSE']._serialized_end=1557 + _globals['_LISTREMOTEFILESREQUEST']._serialized_start=1560 + _globals['_LISTREMOTEFILESREQUEST']._serialized_end=1729 + _globals['_LISTREMOTEFILESRESPONSE']._serialized_start=1732 + _globals['_LISTREMOTEFILESRESPONSE']._serialized_end=1866 + _globals['_CREATEREMOTEFILEREQUEST']._serialized_start=1869 + _globals['_CREATEREMOTEFILEREQUEST']._serialized_end=2511 + _globals['_CREATEREMOTEFILERESPONSE']._serialized_start=2513 + _globals['_CREATEREMOTEFILERESPONSE']._serialized_end=2611 + _globals['_DELETEREMOTEFILEREQUEST']._serialized_start=2613 + _globals['_DELETEREMOTEFILEREQUEST']._serialized_end=2681 + _globals['_DELETEREMOTEFILERESPONSE']._serialized_start=2683 + _globals['_DELETEREMOTEFILERESPONSE']._serialized_end=2709 + _globals['_BATCHDELETEREMOTEFILESREQUEST']._serialized_start=2711 + _globals['_BATCHDELETEREMOTEFILESREQUEST']._serialized_end=2782 + _globals['_BATCHDELETEREMOTEFILESRESPONSE']._serialized_start=2784 + _globals['_BATCHDELETEREMOTEFILESRESPONSE']._serialized_end=2816 + _globals['_UPDATEREMOTEFILEREQUEST']._serialized_start=2819 + _globals['_UPDATEREMOTEFILEREQUEST']._serialized_end=2982 + _globals['_UPDATEREMOTEFILERESPONSE']._serialized_start=2984 + _globals['_UPDATEREMOTEFILERESPONSE']._serialized_end=3082 + _globals['_GETREMOTEFILEDOWNLOADURLREQUEST']._serialized_start=3084 + _globals['_GETREMOTEFILEDOWNLOADURLREQUEST']._serialized_end=3160 + _globals['_GETREMOTEFILEDOWNLOADURLRESPONSE']._serialized_start=3162 + _globals['_GETREMOTEFILEDOWNLOADURLRESPONSE']._serialized_end=3236 + _globals['_REMOTEFILESERVICE']._serialized_start=3387 + _globals['_REMOTEFILESERVICE']._serialized_end=4986 # @@protoc_insertion_point(module_scope) diff --git a/python/lib/sift/remote_files/v1/remote_files_pb2.pyi b/python/lib/sift/remote_files/v1/remote_files_pb2.pyi index 36b9a3e4..8bef90af 100644 --- a/python/lib/sift/remote_files/v1/remote_files_pb2.pyi +++ b/python/lib/sift/remote_files/v1/remote_files_pb2.pyi @@ -118,17 +118,22 @@ class VideoMetadata(google.protobuf.message.Message): HEIGHT_FIELD_NUMBER: builtins.int WIDTH_FIELD_NUMBER: builtins.int DURATION_SECONDS_FIELD_NUMBER: builtins.int + TIMESTAMP_FIELD_NUMBER: builtins.int height: builtins.int width: builtins.int duration_seconds: builtins.float + @property + def timestamp(self) -> google.protobuf.timestamp_pb2.Timestamp: ... def __init__( self, *, height: builtins.int = ..., width: builtins.int = ..., duration_seconds: builtins.float = ..., + timestamp: google.protobuf.timestamp_pb2.Timestamp | None = ..., ) -> None: ... - def ClearField(self, field_name: typing.Literal["duration_seconds", b"duration_seconds", "height", b"height", "width", b"width"]) -> None: ... + def HasField(self, field_name: typing.Literal["timestamp", b"timestamp"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["duration_seconds", b"duration_seconds", "height", b"height", "timestamp", b"timestamp", "width", b"width"]) -> None: ... global___VideoMetadata = VideoMetadata @@ -400,7 +405,7 @@ class UpdateRemoteFileRequest(google.protobuf.message.Message): @property def update_mask(self) -> google.protobuf.field_mask_pb2.FieldMask: - """The list of fields to be updated. The field available to be updated is `description`.""" + """The list of fields to be updated. The fields available to be updated are `description` and `metadata`.""" def __init__( self, diff --git a/python/lib/sift/report_templates/__init__.py b/python/lib/sift/report_templates/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/python/lib/sift/report_templates/v1/__init__.py b/python/lib/sift/report_templates/v1/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/python/lib/sift/report_templates/v1/report_templates_pb2.py b/python/lib/sift/report_templates/v1/report_templates_pb2.py new file mode 100644 index 00000000..dd6a3fa1 --- /dev/null +++ b/python/lib/sift/report_templates/v1/report_templates_pb2.py @@ -0,0 +1,113 @@ +# -*- coding: utf-8 -*- +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: sift/report_templates/v1/report_templates.proto +# Protobuf Python Version: 5.26.1 +"""Generated protocol buffer code.""" +from google.protobuf import descriptor as _descriptor +from google.protobuf import descriptor_pool as _descriptor_pool +from google.protobuf import symbol_database as _symbol_database +from google.protobuf.internal import builder as _builder +# @@protoc_insertion_point(imports) + +_sym_db = _symbol_database.Default() + + +from google.api import annotations_pb2 as google_dot_api_dot_annotations__pb2 +from google.api import field_behavior_pb2 as google_dot_api_dot_field__behavior__pb2 +from google.protobuf import timestamp_pb2 as google_dot_protobuf_dot_timestamp__pb2 +from protoc_gen_openapiv2.options import annotations_pb2 as protoc__gen__openapiv2_dot_options_dot_annotations__pb2 + + +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n/sift/report_templates/v1/report_templates.proto\x12\x18sift.report_templates.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\"\xda\x05\n\x0eReportTemplate\x12\x31\n\x12report_template_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x10reportTemplateId\x12,\n\x0forganization_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12\'\n\nclient_key\x18\x03 \x01(\tB\x03\xe0\x41\x01H\x00R\tclientKey\x88\x01\x01\x12\x17\n\x04name\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x04name\x12*\n\x0b\x64\x65scription\x18\x05 \x01(\tB\x03\xe0\x41\x01H\x01R\x0b\x64\x65scription\x88\x01\x01\x12I\n\rarchived_date\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x01H\x02R\x0c\x61rchivedDate\x88\x01\x01\x12\x30\n\x12\x63reated_by_user_id\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x42\n\x0c\x63reated_date\x18\t \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\n \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12G\n\x05rules\x18\x0b \x03(\x0b\x32,.sift.report_templates.v1.ReportTemplateRuleB\x03\xe0\x41\x02R\x05rules\x12\x44\n\x04tags\x18\x0c \x03(\x0b\x32+.sift.report_templates.v1.ReportTemplateTagB\x03\xe0\x41\x02R\x04tagsB\r\n\x0b_client_keyB\x0e\n\x0c_descriptionB\x10\n\x0e_archived_date\"\x94\x01\n\x12ReportTemplateRule\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12+\n\x0frule_version_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\rruleVersionId\x12\x33\n\x13rule_version_number\x18\x03 \x01(\rB\x03\xe0\x41\x02R\x11ruleVersionNumber\"3\n\x11ReportTemplateTag\x12\x1e\n\x08tag_name\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07tagName\"\x9f\x01\n\x18GetReportTemplateRequest\x12\x31\n\x12report_template_id\x18\x01 \x01(\tB\x03\xe0\x41\x01R\x10reportTemplateId\x12\"\n\nclient_key\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tclientKey\x12,\n\x0forganization_id\x18\x03 \x01(\tB\x03\xe0\x41\x01R\x0eorganizationId\"s\n\x19GetReportTemplateResponse\x12V\n\x0freport_template\x18\x01 \x01(\x0b\x32(.sift.report_templates.v1.ReportTemplateB\x03\xe0\x41\x02R\x0ereportTemplate\"\xe0\x03\n\x1b\x43reateReportTemplateRequest\x12\x17\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x04name\x12\'\n\nclient_key\x18\x02 \x01(\tB\x03\xe0\x41\x01H\x01R\tclientKey\x88\x01\x01\x12*\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x03\xe0\x41\x01H\x02R\x0b\x64\x65scription\x88\x01\x01\x12 \n\ttag_names\x18\x04 \x03(\tB\x03\xe0\x41\x02R\x08tagNames\x12,\n\x0forganization_id\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12^\n\x08rule_ids\x18\x07 \x01(\x0b\x32<.sift.report_templates.v1.CreateReportTemplateRequestRuleIdsB\x03\xe0\x41\x01H\x00R\x07ruleIds\x12p\n\x10rule_client_keys\x18\x08 \x01(\x0b\x32?.sift.report_templates.v1.CreateReportTemplateRequestClientKeysB\x03\xe0\x41\x01H\x00R\x0eruleClientKeysB\x12\n\x10rule_identifiersB\r\n\x0b_client_keyB\x0e\n\x0c_description\"D\n\"CreateReportTemplateRequestRuleIds\x12\x1e\n\x08rule_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x07ruleIds\"V\n%CreateReportTemplateRequestClientKeys\x12-\n\x10rule_client_keys\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x0eruleClientKeys\"v\n\x1c\x43reateReportTemplateResponse\x12V\n\x0freport_template\x18\x01 \x01(\x0b\x32(.sift.report_templates.v1.ReportTemplateB\x03\xe0\x41\x02R\x0ereportTemplate2\xa7\x04\n\x15ReportTemplateService\x12\xac\x02\n\x11GetReportTemplate\x12\x32.sift.report_templates.v1.GetReportTemplateRequest\x1a\x33.sift.report_templates.v1.GetReportTemplateResponse\"\xad\x01\x92\x41\x30\x12\x11GetReportTemplate\x1a\x1bRetrieve a report template.\x82\xd3\xe4\x93\x02t\x12-/api/v1/report-templates/{report_template_id}ZC\x12\x41/v1/organizations/{organization_id}/report_templates/{client_key}\x12\xde\x01\n\x14\x43reateReportTemplate\x12\x35.sift.report_templates.v1.CreateReportTemplateRequest\x1a\x36.sift.report_templates.v1.CreateReportTemplateResponse\"W\x92\x41\x31\x12\x14InsertReportTemplate\x1a\x19\x43reate a report template.\x82\xd3\xe4\x93\x02\x1d\"\x18/api/v1/report-templates:\x01*B\xcf\x01\n\x1c\x63om.sift.report_templates.v1B\x14ReportTemplatesProtoP\x01\xa2\x02\x03SRX\xaa\x02\x17Sift.ReportTemplates.V1\xca\x02\x17Sift\\ReportTemplates\\V1\xe2\x02#Sift\\ReportTemplates\\V1\\GPBMetadata\xea\x02\x19Sift::ReportTemplates::V1\x92\x41\x1a\x12\x18\n\x16ReportTemplate serviceb\x06proto3') + +_globals = globals() +_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) +_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'sift.report_templates.v1.report_templates_pb2', _globals) +if not _descriptor._USE_C_DESCRIPTORS: + _globals['DESCRIPTOR']._loaded_options = None + _globals['DESCRIPTOR']._serialized_options = b'\n\034com.sift.report_templates.v1B\024ReportTemplatesProtoP\001\242\002\003SRX\252\002\027Sift.ReportTemplates.V1\312\002\027Sift\\ReportTemplates\\V1\342\002#Sift\\ReportTemplates\\V1\\GPBMetadata\352\002\031Sift::ReportTemplates::V1\222A\032\022\030\n\026ReportTemplate service' + _globals['_REPORTTEMPLATE'].fields_by_name['report_template_id']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['report_template_id']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['organization_id']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['organization_id']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['client_key']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['client_key']._serialized_options = b'\340A\001' + _globals['_REPORTTEMPLATE'].fields_by_name['name']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['name']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['description']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['description']._serialized_options = b'\340A\001' + _globals['_REPORTTEMPLATE'].fields_by_name['archived_date']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['archived_date']._serialized_options = b'\340A\001' + _globals['_REPORTTEMPLATE'].fields_by_name['created_by_user_id']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['created_by_user_id']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['modified_by_user_id']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['modified_by_user_id']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['created_date']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['created_date']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['modified_date']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['modified_date']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['rules']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['rules']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATE'].fields_by_name['tags']._loaded_options = None + _globals['_REPORTTEMPLATE'].fields_by_name['tags']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATERULE'].fields_by_name['rule_id']._loaded_options = None + _globals['_REPORTTEMPLATERULE'].fields_by_name['rule_id']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATERULE'].fields_by_name['rule_version_id']._loaded_options = None + _globals['_REPORTTEMPLATERULE'].fields_by_name['rule_version_id']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATERULE'].fields_by_name['rule_version_number']._loaded_options = None + _globals['_REPORTTEMPLATERULE'].fields_by_name['rule_version_number']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATETAG'].fields_by_name['tag_name']._loaded_options = None + _globals['_REPORTTEMPLATETAG'].fields_by_name['tag_name']._serialized_options = b'\340A\002' + _globals['_GETREPORTTEMPLATEREQUEST'].fields_by_name['report_template_id']._loaded_options = None + _globals['_GETREPORTTEMPLATEREQUEST'].fields_by_name['report_template_id']._serialized_options = b'\340A\001' + _globals['_GETREPORTTEMPLATEREQUEST'].fields_by_name['client_key']._loaded_options = None + _globals['_GETREPORTTEMPLATEREQUEST'].fields_by_name['client_key']._serialized_options = b'\340A\001' + _globals['_GETREPORTTEMPLATEREQUEST'].fields_by_name['organization_id']._loaded_options = None + _globals['_GETREPORTTEMPLATEREQUEST'].fields_by_name['organization_id']._serialized_options = b'\340A\001' + _globals['_GETREPORTTEMPLATERESPONSE'].fields_by_name['report_template']._loaded_options = None + _globals['_GETREPORTTEMPLATERESPONSE'].fields_by_name['report_template']._serialized_options = b'\340A\002' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['name']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['name']._serialized_options = b'\340A\002' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['client_key']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['client_key']._serialized_options = b'\340A\001' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['description']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['description']._serialized_options = b'\340A\001' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['tag_names']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['tag_names']._serialized_options = b'\340A\002' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['organization_id']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['organization_id']._serialized_options = b'\340A\002' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['rule_ids']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['rule_ids']._serialized_options = b'\340A\001' + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['rule_client_keys']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUEST'].fields_by_name['rule_client_keys']._serialized_options = b'\340A\001' + _globals['_CREATEREPORTTEMPLATEREQUESTRULEIDS'].fields_by_name['rule_ids']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUESTRULEIDS'].fields_by_name['rule_ids']._serialized_options = b'\340A\002' + _globals['_CREATEREPORTTEMPLATEREQUESTCLIENTKEYS'].fields_by_name['rule_client_keys']._loaded_options = None + _globals['_CREATEREPORTTEMPLATEREQUESTCLIENTKEYS'].fields_by_name['rule_client_keys']._serialized_options = b'\340A\002' + _globals['_CREATEREPORTTEMPLATERESPONSE'].fields_by_name['report_template']._loaded_options = None + _globals['_CREATEREPORTTEMPLATERESPONSE'].fields_by_name['report_template']._serialized_options = b'\340A\002' + _globals['_REPORTTEMPLATESERVICE'].methods_by_name['GetReportTemplate']._loaded_options = None + _globals['_REPORTTEMPLATESERVICE'].methods_by_name['GetReportTemplate']._serialized_options = b'\222A0\022\021GetReportTemplate\032\033Retrieve a report template.\202\323\344\223\002t\022-/api/v1/report-templates/{report_template_id}ZC\022A/v1/organizations/{organization_id}/report_templates/{client_key}' + _globals['_REPORTTEMPLATESERVICE'].methods_by_name['CreateReportTemplate']._loaded_options = None + _globals['_REPORTTEMPLATESERVICE'].methods_by_name['CreateReportTemplate']._serialized_options = b'\222A1\022\024InsertReportTemplate\032\031Create a report template.\202\323\344\223\002\035\"\030/api/v1/report-templates:\001*' + _globals['_REPORTTEMPLATE']._serialized_start=222 + _globals['_REPORTTEMPLATE']._serialized_end=952 + _globals['_REPORTTEMPLATERULE']._serialized_start=955 + _globals['_REPORTTEMPLATERULE']._serialized_end=1103 + _globals['_REPORTTEMPLATETAG']._serialized_start=1105 + _globals['_REPORTTEMPLATETAG']._serialized_end=1156 + _globals['_GETREPORTTEMPLATEREQUEST']._serialized_start=1159 + _globals['_GETREPORTTEMPLATEREQUEST']._serialized_end=1318 + _globals['_GETREPORTTEMPLATERESPONSE']._serialized_start=1320 + _globals['_GETREPORTTEMPLATERESPONSE']._serialized_end=1435 + _globals['_CREATEREPORTTEMPLATEREQUEST']._serialized_start=1438 + _globals['_CREATEREPORTTEMPLATEREQUEST']._serialized_end=1918 + _globals['_CREATEREPORTTEMPLATEREQUESTRULEIDS']._serialized_start=1920 + _globals['_CREATEREPORTTEMPLATEREQUESTRULEIDS']._serialized_end=1988 + _globals['_CREATEREPORTTEMPLATEREQUESTCLIENTKEYS']._serialized_start=1990 + _globals['_CREATEREPORTTEMPLATEREQUESTCLIENTKEYS']._serialized_end=2076 + _globals['_CREATEREPORTTEMPLATERESPONSE']._serialized_start=2078 + _globals['_CREATEREPORTTEMPLATERESPONSE']._serialized_end=2196 + _globals['_REPORTTEMPLATESERVICE']._serialized_start=2199 + _globals['_REPORTTEMPLATESERVICE']._serialized_end=2750 +# @@protoc_insertion_point(module_scope) diff --git a/python/lib/sift/report_templates/v1/report_templates_pb2.pyi b/python/lib/sift/report_templates/v1/report_templates_pb2.pyi new file mode 100644 index 00000000..9c622c4e --- /dev/null +++ b/python/lib/sift/report_templates/v1/report_templates_pb2.pyi @@ -0,0 +1,253 @@ +""" +@generated by mypy-protobuf. Do not edit manually! +isort:skip_file +""" + +import builtins +import collections.abc +import google.protobuf.descriptor +import google.protobuf.internal.containers +import google.protobuf.message +import google.protobuf.timestamp_pb2 +import typing + +DESCRIPTOR: google.protobuf.descriptor.FileDescriptor + +@typing.final +class ReportTemplate(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + REPORT_TEMPLATE_ID_FIELD_NUMBER: builtins.int + ORGANIZATION_ID_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int + NAME_FIELD_NUMBER: builtins.int + DESCRIPTION_FIELD_NUMBER: builtins.int + ARCHIVED_DATE_FIELD_NUMBER: builtins.int + CREATED_BY_USER_ID_FIELD_NUMBER: builtins.int + MODIFIED_BY_USER_ID_FIELD_NUMBER: builtins.int + CREATED_DATE_FIELD_NUMBER: builtins.int + MODIFIED_DATE_FIELD_NUMBER: builtins.int + RULES_FIELD_NUMBER: builtins.int + TAGS_FIELD_NUMBER: builtins.int + report_template_id: builtins.str + organization_id: builtins.str + client_key: builtins.str + name: builtins.str + description: builtins.str + created_by_user_id: builtins.str + modified_by_user_id: builtins.str + @property + def archived_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ... + @property + def created_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ... + @property + def modified_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ... + @property + def rules(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ReportTemplateRule]: ... + @property + def tags(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ReportTemplateTag]: ... + def __init__( + self, + *, + report_template_id: builtins.str = ..., + organization_id: builtins.str = ..., + client_key: builtins.str | None = ..., + name: builtins.str = ..., + description: builtins.str | None = ..., + archived_date: google.protobuf.timestamp_pb2.Timestamp | None = ..., + created_by_user_id: builtins.str = ..., + modified_by_user_id: builtins.str = ..., + created_date: google.protobuf.timestamp_pb2.Timestamp | None = ..., + modified_date: google.protobuf.timestamp_pb2.Timestamp | None = ..., + rules: collections.abc.Iterable[global___ReportTemplateRule] | None = ..., + tags: collections.abc.Iterable[global___ReportTemplateTag] | None = ..., + ) -> None: ... + def HasField(self, field_name: typing.Literal["_archived_date", b"_archived_date", "_client_key", b"_client_key", "_description", b"_description", "archived_date", b"archived_date", "client_key", b"client_key", "created_date", b"created_date", "description", b"description", "modified_date", b"modified_date"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["_archived_date", b"_archived_date", "_client_key", b"_client_key", "_description", b"_description", "archived_date", b"archived_date", "client_key", b"client_key", "created_by_user_id", b"created_by_user_id", "created_date", b"created_date", "description", b"description", "modified_by_user_id", b"modified_by_user_id", "modified_date", b"modified_date", "name", b"name", "organization_id", b"organization_id", "report_template_id", b"report_template_id", "rules", b"rules", "tags", b"tags"]) -> None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["_archived_date", b"_archived_date"]) -> typing.Literal["archived_date"] | None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["_client_key", b"_client_key"]) -> typing.Literal["client_key"] | None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["_description", b"_description"]) -> typing.Literal["description"] | None: ... + +global___ReportTemplate = ReportTemplate + +@typing.final +class ReportTemplateRule(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + RULE_ID_FIELD_NUMBER: builtins.int + RULE_VERSION_ID_FIELD_NUMBER: builtins.int + RULE_VERSION_NUMBER_FIELD_NUMBER: builtins.int + rule_id: builtins.str + rule_version_id: builtins.str + rule_version_number: builtins.int + def __init__( + self, + *, + rule_id: builtins.str = ..., + rule_version_id: builtins.str = ..., + rule_version_number: builtins.int = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["rule_id", b"rule_id", "rule_version_id", b"rule_version_id", "rule_version_number", b"rule_version_number"]) -> None: ... + +global___ReportTemplateRule = ReportTemplateRule + +@typing.final +class ReportTemplateTag(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + TAG_NAME_FIELD_NUMBER: builtins.int + tag_name: builtins.str + def __init__( + self, + *, + tag_name: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["tag_name", b"tag_name"]) -> None: ... + +global___ReportTemplateTag = ReportTemplateTag + +@typing.final +class GetReportTemplateRequest(google.protobuf.message.Message): + """The request for a call to `ReportTemplateService_GetReportTemplate` to retrieve a report template. + If `report_template_id` is provided then all other arguments will be ignored. The argument `report_template_id` + should not be used together with `client_key`. The `organization_id` argument is only required + if using `client_key` and the user belongs to multiple organizations. + """ + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + REPORT_TEMPLATE_ID_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int + ORGANIZATION_ID_FIELD_NUMBER: builtins.int + report_template_id: builtins.str + client_key: builtins.str + organization_id: builtins.str + def __init__( + self, + *, + report_template_id: builtins.str = ..., + client_key: builtins.str = ..., + organization_id: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["client_key", b"client_key", "organization_id", b"organization_id", "report_template_id", b"report_template_id"]) -> None: ... + +global___GetReportTemplateRequest = GetReportTemplateRequest + +@typing.final +class GetReportTemplateResponse(google.protobuf.message.Message): + """The request of a call to `ReportTemplateService_GetReportTemplate` to retrieve a report template.""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + REPORT_TEMPLATE_FIELD_NUMBER: builtins.int + @property + def report_template(self) -> global___ReportTemplate: ... + def __init__( + self, + *, + report_template: global___ReportTemplate | None = ..., + ) -> None: ... + def HasField(self, field_name: typing.Literal["report_template", b"report_template"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["report_template", b"report_template"]) -> None: ... + +global___GetReportTemplateResponse = GetReportTemplateResponse + +@typing.final +class CreateReportTemplateRequest(google.protobuf.message.Message): + """The request of a call to `ReportTemplateService_CreateReportTemplate` to create a report template.""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + NAME_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int + DESCRIPTION_FIELD_NUMBER: builtins.int + TAG_NAMES_FIELD_NUMBER: builtins.int + ORGANIZATION_ID_FIELD_NUMBER: builtins.int + RULE_IDS_FIELD_NUMBER: builtins.int + RULE_CLIENT_KEYS_FIELD_NUMBER: builtins.int + name: builtins.str + client_key: builtins.str + description: builtins.str + organization_id: builtins.str + """`organization_id` is only required if your user belongs to multiple organizations""" + @property + def tag_names(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... + @property + def rule_ids(self) -> global___CreateReportTemplateRequestRuleIds: ... + @property + def rule_client_keys(self) -> global___CreateReportTemplateRequestClientKeys: ... + def __init__( + self, + *, + name: builtins.str = ..., + client_key: builtins.str | None = ..., + description: builtins.str | None = ..., + tag_names: collections.abc.Iterable[builtins.str] | None = ..., + organization_id: builtins.str = ..., + rule_ids: global___CreateReportTemplateRequestRuleIds | None = ..., + rule_client_keys: global___CreateReportTemplateRequestClientKeys | None = ..., + ) -> None: ... + def HasField(self, field_name: typing.Literal["_client_key", b"_client_key", "_description", b"_description", "client_key", b"client_key", "description", b"description", "rule_client_keys", b"rule_client_keys", "rule_identifiers", b"rule_identifiers", "rule_ids", b"rule_ids"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["_client_key", b"_client_key", "_description", b"_description", "client_key", b"client_key", "description", b"description", "name", b"name", "organization_id", b"organization_id", "rule_client_keys", b"rule_client_keys", "rule_identifiers", b"rule_identifiers", "rule_ids", b"rule_ids", "tag_names", b"tag_names"]) -> None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["_client_key", b"_client_key"]) -> typing.Literal["client_key"] | None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["_description", b"_description"]) -> typing.Literal["description"] | None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["rule_identifiers", b"rule_identifiers"]) -> typing.Literal["rule_ids", "rule_client_keys"] | None: ... + +global___CreateReportTemplateRequest = CreateReportTemplateRequest + +@typing.final +class CreateReportTemplateRequestRuleIds(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + RULE_IDS_FIELD_NUMBER: builtins.int + @property + def rule_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... + def __init__( + self, + *, + rule_ids: collections.abc.Iterable[builtins.str] | None = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["rule_ids", b"rule_ids"]) -> None: ... + +global___CreateReportTemplateRequestRuleIds = CreateReportTemplateRequestRuleIds + +@typing.final +class CreateReportTemplateRequestClientKeys(google.protobuf.message.Message): + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + RULE_CLIENT_KEYS_FIELD_NUMBER: builtins.int + @property + def rule_client_keys(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... + def __init__( + self, + *, + rule_client_keys: collections.abc.Iterable[builtins.str] | None = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["rule_client_keys", b"rule_client_keys"]) -> None: ... + +global___CreateReportTemplateRequestClientKeys = CreateReportTemplateRequestClientKeys + +@typing.final +class CreateReportTemplateResponse(google.protobuf.message.Message): + """The response of a call to `ReportTemplateService_CreateReportTemplate` to create a report template.""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + REPORT_TEMPLATE_FIELD_NUMBER: builtins.int + @property + def report_template(self) -> global___ReportTemplate: ... + def __init__( + self, + *, + report_template: global___ReportTemplate | None = ..., + ) -> None: ... + def HasField(self, field_name: typing.Literal["report_template", b"report_template"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["report_template", b"report_template"]) -> None: ... + +global___CreateReportTemplateResponse = CreateReportTemplateResponse diff --git a/python/lib/sift/report_templates/v1/report_templates_pb2_grpc.py b/python/lib/sift/report_templates/v1/report_templates_pb2_grpc.py new file mode 100644 index 00000000..ab619522 --- /dev/null +++ b/python/lib/sift/report_templates/v1/report_templates_pb2_grpc.py @@ -0,0 +1,101 @@ +# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT! +"""Client and server classes corresponding to protobuf-defined services.""" +import grpc + +from sift.report_templates.v1 import report_templates_pb2 as sift_dot_report__templates_dot_v1_dot_report__templates__pb2 + + +class ReportTemplateServiceStub(object): + """Missing associated documentation comment in .proto file.""" + + def __init__(self, channel): + """Constructor. + + Args: + channel: A grpc.Channel. + """ + self.GetReportTemplate = channel.unary_unary( + '/sift.report_templates.v1.ReportTemplateService/GetReportTemplate', + request_serializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.GetReportTemplateRequest.SerializeToString, + response_deserializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.GetReportTemplateResponse.FromString, + ) + self.CreateReportTemplate = channel.unary_unary( + '/sift.report_templates.v1.ReportTemplateService/CreateReportTemplate', + request_serializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.CreateReportTemplateRequest.SerializeToString, + response_deserializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.CreateReportTemplateResponse.FromString, + ) + + +class ReportTemplateServiceServicer(object): + """Missing associated documentation comment in .proto file.""" + + def GetReportTemplate(self, request, context): + """Retrieve a report template. + """ + context.set_code(grpc.StatusCode.UNIMPLEMENTED) + context.set_details('Method not implemented!') + raise NotImplementedError('Method not implemented!') + + def CreateReportTemplate(self, request, context): + """Create a report template. + """ + context.set_code(grpc.StatusCode.UNIMPLEMENTED) + context.set_details('Method not implemented!') + raise NotImplementedError('Method not implemented!') + + +def add_ReportTemplateServiceServicer_to_server(servicer, server): + rpc_method_handlers = { + 'GetReportTemplate': grpc.unary_unary_rpc_method_handler( + servicer.GetReportTemplate, + request_deserializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.GetReportTemplateRequest.FromString, + response_serializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.GetReportTemplateResponse.SerializeToString, + ), + 'CreateReportTemplate': grpc.unary_unary_rpc_method_handler( + servicer.CreateReportTemplate, + request_deserializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.CreateReportTemplateRequest.FromString, + response_serializer=sift_dot_report__templates_dot_v1_dot_report__templates__pb2.CreateReportTemplateResponse.SerializeToString, + ), + } + generic_handler = grpc.method_handlers_generic_handler( + 'sift.report_templates.v1.ReportTemplateService', rpc_method_handlers) + server.add_generic_rpc_handlers((generic_handler,)) + + + # This class is part of an EXPERIMENTAL API. +class ReportTemplateService(object): + """Missing associated documentation comment in .proto file.""" + + @staticmethod + def GetReportTemplate(request, + target, + options=(), + channel_credentials=None, + call_credentials=None, + insecure=False, + compression=None, + wait_for_ready=None, + timeout=None, + metadata=None): + return grpc.experimental.unary_unary(request, target, '/sift.report_templates.v1.ReportTemplateService/GetReportTemplate', + sift_dot_report__templates_dot_v1_dot_report__templates__pb2.GetReportTemplateRequest.SerializeToString, + sift_dot_report__templates_dot_v1_dot_report__templates__pb2.GetReportTemplateResponse.FromString, + options, channel_credentials, + insecure, call_credentials, compression, wait_for_ready, timeout, metadata) + + @staticmethod + def CreateReportTemplate(request, + target, + options=(), + channel_credentials=None, + call_credentials=None, + insecure=False, + compression=None, + wait_for_ready=None, + timeout=None, + metadata=None): + return grpc.experimental.unary_unary(request, target, '/sift.report_templates.v1.ReportTemplateService/CreateReportTemplate', + sift_dot_report__templates_dot_v1_dot_report__templates__pb2.CreateReportTemplateRequest.SerializeToString, + sift_dot_report__templates_dot_v1_dot_report__templates__pb2.CreateReportTemplateResponse.FromString, + options, channel_credentials, + insecure, call_credentials, compression, wait_for_ready, timeout, metadata) diff --git a/python/lib/sift/report_templates/v1/report_templates_pb2_grpc.pyi b/python/lib/sift/report_templates/v1/report_templates_pb2_grpc.pyi new file mode 100644 index 00000000..45ea1add --- /dev/null +++ b/python/lib/sift/report_templates/v1/report_templates_pb2_grpc.pyi @@ -0,0 +1,64 @@ +""" +@generated by mypy-protobuf. Do not edit manually! +isort:skip_file +""" + +import abc +import collections.abc +import grpc +import grpc.aio +import sift.report_templates.v1.report_templates_pb2 +import typing + +_T = typing.TypeVar("_T") + +class _MaybeAsyncIterator(collections.abc.AsyncIterator[_T], collections.abc.Iterator[_T], metaclass=abc.ABCMeta): ... + +class _ServicerContext(grpc.ServicerContext, grpc.aio.ServicerContext): # type: ignore[misc, type-arg] + ... + +class ReportTemplateServiceStub: + def __init__(self, channel: typing.Union[grpc.Channel, grpc.aio.Channel]) -> None: ... + GetReportTemplate: grpc.UnaryUnaryMultiCallable[ + sift.report_templates.v1.report_templates_pb2.GetReportTemplateRequest, + sift.report_templates.v1.report_templates_pb2.GetReportTemplateResponse, + ] + """Retrieve a report template.""" + + CreateReportTemplate: grpc.UnaryUnaryMultiCallable[ + sift.report_templates.v1.report_templates_pb2.CreateReportTemplateRequest, + sift.report_templates.v1.report_templates_pb2.CreateReportTemplateResponse, + ] + """Create a report template.""" + +class ReportTemplateServiceAsyncStub: + GetReportTemplate: grpc.aio.UnaryUnaryMultiCallable[ + sift.report_templates.v1.report_templates_pb2.GetReportTemplateRequest, + sift.report_templates.v1.report_templates_pb2.GetReportTemplateResponse, + ] + """Retrieve a report template.""" + + CreateReportTemplate: grpc.aio.UnaryUnaryMultiCallable[ + sift.report_templates.v1.report_templates_pb2.CreateReportTemplateRequest, + sift.report_templates.v1.report_templates_pb2.CreateReportTemplateResponse, + ] + """Create a report template.""" + +class ReportTemplateServiceServicer(metaclass=abc.ABCMeta): + @abc.abstractmethod + def GetReportTemplate( + self, + request: sift.report_templates.v1.report_templates_pb2.GetReportTemplateRequest, + context: _ServicerContext, + ) -> typing.Union[sift.report_templates.v1.report_templates_pb2.GetReportTemplateResponse, collections.abc.Awaitable[sift.report_templates.v1.report_templates_pb2.GetReportTemplateResponse]]: + """Retrieve a report template.""" + + @abc.abstractmethod + def CreateReportTemplate( + self, + request: sift.report_templates.v1.report_templates_pb2.CreateReportTemplateRequest, + context: _ServicerContext, + ) -> typing.Union[sift.report_templates.v1.report_templates_pb2.CreateReportTemplateResponse, collections.abc.Awaitable[sift.report_templates.v1.report_templates_pb2.CreateReportTemplateResponse]]: + """Create a report template.""" + +def add_ReportTemplateServiceServicer_to_server(servicer: ReportTemplateServiceServicer, server: typing.Union[grpc.Server, grpc.aio.Server]) -> None: ... diff --git a/python/lib/sift/rules/v1/rules_pb2.py b/python/lib/sift/rules/v1/rules_pb2.py index d82298ce..2e5aa335 100644 --- a/python/lib/sift/rules/v1/rules_pb2.py +++ b/python/lib/sift/rules/v1/rules_pb2.py @@ -19,7 +19,7 @@ from sift.annotations.v1 import annotations_pb2 as sift_dot_annotations_dot_v1_dot_annotations__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x19sift/rules/v1/rules.proto\x12\rsift.rules.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\x1a%sift/annotations/v1/annotations.proto\"\xd3\x04\n\x04Rule\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12\x1e\n\x08\x61sset_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\x17\n\x04name\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x04name\x12%\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x0b\x64\x65scription\x12\"\n\nis_enabled\x18\x06 \x01(\x08\x42\x03\xe0\x41\x02R\tisEnabled\x12\x42\n\x0c\x63reated_date\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x30\n\x12\x63reated_by_user_id\x18\t \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\n \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12,\n\x0forganization_id\x18\x0b \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12\x41\n\nconditions\x18\x0c \x03(\x0b\x32\x1c.sift.rules.v1.RuleConditionB\x03\xe0\x41\x02R\nconditions\x12\x42\n\x0crule_version\x18\r \x01(\x0b\x32\x1a.sift.rules.v1.RuleVersionB\x03\xe0\x41\x02R\x0bruleVersionJ\x04\x08\x05\x10\x06\"\x9b\x04\n\rRuleCondition\x12/\n\x11rule_condition_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0fruleConditionId\x12\x1c\n\x07rule_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12K\n\nexpression\x18\x03 \x01(\x0b\x32&.sift.rules.v1.RuleConditionExpressionB\x03\xe0\x41\x02R\nexpression\x12\x42\n\x0c\x63reated_date\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x38\n\x07\x61\x63tions\x18\t \x03(\x0b\x32\x19.sift.rules.v1.RuleActionB\x03\xe0\x41\x02R\x07\x61\x63tions\x12>\n\x19rule_condition_version_id\x18\n \x01(\tB\x03\xe0\x41\x02R\x16ruleConditionVersionIdJ\x04\x08\x04\x10\x05\"\xa6\x04\n\nRuleAction\x12)\n\x0erule_action_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cruleActionId\x12/\n\x11rule_condition_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0fruleConditionId\x12?\n\x0b\x61\x63tion_type\x18\x03 \x01(\x0e\x32\x19.sift.rules.v1.ActionKindB\x03\xe0\x41\x02R\nactionType\x12Q\n\rconfiguration\x18\x04 \x01(\x0b\x32&.sift.rules.v1.RuleActionConfigurationB\x03\xe0\x41\x02R\rconfiguration\x12\x42\n\x0c\x63reated_date\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x38\n\x16rule_action_version_id\x18\t \x01(\tB\x03\xe0\x41\x02R\x13ruleActionVersionId\"5\n\x16RuleAssetConfiguration\x12\x1b\n\tasset_ids\x18\x01 \x03(\tR\x08\x61ssetIds\"\xd9\x02\n\x12SearchRulesRequest\x12\x19\n\x05limit\x18\x01 \x01(\rH\x00R\x05limit\x88\x01\x01\x12\x16\n\x06offset\x18\x02 \x01(\rR\x06offset\x12\x35\n\x05order\x18\x03 \x01(\x0e\x32\x1a.sift.rules.v1.SearchOrderH\x01R\x05order\x88\x01\x01\x12!\n\x0cname_matches\x18\x04 \x01(\tR\x0bnameMatches\x12%\n\x0e\x63\x61se_sensitive\x18\x05 \x01(\x08R\rcaseSensitive\x12\x16\n\x06regexp\x18\x06 \x01(\x08R\x06regexp\x12\x1e\n\x08order_by\x18\x07 \x01(\tH\x02R\x07orderBy\x88\x01\x01\x12\x19\n\x08rule_ids\x18\x08 \x03(\tR\x07ruleIds\x12\x1b\n\tasset_ids\x18\t \x03(\tR\x08\x61ssetIdsB\x08\n\x06_limitB\x08\n\x06_orderB\x0b\n\t_order_by\"`\n\x13SearchRulesResponse\x12\x19\n\x05\x63ount\x18\x01 \x01(\rB\x03\xe0\x41\x02R\x05\x63ount\x12.\n\x05rules\x18\x02 \x03(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x05rules\".\n\x0eGetRuleRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\"?\n\x0fGetRuleResponse\x12,\n\x04rule\x18\x01 \x01(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x04rule\"6\n\x14\x42\x61tchGetRulesRequest\x12\x1e\n\x08rule_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x07ruleIds\"G\n\x15\x42\x61tchGetRulesResponse\x12.\n\x05rules\x18\x01 \x03(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x05rules\"R\n\x11\x43reateRuleRequest\x12=\n\x06update\x18\x01 \x01(\x0b\x32 .sift.rules.v1.UpdateRuleRequestB\x03\xe0\x41\x02R\x06update\"2\n\x12\x43reateRuleResponse\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\"\xdb\x02\n\x11UpdateRuleRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tH\x00R\x06ruleId\x88\x01\x01\x12\x17\n\x04name\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x04name\x12%\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x0b\x64\x65scription\x12\x1e\n\x08\x61sset_id\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\"\n\nis_enabled\x18\x05 \x01(\x08\x42\x03\xe0\x41\x02R\tisEnabled\x12J\n\nconditions\x18\x06 \x03(\x0b\x32%.sift.rules.v1.UpdateConditionRequestB\x03\xe0\x41\x02R\nconditions\x12\'\n\x0forganization_id\x18\x07 \x01(\tR\x0eorganizationId\x12#\n\rversion_notes\x18\x08 \x01(\tR\x0cversionNotesB\n\n\x08_rule_id\"\xf5\x01\n\x16UpdateConditionRequest\x12/\n\x11rule_condition_id\x18\x01 \x01(\tH\x00R\x0fruleConditionId\x88\x01\x01\x12K\n\nexpression\x18\x03 \x01(\x0b\x32&.sift.rules.v1.RuleConditionExpressionB\x03\xe0\x41\x02R\nexpression\x12\x41\n\x07\x61\x63tions\x18\x04 \x03(\x0b\x32\".sift.rules.v1.UpdateActionRequestB\x03\xe0\x41\x02R\x07\x61\x63tionsB\x14\n\x12_rule_condition_idJ\x04\x08\x02\x10\x03\"\xe7\x01\n\x13UpdateActionRequest\x12)\n\x0erule_action_id\x18\x01 \x01(\tH\x00R\x0cruleActionId\x88\x01\x01\x12?\n\x0b\x61\x63tion_type\x18\x02 \x01(\x0e\x32\x19.sift.rules.v1.ActionKindB\x03\xe0\x41\x02R\nactionType\x12Q\n\rconfiguration\x18\x03 \x01(\x0b\x32&.sift.rules.v1.RuleActionConfigurationB\x03\xe0\x41\x02R\rconfigurationB\x11\n\x0f_rule_action_id\"2\n\x12UpdateRuleResponse\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\"1\n\x11\x44\x65leteRuleRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\"\x14\n\x12\x44\x65leteRuleResponse\"C\n\x1dViewHumanFriendlyRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId:\x02\x18\x01\"H\n\x1eViewHumanFriendlyRulesResponse\x12\"\n\nrules_json\x18\x01 \x01(\tB\x03\xe0\x41\x02R\trulesJson:\x02\x18\x01\"\x97\x01\n\x1fUpdateHumanFriendlyRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\"\n\nrules_json\x18\x02 \x01(\tB\x03\xe0\x41\x02R\trulesJson\x12,\n\x0forganization_id\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId:\x02\x18\x01\"\x8c\x01\n UpdateHumanFriendlyRulesResponse\x12\x1d\n\x07success\x18\x01 \x01(\x08\x42\x03\xe0\x41\x02R\x07success\x12$\n\x0brules_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02R\nrulesCount\x12\x1f\n\x08messages\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x08messages:\x02\x18\x01\"6\n\x14ViewJsonRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\";\n\x15ViewJsonRulesResponse\x12\"\n\nrules_json\x18\x01 \x01(\tB\x03\xe0\x41\x02R\trulesJson\"\x84\x01\n\x10JsonRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\"\n\nrules_json\x18\x02 \x01(\tB\x03\xe0\x41\x02R\trulesJson\x12,\n\x0forganization_id\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\"\xc1\x02\n\x11JsonRulesResponse\x12\x1d\n\x07success\x18\x01 \x01(\x08\x42\x03\xe0\x41\x02R\x07success\x12/\n\x11total_rules_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02R\x0ftotalRulesCount\x12\x33\n\x13rules_created_count\x18\x03 \x01(\x05\x42\x03\xe0\x41\x02R\x11rulesCreatedCount\x12\x33\n\x13rules_updated_count\x18\x04 \x01(\x05\x42\x03\xe0\x41\x02R\x11rulesUpdatedCount\x12\x33\n\x13rules_deleted_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x02R\x11rulesDeletedCount\x12*\n\x0e\x65rror_messages\x18\x06 \x01(\tH\x00R\rerrorMessages\x88\x01\x01\x42\x11\n\x0f_error_messages\"Z\n\x18ValidateJsonRulesRequest\x12>\n\x07request\x18\x01 \x01(\x0b\x32\x1f.sift.rules.v1.JsonRulesRequestB\x03\xe0\x41\x02R\x07request\"^\n\x19ValidateJsonRulesResponse\x12\x41\n\x08response\x18\x01 \x01(\x0b\x32 .sift.rules.v1.JsonRulesResponseB\x03\xe0\x41\x02R\x08response\"X\n\x16UpdateJsonRulesRequest\x12>\n\x07request\x18\x01 \x01(\x0b\x32\x1f.sift.rules.v1.JsonRulesRequestB\x03\xe0\x41\x02R\x07request\"\\\n\x17UpdateJsonRulesResponse\x12\x41\n\x08response\x18\x01 \x01(\x0b\x32 .sift.rules.v1.JsonRulesResponseB\x03\xe0\x41\x02R\x08response\"\x95\x01\n\x17ListRuleVersionsRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12 \n\tpage_size\x18\x02 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x16\n\x06\x66ilter\x18\x04 \x01(\tR\x06\x66ilter\"\xd6\x02\n\x0bRuleVersion\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12+\n\x0frule_version_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\rruleVersionId\x12\x1d\n\x07version\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x07version\x12\x42\n\x0c\x63reated_date\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x05 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12(\n\rversion_notes\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0cversionNotes\x12=\n\x18generated_change_message\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x16generatedChangeMessage\"\x88\x01\n\x18ListRuleVersionsResponse\x12\x44\n\rrule_versions\x18\x01 \x03(\x0b\x32\x1a.sift.rules.v1.RuleVersionB\x03\xe0\x41\x02R\x0cruleVersions\x12&\n\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken\"D\n\x15GetRuleVersionRequest\x12+\n\x0frule_version_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\rruleVersionId\"F\n\x16GetRuleVersionResponse\x12,\n\x04rule\x18\x01 \x01(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x04rule\"L\n\x1b\x42\x61tchGetRuleVersionsRequest\x12-\n\x10rule_version_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x0eruleVersionIds\"N\n\x1c\x42\x61tchGetRuleVersionsResponse\x12.\n\x05rules\x18\x01 \x03(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x05rules\"\xf4\x01\n\x17RuleConditionExpression\x12r\n\x19single_channel_comparison\x18\x01 \x01(\x0b\x32\x30.sift.rules.v1.SingleChannelComparisonExpressionB\x02\x18\x01H\x00R\x17singleChannelComparison\x12W\n\x12\x63\x61lculated_channel\x18\x02 \x01(\x0b\x32&.sift.rules.v1.CalculatedChannelConfigH\x00R\x11\x63\x61lculatedChannelB\x0c\n\nexpression\"\xcb\x02\n!SingleChannelComparisonExpression\x12\x30\n\x11\x63hannel_component\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x10\x63hannelComponent\x12&\n\x0c\x63hannel_name\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0b\x63hannelName\x12G\n\ncomparator\x18\x03 \x01(\x0e\x32\".sift.rules.v1.ConditionComparatorB\x03\xe0\x41\x02R\ncomparator\x12\x18\n\x06\x64ouble\x18\x04 \x01(\x01H\x00R\x06\x64ouble\x12\x18\n\x06string\x18\x05 \x01(\tH\x00R\x06string\x12\x42\n\nlast_value\x18\x06 \x01(\x0b\x32!.sift.rules.v1.LastValueThresholdH\x00R\tlastValueB\x0b\n\tthreshold\"\x14\n\x12LastValueThreshold\"\x98\x02\n\x17\x43\x61lculatedChannelConfig\x12q\n\x12\x63hannel_references\x18\x01 \x03(\x0b\x32=.sift.rules.v1.CalculatedChannelConfig.ChannelReferencesEntryB\x03\xe0\x41\x02R\x11\x63hannelReferences\x12#\n\nexpression\x18\x02 \x01(\tB\x03\xe0\x41\x02R\nexpression\x1a\x65\n\x16\x43hannelReferencesEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x35\n\x05value\x18\x02 \x01(\x0b\x32\x1f.sift.rules.v1.ChannelReferenceR\x05value:\x02\x38\x01\"N\n\x10\x43hannelReference\x12\x17\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x04name\x12!\n\tcomponent\x18\x02 \x01(\tB\x03\xe0\x41\x02R\tcomponent\"\xd0\x01\n\x17RuleActionConfiguration\x12T\n\x0cnotification\x18\x01 \x01(\x0b\x32..sift.rules.v1.NotificationActionConfigurationH\x00R\x0cnotification\x12N\n\nannotation\x18\x02 \x01(\x0b\x32,.sift.rules.v1.AnnotationActionConfigurationH\x00R\nannotationB\x0f\n\rconfiguration\"T\n\x1fNotificationActionConfiguration\x12\x31\n\x12recipient_user_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x10recipientUserIds\"\xd7\x01\n\x1d\x41nnotationActionConfiguration\x12\x1c\n\x07tag_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x06tagIds\x12L\n\x0f\x61nnotation_type\x18\x02 \x01(\x0e\x32#.sift.annotations.v1.AnnotationTypeR\x0e\x61nnotationType\x12\x32\n\x13\x61ssigned_to_user_id\x18\x03 \x01(\tH\x00R\x10\x61ssignedToUserId\x88\x01\x01\x42\x16\n\x14_assigned_to_user_id\"\x8a\x02\n\x14\x45valuateRulesRequest\x12\x1e\n\x08rule_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x07ruleIds\x12X\n\x12\x61nnotation_options\x18\x02 \x01(\x0b\x32).sift.rules.v1.EvaluatedAnnotationOptionsR\x11\x61nnotationOptions\x12\x17\n\x06run_id\x18\x03 \x01(\tH\x00R\x05runId\x12>\n\ntime_range\x18\x04 \x01(\x0b\x32\x1d.sift.rules.v1.TimeRangeQueryH\x00R\ttimeRange\x12\x17\n\x07\x64ry_run\x18\x05 \x01(\x08R\x06\x64ryRunB\x06\n\x04time\"5\n\x1a\x45valuatedAnnotationOptions\x12\x17\n\x07tag_ids\x18\x01 \x03(\tR\x06tagIds\"\x82\x01\n\x0eTimeRangeQuery\x12\x39\n\nstart_time\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tstartTime\x12\x35\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x07\x65ndTime\"\xa2\x01\n\x15\x45valuateRulesResponse\x12\x38\n\x18\x63reated_annotation_count\x18\x01 \x01(\x05R\x16\x63reatedAnnotationCount\x12O\n\x13\x64ry_run_annotations\x18\x02 \x03(\x0b\x32\x1f.sift.rules.v1.DryRunAnnotationR\x11\x64ryRunAnnotations\"\xed\x01\n\x10\x44ryRunAnnotation\x12!\n\x0c\x63ondition_id\x18\x01 \x01(\tR\x0b\x63onditionId\x12\x12\n\x04name\x18\x02 \x01(\tR\x04name\x12\x39\n\nstart_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tstartTime\x12\x35\n\x08\x65nd_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x07\x65ndTime\x12\x30\n\x14\x63ondition_version_id\x18\x05 \x01(\tR\x12\x63onditionVersionId*\\\n\x0bSearchOrder\x12 \n\x18SEARCH_ORDER_UNSPECIFIED\x10\x00\x1a\x02\x08\x01\x12\x14\n\x10SEARCH_ORDER_ASC\x10\x01\x12\x15\n\x11SEARCH_ORDER_DESC\x10\x02*O\n\nActionKind\x12\x1f\n\x17\x41\x43TION_KIND_UNSPECIFIED\x10\x00\x1a\x02\x08\x01\x12\x10\n\x0cNOTIFICATION\x10\x01\x12\x0e\n\nANNOTATION\x10\x02*\xad\x01\n\x13\x43onditionComparator\x12(\n CONDITION_COMPARATOR_UNSPECIFIED\x10\x00\x1a\x02\x08\x01\x12\r\n\tLESS_THAN\x10\x01\x12\x16\n\x12LESS_THAN_OR_EQUAL\x10\x02\x12\x10\n\x0cGREATER_THAN\x10\x03\x12\x19\n\x15GREATER_THAN_OR_EQUAL\x10\x04\x12\t\n\x05\x45QUAL\x10\x05\x12\r\n\tNOT_EQUAL\x10\x06\x32\xae\x19\n\x0bRuleService\x12\xb9\x01\n\x0bSearchRules\x12!.sift.rules.v1.SearchRulesRequest\x1a\".sift.rules.v1.SearchRulesResponse\"c\x92\x41\x41\x12\x0bSearchRules\x1a\x32Queries rules based on provided search parameters.\x82\xd3\xe4\x93\x02\x19\"\x14/api/v1/rules/search:\x01*\x12\x94\x01\n\x07GetRule\x12\x1d.sift.rules.v1.GetRuleRequest\x1a\x1e.sift.rules.v1.GetRuleResponse\"J\x92\x41\x32\x12\x07GetRule\x1a\'Retrieves the latest version of a rule.\x82\xd3\xe4\x93\x02\x0f\x12\r/api/v1/rules\x12\xaa\x01\n\rBatchGetRules\x12#.sift.rules.v1.BatchGetRulesRequest\x1a$.sift.rules.v1.BatchGetRulesResponse\"N\x92\x41*\x12\rBatchGetRules\x1a\x19Retrieves multiple rules.\x82\xd3\xe4\x93\x02\x1b\"\x16/api/v1/rules:batchGet:\x01*\x12\x8b\x01\n\nCreateRule\x12 .sift.rules.v1.CreateRuleRequest\x1a!.sift.rules.v1.CreateRuleResponse\"8\x92\x41\x1d\x12\nCreateRule\x1a\x0f\x43reates a rule.\x82\xd3\xe4\x93\x02\x12\"\r/api/v1/rules:\x01*\x12\x95\x01\n\nUpdateRule\x12 .sift.rules.v1.UpdateRuleRequest\x1a!.sift.rules.v1.UpdateRuleResponse\"B\x92\x41\'\x12\nUpdateRule\x1a\x19Updates an existing rule.\x82\xd3\xe4\x93\x02\x12\x1a\r/api/v1/rules:\x01*\x12\x92\x01\n\nDeleteRule\x12 .sift.rules.v1.DeleteRuleRequest\x1a!.sift.rules.v1.DeleteRuleResponse\"?\x92\x41\x1d\x12\nDeleteRule\x1a\x0f\x44\x65letes a rule.\x82\xd3\xe4\x93\x02\x19\"\x14/api/v1/rules/delete:\x01*\x12\xdb\x01\n\rEvaluateRules\x12#.sift.rules.v1.EvaluateRulesRequest\x1a$.sift.rules.v1.EvaluateRulesResponse\"\x7f\x92\x41[\x12\rEvaluateRules\x1aJEvaluates the provided rules and generate annotations based on the result.\x82\xd3\xe4\x93\x02\x1b\"\x16/api/v1/rules/evaluate:\x01*\x12\x84\x02\n\x16ViewHumanFriendlyRules\x12,.sift.rules.v1.ViewHumanFriendlyRulesRequest\x1a-.sift.rules.v1.ViewHumanFriendlyRulesResponse\"\x8c\x01\x88\x02\x01\x92\x41_\x12\x16ViewHumanFriendlyRules\x1a\x45Retrieve a JSON object containing all of the rules for a given asset.\x82\xd3\xe4\x93\x02!\x12\x1f/api/v1/rules:viewHumanFriendly\x12\xd3\x01\n\rViewJsonRules\x12#.sift.rules.v1.ViewJsonRulesRequest\x1a$.sift.rules.v1.ViewJsonRulesResponse\"w\x92\x41V\x12\rViewJsonRules\x1a\x45Retrieve a JSON object containing all of the rules for a given asset.\x82\xd3\xe4\x93\x02\x18\x12\x16/api/v1/rules:viewJson\x12\x94\x02\n\x18UpdateHumanFriendlyRules\x12..sift.rules.v1.UpdateHumanFriendlyRulesRequest\x1a/.sift.rules.v1.UpdateHumanFriendlyRulesResponse\"\x96\x01\x88\x02\x01\x92\x41\x64\x12\x18UpdateHumanFriendlyRules\x1aHBatch update rules given the `rules_json` which is a JSON list of rules.\x82\xd3\xe4\x93\x02&\"!/api/v1/rules:updateHumanFriendly:\x01*\x12\xfd\x01\n\x11ValidateJsonRules\x12\'.sift.rules.v1.ValidateJsonRulesRequest\x1a(.sift.rules.v1.ValidateJsonRulesResponse\"\x94\x01\x92\x41l\x12\x11ValidateJsonRules\x1aWValidate a batch update for rules given the `rules_json` which is a JSON list of rules.\x82\xd3\xe4\x93\x02\x1f\"\x1a/api/v1/rules:validateJson:\x01*\x12\xe4\x01\n\x0fUpdateJsonRules\x12%.sift.rules.v1.UpdateJsonRulesRequest\x1a&.sift.rules.v1.UpdateJsonRulesResponse\"\x81\x01\x92\x41[\x12\x0fUpdateJsonRules\x1aHBatch update rules given the `rules_json` which is a JSON list of rules.\x82\xd3\xe4\x93\x02\x1d\"\x18/api/v1/rules:updateJson:\x01*\x12\xd9\x01\n\x10ListRuleVersions\x12&.sift.rules.v1.ListRuleVersionsRequest\x1a\'.sift.rules.v1.ListRuleVersionsResponse\"t\x92\x41I\x12\x10ListRuleVersions\x1a\x35Retrieves a list of rule versions for the given rule.\x82\xd3\xe4\x93\x02\"\x12 /api/v1/rules/{rule_id}/versions\x12\xb8\x01\n\x0eGetRuleVersion\x12$.sift.rules.v1.GetRuleVersionRequest\x1a%.sift.rules.v1.GetRuleVersionResponse\"Y\x92\x41\x39\x12\x0eGetRuleVersion\x1a\'Retrieves a specific version of a rule.\x82\xd3\xe4\x93\x02\x17\x12\x15/api/v1/rules:version\x12\xdf\x01\n\x14\x42\x61tchGetRuleVersions\x12*.sift.rules.v1.BatchGetRuleVersionsRequest\x1a+.sift.rules.v1.BatchGetRuleVersionsResponse\"n\x92\x41\x42\x12\x14\x42\x61tchGetRuleVersions\x1a*Retrieves multiple rules by rule versions.\x82\xd3\xe4\x93\x02#\"\x1e/api/v1/rules:batchGetVersions:\x01*\x1a\xb1\x01\x92\x41\xad\x01\x12\x30Service to programmatically interact with rules.\x1ay\n\x1fRead more about what rules are.\x12Vhttps://customer.support.siftstack.com/servicedesk/customer/portal/2/article/265421102B\x88\x01\n\x11\x63om.sift.rules.v1B\nRulesProtoP\x01\xa2\x02\x03SRX\xaa\x02\rSift.Rules.V1\xca\x02\rSift\\Rules\\V1\xe2\x02\x19Sift\\Rules\\V1\\GPBMetadata\xea\x02\x0fSift::Rules::V1\x92\x41\x10\x12\x0e\n\x0cRule Serviceb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x19sift/rules/v1/rules.proto\x12\rsift.rules.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\x1a%sift/annotations/v1/annotations.proto\"\xf7\x04\n\x04Rule\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12\x1e\n\x08\x61sset_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\x17\n\x04name\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x04name\x12%\n\x0b\x64\x65scription\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x0b\x64\x65scription\x12\"\n\nis_enabled\x18\x06 \x01(\x08\x42\x03\xe0\x41\x02R\tisEnabled\x12\x42\n\x0c\x63reated_date\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x30\n\x12\x63reated_by_user_id\x18\t \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\n \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12,\n\x0forganization_id\x18\x0b \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\x12\x41\n\nconditions\x18\x0c \x03(\x0b\x32\x1c.sift.rules.v1.RuleConditionB\x03\xe0\x41\x02R\nconditions\x12\x42\n\x0crule_version\x18\r \x01(\x0b\x32\x1a.sift.rules.v1.RuleVersionB\x03\xe0\x41\x02R\x0bruleVersion\x12\"\n\nclient_key\x18\x0e \x01(\tB\x03\xe0\x41\x01R\tclientKeyJ\x04\x08\x05\x10\x06\"\x9b\x04\n\rRuleCondition\x12/\n\x11rule_condition_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0fruleConditionId\x12\x1c\n\x07rule_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12K\n\nexpression\x18\x03 \x01(\x0b\x32&.sift.rules.v1.RuleConditionExpressionB\x03\xe0\x41\x02R\nexpression\x12\x42\n\x0c\x63reated_date\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x38\n\x07\x61\x63tions\x18\t \x03(\x0b\x32\x19.sift.rules.v1.RuleActionB\x03\xe0\x41\x02R\x07\x61\x63tions\x12>\n\x19rule_condition_version_id\x18\n \x01(\tB\x03\xe0\x41\x02R\x16ruleConditionVersionIdJ\x04\x08\x04\x10\x05\"\xa6\x04\n\nRuleAction\x12)\n\x0erule_action_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x0cruleActionId\x12/\n\x11rule_condition_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0fruleConditionId\x12?\n\x0b\x61\x63tion_type\x18\x03 \x01(\x0e\x32\x19.sift.rules.v1.ActionKindB\x03\xe0\x41\x02R\nactionType\x12Q\n\rconfiguration\x18\x04 \x01(\x0b\x32&.sift.rules.v1.RuleActionConfigurationB\x03\xe0\x41\x02R\rconfiguration\x12\x42\n\x0c\x63reated_date\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x44\n\rmodified_date\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0cmodifiedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12\x32\n\x13modified_by_user_id\x18\x08 \x01(\tB\x03\xe0\x41\x02R\x10modifiedByUserId\x12\x38\n\x16rule_action_version_id\x18\t \x01(\tB\x03\xe0\x41\x02R\x13ruleActionVersionId\"5\n\x16RuleAssetConfiguration\x12\x1b\n\tasset_ids\x18\x01 \x03(\tR\x08\x61ssetIds\"\xd9\x02\n\x12SearchRulesRequest\x12\x19\n\x05limit\x18\x01 \x01(\rH\x00R\x05limit\x88\x01\x01\x12\x16\n\x06offset\x18\x02 \x01(\rR\x06offset\x12\x35\n\x05order\x18\x03 \x01(\x0e\x32\x1a.sift.rules.v1.SearchOrderH\x01R\x05order\x88\x01\x01\x12!\n\x0cname_matches\x18\x04 \x01(\tR\x0bnameMatches\x12%\n\x0e\x63\x61se_sensitive\x18\x05 \x01(\x08R\rcaseSensitive\x12\x16\n\x06regexp\x18\x06 \x01(\x08R\x06regexp\x12\x1e\n\x08order_by\x18\x07 \x01(\tH\x02R\x07orderBy\x88\x01\x01\x12\x19\n\x08rule_ids\x18\x08 \x03(\tR\x07ruleIds\x12\x1b\n\tasset_ids\x18\t \x03(\tR\x08\x61ssetIdsB\x08\n\x06_limitB\x08\n\x06_orderB\x0b\n\t_order_by\"`\n\x13SearchRulesResponse\x12\x19\n\x05\x63ount\x18\x01 \x01(\rB\x03\xe0\x41\x02R\x05\x63ount\x12.\n\x05rules\x18\x02 \x03(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x05rules\"R\n\x0eGetRuleRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x01R\x06ruleId\x12\"\n\nclient_key\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tclientKey\"?\n\x0fGetRuleResponse\x12,\n\x04rule\x18\x01 \x01(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x04rule\"\\\n\x14\x42\x61tchGetRulesRequest\x12\x1e\n\x08rule_ids\x18\x01 \x03(\tB\x03\xe0\x41\x01R\x07ruleIds\x12$\n\x0b\x63lient_keys\x18\x02 \x03(\tB\x03\xe0\x41\x01R\nclientKeys\"G\n\x15\x42\x61tchGetRulesResponse\x12.\n\x05rules\x18\x01 \x03(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x05rules\"R\n\x11\x43reateRuleRequest\x12=\n\x06update\x18\x01 \x01(\x0b\x32 .sift.rules.v1.UpdateRuleRequestB\x03\xe0\x41\x02R\x06update\"2\n\x12\x43reateRuleResponse\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\"\x8e\x03\n\x11UpdateRuleRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tH\x00R\x06ruleId\x88\x01\x01\x12\x17\n\x04name\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x04name\x12%\n\x0b\x64\x65scription\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x0b\x64\x65scription\x12\x1e\n\x08\x61sset_id\x18\x04 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\"\n\nis_enabled\x18\x05 \x01(\x08\x42\x03\xe0\x41\x02R\tisEnabled\x12J\n\nconditions\x18\x06 \x03(\x0b\x32%.sift.rules.v1.UpdateConditionRequestB\x03\xe0\x41\x02R\nconditions\x12\'\n\x0forganization_id\x18\x07 \x01(\tR\x0eorganizationId\x12#\n\rversion_notes\x18\x08 \x01(\tR\x0cversionNotes\x12\"\n\nclient_key\x18\t \x01(\tH\x01R\tclientKey\x88\x01\x01\x42\n\n\x08_rule_idB\r\n\x0b_client_key\"\xf5\x01\n\x16UpdateConditionRequest\x12/\n\x11rule_condition_id\x18\x01 \x01(\tH\x00R\x0fruleConditionId\x88\x01\x01\x12K\n\nexpression\x18\x03 \x01(\x0b\x32&.sift.rules.v1.RuleConditionExpressionB\x03\xe0\x41\x02R\nexpression\x12\x41\n\x07\x61\x63tions\x18\x04 \x03(\x0b\x32\".sift.rules.v1.UpdateActionRequestB\x03\xe0\x41\x02R\x07\x61\x63tionsB\x14\n\x12_rule_condition_idJ\x04\x08\x02\x10\x03\"\xe7\x01\n\x13UpdateActionRequest\x12)\n\x0erule_action_id\x18\x01 \x01(\tH\x00R\x0cruleActionId\x88\x01\x01\x12?\n\x0b\x61\x63tion_type\x18\x02 \x01(\x0e\x32\x19.sift.rules.v1.ActionKindB\x03\xe0\x41\x02R\nactionType\x12Q\n\rconfiguration\x18\x03 \x01(\x0b\x32&.sift.rules.v1.RuleActionConfigurationB\x03\xe0\x41\x02R\rconfigurationB\x11\n\x0f_rule_action_id\"2\n\x12UpdateRuleResponse\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\"U\n\x11\x44\x65leteRuleRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x01R\x06ruleId\x12\"\n\nclient_key\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tclientKey\"\x14\n\x12\x44\x65leteRuleResponse\"C\n\x1dViewHumanFriendlyRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId:\x02\x18\x01\"H\n\x1eViewHumanFriendlyRulesResponse\x12\"\n\nrules_json\x18\x01 \x01(\tB\x03\xe0\x41\x02R\trulesJson:\x02\x18\x01\"\x97\x01\n\x1fUpdateHumanFriendlyRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\"\n\nrules_json\x18\x02 \x01(\tB\x03\xe0\x41\x02R\trulesJson\x12,\n\x0forganization_id\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId:\x02\x18\x01\"\x8c\x01\n UpdateHumanFriendlyRulesResponse\x12\x1d\n\x07success\x18\x01 \x01(\x08\x42\x03\xe0\x41\x02R\x07success\x12$\n\x0brules_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02R\nrulesCount\x12\x1f\n\x08messages\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x08messages:\x02\x18\x01\"6\n\x14ViewJsonRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\";\n\x15ViewJsonRulesResponse\x12\"\n\nrules_json\x18\x01 \x01(\tB\x03\xe0\x41\x02R\trulesJson\"\x84\x01\n\x10JsonRulesRequest\x12\x1e\n\x08\x61sset_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x07\x61ssetId\x12\"\n\nrules_json\x18\x02 \x01(\tB\x03\xe0\x41\x02R\trulesJson\x12,\n\x0forganization_id\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x0eorganizationId\"\xc1\x02\n\x11JsonRulesResponse\x12\x1d\n\x07success\x18\x01 \x01(\x08\x42\x03\xe0\x41\x02R\x07success\x12/\n\x11total_rules_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x02R\x0ftotalRulesCount\x12\x33\n\x13rules_created_count\x18\x03 \x01(\x05\x42\x03\xe0\x41\x02R\x11rulesCreatedCount\x12\x33\n\x13rules_updated_count\x18\x04 \x01(\x05\x42\x03\xe0\x41\x02R\x11rulesUpdatedCount\x12\x33\n\x13rules_deleted_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x02R\x11rulesDeletedCount\x12*\n\x0e\x65rror_messages\x18\x06 \x01(\tH\x00R\rerrorMessages\x88\x01\x01\x42\x11\n\x0f_error_messages\"Z\n\x18ValidateJsonRulesRequest\x12>\n\x07request\x18\x01 \x01(\x0b\x32\x1f.sift.rules.v1.JsonRulesRequestB\x03\xe0\x41\x02R\x07request\"^\n\x19ValidateJsonRulesResponse\x12\x41\n\x08response\x18\x01 \x01(\x0b\x32 .sift.rules.v1.JsonRulesResponseB\x03\xe0\x41\x02R\x08response\"X\n\x16UpdateJsonRulesRequest\x12>\n\x07request\x18\x01 \x01(\x0b\x32\x1f.sift.rules.v1.JsonRulesRequestB\x03\xe0\x41\x02R\x07request\"\\\n\x17UpdateJsonRulesResponse\x12\x41\n\x08response\x18\x01 \x01(\x0b\x32 .sift.rules.v1.JsonRulesResponseB\x03\xe0\x41\x02R\x08response\"\x95\x01\n\x17ListRuleVersionsRequest\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12 \n\tpage_size\x18\x02 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x16\n\x06\x66ilter\x18\x04 \x01(\tR\x06\x66ilter\"\xd6\x02\n\x0bRuleVersion\x12\x1c\n\x07rule_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06ruleId\x12+\n\x0frule_version_id\x18\x02 \x01(\tB\x03\xe0\x41\x02R\rruleVersionId\x12\x1d\n\x07version\x18\x03 \x01(\tB\x03\xe0\x41\x02R\x07version\x12\x42\n\x0c\x63reated_date\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02R\x0b\x63reatedDate\x12\x30\n\x12\x63reated_by_user_id\x18\x05 \x01(\tB\x03\xe0\x41\x02R\x0f\x63reatedByUserId\x12(\n\rversion_notes\x18\x06 \x01(\tB\x03\xe0\x41\x02R\x0cversionNotes\x12=\n\x18generated_change_message\x18\x07 \x01(\tB\x03\xe0\x41\x02R\x16generatedChangeMessage\"\x88\x01\n\x18ListRuleVersionsResponse\x12\x44\n\rrule_versions\x18\x01 \x03(\x0b\x32\x1a.sift.rules.v1.RuleVersionB\x03\xe0\x41\x02R\x0cruleVersions\x12&\n\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken\"D\n\x15GetRuleVersionRequest\x12+\n\x0frule_version_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\rruleVersionId\"F\n\x16GetRuleVersionResponse\x12,\n\x04rule\x18\x01 \x01(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x04rule\"L\n\x1b\x42\x61tchGetRuleVersionsRequest\x12-\n\x10rule_version_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x0eruleVersionIds\"N\n\x1c\x42\x61tchGetRuleVersionsResponse\x12.\n\x05rules\x18\x01 \x03(\x0b\x32\x13.sift.rules.v1.RuleB\x03\xe0\x41\x02R\x05rules\"\xf4\x01\n\x17RuleConditionExpression\x12r\n\x19single_channel_comparison\x18\x01 \x01(\x0b\x32\x30.sift.rules.v1.SingleChannelComparisonExpressionB\x02\x18\x01H\x00R\x17singleChannelComparison\x12W\n\x12\x63\x61lculated_channel\x18\x02 \x01(\x0b\x32&.sift.rules.v1.CalculatedChannelConfigH\x00R\x11\x63\x61lculatedChannelB\x0c\n\nexpression\"\xcb\x02\n!SingleChannelComparisonExpression\x12\x30\n\x11\x63hannel_component\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x10\x63hannelComponent\x12&\n\x0c\x63hannel_name\x18\x02 \x01(\tB\x03\xe0\x41\x02R\x0b\x63hannelName\x12G\n\ncomparator\x18\x03 \x01(\x0e\x32\".sift.rules.v1.ConditionComparatorB\x03\xe0\x41\x02R\ncomparator\x12\x18\n\x06\x64ouble\x18\x04 \x01(\x01H\x00R\x06\x64ouble\x12\x18\n\x06string\x18\x05 \x01(\tH\x00R\x06string\x12\x42\n\nlast_value\x18\x06 \x01(\x0b\x32!.sift.rules.v1.LastValueThresholdH\x00R\tlastValueB\x0b\n\tthreshold\"\x14\n\x12LastValueThreshold\"\x98\x02\n\x17\x43\x61lculatedChannelConfig\x12q\n\x12\x63hannel_references\x18\x01 \x03(\x0b\x32=.sift.rules.v1.CalculatedChannelConfig.ChannelReferencesEntryB\x03\xe0\x41\x02R\x11\x63hannelReferences\x12#\n\nexpression\x18\x02 \x01(\tB\x03\xe0\x41\x02R\nexpression\x1a\x65\n\x16\x43hannelReferencesEntry\x12\x10\n\x03key\x18\x01 \x01(\tR\x03key\x12\x35\n\x05value\x18\x02 \x01(\x0b\x32\x1f.sift.rules.v1.ChannelReferenceR\x05value:\x02\x38\x01\"N\n\x10\x43hannelReference\x12\x17\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x04name\x12!\n\tcomponent\x18\x02 \x01(\tB\x03\xe0\x41\x02R\tcomponent\"\xd0\x01\n\x17RuleActionConfiguration\x12T\n\x0cnotification\x18\x01 \x01(\x0b\x32..sift.rules.v1.NotificationActionConfigurationH\x00R\x0cnotification\x12N\n\nannotation\x18\x02 \x01(\x0b\x32,.sift.rules.v1.AnnotationActionConfigurationH\x00R\nannotationB\x0f\n\rconfiguration\"T\n\x1fNotificationActionConfiguration\x12\x31\n\x12recipient_user_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x10recipientUserIds\"\xd7\x01\n\x1d\x41nnotationActionConfiguration\x12\x1c\n\x07tag_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x06tagIds\x12L\n\x0f\x61nnotation_type\x18\x02 \x01(\x0e\x32#.sift.annotations.v1.AnnotationTypeR\x0e\x61nnotationType\x12\x32\n\x13\x61ssigned_to_user_id\x18\x03 \x01(\tH\x00R\x10\x61ssignedToUserId\x88\x01\x01\x42\x16\n\x14_assigned_to_user_id\"\x8a\x02\n\x14\x45valuateRulesRequest\x12\x1e\n\x08rule_ids\x18\x01 \x03(\tB\x03\xe0\x41\x02R\x07ruleIds\x12X\n\x12\x61nnotation_options\x18\x02 \x01(\x0b\x32).sift.rules.v1.EvaluatedAnnotationOptionsR\x11\x61nnotationOptions\x12\x17\n\x06run_id\x18\x03 \x01(\tH\x00R\x05runId\x12>\n\ntime_range\x18\x04 \x01(\x0b\x32\x1d.sift.rules.v1.TimeRangeQueryH\x00R\ttimeRange\x12\x17\n\x07\x64ry_run\x18\x05 \x01(\x08R\x06\x64ryRunB\x06\n\x04time\"5\n\x1a\x45valuatedAnnotationOptions\x12\x17\n\x07tag_ids\x18\x01 \x03(\tR\x06tagIds\"\x82\x01\n\x0eTimeRangeQuery\x12\x39\n\nstart_time\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tstartTime\x12\x35\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x07\x65ndTime\"\xa2\x01\n\x15\x45valuateRulesResponse\x12\x38\n\x18\x63reated_annotation_count\x18\x01 \x01(\x05R\x16\x63reatedAnnotationCount\x12O\n\x13\x64ry_run_annotations\x18\x02 \x03(\x0b\x32\x1f.sift.rules.v1.DryRunAnnotationR\x11\x64ryRunAnnotations\"\xed\x01\n\x10\x44ryRunAnnotation\x12!\n\x0c\x63ondition_id\x18\x01 \x01(\tR\x0b\x63onditionId\x12\x12\n\x04name\x18\x02 \x01(\tR\x04name\x12\x39\n\nstart_time\x18\x03 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\tstartTime\x12\x35\n\x08\x65nd_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampR\x07\x65ndTime\x12\x30\n\x14\x63ondition_version_id\x18\x05 \x01(\tR\x12\x63onditionVersionId*\\\n\x0bSearchOrder\x12 \n\x18SEARCH_ORDER_UNSPECIFIED\x10\x00\x1a\x02\x08\x01\x12\x14\n\x10SEARCH_ORDER_ASC\x10\x01\x12\x15\n\x11SEARCH_ORDER_DESC\x10\x02*O\n\nActionKind\x12\x1f\n\x17\x41\x43TION_KIND_UNSPECIFIED\x10\x00\x1a\x02\x08\x01\x12\x10\n\x0cNOTIFICATION\x10\x01\x12\x0e\n\nANNOTATION\x10\x02*\xad\x01\n\x13\x43onditionComparator\x12(\n CONDITION_COMPARATOR_UNSPECIFIED\x10\x00\x1a\x02\x08\x01\x12\r\n\tLESS_THAN\x10\x01\x12\x16\n\x12LESS_THAN_OR_EQUAL\x10\x02\x12\x10\n\x0cGREATER_THAN\x10\x03\x12\x19\n\x15GREATER_THAN_OR_EQUAL\x10\x04\x12\t\n\x05\x45QUAL\x10\x05\x12\r\n\tNOT_EQUAL\x10\x06\x32\xae\x19\n\x0bRuleService\x12\xb9\x01\n\x0bSearchRules\x12!.sift.rules.v1.SearchRulesRequest\x1a\".sift.rules.v1.SearchRulesResponse\"c\x92\x41\x41\x12\x0bSearchRules\x1a\x32Queries rules based on provided search parameters.\x82\xd3\xe4\x93\x02\x19\"\x14/api/v1/rules/search:\x01*\x12\x94\x01\n\x07GetRule\x12\x1d.sift.rules.v1.GetRuleRequest\x1a\x1e.sift.rules.v1.GetRuleResponse\"J\x92\x41\x32\x12\x07GetRule\x1a\'Retrieves the latest version of a rule.\x82\xd3\xe4\x93\x02\x0f\x12\r/api/v1/rules\x12\xaa\x01\n\rBatchGetRules\x12#.sift.rules.v1.BatchGetRulesRequest\x1a$.sift.rules.v1.BatchGetRulesResponse\"N\x92\x41*\x12\rBatchGetRules\x1a\x19Retrieves multiple rules.\x82\xd3\xe4\x93\x02\x1b\"\x16/api/v1/rules:batchGet:\x01*\x12\x8b\x01\n\nCreateRule\x12 .sift.rules.v1.CreateRuleRequest\x1a!.sift.rules.v1.CreateRuleResponse\"8\x92\x41\x1d\x12\nCreateRule\x1a\x0f\x43reates a rule.\x82\xd3\xe4\x93\x02\x12\"\r/api/v1/rules:\x01*\x12\x95\x01\n\nUpdateRule\x12 .sift.rules.v1.UpdateRuleRequest\x1a!.sift.rules.v1.UpdateRuleResponse\"B\x92\x41\'\x12\nUpdateRule\x1a\x19Updates an existing rule.\x82\xd3\xe4\x93\x02\x12\x1a\r/api/v1/rules:\x01*\x12\x92\x01\n\nDeleteRule\x12 .sift.rules.v1.DeleteRuleRequest\x1a!.sift.rules.v1.DeleteRuleResponse\"?\x92\x41\x1d\x12\nDeleteRule\x1a\x0f\x44\x65letes a rule.\x82\xd3\xe4\x93\x02\x19\"\x14/api/v1/rules/delete:\x01*\x12\xdb\x01\n\rEvaluateRules\x12#.sift.rules.v1.EvaluateRulesRequest\x1a$.sift.rules.v1.EvaluateRulesResponse\"\x7f\x92\x41[\x12\rEvaluateRules\x1aJEvaluates the provided rules and generate annotations based on the result.\x82\xd3\xe4\x93\x02\x1b\"\x16/api/v1/rules/evaluate:\x01*\x12\x84\x02\n\x16ViewHumanFriendlyRules\x12,.sift.rules.v1.ViewHumanFriendlyRulesRequest\x1a-.sift.rules.v1.ViewHumanFriendlyRulesResponse\"\x8c\x01\x88\x02\x01\x92\x41_\x12\x16ViewHumanFriendlyRules\x1a\x45Retrieve a JSON object containing all of the rules for a given asset.\x82\xd3\xe4\x93\x02!\x12\x1f/api/v1/rules:viewHumanFriendly\x12\xd3\x01\n\rViewJsonRules\x12#.sift.rules.v1.ViewJsonRulesRequest\x1a$.sift.rules.v1.ViewJsonRulesResponse\"w\x92\x41V\x12\rViewJsonRules\x1a\x45Retrieve a JSON object containing all of the rules for a given asset.\x82\xd3\xe4\x93\x02\x18\x12\x16/api/v1/rules:viewJson\x12\x94\x02\n\x18UpdateHumanFriendlyRules\x12..sift.rules.v1.UpdateHumanFriendlyRulesRequest\x1a/.sift.rules.v1.UpdateHumanFriendlyRulesResponse\"\x96\x01\x88\x02\x01\x92\x41\x64\x12\x18UpdateHumanFriendlyRules\x1aHBatch update rules given the `rules_json` which is a JSON list of rules.\x82\xd3\xe4\x93\x02&\"!/api/v1/rules:updateHumanFriendly:\x01*\x12\xfd\x01\n\x11ValidateJsonRules\x12\'.sift.rules.v1.ValidateJsonRulesRequest\x1a(.sift.rules.v1.ValidateJsonRulesResponse\"\x94\x01\x92\x41l\x12\x11ValidateJsonRules\x1aWValidate a batch update for rules given the `rules_json` which is a JSON list of rules.\x82\xd3\xe4\x93\x02\x1f\"\x1a/api/v1/rules:validateJson:\x01*\x12\xe4\x01\n\x0fUpdateJsonRules\x12%.sift.rules.v1.UpdateJsonRulesRequest\x1a&.sift.rules.v1.UpdateJsonRulesResponse\"\x81\x01\x92\x41[\x12\x0fUpdateJsonRules\x1aHBatch update rules given the `rules_json` which is a JSON list of rules.\x82\xd3\xe4\x93\x02\x1d\"\x18/api/v1/rules:updateJson:\x01*\x12\xd9\x01\n\x10ListRuleVersions\x12&.sift.rules.v1.ListRuleVersionsRequest\x1a\'.sift.rules.v1.ListRuleVersionsResponse\"t\x92\x41I\x12\x10ListRuleVersions\x1a\x35Retrieves a list of rule versions for the given rule.\x82\xd3\xe4\x93\x02\"\x12 /api/v1/rules/{rule_id}/versions\x12\xb8\x01\n\x0eGetRuleVersion\x12$.sift.rules.v1.GetRuleVersionRequest\x1a%.sift.rules.v1.GetRuleVersionResponse\"Y\x92\x41\x39\x12\x0eGetRuleVersion\x1a\'Retrieves a specific version of a rule.\x82\xd3\xe4\x93\x02\x17\x12\x15/api/v1/rules:version\x12\xdf\x01\n\x14\x42\x61tchGetRuleVersions\x12*.sift.rules.v1.BatchGetRuleVersionsRequest\x1a+.sift.rules.v1.BatchGetRuleVersionsResponse\"n\x92\x41\x42\x12\x14\x42\x61tchGetRuleVersions\x1a*Retrieves multiple rules by rule versions.\x82\xd3\xe4\x93\x02#\"\x1e/api/v1/rules:batchGetVersions:\x01*\x1a\xb1\x01\x92\x41\xad\x01\x12\x30Service to programmatically interact with rules.\x1ay\n\x1fRead more about what rules are.\x12Vhttps://customer.support.siftstack.com/servicedesk/customer/portal/2/article/265421102B\x88\x01\n\x11\x63om.sift.rules.v1B\nRulesProtoP\x01\xa2\x02\x03SRX\xaa\x02\rSift.Rules.V1\xca\x02\rSift\\Rules\\V1\xe2\x02\x19Sift\\Rules\\V1\\GPBMetadata\xea\x02\x0fSift::Rules::V1\x92\x41\x10\x12\x0e\n\x0cRule Serviceb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -57,6 +57,8 @@ _globals['_RULE'].fields_by_name['conditions']._serialized_options = b'\340A\002' _globals['_RULE'].fields_by_name['rule_version']._loaded_options = None _globals['_RULE'].fields_by_name['rule_version']._serialized_options = b'\340A\002' + _globals['_RULE'].fields_by_name['client_key']._loaded_options = None + _globals['_RULE'].fields_by_name['client_key']._serialized_options = b'\340A\001' _globals['_RULECONDITION'].fields_by_name['rule_condition_id']._loaded_options = None _globals['_RULECONDITION'].fields_by_name['rule_condition_id']._serialized_options = b'\340A\002' _globals['_RULECONDITION'].fields_by_name['rule_id']._loaded_options = None @@ -98,11 +100,15 @@ _globals['_SEARCHRULESRESPONSE'].fields_by_name['rules']._loaded_options = None _globals['_SEARCHRULESRESPONSE'].fields_by_name['rules']._serialized_options = b'\340A\002' _globals['_GETRULEREQUEST'].fields_by_name['rule_id']._loaded_options = None - _globals['_GETRULEREQUEST'].fields_by_name['rule_id']._serialized_options = b'\340A\002' + _globals['_GETRULEREQUEST'].fields_by_name['rule_id']._serialized_options = b'\340A\001' + _globals['_GETRULEREQUEST'].fields_by_name['client_key']._loaded_options = None + _globals['_GETRULEREQUEST'].fields_by_name['client_key']._serialized_options = b'\340A\001' _globals['_GETRULERESPONSE'].fields_by_name['rule']._loaded_options = None _globals['_GETRULERESPONSE'].fields_by_name['rule']._serialized_options = b'\340A\002' _globals['_BATCHGETRULESREQUEST'].fields_by_name['rule_ids']._loaded_options = None - _globals['_BATCHGETRULESREQUEST'].fields_by_name['rule_ids']._serialized_options = b'\340A\002' + _globals['_BATCHGETRULESREQUEST'].fields_by_name['rule_ids']._serialized_options = b'\340A\001' + _globals['_BATCHGETRULESREQUEST'].fields_by_name['client_keys']._loaded_options = None + _globals['_BATCHGETRULESREQUEST'].fields_by_name['client_keys']._serialized_options = b'\340A\001' _globals['_BATCHGETRULESRESPONSE'].fields_by_name['rules']._loaded_options = None _globals['_BATCHGETRULESRESPONSE'].fields_by_name['rules']._serialized_options = b'\340A\002' _globals['_CREATERULEREQUEST'].fields_by_name['update']._loaded_options = None @@ -130,7 +136,9 @@ _globals['_UPDATERULERESPONSE'].fields_by_name['rule_id']._loaded_options = None _globals['_UPDATERULERESPONSE'].fields_by_name['rule_id']._serialized_options = b'\340A\002' _globals['_DELETERULEREQUEST'].fields_by_name['rule_id']._loaded_options = None - _globals['_DELETERULEREQUEST'].fields_by_name['rule_id']._serialized_options = b'\340A\002' + _globals['_DELETERULEREQUEST'].fields_by_name['rule_id']._serialized_options = b'\340A\001' + _globals['_DELETERULEREQUEST'].fields_by_name['client_key']._loaded_options = None + _globals['_DELETERULEREQUEST'].fields_by_name['client_key']._serialized_options = b'\340A\001' _globals['_VIEWHUMANFRIENDLYRULESREQUEST'].fields_by_name['asset_id']._loaded_options = None _globals['_VIEWHUMANFRIENDLYRULESREQUEST'].fields_by_name['asset_id']._serialized_options = b'\340A\002' _globals['_VIEWHUMANFRIENDLYRULESREQUEST']._loaded_options = None @@ -269,114 +277,114 @@ _globals['_RULESERVICE'].methods_by_name['GetRuleVersion']._serialized_options = b'\222A9\022\016GetRuleVersion\032\'Retrieves a specific version of a rule.\202\323\344\223\002\027\022\025/api/v1/rules:version' _globals['_RULESERVICE'].methods_by_name['BatchGetRuleVersions']._loaded_options = None _globals['_RULESERVICE'].methods_by_name['BatchGetRuleVersions']._serialized_options = b'\222AB\022\024BatchGetRuleVersions\032*Retrieves multiple rules by rule versions.\202\323\344\223\002#\"\036/api/v1/rules:batchGetVersions:\001*' - _globals['_SEARCHORDER']._serialized_start=8423 - _globals['_SEARCHORDER']._serialized_end=8515 - _globals['_ACTIONKIND']._serialized_start=8517 - _globals['_ACTIONKIND']._serialized_end=8596 - _globals['_CONDITIONCOMPARATOR']._serialized_start=8599 - _globals['_CONDITIONCOMPARATOR']._serialized_end=8772 + _globals['_SEARCHORDER']._serialized_start=8620 + _globals['_SEARCHORDER']._serialized_end=8712 + _globals['_ACTIONKIND']._serialized_start=8714 + _globals['_ACTIONKIND']._serialized_end=8793 + _globals['_CONDITIONCOMPARATOR']._serialized_start=8796 + _globals['_CONDITIONCOMPARATOR']._serialized_end=8969 _globals['_RULE']._serialized_start=228 - _globals['_RULE']._serialized_end=823 - _globals['_RULECONDITION']._serialized_start=826 - _globals['_RULECONDITION']._serialized_end=1365 - _globals['_RULEACTION']._serialized_start=1368 - _globals['_RULEACTION']._serialized_end=1918 - _globals['_RULEASSETCONFIGURATION']._serialized_start=1920 - _globals['_RULEASSETCONFIGURATION']._serialized_end=1973 - _globals['_SEARCHRULESREQUEST']._serialized_start=1976 - _globals['_SEARCHRULESREQUEST']._serialized_end=2321 - _globals['_SEARCHRULESRESPONSE']._serialized_start=2323 - _globals['_SEARCHRULESRESPONSE']._serialized_end=2419 - _globals['_GETRULEREQUEST']._serialized_start=2421 - _globals['_GETRULEREQUEST']._serialized_end=2467 - _globals['_GETRULERESPONSE']._serialized_start=2469 - _globals['_GETRULERESPONSE']._serialized_end=2532 - _globals['_BATCHGETRULESREQUEST']._serialized_start=2534 - _globals['_BATCHGETRULESREQUEST']._serialized_end=2588 - _globals['_BATCHGETRULESRESPONSE']._serialized_start=2590 - _globals['_BATCHGETRULESRESPONSE']._serialized_end=2661 - _globals['_CREATERULEREQUEST']._serialized_start=2663 - _globals['_CREATERULEREQUEST']._serialized_end=2745 - _globals['_CREATERULERESPONSE']._serialized_start=2747 - _globals['_CREATERULERESPONSE']._serialized_end=2797 - _globals['_UPDATERULEREQUEST']._serialized_start=2800 - _globals['_UPDATERULEREQUEST']._serialized_end=3147 - _globals['_UPDATECONDITIONREQUEST']._serialized_start=3150 - _globals['_UPDATECONDITIONREQUEST']._serialized_end=3395 - _globals['_UPDATEACTIONREQUEST']._serialized_start=3398 - _globals['_UPDATEACTIONREQUEST']._serialized_end=3629 - _globals['_UPDATERULERESPONSE']._serialized_start=3631 - _globals['_UPDATERULERESPONSE']._serialized_end=3681 - _globals['_DELETERULEREQUEST']._serialized_start=3683 - _globals['_DELETERULEREQUEST']._serialized_end=3732 - _globals['_DELETERULERESPONSE']._serialized_start=3734 - _globals['_DELETERULERESPONSE']._serialized_end=3754 - _globals['_VIEWHUMANFRIENDLYRULESREQUEST']._serialized_start=3756 - _globals['_VIEWHUMANFRIENDLYRULESREQUEST']._serialized_end=3823 - _globals['_VIEWHUMANFRIENDLYRULESRESPONSE']._serialized_start=3825 - _globals['_VIEWHUMANFRIENDLYRULESRESPONSE']._serialized_end=3897 - _globals['_UPDATEHUMANFRIENDLYRULESREQUEST']._serialized_start=3900 - _globals['_UPDATEHUMANFRIENDLYRULESREQUEST']._serialized_end=4051 - _globals['_UPDATEHUMANFRIENDLYRULESRESPONSE']._serialized_start=4054 - _globals['_UPDATEHUMANFRIENDLYRULESRESPONSE']._serialized_end=4194 - _globals['_VIEWJSONRULESREQUEST']._serialized_start=4196 - _globals['_VIEWJSONRULESREQUEST']._serialized_end=4250 - _globals['_VIEWJSONRULESRESPONSE']._serialized_start=4252 - _globals['_VIEWJSONRULESRESPONSE']._serialized_end=4311 - _globals['_JSONRULESREQUEST']._serialized_start=4314 - _globals['_JSONRULESREQUEST']._serialized_end=4446 - _globals['_JSONRULESRESPONSE']._serialized_start=4449 - _globals['_JSONRULESRESPONSE']._serialized_end=4770 - _globals['_VALIDATEJSONRULESREQUEST']._serialized_start=4772 - _globals['_VALIDATEJSONRULESREQUEST']._serialized_end=4862 - _globals['_VALIDATEJSONRULESRESPONSE']._serialized_start=4864 - _globals['_VALIDATEJSONRULESRESPONSE']._serialized_end=4958 - _globals['_UPDATEJSONRULESREQUEST']._serialized_start=4960 - _globals['_UPDATEJSONRULESREQUEST']._serialized_end=5048 - _globals['_UPDATEJSONRULESRESPONSE']._serialized_start=5050 - _globals['_UPDATEJSONRULESRESPONSE']._serialized_end=5142 - _globals['_LISTRULEVERSIONSREQUEST']._serialized_start=5145 - _globals['_LISTRULEVERSIONSREQUEST']._serialized_end=5294 - _globals['_RULEVERSION']._serialized_start=5297 - _globals['_RULEVERSION']._serialized_end=5639 - _globals['_LISTRULEVERSIONSRESPONSE']._serialized_start=5642 - _globals['_LISTRULEVERSIONSRESPONSE']._serialized_end=5778 - _globals['_GETRULEVERSIONREQUEST']._serialized_start=5780 - _globals['_GETRULEVERSIONREQUEST']._serialized_end=5848 - _globals['_GETRULEVERSIONRESPONSE']._serialized_start=5850 - _globals['_GETRULEVERSIONRESPONSE']._serialized_end=5920 - _globals['_BATCHGETRULEVERSIONSREQUEST']._serialized_start=5922 - _globals['_BATCHGETRULEVERSIONSREQUEST']._serialized_end=5998 - _globals['_BATCHGETRULEVERSIONSRESPONSE']._serialized_start=6000 - _globals['_BATCHGETRULEVERSIONSRESPONSE']._serialized_end=6078 - _globals['_RULECONDITIONEXPRESSION']._serialized_start=6081 - _globals['_RULECONDITIONEXPRESSION']._serialized_end=6325 - _globals['_SINGLECHANNELCOMPARISONEXPRESSION']._serialized_start=6328 - _globals['_SINGLECHANNELCOMPARISONEXPRESSION']._serialized_end=6659 - _globals['_LASTVALUETHRESHOLD']._serialized_start=6661 - _globals['_LASTVALUETHRESHOLD']._serialized_end=6681 - _globals['_CALCULATEDCHANNELCONFIG']._serialized_start=6684 - _globals['_CALCULATEDCHANNELCONFIG']._serialized_end=6964 - _globals['_CALCULATEDCHANNELCONFIG_CHANNELREFERENCESENTRY']._serialized_start=6863 - _globals['_CALCULATEDCHANNELCONFIG_CHANNELREFERENCESENTRY']._serialized_end=6964 - _globals['_CHANNELREFERENCE']._serialized_start=6966 - _globals['_CHANNELREFERENCE']._serialized_end=7044 - _globals['_RULEACTIONCONFIGURATION']._serialized_start=7047 - _globals['_RULEACTIONCONFIGURATION']._serialized_end=7255 - _globals['_NOTIFICATIONACTIONCONFIGURATION']._serialized_start=7257 - _globals['_NOTIFICATIONACTIONCONFIGURATION']._serialized_end=7341 - _globals['_ANNOTATIONACTIONCONFIGURATION']._serialized_start=7344 - _globals['_ANNOTATIONACTIONCONFIGURATION']._serialized_end=7559 - _globals['_EVALUATERULESREQUEST']._serialized_start=7562 - _globals['_EVALUATERULESREQUEST']._serialized_end=7828 - _globals['_EVALUATEDANNOTATIONOPTIONS']._serialized_start=7830 - _globals['_EVALUATEDANNOTATIONOPTIONS']._serialized_end=7883 - _globals['_TIMERANGEQUERY']._serialized_start=7886 - _globals['_TIMERANGEQUERY']._serialized_end=8016 - _globals['_EVALUATERULESRESPONSE']._serialized_start=8019 - _globals['_EVALUATERULESRESPONSE']._serialized_end=8181 - _globals['_DRYRUNANNOTATION']._serialized_start=8184 - _globals['_DRYRUNANNOTATION']._serialized_end=8421 - _globals['_RULESERVICE']._serialized_start=8775 - _globals['_RULESERVICE']._serialized_end=12021 + _globals['_RULE']._serialized_end=859 + _globals['_RULECONDITION']._serialized_start=862 + _globals['_RULECONDITION']._serialized_end=1401 + _globals['_RULEACTION']._serialized_start=1404 + _globals['_RULEACTION']._serialized_end=1954 + _globals['_RULEASSETCONFIGURATION']._serialized_start=1956 + _globals['_RULEASSETCONFIGURATION']._serialized_end=2009 + _globals['_SEARCHRULESREQUEST']._serialized_start=2012 + _globals['_SEARCHRULESREQUEST']._serialized_end=2357 + _globals['_SEARCHRULESRESPONSE']._serialized_start=2359 + _globals['_SEARCHRULESRESPONSE']._serialized_end=2455 + _globals['_GETRULEREQUEST']._serialized_start=2457 + _globals['_GETRULEREQUEST']._serialized_end=2539 + _globals['_GETRULERESPONSE']._serialized_start=2541 + _globals['_GETRULERESPONSE']._serialized_end=2604 + _globals['_BATCHGETRULESREQUEST']._serialized_start=2606 + _globals['_BATCHGETRULESREQUEST']._serialized_end=2698 + _globals['_BATCHGETRULESRESPONSE']._serialized_start=2700 + _globals['_BATCHGETRULESRESPONSE']._serialized_end=2771 + _globals['_CREATERULEREQUEST']._serialized_start=2773 + _globals['_CREATERULEREQUEST']._serialized_end=2855 + _globals['_CREATERULERESPONSE']._serialized_start=2857 + _globals['_CREATERULERESPONSE']._serialized_end=2907 + _globals['_UPDATERULEREQUEST']._serialized_start=2910 + _globals['_UPDATERULEREQUEST']._serialized_end=3308 + _globals['_UPDATECONDITIONREQUEST']._serialized_start=3311 + _globals['_UPDATECONDITIONREQUEST']._serialized_end=3556 + _globals['_UPDATEACTIONREQUEST']._serialized_start=3559 + _globals['_UPDATEACTIONREQUEST']._serialized_end=3790 + _globals['_UPDATERULERESPONSE']._serialized_start=3792 + _globals['_UPDATERULERESPONSE']._serialized_end=3842 + _globals['_DELETERULEREQUEST']._serialized_start=3844 + _globals['_DELETERULEREQUEST']._serialized_end=3929 + _globals['_DELETERULERESPONSE']._serialized_start=3931 + _globals['_DELETERULERESPONSE']._serialized_end=3951 + _globals['_VIEWHUMANFRIENDLYRULESREQUEST']._serialized_start=3953 + _globals['_VIEWHUMANFRIENDLYRULESREQUEST']._serialized_end=4020 + _globals['_VIEWHUMANFRIENDLYRULESRESPONSE']._serialized_start=4022 + _globals['_VIEWHUMANFRIENDLYRULESRESPONSE']._serialized_end=4094 + _globals['_UPDATEHUMANFRIENDLYRULESREQUEST']._serialized_start=4097 + _globals['_UPDATEHUMANFRIENDLYRULESREQUEST']._serialized_end=4248 + _globals['_UPDATEHUMANFRIENDLYRULESRESPONSE']._serialized_start=4251 + _globals['_UPDATEHUMANFRIENDLYRULESRESPONSE']._serialized_end=4391 + _globals['_VIEWJSONRULESREQUEST']._serialized_start=4393 + _globals['_VIEWJSONRULESREQUEST']._serialized_end=4447 + _globals['_VIEWJSONRULESRESPONSE']._serialized_start=4449 + _globals['_VIEWJSONRULESRESPONSE']._serialized_end=4508 + _globals['_JSONRULESREQUEST']._serialized_start=4511 + _globals['_JSONRULESREQUEST']._serialized_end=4643 + _globals['_JSONRULESRESPONSE']._serialized_start=4646 + _globals['_JSONRULESRESPONSE']._serialized_end=4967 + _globals['_VALIDATEJSONRULESREQUEST']._serialized_start=4969 + _globals['_VALIDATEJSONRULESREQUEST']._serialized_end=5059 + _globals['_VALIDATEJSONRULESRESPONSE']._serialized_start=5061 + _globals['_VALIDATEJSONRULESRESPONSE']._serialized_end=5155 + _globals['_UPDATEJSONRULESREQUEST']._serialized_start=5157 + _globals['_UPDATEJSONRULESREQUEST']._serialized_end=5245 + _globals['_UPDATEJSONRULESRESPONSE']._serialized_start=5247 + _globals['_UPDATEJSONRULESRESPONSE']._serialized_end=5339 + _globals['_LISTRULEVERSIONSREQUEST']._serialized_start=5342 + _globals['_LISTRULEVERSIONSREQUEST']._serialized_end=5491 + _globals['_RULEVERSION']._serialized_start=5494 + _globals['_RULEVERSION']._serialized_end=5836 + _globals['_LISTRULEVERSIONSRESPONSE']._serialized_start=5839 + _globals['_LISTRULEVERSIONSRESPONSE']._serialized_end=5975 + _globals['_GETRULEVERSIONREQUEST']._serialized_start=5977 + _globals['_GETRULEVERSIONREQUEST']._serialized_end=6045 + _globals['_GETRULEVERSIONRESPONSE']._serialized_start=6047 + _globals['_GETRULEVERSIONRESPONSE']._serialized_end=6117 + _globals['_BATCHGETRULEVERSIONSREQUEST']._serialized_start=6119 + _globals['_BATCHGETRULEVERSIONSREQUEST']._serialized_end=6195 + _globals['_BATCHGETRULEVERSIONSRESPONSE']._serialized_start=6197 + _globals['_BATCHGETRULEVERSIONSRESPONSE']._serialized_end=6275 + _globals['_RULECONDITIONEXPRESSION']._serialized_start=6278 + _globals['_RULECONDITIONEXPRESSION']._serialized_end=6522 + _globals['_SINGLECHANNELCOMPARISONEXPRESSION']._serialized_start=6525 + _globals['_SINGLECHANNELCOMPARISONEXPRESSION']._serialized_end=6856 + _globals['_LASTVALUETHRESHOLD']._serialized_start=6858 + _globals['_LASTVALUETHRESHOLD']._serialized_end=6878 + _globals['_CALCULATEDCHANNELCONFIG']._serialized_start=6881 + _globals['_CALCULATEDCHANNELCONFIG']._serialized_end=7161 + _globals['_CALCULATEDCHANNELCONFIG_CHANNELREFERENCESENTRY']._serialized_start=7060 + _globals['_CALCULATEDCHANNELCONFIG_CHANNELREFERENCESENTRY']._serialized_end=7161 + _globals['_CHANNELREFERENCE']._serialized_start=7163 + _globals['_CHANNELREFERENCE']._serialized_end=7241 + _globals['_RULEACTIONCONFIGURATION']._serialized_start=7244 + _globals['_RULEACTIONCONFIGURATION']._serialized_end=7452 + _globals['_NOTIFICATIONACTIONCONFIGURATION']._serialized_start=7454 + _globals['_NOTIFICATIONACTIONCONFIGURATION']._serialized_end=7538 + _globals['_ANNOTATIONACTIONCONFIGURATION']._serialized_start=7541 + _globals['_ANNOTATIONACTIONCONFIGURATION']._serialized_end=7756 + _globals['_EVALUATERULESREQUEST']._serialized_start=7759 + _globals['_EVALUATERULESREQUEST']._serialized_end=8025 + _globals['_EVALUATEDANNOTATIONOPTIONS']._serialized_start=8027 + _globals['_EVALUATEDANNOTATIONOPTIONS']._serialized_end=8080 + _globals['_TIMERANGEQUERY']._serialized_start=8083 + _globals['_TIMERANGEQUERY']._serialized_end=8213 + _globals['_EVALUATERULESRESPONSE']._serialized_start=8216 + _globals['_EVALUATERULESRESPONSE']._serialized_end=8378 + _globals['_DRYRUNANNOTATION']._serialized_start=8381 + _globals['_DRYRUNANNOTATION']._serialized_end=8618 + _globals['_RULESERVICE']._serialized_start=8972 + _globals['_RULESERVICE']._serialized_end=12218 # @@protoc_insertion_point(module_scope) diff --git a/python/lib/sift/rules/v1/rules_pb2.pyi b/python/lib/sift/rules/v1/rules_pb2.pyi index 5b28967f..b291797d 100644 --- a/python/lib/sift/rules/v1/rules_pb2.pyi +++ b/python/lib/sift/rules/v1/rules_pb2.pyi @@ -103,6 +103,7 @@ class Rule(google.protobuf.message.Message): ORGANIZATION_ID_FIELD_NUMBER: builtins.int CONDITIONS_FIELD_NUMBER: builtins.int RULE_VERSION_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int rule_id: builtins.str asset_id: builtins.str name: builtins.str @@ -111,6 +112,8 @@ class Rule(google.protobuf.message.Message): created_by_user_id: builtins.str modified_by_user_id: builtins.str organization_id: builtins.str + client_key: builtins.str + """client_key is a client provided identifier for the rule. It is immutable after rule creation.""" @property def created_date(self) -> google.protobuf.timestamp_pb2.Timestamp: ... @property @@ -134,9 +137,10 @@ class Rule(google.protobuf.message.Message): organization_id: builtins.str = ..., conditions: collections.abc.Iterable[global___RuleCondition] | None = ..., rule_version: global___RuleVersion | None = ..., + client_key: builtins.str = ..., ) -> None: ... def HasField(self, field_name: typing.Literal["created_date", b"created_date", "modified_date", b"modified_date", "rule_version", b"rule_version"]) -> builtins.bool: ... - def ClearField(self, field_name: typing.Literal["asset_id", b"asset_id", "conditions", b"conditions", "created_by_user_id", b"created_by_user_id", "created_date", b"created_date", "description", b"description", "is_enabled", b"is_enabled", "modified_by_user_id", b"modified_by_user_id", "modified_date", b"modified_date", "name", b"name", "organization_id", b"organization_id", "rule_id", b"rule_id", "rule_version", b"rule_version"]) -> None: ... + def ClearField(self, field_name: typing.Literal["asset_id", b"asset_id", "client_key", b"client_key", "conditions", b"conditions", "created_by_user_id", b"created_by_user_id", "created_date", b"created_date", "description", b"description", "is_enabled", b"is_enabled", "modified_by_user_id", b"modified_by_user_id", "modified_date", b"modified_date", "name", b"name", "organization_id", b"organization_id", "rule_id", b"rule_id", "rule_version", b"rule_version"]) -> None: ... global___Rule = Rule @@ -321,16 +325,21 @@ global___SearchRulesResponse = SearchRulesResponse @typing.final class GetRuleRequest(google.protobuf.message.Message): + """GetRuleRequest is used to retrieve a rule by rule_id or client_key. If both are provided, only rule_id will be used.""" + DESCRIPTOR: google.protobuf.descriptor.Descriptor RULE_ID_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int rule_id: builtins.str + client_key: builtins.str def __init__( self, *, rule_id: builtins.str = ..., + client_key: builtins.str = ..., ) -> None: ... - def ClearField(self, field_name: typing.Literal["rule_id", b"rule_id"]) -> None: ... + def ClearField(self, field_name: typing.Literal["client_key", b"client_key", "rule_id", b"rule_id"]) -> None: ... global___GetRuleRequest = GetRuleRequest @@ -353,17 +362,23 @@ global___GetRuleResponse = GetRuleResponse @typing.final class BatchGetRulesRequest(google.protobuf.message.Message): + """BatchGetRulesRequest is used to retrieve rules by rule_ids or client_keys. If both are provided, both will be used to retrieve rules.""" + DESCRIPTOR: google.protobuf.descriptor.Descriptor RULE_IDS_FIELD_NUMBER: builtins.int + CLIENT_KEYS_FIELD_NUMBER: builtins.int @property def rule_ids(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... + @property + def client_keys(self) -> google.protobuf.internal.containers.RepeatedScalarFieldContainer[builtins.str]: ... def __init__( self, *, rule_ids: collections.abc.Iterable[builtins.str] | None = ..., + client_keys: collections.abc.Iterable[builtins.str] | None = ..., ) -> None: ... - def ClearField(self, field_name: typing.Literal["rule_ids", b"rule_ids"]) -> None: ... + def ClearField(self, field_name: typing.Literal["client_keys", b"client_keys", "rule_ids", b"rule_ids"]) -> None: ... global___BatchGetRulesRequest = BatchGetRulesRequest @@ -417,6 +432,8 @@ global___CreateRuleResponse = CreateRuleResponse @typing.final class UpdateRuleRequest(google.protobuf.message.Message): + """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.""" + DESCRIPTOR: google.protobuf.descriptor.Descriptor RULE_ID_FIELD_NUMBER: builtins.int @@ -427,6 +444,7 @@ class UpdateRuleRequest(google.protobuf.message.Message): CONDITIONS_FIELD_NUMBER: builtins.int ORGANIZATION_ID_FIELD_NUMBER: builtins.int VERSION_NOTES_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int rule_id: builtins.str name: builtins.str description: builtins.str @@ -434,6 +452,7 @@ class UpdateRuleRequest(google.protobuf.message.Message): is_enabled: builtins.bool organization_id: builtins.str version_notes: builtins.str + client_key: builtins.str @property def conditions(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___UpdateConditionRequest]: ... def __init__( @@ -447,9 +466,13 @@ class UpdateRuleRequest(google.protobuf.message.Message): conditions: collections.abc.Iterable[global___UpdateConditionRequest] | None = ..., organization_id: builtins.str = ..., version_notes: builtins.str = ..., + client_key: builtins.str | None = ..., ) -> None: ... - def HasField(self, field_name: typing.Literal["_rule_id", b"_rule_id", "rule_id", b"rule_id"]) -> builtins.bool: ... - def ClearField(self, field_name: typing.Literal["_rule_id", b"_rule_id", "asset_id", b"asset_id", "conditions", b"conditions", "description", b"description", "is_enabled", b"is_enabled", "name", b"name", "organization_id", b"organization_id", "rule_id", b"rule_id", "version_notes", b"version_notes"]) -> None: ... + def HasField(self, field_name: typing.Literal["_client_key", b"_client_key", "_rule_id", b"_rule_id", "client_key", b"client_key", "rule_id", b"rule_id"]) -> builtins.bool: ... + def ClearField(self, field_name: typing.Literal["_client_key", b"_client_key", "_rule_id", b"_rule_id", "asset_id", b"asset_id", "client_key", b"client_key", "conditions", b"conditions", "description", b"description", "is_enabled", b"is_enabled", "name", b"name", "organization_id", b"organization_id", "rule_id", b"rule_id", "version_notes", b"version_notes"]) -> None: ... + @typing.overload + def WhichOneof(self, oneof_group: typing.Literal["_client_key", b"_client_key"]) -> typing.Literal["client_key"] | None: ... + @typing.overload def WhichOneof(self, oneof_group: typing.Literal["_rule_id", b"_rule_id"]) -> typing.Literal["rule_id"] | None: ... global___UpdateRuleRequest = UpdateRuleRequest @@ -520,16 +543,21 @@ global___UpdateRuleResponse = UpdateRuleResponse @typing.final class DeleteRuleRequest(google.protobuf.message.Message): + """DeleteRuleRequest is used to delete a rule by rule_id or client_key. If both are provided, only rule_id will be used.""" + DESCRIPTOR: google.protobuf.descriptor.Descriptor RULE_ID_FIELD_NUMBER: builtins.int + CLIENT_KEY_FIELD_NUMBER: builtins.int rule_id: builtins.str + client_key: builtins.str def __init__( self, *, rule_id: builtins.str = ..., + client_key: builtins.str = ..., ) -> None: ... - def ClearField(self, field_name: typing.Literal["rule_id", b"rule_id"]) -> None: ... + def ClearField(self, field_name: typing.Literal["client_key", b"client_key", "rule_id", b"rule_id"]) -> None: ... global___DeleteRuleRequest = DeleteRuleRequest diff --git a/python/lib/sift/users/v2/users_pb2.py b/python/lib/sift/users/v2/users_pb2.py index d84665f2..648f90bf 100644 --- a/python/lib/sift/users/v2/users_pb2.py +++ b/python/lib/sift/users/v2/users_pb2.py @@ -18,7 +18,7 @@ from sift.common.type.v1 import user_pb2 as sift_dot_common_dot_type_dot_v1_dot_user__pb2 -DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x19sift/users/v2/users.proto\x12\rsift.users.v2\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\x1a\x1esift/common/type/v1/user.proto\"\x7f\n#UpdateUserOrganizationActiveRequest\x12\x17\n\x07user_id\x18\x01 \x01(\tR\x06userId\x12\'\n\x0forganization_id\x18\x02 \x01(\tR\x0eorganizationId\x12\x16\n\x06\x61\x63tive\x18\x03 \x01(\x08R\x06\x61\x63tive\"&\n$UpdateUserOrganizationActiveResponse\".\n\x0eGetUserRequest\x12\x1c\n\x07user_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06userId\"@\n\x0fGetUserResponse\x12-\n\x04user\x18\x01 \x01(\x0b\x32\x19.sift.common.type.v1.UserR\x04user2\xf6\x03\n\x0bUserService\x12\x96\x02\n\x1cUpdateUserOrganizationActive\x12\x32.sift.users.v2.UpdateUserOrganizationActiveRequest\x1a\x33.sift.users.v2.UpdateUserOrganizationActiveResponse\"\x8c\x01\x92\x41`\x12\x1cUpdateUserOrganizationActive\x1a@Used to toggle a user\'s active status within their organization.\x82\xd3\xe4\x93\x02#\"\x1e/api/v2/users/{user_id}/active:\x01*\x12\x8f\x01\n\x07GetUser\x12\x1d.sift.users.v2.GetUserRequest\x1a\x1e.sift.users.v2.GetUserResponse\"E\x92\x41#\x12\x07GetUser\x1a\x18Retrieves a user object.\x82\xd3\xe4\x93\x02\x19\x12\x17/api/v2/users/{user_id}\x1a<\x92\x41\x39\x12\x37Service to programmatically interact with user objects.B\x88\x01\n\x11\x63om.sift.users.v2B\nUsersProtoP\x01\xa2\x02\x03SUX\xaa\x02\rSift.Users.V2\xca\x02\rSift\\Users\\V2\xe2\x02\x19Sift\\Users\\V2\\GPBMetadata\xea\x02\x0fSift::Users::V2\x92\x41\x10\x12\x0e\n\x0cUser Serviceb\x06proto3') +DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x19sift/users/v2/users.proto\x12\rsift.users.v2\x1a\x1cgoogle/api/annotations.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a.protoc-gen-openapiv2/options/annotations.proto\x1a\x1esift/common/type/v1/user.proto\"\x7f\n#UpdateUserOrganizationActiveRequest\x12\x17\n\x07user_id\x18\x01 \x01(\tR\x06userId\x12\'\n\x0forganization_id\x18\x02 \x01(\tR\x0eorganizationId\x12\x16\n\x06\x61\x63tive\x18\x03 \x01(\x08R\x06\x61\x63tive\"&\n$UpdateUserOrganizationActiveResponse\".\n\x0eGetUserRequest\x12\x1c\n\x07user_id\x18\x01 \x01(\tB\x03\xe0\x41\x02R\x06userId\"@\n\x0fGetUserResponse\x12-\n\x04user\x18\x01 \x01(\x0b\x32\x19.sift.common.type.v1.UserR\x04user\"\xa9\x01\n\x16ListActiveUsersRequest\x12 \n\tpage_size\x18\x01 \x01(\rB\x03\xe0\x41\x01R\x08pageSize\x12\"\n\npage_token\x18\x02 \x01(\tB\x03\xe0\x41\x01R\tpageToken\x12\x1b\n\x06\x66ilter\x18\x03 \x01(\tB\x03\xe0\x41\x01R\x06\x66ilter\x12,\n\x0forganization_id\x18\x04 \x01(\tB\x03\xe0\x41\x01R\x0eorganizationId\"r\n\x17ListActiveUsersResponse\x12/\n\x05users\x18\x01 \x03(\x0b\x32\x19.sift.common.type.v1.UserR\x05users\x12&\n\x0fnext_page_token\x18\x02 \x01(\tR\rnextPageToken2\x98\x05\n\x0bUserService\x12\x96\x02\n\x1cUpdateUserOrganizationActive\x12\x32.sift.users.v2.UpdateUserOrganizationActiveRequest\x1a\x33.sift.users.v2.UpdateUserOrganizationActiveResponse\"\x8c\x01\x92\x41`\x12\x1cUpdateUserOrganizationActive\x1a@Used to toggle a user\'s active status within their organization.\x82\xd3\xe4\x93\x02#\"\x1e/api/v2/users/{user_id}/active:\x01*\x12\x8f\x01\n\x07GetUser\x12\x1d.sift.users.v2.GetUserRequest\x1a\x1e.sift.users.v2.GetUserResponse\"E\x92\x41#\x12\x07GetUser\x1a\x18Retrieves a user object.\x82\xd3\xe4\x93\x02\x19\x12\x17/api/v2/users/{user_id}\x12\x9f\x01\n\x0fListActiveUsers\x12%.sift.users.v2.ListActiveUsersRequest\x1a&.sift.users.v2.ListActiveUsersResponse\"=\x92\x41%\x12\x0fListActiveUsers\x1a\x12List active users.\x82\xd3\xe4\x93\x02\x0f\x12\r/api/v2/users\x1a<\x92\x41\x39\x12\x37Service to programmatically interact with user objects.B\x88\x01\n\x11\x63om.sift.users.v2B\nUsersProtoP\x01\xa2\x02\x03SUX\xaa\x02\rSift.Users.V2\xca\x02\rSift\\Users\\V2\xe2\x02\x19Sift\\Users\\V2\\GPBMetadata\xea\x02\x0fSift::Users::V2\x92\x41\x10\x12\x0e\n\x0cUser Serviceb\x06proto3') _globals = globals() _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals) @@ -28,12 +28,22 @@ _globals['DESCRIPTOR']._serialized_options = b'\n\021com.sift.users.v2B\nUsersProtoP\001\242\002\003SUX\252\002\rSift.Users.V2\312\002\rSift\\Users\\V2\342\002\031Sift\\Users\\V2\\GPBMetadata\352\002\017Sift::Users::V2\222A\020\022\016\n\014User Service' _globals['_GETUSERREQUEST'].fields_by_name['user_id']._loaded_options = None _globals['_GETUSERREQUEST'].fields_by_name['user_id']._serialized_options = b'\340A\002' + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['page_size']._loaded_options = None + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['page_size']._serialized_options = b'\340A\001' + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['page_token']._loaded_options = None + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['page_token']._serialized_options = b'\340A\001' + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['filter']._loaded_options = None + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['filter']._serialized_options = b'\340A\001' + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['organization_id']._loaded_options = None + _globals['_LISTACTIVEUSERSREQUEST'].fields_by_name['organization_id']._serialized_options = b'\340A\001' _globals['_USERSERVICE']._loaded_options = None _globals['_USERSERVICE']._serialized_options = b'\222A9\0227Service to programmatically interact with user objects.' _globals['_USERSERVICE'].methods_by_name['UpdateUserOrganizationActive']._loaded_options = None _globals['_USERSERVICE'].methods_by_name['UpdateUserOrganizationActive']._serialized_options = b'\222A`\022\034UpdateUserOrganizationActive\032@Used to toggle a user\'s active status within their organization.\202\323\344\223\002#\"\036/api/v2/users/{user_id}/active:\001*' _globals['_USERSERVICE'].methods_by_name['GetUser']._loaded_options = None _globals['_USERSERVICE'].methods_by_name['GetUser']._serialized_options = b'\222A#\022\007GetUser\032\030Retrieves a user object.\202\323\344\223\002\031\022\027/api/v2/users/{user_id}' + _globals['_USERSERVICE'].methods_by_name['ListActiveUsers']._loaded_options = None + _globals['_USERSERVICE'].methods_by_name['ListActiveUsers']._serialized_options = b'\222A%\022\017ListActiveUsers\032\022List active users.\202\323\344\223\002\017\022\r/api/v2/users' _globals['_UPDATEUSERORGANIZATIONACTIVEREQUEST']._serialized_start=187 _globals['_UPDATEUSERORGANIZATIONACTIVEREQUEST']._serialized_end=314 _globals['_UPDATEUSERORGANIZATIONACTIVERESPONSE']._serialized_start=316 @@ -42,6 +52,10 @@ _globals['_GETUSERREQUEST']._serialized_end=402 _globals['_GETUSERRESPONSE']._serialized_start=404 _globals['_GETUSERRESPONSE']._serialized_end=468 - _globals['_USERSERVICE']._serialized_start=471 - _globals['_USERSERVICE']._serialized_end=973 + _globals['_LISTACTIVEUSERSREQUEST']._serialized_start=471 + _globals['_LISTACTIVEUSERSREQUEST']._serialized_end=640 + _globals['_LISTACTIVEUSERSRESPONSE']._serialized_start=642 + _globals['_LISTACTIVEUSERSRESPONSE']._serialized_end=756 + _globals['_USERSERVICE']._serialized_start=759 + _globals['_USERSERVICE']._serialized_end=1423 # @@protoc_insertion_point(module_scope) diff --git a/python/lib/sift/users/v2/users_pb2.pyi b/python/lib/sift/users/v2/users_pb2.pyi index 270cb2ee..b3aaf7fb 100644 --- a/python/lib/sift/users/v2/users_pb2.pyi +++ b/python/lib/sift/users/v2/users_pb2.pyi @@ -4,7 +4,9 @@ isort:skip_file """ import builtins +import collections.abc import google.protobuf.descriptor +import google.protobuf.internal.containers import google.protobuf.message import sift.common.type.v1.user_pb2 import typing @@ -76,3 +78,65 @@ class GetUserResponse(google.protobuf.message.Message): def ClearField(self, field_name: typing.Literal["user", b"user"]) -> None: ... global___GetUserResponse = GetUserResponse + +@typing.final +class ListActiveUsersRequest(google.protobuf.message.Message): + """The request for a call to `UserService_ListActiveUsers` to retrieve users.""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + PAGE_SIZE_FIELD_NUMBER: builtins.int + PAGE_TOKEN_FIELD_NUMBER: builtins.int + FILTER_FIELD_NUMBER: builtins.int + ORGANIZATION_ID_FIELD_NUMBER: builtins.int + page_size: builtins.int + """The maximum number of users to return. The service may return fewer than this value. + If unspecified, at most 50 users will be returned. The maximum value is 1000; values above + 1000 will be coerced to 1000. Optional. + """ + page_token: builtins.str + """A page token, received from a previous `ListActiveUsers` call. + Provide this to retrieve the subsequent page. + When paginating, all other parameters provided to `ListActiveUsers` must match + the call that provided the page token. Optional. + """ + filter: builtins.str + """A [Common Expression Language (CEL)](https://github.com/google/cel-spec) filter string. + Available fields to filter by are `user_id` and `name`. + For further information about how to use CELs, please refer to [this guide](https://github.com/google/cel-spec/blob/master/doc/langdef.md#standard-definitions). + For more information about the fields used for filtering, please refer to [this definition](/protocol-buffers/documentation#users). Optional. + """ + organization_id: builtins.str + """Optional. If provided, this will scope down the user search to just those in the organization ID provided.""" + def __init__( + self, + *, + page_size: builtins.int = ..., + page_token: builtins.str = ..., + filter: builtins.str = ..., + organization_id: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["filter", b"filter", "organization_id", b"organization_id", "page_size", b"page_size", "page_token", b"page_token"]) -> None: ... + +global___ListActiveUsersRequest = ListActiveUsersRequest + +@typing.final +class ListActiveUsersResponse(google.protobuf.message.Message): + """The response of a call to `UserService_ListActiveUsersResponse`.""" + + DESCRIPTOR: google.protobuf.descriptor.Descriptor + + USERS_FIELD_NUMBER: builtins.int + NEXT_PAGE_TOKEN_FIELD_NUMBER: builtins.int + next_page_token: builtins.str + @property + def users(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[sift.common.type.v1.user_pb2.User]: ... + def __init__( + self, + *, + users: collections.abc.Iterable[sift.common.type.v1.user_pb2.User] | None = ..., + next_page_token: builtins.str = ..., + ) -> None: ... + def ClearField(self, field_name: typing.Literal["next_page_token", b"next_page_token", "users", b"users"]) -> None: ... + +global___ListActiveUsersResponse = ListActiveUsersResponse diff --git a/python/lib/sift/users/v2/users_pb2_grpc.py b/python/lib/sift/users/v2/users_pb2_grpc.py index f79790df..4a75ce29 100644 --- a/python/lib/sift/users/v2/users_pb2_grpc.py +++ b/python/lib/sift/users/v2/users_pb2_grpc.py @@ -24,6 +24,11 @@ def __init__(self, channel): request_serializer=sift_dot_users_dot_v2_dot_users__pb2.GetUserRequest.SerializeToString, response_deserializer=sift_dot_users_dot_v2_dot_users__pb2.GetUserResponse.FromString, ) + self.ListActiveUsers = channel.unary_unary( + '/sift.users.v2.UserService/ListActiveUsers', + request_serializer=sift_dot_users_dot_v2_dot_users__pb2.ListActiveUsersRequest.SerializeToString, + response_deserializer=sift_dot_users_dot_v2_dot_users__pb2.ListActiveUsersResponse.FromString, + ) class UserServiceServicer(object): @@ -43,6 +48,13 @@ def GetUser(self, request, context): context.set_details('Method not implemented!') raise NotImplementedError('Method not implemented!') + def ListActiveUsers(self, request, context): + """List active users. + """ + context.set_code(grpc.StatusCode.UNIMPLEMENTED) + context.set_details('Method not implemented!') + raise NotImplementedError('Method not implemented!') + def add_UserServiceServicer_to_server(servicer, server): rpc_method_handlers = { @@ -56,6 +68,11 @@ def add_UserServiceServicer_to_server(servicer, server): request_deserializer=sift_dot_users_dot_v2_dot_users__pb2.GetUserRequest.FromString, response_serializer=sift_dot_users_dot_v2_dot_users__pb2.GetUserResponse.SerializeToString, ), + 'ListActiveUsers': grpc.unary_unary_rpc_method_handler( + servicer.ListActiveUsers, + request_deserializer=sift_dot_users_dot_v2_dot_users__pb2.ListActiveUsersRequest.FromString, + response_serializer=sift_dot_users_dot_v2_dot_users__pb2.ListActiveUsersResponse.SerializeToString, + ), } generic_handler = grpc.method_handlers_generic_handler( 'sift.users.v2.UserService', rpc_method_handlers) @@ -99,3 +116,20 @@ def GetUser(request, sift_dot_users_dot_v2_dot_users__pb2.GetUserResponse.FromString, options, channel_credentials, insecure, call_credentials, compression, wait_for_ready, timeout, metadata) + + @staticmethod + def ListActiveUsers(request, + target, + options=(), + channel_credentials=None, + call_credentials=None, + insecure=False, + compression=None, + wait_for_ready=None, + timeout=None, + metadata=None): + return grpc.experimental.unary_unary(request, target, '/sift.users.v2.UserService/ListActiveUsers', + sift_dot_users_dot_v2_dot_users__pb2.ListActiveUsersRequest.SerializeToString, + sift_dot_users_dot_v2_dot_users__pb2.ListActiveUsersResponse.FromString, + options, channel_credentials, + insecure, call_credentials, compression, wait_for_ready, timeout, metadata) diff --git a/python/lib/sift/users/v2/users_pb2_grpc.pyi b/python/lib/sift/users/v2/users_pb2_grpc.pyi index 1db066ce..f4f5eb28 100644 --- a/python/lib/sift/users/v2/users_pb2_grpc.pyi +++ b/python/lib/sift/users/v2/users_pb2_grpc.pyi @@ -31,6 +31,12 @@ class UserServiceStub: ] """Retrieves a user object.""" + ListActiveUsers: grpc.UnaryUnaryMultiCallable[ + sift.users.v2.users_pb2.ListActiveUsersRequest, + sift.users.v2.users_pb2.ListActiveUsersResponse, + ] + """List active users.""" + class UserServiceAsyncStub: UpdateUserOrganizationActive: grpc.aio.UnaryUnaryMultiCallable[ sift.users.v2.users_pb2.UpdateUserOrganizationActiveRequest, @@ -44,6 +50,12 @@ class UserServiceAsyncStub: ] """Retrieves a user object.""" + ListActiveUsers: grpc.aio.UnaryUnaryMultiCallable[ + sift.users.v2.users_pb2.ListActiveUsersRequest, + sift.users.v2.users_pb2.ListActiveUsersResponse, + ] + """List active users.""" + class UserServiceServicer(metaclass=abc.ABCMeta): @abc.abstractmethod def UpdateUserOrganizationActive( @@ -61,4 +73,12 @@ class UserServiceServicer(metaclass=abc.ABCMeta): ) -> typing.Union[sift.users.v2.users_pb2.GetUserResponse, collections.abc.Awaitable[sift.users.v2.users_pb2.GetUserResponse]]: """Retrieves a user object.""" + @abc.abstractmethod + def ListActiveUsers( + self, + request: sift.users.v2.users_pb2.ListActiveUsersRequest, + context: _ServicerContext, + ) -> typing.Union[sift.users.v2.users_pb2.ListActiveUsersResponse, collections.abc.Awaitable[sift.users.v2.users_pb2.ListActiveUsersResponse]]: + """List active users.""" + def add_UserServiceServicer_to_server(servicer: UserServiceServicer, server: typing.Union[grpc.Server, grpc.aio.Server]) -> None: ...