From 37a9bd9b2fa1f427a1b676160b930e3bf0a582da Mon Sep 17 00:00:00 2001 From: Richard Hua Date: Wed, 31 Jul 2024 10:07:42 -0700 Subject: [PATCH] Regenerate protos --- dev/docker/down | 5 + dev/down | 4 + dev/generate | 2 +- pkg/api/service.go | 4 +- .../identity/associations/signature.pb.go | 171 +++--- .../private_preferences.pb.go | 12 +- pkg/proto/mls/database/intents.pb.go | 580 ++++++++++++++---- .../mls/message_contents/group_metadata.pb.go | 226 ++++++- .../identity/api/v1/identity.swagger.json | 48 +- .../mls_validation/v1/service.swagger.json | 48 +- .../message_api/message_api.swagger.json | 58 +- .../xmtpv4/message_api/message_api.pb.go | 442 ++++++------- .../xmtpv4/message_api/message_api.pb.gw.go | 18 +- .../xmtpv4/message_api/message_api_grpc.pb.go | 50 +- 14 files changed, 1116 insertions(+), 552 deletions(-) create mode 100755 dev/docker/down create mode 100755 dev/down diff --git a/dev/docker/down b/dev/docker/down new file mode 100755 index 00000000..94991e9f --- /dev/null +++ b/dev/docker/down @@ -0,0 +1,5 @@ +#!/usr/bin/env sh +set -e +. dev/docker/env + +docker_compose down diff --git a/dev/down b/dev/down new file mode 100755 index 00000000..48df8515 --- /dev/null +++ b/dev/down @@ -0,0 +1,4 @@ +#!/bin/bash +set -e + +dev/docker/down diff --git a/dev/generate b/dev/generate index 359ce990..b83609ef 100755 --- a/dev/generate +++ b/dev/generate @@ -5,7 +5,7 @@ go generate ./... # TODO: Generate mocks rm -rf pkg/proto/**/*.pb.go pkg/proto/**/*.pb.gw.go pkg/proto/**/*.swagger.json -if ! buf generate https://github.com/xmtp/proto.git#branch=rich/xmtpv4,subdir=proto; then +if ! buf generate https://github.com/xmtp/proto.git#subdir=proto; then echo "Failed to generate protobuf definitions" exit 1 fi \ No newline at end of file diff --git a/pkg/api/service.go b/pkg/api/service.go index 301361e4..6cb9d13a 100644 --- a/pkg/api/service.go +++ b/pkg/api/service.go @@ -21,8 +21,8 @@ func NewReplicationApiService(ctx context.Context, log *zap.Logger) (message_api return &Service{ctx: ctx, log: log}, nil } -func (s *Service) SubscribeEnvelopes(req *message_api.BatchSubscribeEnvelopesRequest, server message_api.ReplicationApi_SubscribeEnvelopesServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeEnvelopes not implemented") +func (s *Service) BatchSubscribeEnvelopes(req *message_api.BatchSubscribeEnvelopesRequest, server message_api.ReplicationApi_BatchSubscribeEnvelopesServer) error { + return status.Errorf(codes.Unimplemented, "method BatchSubscribeEnvelopes not implemented") } func (s *Service) QueryEnvelopes(ctx context.Context, req *message_api.QueryEnvelopesRequest) (*message_api.QueryEnvelopesResponse, error) { diff --git a/pkg/proto/identity/associations/signature.pb.go b/pkg/proto/identity/associations/signature.pb.go index 3ce57376..5ea0023e 100644 --- a/pkg/proto/identity/associations/signature.pb.go +++ b/pkg/proto/identity/associations/signature.pb.go @@ -130,23 +130,25 @@ func (x *RecoverableEd25519Signature) GetPublicKey() []byte { return nil } -// Smart wallet signature -type Erc1271Signature struct { +// Smart Contract Wallet signature +type SmartContractWalletSignature struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // CAIP-10 + // CAIP-10 string // https://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md AccountId string `protobuf:"bytes,1,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` // Specify the block number to verify the signature against BlockNumber uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` // The actual signature bytes Signature []byte `protobuf:"bytes,3,opt,name=signature,proto3" json:"signature,omitempty"` + // The RPC URL specifies a chain to verify the signature against + ChainRpcUrl string `protobuf:"bytes,4,opt,name=chain_rpc_url,json=chainRpcUrl,proto3" json:"chain_rpc_url,omitempty"` } -func (x *Erc1271Signature) Reset() { - *x = Erc1271Signature{} +func (x *SmartContractWalletSignature) Reset() { + *x = SmartContractWalletSignature{} if protoimpl.UnsafeEnabled { mi := &file_identity_associations_signature_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -154,13 +156,13 @@ func (x *Erc1271Signature) Reset() { } } -func (x *Erc1271Signature) String() string { +func (x *SmartContractWalletSignature) String() string { return protoimpl.X.MessageStringOf(x) } -func (*Erc1271Signature) ProtoMessage() {} +func (*SmartContractWalletSignature) ProtoMessage() {} -func (x *Erc1271Signature) ProtoReflect() protoreflect.Message { +func (x *SmartContractWalletSignature) ProtoReflect() protoreflect.Message { mi := &file_identity_associations_signature_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -172,32 +174,39 @@ func (x *Erc1271Signature) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use Erc1271Signature.ProtoReflect.Descriptor instead. -func (*Erc1271Signature) Descriptor() ([]byte, []int) { +// Deprecated: Use SmartContractWalletSignature.ProtoReflect.Descriptor instead. +func (*SmartContractWalletSignature) Descriptor() ([]byte, []int) { return file_identity_associations_signature_proto_rawDescGZIP(), []int{2} } -func (x *Erc1271Signature) GetAccountId() string { +func (x *SmartContractWalletSignature) GetAccountId() string { if x != nil { return x.AccountId } return "" } -func (x *Erc1271Signature) GetBlockNumber() uint64 { +func (x *SmartContractWalletSignature) GetBlockNumber() uint64 { if x != nil { return x.BlockNumber } return 0 } -func (x *Erc1271Signature) GetSignature() []byte { +func (x *SmartContractWalletSignature) GetSignature() []byte { if x != nil { return x.Signature } return nil } +func (x *SmartContractWalletSignature) GetChainRpcUrl() string { + if x != nil { + return x.ChainRpcUrl + } + return "" +} + // An existing address on xmtpv2 may have already signed a legacy identity key // of type SignedPublicKey via the 'Create Identity' signature. // For migration to xmtpv3, the legacy key is permitted to sign on behalf of the @@ -274,7 +283,7 @@ type Signature struct { // Types that are assignable to Signature: // // *Signature_Erc_191 - // *Signature_Erc_1271 + // *Signature_Erc_6492 // *Signature_InstallationKey // *Signature_DelegatedErc_191 Signature isSignature_Signature `protobuf_oneof:"signature"` @@ -326,9 +335,9 @@ func (x *Signature) GetErc_191() *RecoverableEcdsaSignature { return nil } -func (x *Signature) GetErc_1271() *Erc1271Signature { - if x, ok := x.GetSignature().(*Signature_Erc_1271); ok { - return x.Erc_1271 +func (x *Signature) GetErc_6492() *SmartContractWalletSignature { + if x, ok := x.GetSignature().(*Signature_Erc_6492); ok { + return x.Erc_6492 } return nil } @@ -355,8 +364,8 @@ type Signature_Erc_191 struct { Erc_191 *RecoverableEcdsaSignature `protobuf:"bytes,1,opt,name=erc_191,json=erc191,proto3,oneof"` } -type Signature_Erc_1271 struct { - Erc_1271 *Erc1271Signature `protobuf:"bytes,2,opt,name=erc_1271,json=erc1271,proto3,oneof"` +type Signature_Erc_6492 struct { + Erc_6492 *SmartContractWalletSignature `protobuf:"bytes,2,opt,name=erc_6492,json=erc6492,proto3,oneof"` } type Signature_InstallationKey struct { @@ -369,7 +378,7 @@ type Signature_DelegatedErc_191 struct { func (*Signature_Erc_191) isSignature_Signature() {} -func (*Signature_Erc_1271) isSignature_Signature() {} +func (*Signature_Erc_6492) isSignature_Signature() {} func (*Signature_InstallationKey) isSignature_Signature() {} @@ -392,66 +401,70 @@ var file_identity_associations_signature_proto_rawDesc = []byte{ 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x62, 0x79, 0x74, 0x65, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x22, 0x72, 0x0a, - 0x10, 0x45, 0x72, 0x63, 0x31, 0x32, 0x37, 0x31, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, - 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, - 0x62, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, - 0x65, 0x22, 0xbc, 0x01, 0x0a, 0x18, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x6c, 0x65, - 0x67, 0x61, 0x74, 0x65, 0x64, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x4b, - 0x0a, 0x0d, 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x6b, 0x65, 0x79, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x53, 0x69, - 0x67, 0x6e, 0x65, 0x64, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x52, 0x0c, 0x64, - 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x53, 0x0a, 0x09, 0x73, - 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x35, - 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, - 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x52, 0x65, 0x63, 0x6f, - 0x76, 0x65, 0x72, 0x61, 0x62, 0x6c, 0x65, 0x45, 0x63, 0x64, 0x73, 0x61, 0x53, 0x69, 0x67, 0x6e, - 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x22, 0xff, 0x02, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x50, - 0x0a, 0x07, 0x65, 0x72, 0x63, 0x5f, 0x31, 0x39, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x28, 0x0c, 0x52, 0x09, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x22, 0xa2, 0x01, + 0x0a, 0x1c, 0x53, 0x6d, 0x61, 0x72, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x57, + 0x61, 0x6c, 0x6c, 0x65, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x1d, + 0x0a, 0x0a, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x49, 0x64, 0x12, 0x21, 0x0a, + 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x04, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x12, 0x1c, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, 0x22, + 0x0a, 0x0d, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x72, 0x70, 0x63, 0x5f, 0x75, 0x72, 0x6c, 0x18, + 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x52, 0x70, 0x63, 0x55, + 0x72, 0x6c, 0x22, 0xbc, 0x01, 0x0a, 0x18, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x6c, + 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, + 0x4b, 0x0a, 0x0d, 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x6b, 0x65, 0x79, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x26, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x65, + 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x53, + 0x69, 0x67, 0x6e, 0x65, 0x64, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x52, 0x0c, + 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x4b, 0x65, 0x79, 0x12, 0x53, 0x0a, 0x09, + 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x35, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x52, 0x65, 0x63, 0x6f, 0x76, 0x65, 0x72, 0x61, 0x62, 0x6c, 0x65, 0x45, 0x63, 0x64, 0x73, 0x61, 0x53, 0x69, 0x67, - 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x48, 0x00, 0x52, 0x06, 0x65, 0x72, 0x63, 0x31, 0x39, 0x31, - 0x12, 0x49, 0x0a, 0x08, 0x65, 0x72, 0x63, 0x5f, 0x31, 0x32, 0x37, 0x31, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x2c, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, + 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x52, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, + 0x65, 0x22, 0x8b, 0x03, 0x0a, 0x09, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x12, + 0x50, 0x0a, 0x07, 0x65, 0x72, 0x63, 0x5f, 0x31, 0x39, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x35, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, + 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x52, 0x65, + 0x63, 0x6f, 0x76, 0x65, 0x72, 0x61, 0x62, 0x6c, 0x65, 0x45, 0x63, 0x64, 0x73, 0x61, 0x53, 0x69, + 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x48, 0x00, 0x52, 0x06, 0x65, 0x72, 0x63, 0x31, 0x39, + 0x31, 0x12, 0x55, 0x0a, 0x08, 0x65, 0x72, 0x63, 0x5f, 0x36, 0x34, 0x39, 0x32, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x38, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, + 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, + 0x2e, 0x53, 0x6d, 0x61, 0x72, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x57, 0x61, + 0x6c, 0x6c, 0x65, 0x74, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x48, 0x00, 0x52, + 0x07, 0x65, 0x72, 0x63, 0x36, 0x34, 0x39, 0x32, 0x12, 0x64, 0x0a, 0x10, 0x69, 0x6e, 0x73, 0x74, + 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x0b, 0x32, 0x37, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, - 0x45, 0x72, 0x63, 0x31, 0x32, 0x37, 0x31, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x48, 0x00, 0x52, 0x07, 0x65, 0x72, 0x63, 0x31, 0x32, 0x37, 0x31, 0x12, 0x64, 0x0a, 0x10, 0x69, - 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6b, 0x65, 0x79, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x37, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, + 0x52, 0x65, 0x63, 0x6f, 0x76, 0x65, 0x72, 0x61, 0x62, 0x6c, 0x65, 0x45, 0x64, 0x32, 0x35, 0x35, + 0x31, 0x39, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x48, 0x00, 0x52, 0x0f, 0x69, + 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4b, 0x65, 0x79, 0x12, 0x62, + 0x0a, 0x11, 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x65, 0x72, 0x63, 0x5f, + 0x31, 0x39, 0x31, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x34, 0x2e, 0x78, 0x6d, 0x74, 0x70, + 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, 0x44, 0x65, 0x6c, + 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x48, + 0x00, 0x52, 0x0f, 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x45, 0x72, 0x63, 0x31, + 0x39, 0x31, 0x42, 0x0b, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x42, + 0xf1, 0x01, 0x0a, 0x1e, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x2e, 0x52, 0x65, 0x63, 0x6f, 0x76, 0x65, 0x72, 0x61, 0x62, 0x6c, 0x65, 0x45, 0x64, - 0x32, 0x35, 0x35, 0x31, 0x39, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x48, 0x00, - 0x52, 0x0f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4b, 0x65, - 0x79, 0x12, 0x62, 0x0a, 0x11, 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x65, - 0x72, 0x63, 0x5f, 0x31, 0x39, 0x31, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x34, 0x2e, 0x78, - 0x6d, 0x74, 0x70, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, - 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x4c, 0x65, 0x67, 0x61, 0x63, 0x79, - 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x48, 0x00, 0x52, 0x0f, 0x64, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x64, 0x45, - 0x72, 0x63, 0x31, 0x39, 0x31, 0x42, 0x0b, 0x0a, 0x09, 0x73, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, - 0x72, 0x65, 0x42, 0xf1, 0x01, 0x0a, 0x1e, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, - 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2e, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x42, 0x0e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, - 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x35, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, - 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, 0x2f, 0x70, - 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, - 0x79, 0x2f, 0x61, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xa2, 0x02, - 0x03, 0x58, 0x49, 0x41, 0xaa, 0x02, 0x1a, 0x58, 0x6d, 0x74, 0x70, 0x2e, 0x49, 0x64, 0x65, 0x6e, - 0x74, 0x69, 0x74, 0x79, 0x2e, 0x41, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x73, 0xca, 0x02, 0x1a, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, - 0x79, 0x5c, 0x41, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xe2, 0x02, - 0x26, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5c, 0x41, - 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, - 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1c, 0x58, 0x6d, 0x74, 0x70, 0x3a, 0x3a, - 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x3a, 0x3a, 0x41, 0x73, 0x73, 0x6f, 0x63, 0x69, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6e, 0x73, 0x42, 0x0e, 0x53, 0x69, 0x67, 0x6e, 0x61, 0x74, 0x75, 0x72, 0x65, 0x50, 0x72, 0x6f, + 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x35, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, + 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, 0x2f, 0x70, 0x6b, 0x67, 0x2f, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x2f, 0x61, + 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xa2, 0x02, 0x03, 0x58, 0x49, + 0x41, 0xaa, 0x02, 0x1a, 0x58, 0x6d, 0x74, 0x70, 0x2e, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, + 0x79, 0x2e, 0x41, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xca, 0x02, + 0x1a, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5c, 0x41, + 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0xe2, 0x02, 0x26, 0x58, 0x6d, + 0x74, 0x70, 0x5c, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x5c, 0x41, 0x73, 0x73, 0x6f, + 0x63, 0x69, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1c, 0x58, 0x6d, 0x74, 0x70, 0x3a, 0x3a, 0x49, 0x64, 0x65, + 0x6e, 0x74, 0x69, 0x74, 0x79, 0x3a, 0x3a, 0x41, 0x73, 0x73, 0x6f, 0x63, 0x69, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -470,7 +483,7 @@ var file_identity_associations_signature_proto_msgTypes = make([]protoimpl.Messa var file_identity_associations_signature_proto_goTypes = []any{ (*RecoverableEcdsaSignature)(nil), // 0: xmtp.identity.associations.RecoverableEcdsaSignature (*RecoverableEd25519Signature)(nil), // 1: xmtp.identity.associations.RecoverableEd25519Signature - (*Erc1271Signature)(nil), // 2: xmtp.identity.associations.Erc1271Signature + (*SmartContractWalletSignature)(nil), // 2: xmtp.identity.associations.SmartContractWalletSignature (*LegacyDelegatedSignature)(nil), // 3: xmtp.identity.associations.LegacyDelegatedSignature (*Signature)(nil), // 4: xmtp.identity.associations.Signature (*message_contents.SignedPublicKey)(nil), // 5: xmtp.message_contents.SignedPublicKey @@ -479,7 +492,7 @@ var file_identity_associations_signature_proto_depIdxs = []int32{ 5, // 0: xmtp.identity.associations.LegacyDelegatedSignature.delegated_key:type_name -> xmtp.message_contents.SignedPublicKey 0, // 1: xmtp.identity.associations.LegacyDelegatedSignature.signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature 0, // 2: xmtp.identity.associations.Signature.erc_191:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature - 2, // 3: xmtp.identity.associations.Signature.erc_1271:type_name -> xmtp.identity.associations.Erc1271Signature + 2, // 3: xmtp.identity.associations.Signature.erc_6492:type_name -> xmtp.identity.associations.SmartContractWalletSignature 1, // 4: xmtp.identity.associations.Signature.installation_key:type_name -> xmtp.identity.associations.RecoverableEd25519Signature 3, // 5: xmtp.identity.associations.Signature.delegated_erc_191:type_name -> xmtp.identity.associations.LegacyDelegatedSignature 6, // [6:6] is the sub-list for method output_type @@ -520,7 +533,7 @@ func file_identity_associations_signature_proto_init() { } } file_identity_associations_signature_proto_msgTypes[2].Exporter = func(v any, i int) any { - switch v := v.(*Erc1271Signature); i { + switch v := v.(*SmartContractWalletSignature); i { case 0: return &v.state case 1: @@ -558,7 +571,7 @@ func file_identity_associations_signature_proto_init() { } file_identity_associations_signature_proto_msgTypes[4].OneofWrappers = []any{ (*Signature_Erc_191)(nil), - (*Signature_Erc_1271)(nil), + (*Signature_Erc_6492)(nil), (*Signature_InstallationKey)(nil), (*Signature_DelegatedErc_191)(nil), } diff --git a/pkg/proto/message_contents/private_preferences.pb.go b/pkg/proto/message_contents/private_preferences.pb.go index 5bf8e0b1..911a207a 100644 --- a/pkg/proto/message_contents/private_preferences.pb.go +++ b/pkg/proto/message_contents/private_preferences.pb.go @@ -435,7 +435,7 @@ type PrivatePreferencesAction_AllowGroup struct { unknownFields protoimpl.UnknownFields // Add the given group_ids to the allow list - GroupIds [][]byte `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` + GroupIds []string `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` } func (x *PrivatePreferencesAction_AllowGroup) Reset() { @@ -470,7 +470,7 @@ func (*PrivatePreferencesAction_AllowGroup) Descriptor() ([]byte, []int) { return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 4} } -func (x *PrivatePreferencesAction_AllowGroup) GetGroupIds() [][]byte { +func (x *PrivatePreferencesAction_AllowGroup) GetGroupIds() []string { if x != nil { return x.GroupIds } @@ -484,7 +484,7 @@ type PrivatePreferencesAction_DenyGroup struct { unknownFields protoimpl.UnknownFields // Add the given group_ids to the deny list - GroupIds [][]byte `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` + GroupIds []string `protobuf:"bytes,1,rep,name=group_ids,json=groupIds,proto3" json:"group_ids,omitempty"` } func (x *PrivatePreferencesAction_DenyGroup) Reset() { @@ -519,7 +519,7 @@ func (*PrivatePreferencesAction_DenyGroup) Descriptor() ([]byte, []int) { return file_message_contents_private_preferences_proto_rawDescGZIP(), []int{0, 5} } -func (x *PrivatePreferencesAction_DenyGroup) GetGroupIds() [][]byte { +func (x *PrivatePreferencesAction_DenyGroup) GetGroupIds() []string { if x != nil { return x.GroupIds } @@ -588,10 +588,10 @@ var file_message_contents_private_preferences_proto_rawDesc = []byte{ 0x1b, 0x0a, 0x09, 0x69, 0x6e, 0x62, 0x6f, 0x78, 0x5f, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x69, 0x6e, 0x62, 0x6f, 0x78, 0x49, 0x64, 0x73, 0x1a, 0x29, 0x0a, 0x0a, 0x41, 0x6c, 0x6c, 0x6f, 0x77, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1b, 0x0a, 0x09, 0x67, 0x72, - 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x08, 0x67, + 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x73, 0x1a, 0x28, 0x0a, 0x09, 0x44, 0x65, 0x6e, 0x79, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x12, 0x1b, 0x0a, 0x09, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x69, 0x64, - 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, + 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x08, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x49, 0x64, 0x73, 0x42, 0x0e, 0x0a, 0x0c, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x22, 0x5b, 0x0a, 0x19, 0x50, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x50, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x12, 0x33, diff --git a/pkg/proto/mls/database/intents.pb.go b/pkg/proto/mls/database/intents.pb.go index aab315e9..9894bf63 100644 --- a/pkg/proto/mls/database/intents.pb.go +++ b/pkg/proto/mls/database/intents.pb.go @@ -78,6 +78,121 @@ func (AdminListUpdateType) EnumDescriptor() ([]byte, []int) { return file_mls_database_intents_proto_rawDescGZIP(), []int{0} } +// Type of Permission to Update +type PermissionUpdateType int32 + +const ( + PermissionUpdateType_PERMISSION_UPDATE_TYPE_UNSPECIFIED PermissionUpdateType = 0 + PermissionUpdateType_PERMISSION_UPDATE_TYPE_ADD_MEMBER PermissionUpdateType = 1 + PermissionUpdateType_PERMISSION_UPDATE_TYPE_REMOVE_MEMBER PermissionUpdateType = 2 + PermissionUpdateType_PERMISSION_UPDATE_TYPE_ADD_ADMIN PermissionUpdateType = 3 + PermissionUpdateType_PERMISSION_UPDATE_TYPE_REMOVE_ADMIN PermissionUpdateType = 4 + PermissionUpdateType_PERMISSION_UPDATE_TYPE_UPDATE_METADATA PermissionUpdateType = 5 +) + +// Enum value maps for PermissionUpdateType. +var ( + PermissionUpdateType_name = map[int32]string{ + 0: "PERMISSION_UPDATE_TYPE_UNSPECIFIED", + 1: "PERMISSION_UPDATE_TYPE_ADD_MEMBER", + 2: "PERMISSION_UPDATE_TYPE_REMOVE_MEMBER", + 3: "PERMISSION_UPDATE_TYPE_ADD_ADMIN", + 4: "PERMISSION_UPDATE_TYPE_REMOVE_ADMIN", + 5: "PERMISSION_UPDATE_TYPE_UPDATE_METADATA", + } + PermissionUpdateType_value = map[string]int32{ + "PERMISSION_UPDATE_TYPE_UNSPECIFIED": 0, + "PERMISSION_UPDATE_TYPE_ADD_MEMBER": 1, + "PERMISSION_UPDATE_TYPE_REMOVE_MEMBER": 2, + "PERMISSION_UPDATE_TYPE_ADD_ADMIN": 3, + "PERMISSION_UPDATE_TYPE_REMOVE_ADMIN": 4, + "PERMISSION_UPDATE_TYPE_UPDATE_METADATA": 5, + } +) + +func (x PermissionUpdateType) Enum() *PermissionUpdateType { + p := new(PermissionUpdateType) + *p = x + return p +} + +func (x PermissionUpdateType) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (PermissionUpdateType) Descriptor() protoreflect.EnumDescriptor { + return file_mls_database_intents_proto_enumTypes[1].Descriptor() +} + +func (PermissionUpdateType) Type() protoreflect.EnumType { + return &file_mls_database_intents_proto_enumTypes[1] +} + +func (x PermissionUpdateType) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use PermissionUpdateType.Descriptor instead. +func (PermissionUpdateType) EnumDescriptor() ([]byte, []int) { + return file_mls_database_intents_proto_rawDescGZIP(), []int{1} +} + +// Permission Policy +type PermissionPolicyOption int32 + +const ( + PermissionPolicyOption_PERMISSION_POLICY_OPTION_UNSPECIFIED PermissionPolicyOption = 0 + PermissionPolicyOption_PERMISSION_POLICY_OPTION_ALLOW PermissionPolicyOption = 1 + PermissionPolicyOption_PERMISSION_POLICY_OPTION_DENY PermissionPolicyOption = 2 + PermissionPolicyOption_PERMISSION_POLICY_OPTION_ADMIN_ONLY PermissionPolicyOption = 3 + PermissionPolicyOption_PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY PermissionPolicyOption = 4 +) + +// Enum value maps for PermissionPolicyOption. +var ( + PermissionPolicyOption_name = map[int32]string{ + 0: "PERMISSION_POLICY_OPTION_UNSPECIFIED", + 1: "PERMISSION_POLICY_OPTION_ALLOW", + 2: "PERMISSION_POLICY_OPTION_DENY", + 3: "PERMISSION_POLICY_OPTION_ADMIN_ONLY", + 4: "PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY", + } + PermissionPolicyOption_value = map[string]int32{ + "PERMISSION_POLICY_OPTION_UNSPECIFIED": 0, + "PERMISSION_POLICY_OPTION_ALLOW": 1, + "PERMISSION_POLICY_OPTION_DENY": 2, + "PERMISSION_POLICY_OPTION_ADMIN_ONLY": 3, + "PERMISSION_POLICY_OPTION_SUPER_ADMIN_ONLY": 4, + } +) + +func (x PermissionPolicyOption) Enum() *PermissionPolicyOption { + p := new(PermissionPolicyOption) + *p = x + return p +} + +func (x PermissionPolicyOption) String() string { + return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) +} + +func (PermissionPolicyOption) Descriptor() protoreflect.EnumDescriptor { + return file_mls_database_intents_proto_enumTypes[2].Descriptor() +} + +func (PermissionPolicyOption) Type() protoreflect.EnumType { + return &file_mls_database_intents_proto_enumTypes[2] +} + +func (x PermissionPolicyOption) Number() protoreflect.EnumNumber { + return protoreflect.EnumNumber(x) +} + +// Deprecated: Use PermissionPolicyOption.Descriptor instead. +func (PermissionPolicyOption) EnumDescriptor() ([]byte, []int) { + return file_mls_database_intents_proto_rawDescGZIP(), []int{2} +} + // The data required to publish a message type SendMessageData struct { state protoimpl.MessageState @@ -667,6 +782,74 @@ type UpdateAdminListsData_V1_ struct { func (*UpdateAdminListsData_V1_) isUpdateAdminListsData_Version() {} +// The data required to update permissions +type UpdatePermissionData struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Types that are assignable to Version: + // + // *UpdatePermissionData_V1_ + Version isUpdatePermissionData_Version `protobuf_oneof:"version"` +} + +func (x *UpdatePermissionData) Reset() { + *x = UpdatePermissionData{} + if protoimpl.UnsafeEnabled { + mi := &file_mls_database_intents_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdatePermissionData) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdatePermissionData) ProtoMessage() {} + +func (x *UpdatePermissionData) ProtoReflect() protoreflect.Message { + mi := &file_mls_database_intents_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use UpdatePermissionData.ProtoReflect.Descriptor instead. +func (*UpdatePermissionData) Descriptor() ([]byte, []int) { + return file_mls_database_intents_proto_rawDescGZIP(), []int{9} +} + +func (m *UpdatePermissionData) GetVersion() isUpdatePermissionData_Version { + if m != nil { + return m.Version + } + return nil +} + +func (x *UpdatePermissionData) GetV1() *UpdatePermissionData_V1 { + if x, ok := x.GetVersion().(*UpdatePermissionData_V1_); ok { + return x.V1 + } + return nil +} + +type isUpdatePermissionData_Version interface { + isUpdatePermissionData_Version() +} + +type UpdatePermissionData_V1_ struct { + V1 *UpdatePermissionData_V1 `protobuf:"bytes,1,opt,name=v1,proto3,oneof"` +} + +func (*UpdatePermissionData_V1_) isUpdatePermissionData_Version() {} + // Generic data-type for all post-commit actions type PostCommitAction struct { state protoimpl.MessageState @@ -682,7 +865,7 @@ type PostCommitAction struct { func (x *PostCommitAction) Reset() { *x = PostCommitAction{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[9] + mi := &file_mls_database_intents_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -695,7 +878,7 @@ func (x *PostCommitAction) String() string { func (*PostCommitAction) ProtoMessage() {} func (x *PostCommitAction) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[9] + mi := &file_mls_database_intents_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -708,7 +891,7 @@ func (x *PostCommitAction) ProtoReflect() protoreflect.Message { // Deprecated: Use PostCommitAction.ProtoReflect.Descriptor instead. func (*PostCommitAction) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{9} + return file_mls_database_intents_proto_rawDescGZIP(), []int{10} } func (m *PostCommitAction) GetKind() isPostCommitAction_Kind { @@ -747,7 +930,7 @@ type SendMessageData_V1 struct { func (x *SendMessageData_V1) Reset() { *x = SendMessageData_V1{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[10] + mi := &file_mls_database_intents_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -760,7 +943,7 @@ func (x *SendMessageData_V1) String() string { func (*SendMessageData_V1) ProtoMessage() {} func (x *SendMessageData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[10] + mi := &file_mls_database_intents_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -795,7 +978,7 @@ type AddMembersData_V1 struct { func (x *AddMembersData_V1) Reset() { *x = AddMembersData_V1{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[11] + mi := &file_mls_database_intents_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -808,7 +991,7 @@ func (x *AddMembersData_V1) String() string { func (*AddMembersData_V1) ProtoMessage() {} func (x *AddMembersData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[11] + mi := &file_mls_database_intents_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -843,7 +1026,7 @@ type RemoveMembersData_V1 struct { func (x *RemoveMembersData_V1) Reset() { *x = RemoveMembersData_V1{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[12] + mi := &file_mls_database_intents_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -856,7 +1039,7 @@ func (x *RemoveMembersData_V1) String() string { func (*RemoveMembersData_V1) ProtoMessage() {} func (x *RemoveMembersData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[12] + mi := &file_mls_database_intents_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -894,7 +1077,7 @@ type UpdateGroupMembershipData_V1 struct { func (x *UpdateGroupMembershipData_V1) Reset() { *x = UpdateGroupMembershipData_V1{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[13] + mi := &file_mls_database_intents_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -907,7 +1090,7 @@ func (x *UpdateGroupMembershipData_V1) String() string { func (*UpdateGroupMembershipData_V1) ProtoMessage() {} func (x *UpdateGroupMembershipData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[13] + mi := &file_mls_database_intents_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -950,7 +1133,7 @@ type UpdateMetadataData_V1 struct { func (x *UpdateMetadataData_V1) Reset() { *x = UpdateMetadataData_V1{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[15] + mi := &file_mls_database_intents_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -963,7 +1146,7 @@ func (x *UpdateMetadataData_V1) String() string { func (*UpdateMetadataData_V1) ProtoMessage() {} func (x *UpdateMetadataData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[15] + mi := &file_mls_database_intents_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1006,7 +1189,7 @@ type UpdateAdminListsData_V1 struct { func (x *UpdateAdminListsData_V1) Reset() { *x = UpdateAdminListsData_V1{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[16] + mi := &file_mls_database_intents_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1019,7 +1202,7 @@ func (x *UpdateAdminListsData_V1) String() string { func (*UpdateAdminListsData_V1) ProtoMessage() {} func (x *UpdateAdminListsData_V1) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[16] + mi := &file_mls_database_intents_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1049,6 +1232,71 @@ func (x *UpdateAdminListsData_V1) GetInboxId() string { return "" } +// V1 of UpdatePermissionData +type UpdatePermissionData_V1 struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + PermissionUpdateType PermissionUpdateType `protobuf:"varint,1,opt,name=permission_update_type,json=permissionUpdateType,proto3,enum=xmtp.mls.database.PermissionUpdateType" json:"permission_update_type,omitempty"` + PermissionPolicyOption PermissionPolicyOption `protobuf:"varint,2,opt,name=permission_policy_option,json=permissionPolicyOption,proto3,enum=xmtp.mls.database.PermissionPolicyOption" json:"permission_policy_option,omitempty"` + // Metadata permissions update specify which field permission they are updating + MetadataFieldName *string `protobuf:"bytes,3,opt,name=metadata_field_name,json=metadataFieldName,proto3,oneof" json:"metadata_field_name,omitempty"` +} + +func (x *UpdatePermissionData_V1) Reset() { + *x = UpdatePermissionData_V1{} + if protoimpl.UnsafeEnabled { + mi := &file_mls_database_intents_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *UpdatePermissionData_V1) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*UpdatePermissionData_V1) ProtoMessage() {} + +func (x *UpdatePermissionData_V1) ProtoReflect() protoreflect.Message { + mi := &file_mls_database_intents_proto_msgTypes[18] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use UpdatePermissionData_V1.ProtoReflect.Descriptor instead. +func (*UpdatePermissionData_V1) Descriptor() ([]byte, []int) { + return file_mls_database_intents_proto_rawDescGZIP(), []int{9, 0} +} + +func (x *UpdatePermissionData_V1) GetPermissionUpdateType() PermissionUpdateType { + if x != nil { + return x.PermissionUpdateType + } + return PermissionUpdateType_PERMISSION_UPDATE_TYPE_UNSPECIFIED +} + +func (x *UpdatePermissionData_V1) GetPermissionPolicyOption() PermissionPolicyOption { + if x != nil { + return x.PermissionPolicyOption + } + return PermissionPolicyOption_PERMISSION_POLICY_OPTION_UNSPECIFIED +} + +func (x *UpdatePermissionData_V1) GetMetadataFieldName() string { + if x != nil && x.MetadataFieldName != nil { + return *x.MetadataFieldName + } + return "" +} + // An installation type PostCommitAction_Installation struct { state protoimpl.MessageState @@ -1062,7 +1310,7 @@ type PostCommitAction_Installation struct { func (x *PostCommitAction_Installation) Reset() { *x = PostCommitAction_Installation{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[17] + mi := &file_mls_database_intents_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1075,7 +1323,7 @@ func (x *PostCommitAction_Installation) String() string { func (*PostCommitAction_Installation) ProtoMessage() {} func (x *PostCommitAction_Installation) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[17] + mi := &file_mls_database_intents_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1088,7 +1336,7 @@ func (x *PostCommitAction_Installation) ProtoReflect() protoreflect.Message { // Deprecated: Use PostCommitAction_Installation.ProtoReflect.Descriptor instead. func (*PostCommitAction_Installation) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{9, 0} + return file_mls_database_intents_proto_rawDescGZIP(), []int{10, 0} } func (x *PostCommitAction_Installation) GetInstallationKey() []byte { @@ -1118,7 +1366,7 @@ type PostCommitAction_SendWelcomes struct { func (x *PostCommitAction_SendWelcomes) Reset() { *x = PostCommitAction_SendWelcomes{} if protoimpl.UnsafeEnabled { - mi := &file_mls_database_intents_proto_msgTypes[18] + mi := &file_mls_database_intents_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1131,7 +1379,7 @@ func (x *PostCommitAction_SendWelcomes) String() string { func (*PostCommitAction_SendWelcomes) ProtoMessage() {} func (x *PostCommitAction_SendWelcomes) ProtoReflect() protoreflect.Message { - mi := &file_mls_database_intents_proto_msgTypes[18] + mi := &file_mls_database_intents_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1144,7 +1392,7 @@ func (x *PostCommitAction_SendWelcomes) ProtoReflect() protoreflect.Message { // Deprecated: Use PostCommitAction_SendWelcomes.ProtoReflect.Descriptor instead. func (*PostCommitAction_SendWelcomes) Descriptor() ([]byte, []int) { - return file_mls_database_intents_proto_rawDescGZIP(), []int{9, 1} + return file_mls_database_intents_proto_rawDescGZIP(), []int{10, 1} } func (x *PostCommitAction_SendWelcomes) GetInstallations() []*PostCommitAction_Installation { @@ -1269,56 +1517,111 @@ var file_mls_database_intents_proto_rawDesc = []byte{ 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x69, 0x6e, 0x62, 0x6f, 0x78, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x69, 0x6e, 0x62, 0x6f, 0x78, 0x49, 0x64, 0x42, 0x09, 0x0a, 0x07, 0x76, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0xe8, 0x02, 0x0a, 0x10, 0x50, 0x6f, 0x73, 0x74, 0x43, 0x6f, - 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x57, 0x0a, 0x0d, 0x73, 0x65, - 0x6e, 0x64, 0x5f, 0x77, 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x30, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, - 0x61, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x50, 0x6f, 0x73, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, - 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x53, 0x65, 0x6e, 0x64, 0x57, 0x65, 0x6c, 0x63, 0x6f, - 0x6d, 0x65, 0x73, 0x48, 0x00, 0x52, 0x0c, 0x73, 0x65, 0x6e, 0x64, 0x57, 0x65, 0x6c, 0x63, 0x6f, - 0x6d, 0x65, 0x73, 0x1a, 0x61, 0x0a, 0x0c, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x12, 0x29, 0x0a, 0x10, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0f, 0x69, - 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4b, 0x65, 0x79, 0x12, 0x26, - 0x0a, 0x0f, 0x68, 0x70, 0x6b, 0x65, 0x5f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, - 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0d, 0x68, 0x70, 0x6b, 0x65, 0x50, 0x75, 0x62, - 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x1a, 0x8f, 0x01, 0x0a, 0x0c, 0x53, 0x65, 0x6e, 0x64, 0x57, - 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, 0x73, 0x12, 0x56, 0x0a, 0x0d, 0x69, 0x6e, 0x73, 0x74, 0x61, - 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, - 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, - 0x73, 0x65, 0x2e, 0x50, 0x6f, 0x73, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x0d, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, - 0x27, 0x0a, 0x0f, 0x77, 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, - 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0e, 0x77, 0x65, 0x6c, 0x63, 0x6f, 0x6d, - 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x42, 0x06, 0x0a, 0x04, 0x6b, 0x69, 0x6e, 0x64, - 0x2a, 0xe7, 0x01, 0x0a, 0x13, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x0a, 0x22, 0x41, 0x44, 0x4d, 0x49, - 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, - 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, - 0x12, 0x24, 0x0a, 0x20, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, - 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x44, 0x44, 0x5f, 0x41, - 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x01, 0x12, 0x27, 0x0a, 0x23, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, - 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, - 0x5f, 0x52, 0x45, 0x4d, 0x4f, 0x56, 0x45, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x02, 0x12, - 0x2a, 0x0a, 0x26, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, - 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x44, 0x44, 0x5f, 0x53, 0x55, - 0x50, 0x45, 0x52, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x03, 0x12, 0x2d, 0x0a, 0x29, 0x41, - 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, - 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x4d, 0x4f, 0x56, 0x45, 0x5f, 0x53, 0x55, 0x50, - 0x45, 0x52, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x04, 0x42, 0xb9, 0x01, 0x0a, 0x15, 0x63, - 0x6f, 0x6d, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, 0x61, - 0x62, 0x61, 0x73, 0x65, 0x42, 0x0c, 0x49, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x50, 0x72, 0x6f, - 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x2c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, - 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, 0x2f, 0x70, 0x6b, 0x67, 0x2f, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x6d, 0x6c, 0x73, 0x2f, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, - 0x73, 0x65, 0xa2, 0x02, 0x03, 0x58, 0x4d, 0x44, 0xaa, 0x02, 0x11, 0x58, 0x6d, 0x74, 0x70, 0x2e, - 0x4d, 0x6c, 0x73, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0xca, 0x02, 0x11, 0x58, - 0x6d, 0x74, 0x70, 0x5c, 0x4d, 0x6c, 0x73, 0x5c, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, - 0xe2, 0x02, 0x1d, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x4d, 0x6c, 0x73, 0x5c, 0x44, 0x61, 0x74, 0x61, - 0x62, 0x61, 0x73, 0x65, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, - 0xea, 0x02, 0x13, 0x58, 0x6d, 0x74, 0x70, 0x3a, 0x3a, 0x4d, 0x6c, 0x73, 0x3a, 0x3a, 0x44, 0x61, - 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0xf7, 0x02, 0x0a, 0x14, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, + 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x12, 0x3c, + 0x0a, 0x02, 0x76, 0x31, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2a, 0x2e, 0x78, 0x6d, 0x74, + 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x44, + 0x61, 0x74, 0x61, 0x2e, 0x56, 0x31, 0x48, 0x00, 0x52, 0x02, 0x76, 0x31, 0x1a, 0x95, 0x02, 0x0a, + 0x02, 0x56, 0x31, 0x12, 0x5d, 0x0a, 0x16, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, + 0x6e, 0x5f, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0e, 0x32, 0x27, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, + 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, + 0x6f, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x79, 0x70, 0x65, 0x52, 0x14, 0x70, 0x65, + 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x63, 0x0a, 0x18, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x5f, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x5f, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, + 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, + 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x52, + 0x16, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x50, 0x6f, 0x6c, 0x69, 0x63, + 0x79, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x33, 0x0a, 0x13, 0x6d, 0x65, 0x74, 0x61, 0x64, + 0x61, 0x74, 0x61, 0x5f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, + 0x20, 0x01, 0x28, 0x09, 0x48, 0x00, 0x52, 0x11, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, + 0x46, 0x69, 0x65, 0x6c, 0x64, 0x4e, 0x61, 0x6d, 0x65, 0x88, 0x01, 0x01, 0x42, 0x16, 0x0a, 0x14, + 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x5f, + 0x6e, 0x61, 0x6d, 0x65, 0x42, 0x09, 0x0a, 0x07, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, + 0xe8, 0x02, 0x0a, 0x10, 0x50, 0x6f, 0x73, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x57, 0x0a, 0x0d, 0x73, 0x65, 0x6e, 0x64, 0x5f, 0x77, 0x65, 0x6c, + 0x63, 0x6f, 0x6d, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x78, 0x6d, + 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x2e, + 0x50, 0x6f, 0x73, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, + 0x2e, 0x53, 0x65, 0x6e, 0x64, 0x57, 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, 0x73, 0x48, 0x00, 0x52, + 0x0c, 0x73, 0x65, 0x6e, 0x64, 0x57, 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, 0x73, 0x1a, 0x61, 0x0a, + 0x0c, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x29, 0x0a, + 0x10, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6b, 0x65, + 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4b, 0x65, 0x79, 0x12, 0x26, 0x0a, 0x0f, 0x68, 0x70, 0x6b, 0x65, + 0x5f, 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0c, 0x52, 0x0d, 0x68, 0x70, 0x6b, 0x65, 0x50, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, + 0x1a, 0x8f, 0x01, 0x0a, 0x0c, 0x53, 0x65, 0x6e, 0x64, 0x57, 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, + 0x73, 0x12, 0x56, 0x0a, 0x0d, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, + 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x50, 0x6f, 0x73, + 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x49, 0x6e, + 0x73, 0x74, 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0d, 0x69, 0x6e, 0x73, 0x74, + 0x61, 0x6c, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x27, 0x0a, 0x0f, 0x77, 0x65, 0x6c, + 0x63, 0x6f, 0x6d, 0x65, 0x5f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x0e, 0x77, 0x65, 0x6c, 0x63, 0x6f, 0x6d, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, + 0x67, 0x65, 0x42, 0x06, 0x0a, 0x04, 0x6b, 0x69, 0x6e, 0x64, 0x2a, 0xe7, 0x01, 0x0a, 0x13, 0x41, + 0x64, 0x6d, 0x69, 0x6e, 0x4c, 0x69, 0x73, 0x74, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x26, 0x0a, 0x22, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, + 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, + 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x24, 0x0a, 0x20, 0x41, 0x44, + 0x4d, 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, + 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x44, 0x44, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x01, + 0x12, 0x27, 0x0a, 0x23, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, + 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x4d, 0x4f, 0x56, + 0x45, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x02, 0x12, 0x2a, 0x0a, 0x26, 0x41, 0x44, 0x4d, + 0x49, 0x4e, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, + 0x59, 0x50, 0x45, 0x5f, 0x41, 0x44, 0x44, 0x5f, 0x53, 0x55, 0x50, 0x45, 0x52, 0x5f, 0x41, 0x44, + 0x4d, 0x49, 0x4e, 0x10, 0x03, 0x12, 0x2d, 0x0a, 0x29, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4c, + 0x49, 0x53, 0x54, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, + 0x52, 0x45, 0x4d, 0x4f, 0x56, 0x45, 0x5f, 0x53, 0x55, 0x50, 0x45, 0x52, 0x5f, 0x41, 0x44, 0x4d, + 0x49, 0x4e, 0x10, 0x04, 0x2a, 0x8a, 0x02, 0x0a, 0x14, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, + 0x69, 0x6f, 0x6e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x0a, + 0x22, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x50, 0x44, 0x41, + 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, + 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x25, 0x0a, 0x21, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, + 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, + 0x41, 0x44, 0x44, 0x5f, 0x4d, 0x45, 0x4d, 0x42, 0x45, 0x52, 0x10, 0x01, 0x12, 0x28, 0x0a, 0x24, + 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, + 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x4d, 0x4f, 0x56, 0x45, 0x5f, 0x4d, 0x45, + 0x4d, 0x42, 0x45, 0x52, 0x10, 0x02, 0x12, 0x24, 0x0a, 0x20, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, + 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, + 0x5f, 0x41, 0x44, 0x44, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x03, 0x12, 0x27, 0x0a, 0x23, + 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, + 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x52, 0x45, 0x4d, 0x4f, 0x56, 0x45, 0x5f, 0x41, 0x44, + 0x4d, 0x49, 0x4e, 0x10, 0x04, 0x12, 0x2a, 0x0a, 0x26, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, + 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, + 0x55, 0x50, 0x44, 0x41, 0x54, 0x45, 0x5f, 0x4d, 0x45, 0x54, 0x41, 0x44, 0x41, 0x54, 0x41, 0x10, + 0x05, 0x2a, 0xe1, 0x01, 0x0a, 0x16, 0x50, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, 0x69, 0x6f, 0x6e, + 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x28, 0x0a, 0x24, + 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x50, 0x4f, 0x4c, 0x49, 0x43, + 0x59, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, + 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x22, 0x0a, 0x1e, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, + 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x50, 0x4f, 0x4c, 0x49, 0x43, 0x59, 0x5f, 0x4f, 0x50, 0x54, 0x49, + 0x4f, 0x4e, 0x5f, 0x41, 0x4c, 0x4c, 0x4f, 0x57, 0x10, 0x01, 0x12, 0x21, 0x0a, 0x1d, 0x50, 0x45, + 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x50, 0x4f, 0x4c, 0x49, 0x43, 0x59, 0x5f, + 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x44, 0x45, 0x4e, 0x59, 0x10, 0x02, 0x12, 0x27, 0x0a, + 0x23, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x50, 0x4f, 0x4c, 0x49, + 0x43, 0x59, 0x5f, 0x4f, 0x50, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, + 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x03, 0x12, 0x2d, 0x0a, 0x29, 0x50, 0x45, 0x52, 0x4d, 0x49, 0x53, + 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x50, 0x4f, 0x4c, 0x49, 0x43, 0x59, 0x5f, 0x4f, 0x50, 0x54, 0x49, + 0x4f, 0x4e, 0x5f, 0x53, 0x55, 0x50, 0x45, 0x52, 0x5f, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x5f, 0x4f, + 0x4e, 0x4c, 0x59, 0x10, 0x04, 0x42, 0xb9, 0x01, 0x0a, 0x15, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x6d, + 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x42, + 0x0c, 0x49, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x2c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x6d, 0x74, 0x70, + 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x2f, 0x6d, 0x6c, 0x73, 0x2f, 0x64, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0xa2, 0x02, 0x03, + 0x58, 0x4d, 0x44, 0xaa, 0x02, 0x11, 0x58, 0x6d, 0x74, 0x70, 0x2e, 0x4d, 0x6c, 0x73, 0x2e, 0x44, + 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0xca, 0x02, 0x11, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x4d, + 0x6c, 0x73, 0x5c, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0xe2, 0x02, 0x1d, 0x58, 0x6d, + 0x74, 0x70, 0x5c, 0x4d, 0x6c, 0x73, 0x5c, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x5c, + 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x13, 0x58, 0x6d, + 0x74, 0x70, 0x3a, 0x3a, 0x4d, 0x6c, 0x73, 0x3a, 0x3a, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, + 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1333,50 +1636,57 @@ func file_mls_database_intents_proto_rawDescGZIP() []byte { return file_mls_database_intents_proto_rawDescData } -var file_mls_database_intents_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_database_intents_proto_msgTypes = make([]protoimpl.MessageInfo, 19) +var file_mls_database_intents_proto_enumTypes = make([]protoimpl.EnumInfo, 3) +var file_mls_database_intents_proto_msgTypes = make([]protoimpl.MessageInfo, 21) var file_mls_database_intents_proto_goTypes = []any{ (AdminListUpdateType)(0), // 0: xmtp.mls.database.AdminListUpdateType - (*SendMessageData)(nil), // 1: xmtp.mls.database.SendMessageData - (*AccountAddresses)(nil), // 2: xmtp.mls.database.AccountAddresses - (*InstallationIds)(nil), // 3: xmtp.mls.database.InstallationIds - (*AddressesOrInstallationIds)(nil), // 4: xmtp.mls.database.AddressesOrInstallationIds - (*AddMembersData)(nil), // 5: xmtp.mls.database.AddMembersData - (*RemoveMembersData)(nil), // 6: xmtp.mls.database.RemoveMembersData - (*UpdateGroupMembershipData)(nil), // 7: xmtp.mls.database.UpdateGroupMembershipData - (*UpdateMetadataData)(nil), // 8: xmtp.mls.database.UpdateMetadataData - (*UpdateAdminListsData)(nil), // 9: xmtp.mls.database.UpdateAdminListsData - (*PostCommitAction)(nil), // 10: xmtp.mls.database.PostCommitAction - (*SendMessageData_V1)(nil), // 11: xmtp.mls.database.SendMessageData.V1 - (*AddMembersData_V1)(nil), // 12: xmtp.mls.database.AddMembersData.V1 - (*RemoveMembersData_V1)(nil), // 13: xmtp.mls.database.RemoveMembersData.V1 - (*UpdateGroupMembershipData_V1)(nil), // 14: xmtp.mls.database.UpdateGroupMembershipData.V1 - nil, // 15: xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntry - (*UpdateMetadataData_V1)(nil), // 16: xmtp.mls.database.UpdateMetadataData.V1 - (*UpdateAdminListsData_V1)(nil), // 17: xmtp.mls.database.UpdateAdminListsData.V1 - (*PostCommitAction_Installation)(nil), // 18: xmtp.mls.database.PostCommitAction.Installation - (*PostCommitAction_SendWelcomes)(nil), // 19: xmtp.mls.database.PostCommitAction.SendWelcomes + (PermissionUpdateType)(0), // 1: xmtp.mls.database.PermissionUpdateType + (PermissionPolicyOption)(0), // 2: xmtp.mls.database.PermissionPolicyOption + (*SendMessageData)(nil), // 3: xmtp.mls.database.SendMessageData + (*AccountAddresses)(nil), // 4: xmtp.mls.database.AccountAddresses + (*InstallationIds)(nil), // 5: xmtp.mls.database.InstallationIds + (*AddressesOrInstallationIds)(nil), // 6: xmtp.mls.database.AddressesOrInstallationIds + (*AddMembersData)(nil), // 7: xmtp.mls.database.AddMembersData + (*RemoveMembersData)(nil), // 8: xmtp.mls.database.RemoveMembersData + (*UpdateGroupMembershipData)(nil), // 9: xmtp.mls.database.UpdateGroupMembershipData + (*UpdateMetadataData)(nil), // 10: xmtp.mls.database.UpdateMetadataData + (*UpdateAdminListsData)(nil), // 11: xmtp.mls.database.UpdateAdminListsData + (*UpdatePermissionData)(nil), // 12: xmtp.mls.database.UpdatePermissionData + (*PostCommitAction)(nil), // 13: xmtp.mls.database.PostCommitAction + (*SendMessageData_V1)(nil), // 14: xmtp.mls.database.SendMessageData.V1 + (*AddMembersData_V1)(nil), // 15: xmtp.mls.database.AddMembersData.V1 + (*RemoveMembersData_V1)(nil), // 16: xmtp.mls.database.RemoveMembersData.V1 + (*UpdateGroupMembershipData_V1)(nil), // 17: xmtp.mls.database.UpdateGroupMembershipData.V1 + nil, // 18: xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntry + (*UpdateMetadataData_V1)(nil), // 19: xmtp.mls.database.UpdateMetadataData.V1 + (*UpdateAdminListsData_V1)(nil), // 20: xmtp.mls.database.UpdateAdminListsData.V1 + (*UpdatePermissionData_V1)(nil), // 21: xmtp.mls.database.UpdatePermissionData.V1 + (*PostCommitAction_Installation)(nil), // 22: xmtp.mls.database.PostCommitAction.Installation + (*PostCommitAction_SendWelcomes)(nil), // 23: xmtp.mls.database.PostCommitAction.SendWelcomes } var file_mls_database_intents_proto_depIdxs = []int32{ - 11, // 0: xmtp.mls.database.SendMessageData.v1:type_name -> xmtp.mls.database.SendMessageData.V1 - 2, // 1: xmtp.mls.database.AddressesOrInstallationIds.account_addresses:type_name -> xmtp.mls.database.AccountAddresses - 3, // 2: xmtp.mls.database.AddressesOrInstallationIds.installation_ids:type_name -> xmtp.mls.database.InstallationIds - 12, // 3: xmtp.mls.database.AddMembersData.v1:type_name -> xmtp.mls.database.AddMembersData.V1 - 13, // 4: xmtp.mls.database.RemoveMembersData.v1:type_name -> xmtp.mls.database.RemoveMembersData.V1 - 14, // 5: xmtp.mls.database.UpdateGroupMembershipData.v1:type_name -> xmtp.mls.database.UpdateGroupMembershipData.V1 - 16, // 6: xmtp.mls.database.UpdateMetadataData.v1:type_name -> xmtp.mls.database.UpdateMetadataData.V1 - 17, // 7: xmtp.mls.database.UpdateAdminListsData.v1:type_name -> xmtp.mls.database.UpdateAdminListsData.V1 - 19, // 8: xmtp.mls.database.PostCommitAction.send_welcomes:type_name -> xmtp.mls.database.PostCommitAction.SendWelcomes - 4, // 9: xmtp.mls.database.AddMembersData.V1.addresses_or_installation_ids:type_name -> xmtp.mls.database.AddressesOrInstallationIds - 4, // 10: xmtp.mls.database.RemoveMembersData.V1.addresses_or_installation_ids:type_name -> xmtp.mls.database.AddressesOrInstallationIds - 15, // 11: xmtp.mls.database.UpdateGroupMembershipData.V1.membership_updates:type_name -> xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntry - 0, // 12: xmtp.mls.database.UpdateAdminListsData.V1.admin_list_update_type:type_name -> xmtp.mls.database.AdminListUpdateType - 18, // 13: xmtp.mls.database.PostCommitAction.SendWelcomes.installations:type_name -> xmtp.mls.database.PostCommitAction.Installation - 14, // [14:14] is the sub-list for method output_type - 14, // [14:14] is the sub-list for method input_type - 14, // [14:14] is the sub-list for extension type_name - 14, // [14:14] is the sub-list for extension extendee - 0, // [0:14] is the sub-list for field type_name + 14, // 0: xmtp.mls.database.SendMessageData.v1:type_name -> xmtp.mls.database.SendMessageData.V1 + 4, // 1: xmtp.mls.database.AddressesOrInstallationIds.account_addresses:type_name -> xmtp.mls.database.AccountAddresses + 5, // 2: xmtp.mls.database.AddressesOrInstallationIds.installation_ids:type_name -> xmtp.mls.database.InstallationIds + 15, // 3: xmtp.mls.database.AddMembersData.v1:type_name -> xmtp.mls.database.AddMembersData.V1 + 16, // 4: xmtp.mls.database.RemoveMembersData.v1:type_name -> xmtp.mls.database.RemoveMembersData.V1 + 17, // 5: xmtp.mls.database.UpdateGroupMembershipData.v1:type_name -> xmtp.mls.database.UpdateGroupMembershipData.V1 + 19, // 6: xmtp.mls.database.UpdateMetadataData.v1:type_name -> xmtp.mls.database.UpdateMetadataData.V1 + 20, // 7: xmtp.mls.database.UpdateAdminListsData.v1:type_name -> xmtp.mls.database.UpdateAdminListsData.V1 + 21, // 8: xmtp.mls.database.UpdatePermissionData.v1:type_name -> xmtp.mls.database.UpdatePermissionData.V1 + 23, // 9: xmtp.mls.database.PostCommitAction.send_welcomes:type_name -> xmtp.mls.database.PostCommitAction.SendWelcomes + 6, // 10: xmtp.mls.database.AddMembersData.V1.addresses_or_installation_ids:type_name -> xmtp.mls.database.AddressesOrInstallationIds + 6, // 11: xmtp.mls.database.RemoveMembersData.V1.addresses_or_installation_ids:type_name -> xmtp.mls.database.AddressesOrInstallationIds + 18, // 12: xmtp.mls.database.UpdateGroupMembershipData.V1.membership_updates:type_name -> xmtp.mls.database.UpdateGroupMembershipData.V1.MembershipUpdatesEntry + 0, // 13: xmtp.mls.database.UpdateAdminListsData.V1.admin_list_update_type:type_name -> xmtp.mls.database.AdminListUpdateType + 1, // 14: xmtp.mls.database.UpdatePermissionData.V1.permission_update_type:type_name -> xmtp.mls.database.PermissionUpdateType + 2, // 15: xmtp.mls.database.UpdatePermissionData.V1.permission_policy_option:type_name -> xmtp.mls.database.PermissionPolicyOption + 22, // 16: xmtp.mls.database.PostCommitAction.SendWelcomes.installations:type_name -> xmtp.mls.database.PostCommitAction.Installation + 17, // [17:17] is the sub-list for method output_type + 17, // [17:17] is the sub-list for method input_type + 17, // [17:17] is the sub-list for extension type_name + 17, // [17:17] is the sub-list for extension extendee + 0, // [0:17] is the sub-list for field type_name } func init() { file_mls_database_intents_proto_init() } @@ -1494,7 +1804,7 @@ func file_mls_database_intents_proto_init() { } } file_mls_database_intents_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*PostCommitAction); i { + switch v := v.(*UpdatePermissionData); i { case 0: return &v.state case 1: @@ -1506,7 +1816,7 @@ func file_mls_database_intents_proto_init() { } } file_mls_database_intents_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*SendMessageData_V1); i { + switch v := v.(*PostCommitAction); i { case 0: return &v.state case 1: @@ -1518,7 +1828,7 @@ func file_mls_database_intents_proto_init() { } } file_mls_database_intents_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*AddMembersData_V1); i { + switch v := v.(*SendMessageData_V1); i { case 0: return &v.state case 1: @@ -1530,7 +1840,7 @@ func file_mls_database_intents_proto_init() { } } file_mls_database_intents_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*RemoveMembersData_V1); i { + switch v := v.(*AddMembersData_V1); i { case 0: return &v.state case 1: @@ -1542,6 +1852,18 @@ func file_mls_database_intents_proto_init() { } } file_mls_database_intents_proto_msgTypes[13].Exporter = func(v any, i int) any { + switch v := v.(*RemoveMembersData_V1); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_mls_database_intents_proto_msgTypes[14].Exporter = func(v any, i int) any { switch v := v.(*UpdateGroupMembershipData_V1); i { case 0: return &v.state @@ -1553,7 +1875,7 @@ func file_mls_database_intents_proto_init() { return nil } } - file_mls_database_intents_proto_msgTypes[15].Exporter = func(v any, i int) any { + file_mls_database_intents_proto_msgTypes[16].Exporter = func(v any, i int) any { switch v := v.(*UpdateMetadataData_V1); i { case 0: return &v.state @@ -1565,7 +1887,7 @@ func file_mls_database_intents_proto_init() { return nil } } - file_mls_database_intents_proto_msgTypes[16].Exporter = func(v any, i int) any { + file_mls_database_intents_proto_msgTypes[17].Exporter = func(v any, i int) any { switch v := v.(*UpdateAdminListsData_V1); i { case 0: return &v.state @@ -1577,7 +1899,19 @@ func file_mls_database_intents_proto_init() { return nil } } - file_mls_database_intents_proto_msgTypes[17].Exporter = func(v any, i int) any { + file_mls_database_intents_proto_msgTypes[18].Exporter = func(v any, i int) any { + switch v := v.(*UpdatePermissionData_V1); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_mls_database_intents_proto_msgTypes[19].Exporter = func(v any, i int) any { switch v := v.(*PostCommitAction_Installation); i { case 0: return &v.state @@ -1589,7 +1923,7 @@ func file_mls_database_intents_proto_init() { return nil } } - file_mls_database_intents_proto_msgTypes[18].Exporter = func(v any, i int) any { + file_mls_database_intents_proto_msgTypes[20].Exporter = func(v any, i int) any { switch v := v.(*PostCommitAction_SendWelcomes); i { case 0: return &v.state @@ -1625,15 +1959,19 @@ func file_mls_database_intents_proto_init() { (*UpdateAdminListsData_V1_)(nil), } file_mls_database_intents_proto_msgTypes[9].OneofWrappers = []any{ + (*UpdatePermissionData_V1_)(nil), + } + file_mls_database_intents_proto_msgTypes[10].OneofWrappers = []any{ (*PostCommitAction_SendWelcomes_)(nil), } + file_mls_database_intents_proto_msgTypes[18].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_mls_database_intents_proto_rawDesc, - NumEnums: 1, - NumMessages: 19, + NumEnums: 3, + NumMessages: 21, NumExtensions: 0, NumServices: 0, }, diff --git a/pkg/proto/mls/message_contents/group_metadata.pb.go b/pkg/proto/mls/message_contents/group_metadata.pb.go index 6669aa8d..a5c2611b 100644 --- a/pkg/proto/mls/message_contents/group_metadata.pb.go +++ b/pkg/proto/mls/message_contents/group_metadata.pb.go @@ -85,6 +85,8 @@ type GroupMetadataV1 struct { // This will be removed soon CreatorAccountAddress string `protobuf:"bytes,2,opt,name=creator_account_address,json=creatorAccountAddress,proto3" json:"creator_account_address,omitempty"` CreatorInboxId string `protobuf:"bytes,3,opt,name=creator_inbox_id,json=creatorInboxId,proto3" json:"creator_inbox_id,omitempty"` + // Should only be present for CONVERSATION_TYPE_DM + DmMembers *DmMembers `protobuf:"bytes,4,opt,name=dm_members,json=dmMembers,proto3,oneof" json:"dm_members,omitempty"` } func (x *GroupMetadataV1) Reset() { @@ -140,6 +142,117 @@ func (x *GroupMetadataV1) GetCreatorInboxId() string { return "" } +func (x *GroupMetadataV1) GetDmMembers() *DmMembers { + if x != nil { + return x.DmMembers + } + return nil +} + +// Wrapper around an Inbox Id +type Inbox struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + InboxId string `protobuf:"bytes,1,opt,name=inbox_id,json=inboxId,proto3" json:"inbox_id,omitempty"` +} + +func (x *Inbox) Reset() { + *x = Inbox{} + if protoimpl.UnsafeEnabled { + mi := &file_mls_message_contents_group_metadata_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Inbox) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Inbox) ProtoMessage() {} + +func (x *Inbox) ProtoReflect() protoreflect.Message { + mi := &file_mls_message_contents_group_metadata_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use Inbox.ProtoReflect.Descriptor instead. +func (*Inbox) Descriptor() ([]byte, []int) { + return file_mls_message_contents_group_metadata_proto_rawDescGZIP(), []int{1} +} + +func (x *Inbox) GetInboxId() string { + if x != nil { + return x.InboxId + } + return "" +} + +// Ordering does not matter here +type DmMembers struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + DmMemberOne *Inbox `protobuf:"bytes,1,opt,name=dm_member_one,json=dmMemberOne,proto3" json:"dm_member_one,omitempty"` + DmMemberTwo *Inbox `protobuf:"bytes,2,opt,name=dm_member_two,json=dmMemberTwo,proto3" json:"dm_member_two,omitempty"` +} + +func (x *DmMembers) Reset() { + *x = DmMembers{} + if protoimpl.UnsafeEnabled { + mi := &file_mls_message_contents_group_metadata_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DmMembers) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DmMembers) ProtoMessage() {} + +func (x *DmMembers) ProtoReflect() protoreflect.Message { + mi := &file_mls_message_contents_group_metadata_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use DmMembers.ProtoReflect.Descriptor instead. +func (*DmMembers) Descriptor() ([]byte, []int) { + return file_mls_message_contents_group_metadata_proto_rawDescGZIP(), []int{2} +} + +func (x *DmMembers) GetDmMemberOne() *Inbox { + if x != nil { + return x.DmMemberOne + } + return nil +} + +func (x *DmMembers) GetDmMemberTwo() *Inbox { + if x != nil { + return x.DmMemberTwo + } + return nil +} + var File_mls_message_contents_group_metadata_proto protoreflect.FileDescriptor var file_mls_message_contents_group_metadata_proto_rawDesc = []byte{ @@ -147,7 +260,7 @@ var file_mls_message_contents_group_metadata_proto_rawDesc = []byte{ 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x19, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x22, 0xcd, 0x01, 0x0a, 0x0f, 0x47, 0x72, 0x6f, 0x75, 0x70, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x22, 0xa6, 0x02, 0x0a, 0x0f, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x56, 0x31, 0x12, 0x58, 0x0a, 0x11, 0x63, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2b, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, @@ -160,31 +273,48 @@ var file_mls_message_contents_group_metadata_proto_rawDesc = []byte{ 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x41, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x28, 0x0a, 0x10, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x5f, 0x69, 0x6e, 0x62, 0x6f, 0x78, 0x5f, 0x69, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x63, 0x72, 0x65, 0x61, 0x74, 0x6f, 0x72, 0x49, - 0x6e, 0x62, 0x6f, 0x78, 0x49, 0x64, 0x2a, 0x88, 0x01, 0x0a, 0x10, 0x43, 0x6f, 0x6e, 0x76, 0x65, - 0x72, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, 0x70, 0x65, 0x12, 0x21, 0x0a, 0x1d, 0x43, - 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, - 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1b, - 0x0a, 0x17, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, - 0x59, 0x50, 0x45, 0x5f, 0x47, 0x52, 0x4f, 0x55, 0x50, 0x10, 0x01, 0x12, 0x18, 0x0a, 0x14, 0x43, - 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, - 0x5f, 0x44, 0x4d, 0x10, 0x02, 0x12, 0x1a, 0x0a, 0x16, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, - 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x59, 0x4e, 0x43, 0x10, - 0x03, 0x42, 0xeb, 0x01, 0x0a, 0x1d, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, - 0x6c, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, - 0x6e, 0x74, 0x73, 0x42, 0x12, 0x47, 0x72, 0x6f, 0x75, 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x34, 0x67, 0x69, 0x74, 0x68, 0x75, - 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, - 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x6d, 0x6c, 0x73, 0x2f, 0x6d, - 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0xa2, - 0x02, 0x03, 0x58, 0x4d, 0x4d, 0xaa, 0x02, 0x18, 0x58, 0x6d, 0x74, 0x70, 0x2e, 0x4d, 0x6c, 0x73, - 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, - 0xca, 0x02, 0x18, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x4d, 0x6c, 0x73, 0x5c, 0x4d, 0x65, 0x73, 0x73, - 0x61, 0x67, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0xe2, 0x02, 0x24, 0x58, 0x6d, - 0x74, 0x70, 0x5c, 0x4d, 0x6c, 0x73, 0x5c, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, 0x6f, - 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, - 0x74, 0x61, 0xea, 0x02, 0x1a, 0x58, 0x6d, 0x74, 0x70, 0x3a, 0x3a, 0x4d, 0x6c, 0x73, 0x3a, 0x3a, - 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x62, - 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6e, 0x62, 0x6f, 0x78, 0x49, 0x64, 0x12, 0x48, 0x0a, 0x0a, 0x64, 0x6d, 0x5f, 0x6d, 0x65, 0x6d, + 0x62, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x78, 0x6d, 0x74, + 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x44, 0x6d, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, + 0x48, 0x00, 0x52, 0x09, 0x64, 0x6d, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x88, 0x01, 0x01, + 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x64, 0x6d, 0x5f, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x73, 0x22, + 0x22, 0x0a, 0x05, 0x49, 0x6e, 0x62, 0x6f, 0x78, 0x12, 0x19, 0x0a, 0x08, 0x69, 0x6e, 0x62, 0x6f, + 0x78, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x69, 0x6e, 0x62, 0x6f, + 0x78, 0x49, 0x64, 0x22, 0x97, 0x01, 0x0a, 0x09, 0x44, 0x6d, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, + 0x73, 0x12, 0x44, 0x0a, 0x0d, 0x64, 0x6d, 0x5f, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x5f, 0x6f, + 0x6e, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, + 0x6d, 0x6c, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, + 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x49, 0x6e, 0x62, 0x6f, 0x78, 0x52, 0x0b, 0x64, 0x6d, 0x4d, 0x65, + 0x6d, 0x62, 0x65, 0x72, 0x4f, 0x6e, 0x65, 0x12, 0x44, 0x0a, 0x0d, 0x64, 0x6d, 0x5f, 0x6d, 0x65, + 0x6d, 0x62, 0x65, 0x72, 0x5f, 0x74, 0x77, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, + 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x49, 0x6e, 0x62, 0x6f, 0x78, + 0x52, 0x0b, 0x64, 0x6d, 0x4d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x54, 0x77, 0x6f, 0x2a, 0x88, 0x01, + 0x0a, 0x10, 0x43, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x73, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x79, + 0x70, 0x65, 0x12, 0x21, 0x0a, 0x1d, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, 0x41, 0x54, 0x49, + 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, + 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x1b, 0x0a, 0x17, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, + 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x47, 0x52, 0x4f, 0x55, 0x50, + 0x10, 0x01, 0x12, 0x18, 0x0a, 0x14, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, 0x41, 0x54, 0x49, + 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x44, 0x4d, 0x10, 0x02, 0x12, 0x1a, 0x0a, 0x16, + 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x53, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x54, 0x59, 0x50, + 0x45, 0x5f, 0x53, 0x59, 0x4e, 0x43, 0x10, 0x03, 0x42, 0xeb, 0x01, 0x0a, 0x1d, 0x63, 0x6f, 0x6d, + 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x6d, 0x6c, 0x73, 0x2e, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x42, 0x12, 0x47, 0x72, 0x6f, 0x75, + 0x70, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, + 0x5a, 0x34, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x6d, 0x74, + 0x70, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x2f, 0x6d, 0x6c, 0x73, 0x2f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0xa2, 0x02, 0x03, 0x58, 0x4d, 0x4d, 0xaa, 0x02, 0x18, 0x58, + 0x6d, 0x74, 0x70, 0x2e, 0x4d, 0x6c, 0x73, 0x2e, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, + 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0xca, 0x02, 0x18, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x4d, + 0x6c, 0x73, 0x5c, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, + 0x74, 0x73, 0xe2, 0x02, 0x24, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x4d, 0x6c, 0x73, 0x5c, 0x4d, 0x65, + 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x1a, 0x58, 0x6d, 0x74, 0x70, + 0x3a, 0x3a, 0x4d, 0x6c, 0x73, 0x3a, 0x3a, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x43, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -200,18 +330,23 @@ func file_mls_message_contents_group_metadata_proto_rawDescGZIP() []byte { } var file_mls_message_contents_group_metadata_proto_enumTypes = make([]protoimpl.EnumInfo, 1) -var file_mls_message_contents_group_metadata_proto_msgTypes = make([]protoimpl.MessageInfo, 1) +var file_mls_message_contents_group_metadata_proto_msgTypes = make([]protoimpl.MessageInfo, 3) var file_mls_message_contents_group_metadata_proto_goTypes = []any{ (ConversationType)(0), // 0: xmtp.mls.message_contents.ConversationType (*GroupMetadataV1)(nil), // 1: xmtp.mls.message_contents.GroupMetadataV1 + (*Inbox)(nil), // 2: xmtp.mls.message_contents.Inbox + (*DmMembers)(nil), // 3: xmtp.mls.message_contents.DmMembers } var file_mls_message_contents_group_metadata_proto_depIdxs = []int32{ 0, // 0: xmtp.mls.message_contents.GroupMetadataV1.conversation_type:type_name -> xmtp.mls.message_contents.ConversationType - 1, // [1:1] is the sub-list for method output_type - 1, // [1:1] is the sub-list for method input_type - 1, // [1:1] is the sub-list for extension type_name - 1, // [1:1] is the sub-list for extension extendee - 0, // [0:1] is the sub-list for field type_name + 3, // 1: xmtp.mls.message_contents.GroupMetadataV1.dm_members:type_name -> xmtp.mls.message_contents.DmMembers + 2, // 2: xmtp.mls.message_contents.DmMembers.dm_member_one:type_name -> xmtp.mls.message_contents.Inbox + 2, // 3: xmtp.mls.message_contents.DmMembers.dm_member_two:type_name -> xmtp.mls.message_contents.Inbox + 4, // [4:4] is the sub-list for method output_type + 4, // [4:4] is the sub-list for method input_type + 4, // [4:4] is the sub-list for extension type_name + 4, // [4:4] is the sub-list for extension extendee + 0, // [0:4] is the sub-list for field type_name } func init() { file_mls_message_contents_group_metadata_proto_init() } @@ -232,14 +367,39 @@ func file_mls_message_contents_group_metadata_proto_init() { return nil } } + file_mls_message_contents_group_metadata_proto_msgTypes[1].Exporter = func(v any, i int) any { + switch v := v.(*Inbox); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_mls_message_contents_group_metadata_proto_msgTypes[2].Exporter = func(v any, i int) any { + switch v := v.(*DmMembers); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } + file_mls_message_contents_group_metadata_proto_msgTypes[0].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_mls_message_contents_group_metadata_proto_rawDesc, NumEnums: 1, - NumMessages: 1, + NumMessages: 3, NumExtensions: 0, NumServices: 0, }, diff --git a/pkg/proto/openapi/identity/api/v1/identity.swagger.json b/pkg/proto/openapi/identity/api/v1/identity.swagger.json index ce2bc819..53768ce0 100644 --- a/pkg/proto/openapi/identity/api/v1/identity.swagger.json +++ b/pkg/proto/openapi/identity/api/v1/identity.swagger.json @@ -210,26 +210,6 @@ }, "description": "The first entry of any XID log. The XID must be deterministically derivable\nfrom the address and nonce.\nThe recovery address defaults to the initial associated_address unless\nthere is a subsequent ChangeRecoveryAddress in the log." }, - "associationsErc1271Signature": { - "type": "object", - "properties": { - "accountId": { - "type": "string", - "title": "CAIP-10\nhttps://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md" - }, - "blockNumber": { - "type": "string", - "format": "uint64", - "title": "Specify the block number to verify the signature against" - }, - "signature": { - "type": "string", - "format": "byte", - "title": "The actual signature bytes" - } - }, - "title": "Smart wallet signature" - }, "associationsIdentityAction": { "type": "object", "properties": { @@ -321,6 +301,30 @@ }, "description": "Revokes a member from an XID. The recovery address must sign the revocation." }, + "associationsSmartContractWalletSignature": { + "type": "object", + "properties": { + "accountId": { + "type": "string", + "title": "CAIP-10 string\nhttps://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md" + }, + "blockNumber": { + "type": "string", + "format": "uint64", + "title": "Specify the block number to verify the signature against" + }, + "signature": { + "type": "string", + "format": "byte", + "title": "The actual signature bytes" + }, + "chainRpcUrl": { + "type": "string", + "title": "The RPC URL specifies a chain to verify the signature against" + } + }, + "title": "Smart Contract Wallet signature" + }, "identityassociationsRecoverableEcdsaSignature": { "type": "object", "properties": { @@ -338,8 +342,8 @@ "erc191": { "$ref": "#/definitions/identityassociationsRecoverableEcdsaSignature" }, - "erc1271": { - "$ref": "#/definitions/associationsErc1271Signature" + "erc6492": { + "$ref": "#/definitions/associationsSmartContractWalletSignature" }, "installationKey": { "$ref": "#/definitions/associationsRecoverableEd25519Signature" diff --git a/pkg/proto/openapi/mls_validation/v1/service.swagger.json b/pkg/proto/openapi/mls_validation/v1/service.swagger.json index b64068e6..18e906b8 100644 --- a/pkg/proto/openapi/mls_validation/v1/service.swagger.json +++ b/pkg/proto/openapi/mls_validation/v1/service.swagger.json @@ -159,26 +159,6 @@ }, "description": "The first entry of any XID log. The XID must be deterministically derivable\nfrom the address and nonce.\nThe recovery address defaults to the initial associated_address unless\nthere is a subsequent ChangeRecoveryAddress in the log." }, - "associationsErc1271Signature": { - "type": "object", - "properties": { - "accountId": { - "type": "string", - "title": "CAIP-10\nhttps://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md" - }, - "blockNumber": { - "type": "string", - "format": "uint64", - "title": "Specify the block number to verify the signature against" - }, - "signature": { - "type": "string", - "format": "byte", - "title": "The actual signature bytes" - } - }, - "title": "Smart wallet signature" - }, "associationsIdentityAction": { "type": "object", "properties": { @@ -294,6 +274,30 @@ }, "description": "Revokes a member from an XID. The recovery address must sign the revocation." }, + "associationsSmartContractWalletSignature": { + "type": "object", + "properties": { + "accountId": { + "type": "string", + "title": "CAIP-10 string\nhttps://github.com/ChainAgnostic/CAIPs/blob/main/CAIPs/caip-10.md" + }, + "blockNumber": { + "type": "string", + "format": "uint64", + "title": "Specify the block number to verify the signature against" + }, + "signature": { + "type": "string", + "format": "byte", + "title": "The actual signature bytes" + }, + "chainRpcUrl": { + "type": "string", + "title": "The RPC URL specifies a chain to verify the signature against" + } + }, + "title": "Smart Contract Wallet signature" + }, "identityassociationsRecoverableEcdsaSignature": { "type": "object", "properties": { @@ -311,8 +315,8 @@ "erc191": { "$ref": "#/definitions/identityassociationsRecoverableEcdsaSignature" }, - "erc1271": { - "$ref": "#/definitions/associationsErc1271Signature" + "erc6492": { + "$ref": "#/definitions/associationsSmartContractWalletSignature" }, "installationKey": { "$ref": "#/definitions/associationsRecoverableEd25519Signature" diff --git a/pkg/proto/openapi/xmtpv4/message_api/message_api.swagger.json b/pkg/proto/openapi/xmtpv4/message_api/message_api.swagger.json index 660aba85..20884cf6 100644 --- a/pkg/proto/openapi/xmtpv4/message_api/message_api.swagger.json +++ b/pkg/proto/openapi/xmtpv4/message_api/message_api.swagger.json @@ -18,6 +18,7 @@ "paths": { "/mls/v2/query-envelopes": { "post": { + "summary": "Query envelopes", "operationId": "ReplicationApi_QueryEnvelopes", "responses": { "200": { @@ -50,7 +51,8 @@ }, "/mls/v2/subscribe-envelopes": { "post": { - "operationId": "ReplicationApi_SubscribeEnvelopes", + "summary": "Subscribe to envelopes", + "operationId": "ReplicationApi_BatchSubscribeEnvelopes", "responses": { "200": { "description": "A successful response.(streaming responses)", @@ -58,13 +60,13 @@ "type": "object", "properties": { "result": { - "$ref": "#/definitions/xmtpv4GatewayEnvelope" + "$ref": "#/definitions/xmtpv4BatchSubscribeEnvelopesResponse" }, "error": { "$ref": "#/definitions/rpcStatus" } }, - "title": "Stream result of xmtpv4GatewayEnvelope" + "title": "Stream result of xmtpv4BatchSubscribeEnvelopesResponse" } }, "default": { @@ -97,7 +99,8 @@ "query": { "$ref": "#/definitions/xmtpv4EnvelopesQuery" } - } + }, + "title": "Single subscription request for envelopes" }, "identityassociationsRecoverableEcdsaSignature": { "type": "object", @@ -148,7 +151,21 @@ "$ref": "#/definitions/BatchSubscribeEnvelopesRequestSubscribeEnvelopesRequest" } } - } + }, + "title": "Batch subscribe to envelopes" + }, + "xmtpv4BatchSubscribeEnvelopesResponse": { + "type": "object", + "properties": { + "envelopes": { + "type": "array", + "items": { + "type": "object", + "$ref": "#/definitions/xmtpv4GatewayEnvelope" + } + } + }, + "title": "Streamed response for batch subscribe - can be multiple envelopes at once" }, "xmtpv4BlockchainProof": { "type": "object", @@ -161,7 +178,8 @@ "type": "integer", "format": "int64" } - } + }, + "title": "An alternative to a signature for blockchain payloads" }, "xmtpv4EnvelopesQuery": { "type": "object", @@ -182,7 +200,8 @@ "type": "integer", "format": "int64" } - } + }, + "title": "Query for envelopes, shared by query and subscribe endpoints" }, "xmtpv4GatewayEnvelope": { "type": "object", @@ -194,7 +213,8 @@ "originatorEnvelope": { "$ref": "#/definitions/xmtpv4OriginatorEnvelope" } - } + }, + "title": "Wraps originator envelope with a sequence ID assigned by the gateway" }, "xmtpv4OriginatorEnvelope": { "type": "object", @@ -210,7 +230,8 @@ "blockchainProof": { "$ref": "#/definitions/xmtpv4BlockchainProof" } - } + }, + "title": "Signed originator envelope" }, "xmtpv4QueryEnvelopesRequest": { "type": "object", @@ -218,10 +239,12 @@ "query": { "$ref": "#/definitions/xmtpv4EnvelopesQuery" }, - "pagingInfo": { - "$ref": "#/definitions/xmtpxmtpv4PagingInfo" + "limit": { + "type": "integer", + "format": "int64" } - } + }, + "title": "Query envelopes request" }, "xmtpv4QueryEnvelopesResponse": { "type": "object", @@ -233,17 +256,8 @@ "$ref": "#/definitions/xmtpv4GatewayEnvelope" } } - } - }, - "xmtpxmtpv4PagingInfo": { - "type": "object", - "properties": { - "limit": { - "type": "integer", - "format": "int64" - } }, - "title": "Pagination config for queries" + "title": "Query envelopes response" } } } diff --git a/pkg/proto/xmtpv4/message_api/message_api.pb.go b/pkg/proto/xmtpv4/message_api/message_api.pb.go index 7fc0c831..7121913a 100644 --- a/pkg/proto/xmtpv4/message_api/message_api.pb.go +++ b/pkg/proto/xmtpv4/message_api/message_api.pb.go @@ -1,3 +1,5 @@ +// Message API for XMTP V4 + // Code generated by protoc-gen-go. DO NOT EDIT. // versions: // protoc-gen-go v1.34.2 @@ -22,6 +24,7 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) +// Misbehavior types type Misbehavior int32 const ( @@ -77,6 +80,7 @@ func (Misbehavior) EnumDescriptor() ([]byte, []int) { return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{0} } +// Authenticated data within the MlsPrivateMessage type AuthenticatedData struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -182,6 +186,7 @@ func (x *ClientEnvelope) GetSenderHmac() []byte { return nil } +// Wraps client envelope with payer signature type PayerEnvelope struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -302,6 +307,7 @@ func (x *UnsignedOriginatorEnvelope) GetPayerEnvelope() *PayerEnvelope { return nil } +// An alternative to a signature for blockchain payloads type BlockchainProof struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -357,6 +363,7 @@ func (x *BlockchainProof) GetPublisherId() uint32 { return 0 } +// Signed originator envelope type OriginatorEnvelope struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -446,6 +453,7 @@ func (*OriginatorEnvelope_OriginatorSignature) isOriginatorEnvelope_Proof() {} func (*OriginatorEnvelope_BlockchainProof) isOriginatorEnvelope_Proof() {} +// Wraps originator envelope with a sequence ID assigned by the gateway type GatewayEnvelope struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -501,6 +509,63 @@ func (x *GatewayEnvelope) GetOriginatorEnvelope() *OriginatorEnvelope { return nil } +// Reports node misbehavior, submittable by nodes or by clients +type MisbehaviorReport struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Type Misbehavior `protobuf:"varint,1,opt,name=type,proto3,enum=xmtp.xmtpv4.Misbehavior" json:"type,omitempty"` + Envelopes []*OriginatorEnvelope `protobuf:"bytes,2,rep,name=envelopes,proto3" json:"envelopes,omitempty"` +} + +func (x *MisbehaviorReport) Reset() { + *x = MisbehaviorReport{} + if protoimpl.UnsafeEnabled { + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MisbehaviorReport) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MisbehaviorReport) ProtoMessage() {} + +func (x *MisbehaviorReport) ProtoReflect() protoreflect.Message { + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use MisbehaviorReport.ProtoReflect.Descriptor instead. +func (*MisbehaviorReport) Descriptor() ([]byte, []int) { + return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{7} +} + +func (x *MisbehaviorReport) GetType() Misbehavior { + if x != nil { + return x.Type + } + return Misbehavior_MISBEHAVIOR_UNSPECIFIED +} + +func (x *MisbehaviorReport) GetEnvelopes() []*OriginatorEnvelope { + if x != nil { + return x.Envelopes + } + return nil +} + +// Query for envelopes, shared by query and subscribe endpoints type EnvelopesQuery struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -521,7 +586,7 @@ type EnvelopesQuery struct { func (x *EnvelopesQuery) Reset() { *x = EnvelopesQuery{} if protoimpl.UnsafeEnabled { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[7] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -534,7 +599,7 @@ func (x *EnvelopesQuery) String() string { func (*EnvelopesQuery) ProtoMessage() {} func (x *EnvelopesQuery) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[7] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -547,7 +612,7 @@ func (x *EnvelopesQuery) ProtoReflect() protoreflect.Message { // Deprecated: Use EnvelopesQuery.ProtoReflect.Descriptor instead. func (*EnvelopesQuery) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{7} + return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{8} } func (m *EnvelopesQuery) GetLastSeen() isEnvelopesQuery_LastSeen { @@ -624,6 +689,7 @@ func (*EnvelopesQuery_Topic) isEnvelopesQuery_Filter() {} func (*EnvelopesQuery_OriginatorId) isEnvelopesQuery_Filter() {} +// Batch subscribe to envelopes type BatchSubscribeEnvelopesRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -635,7 +701,7 @@ type BatchSubscribeEnvelopesRequest struct { func (x *BatchSubscribeEnvelopesRequest) Reset() { *x = BatchSubscribeEnvelopesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[8] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -648,7 +714,7 @@ func (x *BatchSubscribeEnvelopesRequest) String() string { func (*BatchSubscribeEnvelopesRequest) ProtoMessage() {} func (x *BatchSubscribeEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[8] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -661,7 +727,7 @@ func (x *BatchSubscribeEnvelopesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use BatchSubscribeEnvelopesRequest.ProtoReflect.Descriptor instead. func (*BatchSubscribeEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{8} + return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{9} } func (x *BatchSubscribeEnvelopesRequest) GetRequests() []*BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest { @@ -671,32 +737,32 @@ func (x *BatchSubscribeEnvelopesRequest) GetRequests() []*BatchSubscribeEnvelope return nil } -// Pagination config for queries -type PagingInfo struct { +// Streamed response for batch subscribe - can be multiple envelopes at once +type BatchSubscribeEnvelopesResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Limit uint32 `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"` + Envelopes []*GatewayEnvelope `protobuf:"bytes,1,rep,name=envelopes,proto3" json:"envelopes,omitempty"` } -func (x *PagingInfo) Reset() { - *x = PagingInfo{} +func (x *BatchSubscribeEnvelopesResponse) Reset() { + *x = BatchSubscribeEnvelopesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[9] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *PagingInfo) String() string { +func (x *BatchSubscribeEnvelopesResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*PagingInfo) ProtoMessage() {} +func (*BatchSubscribeEnvelopesResponse) ProtoMessage() {} -func (x *PagingInfo) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[9] +func (x *BatchSubscribeEnvelopesResponse) ProtoReflect() protoreflect.Message { + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -707,31 +773,32 @@ func (x *PagingInfo) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use PagingInfo.ProtoReflect.Descriptor instead. -func (*PagingInfo) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{9} +// Deprecated: Use BatchSubscribeEnvelopesResponse.ProtoReflect.Descriptor instead. +func (*BatchSubscribeEnvelopesResponse) Descriptor() ([]byte, []int) { + return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{10} } -func (x *PagingInfo) GetLimit() uint32 { +func (x *BatchSubscribeEnvelopesResponse) GetEnvelopes() []*GatewayEnvelope { if x != nil { - return x.Limit + return x.Envelopes } - return 0 + return nil } +// Query envelopes request type QueryEnvelopesRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Query *EnvelopesQuery `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` - PagingInfo *PagingInfo `protobuf:"bytes,2,opt,name=paging_info,json=pagingInfo,proto3" json:"paging_info,omitempty"` + Query *EnvelopesQuery `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` + Limit uint32 `protobuf:"varint,2,opt,name=limit,proto3" json:"limit,omitempty"` } func (x *QueryEnvelopesRequest) Reset() { *x = QueryEnvelopesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[10] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -744,7 +811,7 @@ func (x *QueryEnvelopesRequest) String() string { func (*QueryEnvelopesRequest) ProtoMessage() {} func (x *QueryEnvelopesRequest) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[10] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -757,7 +824,7 @@ func (x *QueryEnvelopesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryEnvelopesRequest.ProtoReflect.Descriptor instead. func (*QueryEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{10} + return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{11} } func (x *QueryEnvelopesRequest) GetQuery() *EnvelopesQuery { @@ -767,13 +834,14 @@ func (x *QueryEnvelopesRequest) GetQuery() *EnvelopesQuery { return nil } -func (x *QueryEnvelopesRequest) GetPagingInfo() *PagingInfo { +func (x *QueryEnvelopesRequest) GetLimit() uint32 { if x != nil { - return x.PagingInfo + return x.Limit } - return nil + return 0 } +// Query envelopes response type QueryEnvelopesResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -785,7 +853,7 @@ type QueryEnvelopesResponse struct { func (x *QueryEnvelopesResponse) Reset() { *x = QueryEnvelopesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[11] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -798,7 +866,7 @@ func (x *QueryEnvelopesResponse) String() string { func (*QueryEnvelopesResponse) ProtoMessage() {} func (x *QueryEnvelopesResponse) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[11] + mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -811,71 +879,17 @@ func (x *QueryEnvelopesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use QueryEnvelopesResponse.ProtoReflect.Descriptor instead. func (*QueryEnvelopesResponse) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{11} -} - -func (x *QueryEnvelopesResponse) GetEnvelopes() []*GatewayEnvelope { - if x != nil { - return x.Envelopes - } - return nil -} - -type MisbehaviorReport struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Type Misbehavior `protobuf:"varint,1,opt,name=type,proto3,enum=xmtp.xmtpv4.Misbehavior" json:"type,omitempty"` - Envelopes []*OriginatorEnvelope `protobuf:"bytes,2,rep,name=envelopes,proto3" json:"envelopes,omitempty"` -} - -func (x *MisbehaviorReport) Reset() { - *x = MisbehaviorReport{} - if protoimpl.UnsafeEnabled { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *MisbehaviorReport) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*MisbehaviorReport) ProtoMessage() {} - -func (x *MisbehaviorReport) ProtoReflect() protoreflect.Message { - mi := &file_xmtpv4_message_api_message_api_proto_msgTypes[12] - if protoimpl.UnsafeEnabled && x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use MisbehaviorReport.ProtoReflect.Descriptor instead. -func (*MisbehaviorReport) Descriptor() ([]byte, []int) { return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{12} } -func (x *MisbehaviorReport) GetType() Misbehavior { - if x != nil { - return x.Type - } - return Misbehavior_MISBEHAVIOR_UNSPECIFIED -} - -func (x *MisbehaviorReport) GetEnvelopes() []*OriginatorEnvelope { +func (x *QueryEnvelopesResponse) GetEnvelopes() []*GatewayEnvelope { if x != nil { return x.Envelopes } return nil } +// Single subscription request for envelopes type BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -913,7 +927,7 @@ func (x *BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest) ProtoReflect( // Deprecated: Use BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest.ProtoReflect.Descriptor instead. func (*BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest) Descriptor() ([]byte, []int) { - return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{8, 0} + return file_xmtpv4_message_api_message_api_proto_rawDescGZIP(), []int{9, 0} } func (x *BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest) GetQuery() *EnvelopesQuery { @@ -995,98 +1009,100 @@ var file_xmtpv4_message_api_message_api_proto_rawDesc = []byte{ 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x4f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x12, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, - 0x72, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x22, 0xb2, 0x01, 0x0a, 0x0e, 0x45, 0x6e, - 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, 0x27, 0x0a, 0x0e, - 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x5f, 0x73, 0x69, 0x64, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, 0x0d, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, - 0x6f, 0x72, 0x53, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x0b, 0x67, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, - 0x5f, 0x73, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, 0x0a, 0x67, 0x61, - 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x05, 0x74, 0x6f, 0x70, 0x69, - 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x48, 0x01, 0x52, 0x05, 0x74, 0x6f, 0x70, 0x69, 0x63, - 0x12, 0x25, 0x0a, 0x0d, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x5f, 0x69, - 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x48, 0x01, 0x52, 0x0c, 0x6f, 0x72, 0x69, 0x67, 0x69, - 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x64, 0x42, 0x0b, 0x0a, 0x09, 0x6c, 0x61, 0x73, 0x74, 0x5f, - 0x73, 0x65, 0x65, 0x6e, 0x42, 0x08, 0x0a, 0x06, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x22, 0xd3, - 0x01, 0x0a, 0x1e, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, - 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x61, 0x0a, 0x08, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x18, 0x01, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x45, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, - 0x34, 0x2e, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, - 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, - 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x08, 0x72, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x73, 0x1a, 0x4e, 0x0a, 0x19, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, - 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x12, 0x31, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x45, - 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x05, 0x71, - 0x75, 0x65, 0x72, 0x79, 0x22, 0x22, 0x0a, 0x0a, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x49, 0x6e, - 0x66, 0x6f, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0d, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x84, 0x01, 0x0a, 0x15, 0x51, 0x75, 0x65, - 0x72, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x12, 0x31, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1b, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, - 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x05, - 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, 0x38, 0x0a, 0x0b, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x5f, - 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x78, 0x6d, 0x74, - 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x50, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x49, - 0x6e, 0x66, 0x6f, 0x52, 0x0a, 0x70, 0x61, 0x67, 0x69, 0x6e, 0x67, 0x49, 0x6e, 0x66, 0x6f, 0x22, - 0x54, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, - 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3a, 0x0a, 0x09, 0x65, 0x6e, 0x76, - 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x78, - 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x47, 0x61, 0x74, 0x65, 0x77, - 0x61, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x09, 0x65, 0x6e, 0x76, 0x65, - 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x22, 0x80, 0x01, 0x0a, 0x11, 0x4d, 0x69, 0x73, 0x62, 0x65, 0x68, - 0x61, 0x76, 0x69, 0x6f, 0x72, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x2c, 0x0a, 0x04, 0x74, - 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, 0x78, 0x6d, 0x74, 0x70, - 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x4d, 0x69, 0x73, 0x62, 0x65, 0x68, 0x61, 0x76, - 0x69, 0x6f, 0x72, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x3d, 0x0a, 0x09, 0x65, 0x6e, 0x76, - 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x78, - 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x4f, 0x72, 0x69, 0x67, 0x69, - 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x09, 0x65, - 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x2a, 0xce, 0x01, 0x0a, 0x0b, 0x4d, 0x69, 0x73, - 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x12, 0x1b, 0x0a, 0x17, 0x4d, 0x49, 0x53, 0x42, - 0x45, 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, - 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x20, 0x0a, 0x1c, 0x4d, 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, - 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x55, 0x4e, 0x41, 0x56, 0x41, 0x49, 0x4c, 0x41, 0x42, 0x4c, 0x45, - 0x5f, 0x4e, 0x4f, 0x44, 0x45, 0x10, 0x01, 0x12, 0x2b, 0x0a, 0x27, 0x4d, 0x49, 0x53, 0x42, 0x45, - 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x4f, 0x55, 0x54, 0x5f, 0x4f, 0x46, 0x5f, 0x4f, 0x52, - 0x44, 0x45, 0x52, 0x5f, 0x4f, 0x52, 0x49, 0x47, 0x49, 0x4e, 0x41, 0x54, 0x4f, 0x52, 0x5f, 0x53, - 0x49, 0x44, 0x10, 0x02, 0x12, 0x28, 0x0a, 0x24, 0x4d, 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, - 0x49, 0x4f, 0x52, 0x5f, 0x44, 0x55, 0x50, 0x4c, 0x49, 0x43, 0x41, 0x54, 0x45, 0x5f, 0x4f, 0x52, - 0x49, 0x47, 0x49, 0x4e, 0x41, 0x54, 0x4f, 0x52, 0x5f, 0x53, 0x49, 0x44, 0x10, 0x03, 0x12, 0x29, - 0x0a, 0x25, 0x4d, 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x43, 0x59, - 0x43, 0x4c, 0x49, 0x43, 0x41, 0x4c, 0x5f, 0x4d, 0x45, 0x53, 0x53, 0x41, 0x47, 0x45, 0x5f, 0x4f, - 0x52, 0x44, 0x45, 0x52, 0x49, 0x4e, 0x47, 0x10, 0x04, 0x32, 0x9b, 0x02, 0x0a, 0x0e, 0x52, 0x65, - 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x41, 0x70, 0x69, 0x12, 0x89, 0x01, 0x0a, - 0x12, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, - 0x70, 0x65, 0x73, 0x12, 0x2b, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, - 0x34, 0x2e, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, - 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x1a, 0x1c, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x47, - 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x22, 0x26, - 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x20, 0x3a, 0x01, 0x2a, 0x22, 0x1b, 0x2f, 0x6d, 0x6c, 0x73, 0x2f, - 0x76, 0x32, 0x2f, 0x73, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2d, 0x65, 0x6e, 0x76, - 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x30, 0x01, 0x12, 0x7d, 0x0a, 0x0e, 0x51, 0x75, 0x65, 0x72, - 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x12, 0x22, 0x2e, 0x78, 0x6d, 0x74, - 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, - 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, - 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x51, 0x75, 0x65, - 0x72, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, - 0x6e, 0x73, 0x65, 0x22, 0x22, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x3a, 0x01, 0x2a, 0x22, 0x17, - 0x2f, 0x6d, 0x6c, 0x73, 0x2f, 0x76, 0x32, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2d, 0x65, 0x6e, - 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x42, 0xa3, 0x01, 0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, - 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x42, 0x0f, 0x4d, 0x65, 0x73, - 0x73, 0x61, 0x67, 0x65, 0x41, 0x70, 0x69, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x32, - 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x2f, - 0x78, 0x6d, 0x74, 0x70, 0x64, 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, - 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x61, - 0x70, 0x69, 0xa2, 0x02, 0x03, 0x58, 0x58, 0x58, 0xaa, 0x02, 0x0b, 0x58, 0x6d, 0x74, 0x70, 0x2e, - 0x58, 0x6d, 0x74, 0x70, 0x76, 0x34, 0xca, 0x02, 0x0b, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x58, 0x6d, - 0x74, 0x70, 0x76, 0x34, 0xe2, 0x02, 0x17, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x58, 0x6d, 0x74, 0x70, - 0x76, 0x34, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, - 0x0c, 0x58, 0x6d, 0x74, 0x70, 0x3a, 0x3a, 0x58, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x62, 0x06, 0x70, - 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x72, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x22, 0x80, 0x01, 0x0a, 0x11, 0x4d, 0x69, + 0x73, 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x12, + 0x2c, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x18, 0x2e, + 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x4d, 0x69, 0x73, 0x62, + 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x3d, 0x0a, + 0x09, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1f, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x4f, + 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, + 0x65, 0x52, 0x09, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x22, 0xb2, 0x01, 0x0a, + 0x0e, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x12, + 0x27, 0x0a, 0x0e, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x5f, 0x73, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, 0x0d, 0x6f, 0x72, 0x69, 0x67, 0x69, + 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x53, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x0b, 0x67, 0x61, 0x74, 0x65, + 0x77, 0x61, 0x79, 0x5f, 0x73, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, + 0x0a, 0x67, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x53, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x05, 0x74, + 0x6f, 0x70, 0x69, 0x63, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x48, 0x01, 0x52, 0x05, 0x74, 0x6f, + 0x70, 0x69, 0x63, 0x12, 0x25, 0x0a, 0x0d, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, + 0x72, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x48, 0x01, 0x52, 0x0c, 0x6f, 0x72, + 0x69, 0x67, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x49, 0x64, 0x42, 0x0b, 0x0a, 0x09, 0x6c, 0x61, + 0x73, 0x74, 0x5f, 0x73, 0x65, 0x65, 0x6e, 0x42, 0x08, 0x0a, 0x06, 0x66, 0x69, 0x6c, 0x74, 0x65, + 0x72, 0x22, 0xd3, 0x01, 0x0a, 0x1e, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, 0x63, + 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x61, 0x0a, 0x08, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, + 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x45, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, + 0x74, 0x70, 0x76, 0x34, 0x2e, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, + 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x2e, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, + 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x08, 0x72, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x1a, 0x4e, 0x0a, 0x19, 0x53, 0x75, 0x62, 0x73, 0x63, + 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x31, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, + 0x34, 0x2e, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, + 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x22, 0x5d, 0x0a, 0x1f, 0x42, 0x61, 0x74, 0x63, 0x68, + 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, + 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x3a, 0x0a, 0x09, 0x65, 0x6e, + 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, + 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x47, 0x61, 0x74, 0x65, + 0x77, 0x61, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x52, 0x09, 0x65, 0x6e, 0x76, + 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x22, 0x60, 0x0a, 0x15, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, + 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x31, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, + 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x45, 0x6e, 0x76, + 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x51, 0x75, 0x65, 0x72, 0x79, 0x52, 0x05, 0x71, 0x75, 0x65, + 0x72, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0d, 0x52, 0x05, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x22, 0x54, 0x0a, 0x16, 0x51, 0x75, 0x65, 0x72, + 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x3a, 0x0a, 0x09, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x18, + 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, + 0x70, 0x76, 0x34, 0x2e, 0x47, 0x61, 0x74, 0x65, 0x77, 0x61, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, + 0x6f, 0x70, 0x65, 0x52, 0x09, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x2a, 0xce, + 0x01, 0x0a, 0x0b, 0x4d, 0x69, 0x73, 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x12, 0x1b, + 0x0a, 0x17, 0x4d, 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x55, 0x4e, + 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x20, 0x0a, 0x1c, 0x4d, + 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x55, 0x4e, 0x41, 0x56, 0x41, + 0x49, 0x4c, 0x41, 0x42, 0x4c, 0x45, 0x5f, 0x4e, 0x4f, 0x44, 0x45, 0x10, 0x01, 0x12, 0x2b, 0x0a, + 0x27, 0x4d, 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x4f, 0x55, 0x54, + 0x5f, 0x4f, 0x46, 0x5f, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x5f, 0x4f, 0x52, 0x49, 0x47, 0x49, 0x4e, + 0x41, 0x54, 0x4f, 0x52, 0x5f, 0x53, 0x49, 0x44, 0x10, 0x02, 0x12, 0x28, 0x0a, 0x24, 0x4d, 0x49, + 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, 0x49, 0x4f, 0x52, 0x5f, 0x44, 0x55, 0x50, 0x4c, 0x49, 0x43, + 0x41, 0x54, 0x45, 0x5f, 0x4f, 0x52, 0x49, 0x47, 0x49, 0x4e, 0x41, 0x54, 0x4f, 0x52, 0x5f, 0x53, + 0x49, 0x44, 0x10, 0x03, 0x12, 0x29, 0x0a, 0x25, 0x4d, 0x49, 0x53, 0x42, 0x45, 0x48, 0x41, 0x56, + 0x49, 0x4f, 0x52, 0x5f, 0x43, 0x59, 0x43, 0x4c, 0x49, 0x43, 0x41, 0x4c, 0x5f, 0x4d, 0x45, 0x53, + 0x53, 0x41, 0x47, 0x45, 0x5f, 0x4f, 0x52, 0x44, 0x45, 0x52, 0x49, 0x4e, 0x47, 0x10, 0x04, 0x32, + 0xb0, 0x02, 0x0a, 0x0e, 0x52, 0x65, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x41, + 0x70, 0x69, 0x12, 0x9e, 0x01, 0x0a, 0x17, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, + 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x12, 0x2b, + 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x42, 0x61, 0x74, + 0x63, 0x68, 0x53, 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, + 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x2c, 0x2e, 0x78, 0x6d, + 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, + 0x75, 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x26, 0x82, 0xd3, 0xe4, 0x93, 0x02, + 0x20, 0x3a, 0x01, 0x2a, 0x22, 0x1b, 0x2f, 0x6d, 0x6c, 0x73, 0x2f, 0x76, 0x32, 0x2f, 0x73, 0x75, + 0x62, 0x73, 0x63, 0x72, 0x69, 0x62, 0x65, 0x2d, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, 0x65, + 0x73, 0x30, 0x01, 0x12, 0x7d, 0x0a, 0x0e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x76, 0x65, + 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x12, 0x22, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, 0x78, 0x6d, 0x74, + 0x70, 0x76, 0x34, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, + 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x23, 0x2e, 0x78, 0x6d, 0x74, 0x70, + 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x2e, 0x51, 0x75, 0x65, 0x72, 0x79, 0x45, 0x6e, 0x76, + 0x65, 0x6c, 0x6f, 0x70, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x22, + 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x1c, 0x3a, 0x01, 0x2a, 0x22, 0x17, 0x2f, 0x6d, 0x6c, 0x73, 0x2f, + 0x76, 0x32, 0x2f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x2d, 0x65, 0x6e, 0x76, 0x65, 0x6c, 0x6f, 0x70, + 0x65, 0x73, 0x42, 0xa3, 0x01, 0x0a, 0x0f, 0x63, 0x6f, 0x6d, 0x2e, 0x78, 0x6d, 0x74, 0x70, 0x2e, + 0x78, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x42, 0x0f, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x41, + 0x70, 0x69, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x32, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x64, + 0x2f, 0x70, 0x6b, 0x67, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x78, 0x6d, 0x74, 0x70, 0x76, + 0x34, 0x2f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x5f, 0x61, 0x70, 0x69, 0xa2, 0x02, 0x03, + 0x58, 0x58, 0x58, 0xaa, 0x02, 0x0b, 0x58, 0x6d, 0x74, 0x70, 0x2e, 0x58, 0x6d, 0x74, 0x70, 0x76, + 0x34, 0xca, 0x02, 0x0b, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x58, 0x6d, 0x74, 0x70, 0x76, 0x34, 0xe2, + 0x02, 0x17, 0x58, 0x6d, 0x74, 0x70, 0x5c, 0x58, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x5c, 0x47, 0x50, + 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x0c, 0x58, 0x6d, 0x74, 0x70, + 0x3a, 0x3a, 0x58, 0x6d, 0x74, 0x70, 0x76, 0x34, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1104,20 +1120,20 @@ func file_xmtpv4_message_api_message_api_proto_rawDescGZIP() []byte { var file_xmtpv4_message_api_message_api_proto_enumTypes = make([]protoimpl.EnumInfo, 1) var file_xmtpv4_message_api_message_api_proto_msgTypes = make([]protoimpl.MessageInfo, 14) var file_xmtpv4_message_api_message_api_proto_goTypes = []any{ - (Misbehavior)(0), // 0: xmtp.xmtpv4.Misbehavior - (*AuthenticatedData)(nil), // 1: xmtp.xmtpv4.AuthenticatedData - (*ClientEnvelope)(nil), // 2: xmtp.xmtpv4.ClientEnvelope - (*PayerEnvelope)(nil), // 3: xmtp.xmtpv4.PayerEnvelope - (*UnsignedOriginatorEnvelope)(nil), // 4: xmtp.xmtpv4.UnsignedOriginatorEnvelope - (*BlockchainProof)(nil), // 5: xmtp.xmtpv4.BlockchainProof - (*OriginatorEnvelope)(nil), // 6: xmtp.xmtpv4.OriginatorEnvelope - (*GatewayEnvelope)(nil), // 7: xmtp.xmtpv4.GatewayEnvelope - (*EnvelopesQuery)(nil), // 8: xmtp.xmtpv4.EnvelopesQuery - (*BatchSubscribeEnvelopesRequest)(nil), // 9: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest - (*PagingInfo)(nil), // 10: xmtp.xmtpv4.PagingInfo - (*QueryEnvelopesRequest)(nil), // 11: xmtp.xmtpv4.QueryEnvelopesRequest - (*QueryEnvelopesResponse)(nil), // 12: xmtp.xmtpv4.QueryEnvelopesResponse - (*MisbehaviorReport)(nil), // 13: xmtp.xmtpv4.MisbehaviorReport + (Misbehavior)(0), // 0: xmtp.xmtpv4.Misbehavior + (*AuthenticatedData)(nil), // 1: xmtp.xmtpv4.AuthenticatedData + (*ClientEnvelope)(nil), // 2: xmtp.xmtpv4.ClientEnvelope + (*PayerEnvelope)(nil), // 3: xmtp.xmtpv4.PayerEnvelope + (*UnsignedOriginatorEnvelope)(nil), // 4: xmtp.xmtpv4.UnsignedOriginatorEnvelope + (*BlockchainProof)(nil), // 5: xmtp.xmtpv4.BlockchainProof + (*OriginatorEnvelope)(nil), // 6: xmtp.xmtpv4.OriginatorEnvelope + (*GatewayEnvelope)(nil), // 7: xmtp.xmtpv4.GatewayEnvelope + (*MisbehaviorReport)(nil), // 8: xmtp.xmtpv4.MisbehaviorReport + (*EnvelopesQuery)(nil), // 9: xmtp.xmtpv4.EnvelopesQuery + (*BatchSubscribeEnvelopesRequest)(nil), // 10: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest + (*BatchSubscribeEnvelopesResponse)(nil), // 11: xmtp.xmtpv4.BatchSubscribeEnvelopesResponse + (*QueryEnvelopesRequest)(nil), // 12: xmtp.xmtpv4.QueryEnvelopesRequest + (*QueryEnvelopesResponse)(nil), // 13: xmtp.xmtpv4.QueryEnvelopesResponse (*BatchSubscribeEnvelopesRequest_SubscribeEnvelopesRequest)(nil), // 14: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.SubscribeEnvelopesRequest (*associations.RecoverableEcdsaSignature)(nil), // 15: xmtp.identity.associations.RecoverableEcdsaSignature } @@ -1127,17 +1143,17 @@ var file_xmtpv4_message_api_message_api_proto_depIdxs = []int32{ 15, // 2: xmtp.xmtpv4.OriginatorEnvelope.originator_signature:type_name -> xmtp.identity.associations.RecoverableEcdsaSignature 5, // 3: xmtp.xmtpv4.OriginatorEnvelope.blockchain_proof:type_name -> xmtp.xmtpv4.BlockchainProof 6, // 4: xmtp.xmtpv4.GatewayEnvelope.originator_envelope:type_name -> xmtp.xmtpv4.OriginatorEnvelope - 14, // 5: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.requests:type_name -> xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.SubscribeEnvelopesRequest - 8, // 6: xmtp.xmtpv4.QueryEnvelopesRequest.query:type_name -> xmtp.xmtpv4.EnvelopesQuery - 10, // 7: xmtp.xmtpv4.QueryEnvelopesRequest.paging_info:type_name -> xmtp.xmtpv4.PagingInfo - 7, // 8: xmtp.xmtpv4.QueryEnvelopesResponse.envelopes:type_name -> xmtp.xmtpv4.GatewayEnvelope - 0, // 9: xmtp.xmtpv4.MisbehaviorReport.type:type_name -> xmtp.xmtpv4.Misbehavior - 6, // 10: xmtp.xmtpv4.MisbehaviorReport.envelopes:type_name -> xmtp.xmtpv4.OriginatorEnvelope - 8, // 11: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.SubscribeEnvelopesRequest.query:type_name -> xmtp.xmtpv4.EnvelopesQuery - 9, // 12: xmtp.xmtpv4.ReplicationApi.SubscribeEnvelopes:input_type -> xmtp.xmtpv4.BatchSubscribeEnvelopesRequest - 11, // 13: xmtp.xmtpv4.ReplicationApi.QueryEnvelopes:input_type -> xmtp.xmtpv4.QueryEnvelopesRequest - 7, // 14: xmtp.xmtpv4.ReplicationApi.SubscribeEnvelopes:output_type -> xmtp.xmtpv4.GatewayEnvelope - 12, // 15: xmtp.xmtpv4.ReplicationApi.QueryEnvelopes:output_type -> xmtp.xmtpv4.QueryEnvelopesResponse + 0, // 5: xmtp.xmtpv4.MisbehaviorReport.type:type_name -> xmtp.xmtpv4.Misbehavior + 6, // 6: xmtp.xmtpv4.MisbehaviorReport.envelopes:type_name -> xmtp.xmtpv4.OriginatorEnvelope + 14, // 7: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.requests:type_name -> xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.SubscribeEnvelopesRequest + 7, // 8: xmtp.xmtpv4.BatchSubscribeEnvelopesResponse.envelopes:type_name -> xmtp.xmtpv4.GatewayEnvelope + 9, // 9: xmtp.xmtpv4.QueryEnvelopesRequest.query:type_name -> xmtp.xmtpv4.EnvelopesQuery + 7, // 10: xmtp.xmtpv4.QueryEnvelopesResponse.envelopes:type_name -> xmtp.xmtpv4.GatewayEnvelope + 9, // 11: xmtp.xmtpv4.BatchSubscribeEnvelopesRequest.SubscribeEnvelopesRequest.query:type_name -> xmtp.xmtpv4.EnvelopesQuery + 10, // 12: xmtp.xmtpv4.ReplicationApi.BatchSubscribeEnvelopes:input_type -> xmtp.xmtpv4.BatchSubscribeEnvelopesRequest + 12, // 13: xmtp.xmtpv4.ReplicationApi.QueryEnvelopes:input_type -> xmtp.xmtpv4.QueryEnvelopesRequest + 11, // 14: xmtp.xmtpv4.ReplicationApi.BatchSubscribeEnvelopes:output_type -> xmtp.xmtpv4.BatchSubscribeEnvelopesResponse + 13, // 15: xmtp.xmtpv4.ReplicationApi.QueryEnvelopes:output_type -> xmtp.xmtpv4.QueryEnvelopesResponse 14, // [14:16] is the sub-list for method output_type 12, // [12:14] is the sub-list for method input_type 12, // [12:12] is the sub-list for extension type_name @@ -1236,7 +1252,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { } } file_xmtpv4_message_api_message_api_proto_msgTypes[7].Exporter = func(v any, i int) any { - switch v := v.(*EnvelopesQuery); i { + switch v := v.(*MisbehaviorReport); i { case 0: return &v.state case 1: @@ -1248,7 +1264,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { } } file_xmtpv4_message_api_message_api_proto_msgTypes[8].Exporter = func(v any, i int) any { - switch v := v.(*BatchSubscribeEnvelopesRequest); i { + switch v := v.(*EnvelopesQuery); i { case 0: return &v.state case 1: @@ -1260,7 +1276,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { } } file_xmtpv4_message_api_message_api_proto_msgTypes[9].Exporter = func(v any, i int) any { - switch v := v.(*PagingInfo); i { + switch v := v.(*BatchSubscribeEnvelopesRequest); i { case 0: return &v.state case 1: @@ -1272,7 +1288,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { } } file_xmtpv4_message_api_message_api_proto_msgTypes[10].Exporter = func(v any, i int) any { - switch v := v.(*QueryEnvelopesRequest); i { + switch v := v.(*BatchSubscribeEnvelopesResponse); i { case 0: return &v.state case 1: @@ -1284,7 +1300,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { } } file_xmtpv4_message_api_message_api_proto_msgTypes[11].Exporter = func(v any, i int) any { - switch v := v.(*QueryEnvelopesResponse); i { + switch v := v.(*QueryEnvelopesRequest); i { case 0: return &v.state case 1: @@ -1296,7 +1312,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { } } file_xmtpv4_message_api_message_api_proto_msgTypes[12].Exporter = func(v any, i int) any { - switch v := v.(*MisbehaviorReport); i { + switch v := v.(*QueryEnvelopesResponse); i { case 0: return &v.state case 1: @@ -1324,7 +1340,7 @@ func file_xmtpv4_message_api_message_api_proto_init() { (*OriginatorEnvelope_OriginatorSignature)(nil), (*OriginatorEnvelope_BlockchainProof)(nil), } - file_xmtpv4_message_api_message_api_proto_msgTypes[7].OneofWrappers = []any{ + file_xmtpv4_message_api_message_api_proto_msgTypes[8].OneofWrappers = []any{ (*EnvelopesQuery_OriginatorSid)(nil), (*EnvelopesQuery_GatewaySid)(nil), (*EnvelopesQuery_Topic)(nil), diff --git a/pkg/proto/xmtpv4/message_api/message_api.pb.gw.go b/pkg/proto/xmtpv4/message_api/message_api.pb.gw.go index 5f5e0715..402c6eb0 100644 --- a/pkg/proto/xmtpv4/message_api/message_api.pb.gw.go +++ b/pkg/proto/xmtpv4/message_api/message_api.pb.gw.go @@ -31,7 +31,7 @@ var _ = runtime.String var _ = utilities.NewDoubleArray var _ = metadata.Join -func request_ReplicationApi_SubscribeEnvelopes_0(ctx context.Context, marshaler runtime.Marshaler, client ReplicationApiClient, req *http.Request, pathParams map[string]string) (ReplicationApi_SubscribeEnvelopesClient, runtime.ServerMetadata, error) { +func request_ReplicationApi_BatchSubscribeEnvelopes_0(ctx context.Context, marshaler runtime.Marshaler, client ReplicationApiClient, req *http.Request, pathParams map[string]string) (ReplicationApi_BatchSubscribeEnvelopesClient, runtime.ServerMetadata, error) { var protoReq BatchSubscribeEnvelopesRequest var metadata runtime.ServerMetadata @@ -39,7 +39,7 @@ func request_ReplicationApi_SubscribeEnvelopes_0(ctx context.Context, marshaler return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } - stream, err := client.SubscribeEnvelopes(ctx, &protoReq) + stream, err := client.BatchSubscribeEnvelopes(ctx, &protoReq) if err != nil { return nil, metadata, err } @@ -84,7 +84,7 @@ func local_request_ReplicationApi_QueryEnvelopes_0(ctx context.Context, marshale // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterReplicationApiHandlerFromEndpoint instead. func RegisterReplicationApiHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ReplicationApiServer) error { - mux.Handle("POST", pattern_ReplicationApi_SubscribeEnvelopes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_ReplicationApi_BatchSubscribeEnvelopes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { err := status.Error(codes.Unimplemented, "streaming calls are not yet supported in the in-process transport") _, outboundMarshaler := runtime.MarshalerForRequest(mux, req) runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) @@ -157,25 +157,25 @@ func RegisterReplicationApiHandler(ctx context.Context, mux *runtime.ServeMux, c // "ReplicationApiClient" to call the correct interceptors. func RegisterReplicationApiHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ReplicationApiClient) error { - mux.Handle("POST", pattern_ReplicationApi_SubscribeEnvelopes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { + mux.Handle("POST", pattern_ReplicationApi_BatchSubscribeEnvelopes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) var err error var annotatedContext context.Context - annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/xmtp.xmtpv4.ReplicationApi/SubscribeEnvelopes", runtime.WithHTTPPathPattern("/mls/v2/subscribe-envelopes")) + annotatedContext, err = runtime.AnnotateContext(ctx, mux, req, "/xmtp.xmtpv4.ReplicationApi/BatchSubscribeEnvelopes", runtime.WithHTTPPathPattern("/mls/v2/subscribe-envelopes")) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } - resp, md, err := request_ReplicationApi_SubscribeEnvelopes_0(annotatedContext, inboundMarshaler, client, req, pathParams) + resp, md, err := request_ReplicationApi_BatchSubscribeEnvelopes_0(annotatedContext, inboundMarshaler, client, req, pathParams) annotatedContext = runtime.NewServerMetadataContext(annotatedContext, md) if err != nil { runtime.HTTPError(annotatedContext, mux, outboundMarshaler, w, req, err) return } - forward_ReplicationApi_SubscribeEnvelopes_0(annotatedContext, mux, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...) + forward_ReplicationApi_BatchSubscribeEnvelopes_0(annotatedContext, mux, outboundMarshaler, w, req, func() (proto.Message, error) { return resp.Recv() }, mux.GetForwardResponseOptions()...) }) @@ -205,13 +205,13 @@ func RegisterReplicationApiHandlerClient(ctx context.Context, mux *runtime.Serve } var ( - pattern_ReplicationApi_SubscribeEnvelopes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"mls", "v2", "subscribe-envelopes"}, "")) + pattern_ReplicationApi_BatchSubscribeEnvelopes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"mls", "v2", "subscribe-envelopes"}, "")) pattern_ReplicationApi_QueryEnvelopes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"mls", "v2", "query-envelopes"}, "")) ) var ( - forward_ReplicationApi_SubscribeEnvelopes_0 = runtime.ForwardResponseStream + forward_ReplicationApi_BatchSubscribeEnvelopes_0 = runtime.ForwardResponseStream forward_ReplicationApi_QueryEnvelopes_0 = runtime.ForwardResponseMessage ) diff --git a/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go b/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go index f9105dde..5f3ecefe 100644 --- a/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go +++ b/pkg/proto/xmtpv4/message_api/message_api_grpc.pb.go @@ -1,3 +1,5 @@ +// Message API for XMTP V4 + // Code generated by protoc-gen-go-grpc. DO NOT EDIT. // versions: // - protoc-gen-go-grpc v1.3.0 @@ -19,15 +21,17 @@ import ( const _ = grpc.SupportPackageIsVersion7 const ( - ReplicationApi_SubscribeEnvelopes_FullMethodName = "/xmtp.xmtpv4.ReplicationApi/SubscribeEnvelopes" - ReplicationApi_QueryEnvelopes_FullMethodName = "/xmtp.xmtpv4.ReplicationApi/QueryEnvelopes" + ReplicationApi_BatchSubscribeEnvelopes_FullMethodName = "/xmtp.xmtpv4.ReplicationApi/BatchSubscribeEnvelopes" + ReplicationApi_QueryEnvelopes_FullMethodName = "/xmtp.xmtpv4.ReplicationApi/QueryEnvelopes" ) // ReplicationApiClient is the client API for ReplicationApi service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type ReplicationApiClient interface { - SubscribeEnvelopes(ctx context.Context, in *BatchSubscribeEnvelopesRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeEnvelopesClient, error) + // Subscribe to envelopes + BatchSubscribeEnvelopes(ctx context.Context, in *BatchSubscribeEnvelopesRequest, opts ...grpc.CallOption) (ReplicationApi_BatchSubscribeEnvelopesClient, error) + // Query envelopes QueryEnvelopes(ctx context.Context, in *QueryEnvelopesRequest, opts ...grpc.CallOption) (*QueryEnvelopesResponse, error) } @@ -39,12 +43,12 @@ func NewReplicationApiClient(cc grpc.ClientConnInterface) ReplicationApiClient { return &replicationApiClient{cc} } -func (c *replicationApiClient) SubscribeEnvelopes(ctx context.Context, in *BatchSubscribeEnvelopesRequest, opts ...grpc.CallOption) (ReplicationApi_SubscribeEnvelopesClient, error) { - stream, err := c.cc.NewStream(ctx, &ReplicationApi_ServiceDesc.Streams[0], ReplicationApi_SubscribeEnvelopes_FullMethodName, opts...) +func (c *replicationApiClient) BatchSubscribeEnvelopes(ctx context.Context, in *BatchSubscribeEnvelopesRequest, opts ...grpc.CallOption) (ReplicationApi_BatchSubscribeEnvelopesClient, error) { + stream, err := c.cc.NewStream(ctx, &ReplicationApi_ServiceDesc.Streams[0], ReplicationApi_BatchSubscribeEnvelopes_FullMethodName, opts...) if err != nil { return nil, err } - x := &replicationApiSubscribeEnvelopesClient{stream} + x := &replicationApiBatchSubscribeEnvelopesClient{stream} if err := x.ClientStream.SendMsg(in); err != nil { return nil, err } @@ -54,17 +58,17 @@ func (c *replicationApiClient) SubscribeEnvelopes(ctx context.Context, in *Batch return x, nil } -type ReplicationApi_SubscribeEnvelopesClient interface { - Recv() (*GatewayEnvelope, error) +type ReplicationApi_BatchSubscribeEnvelopesClient interface { + Recv() (*BatchSubscribeEnvelopesResponse, error) grpc.ClientStream } -type replicationApiSubscribeEnvelopesClient struct { +type replicationApiBatchSubscribeEnvelopesClient struct { grpc.ClientStream } -func (x *replicationApiSubscribeEnvelopesClient) Recv() (*GatewayEnvelope, error) { - m := new(GatewayEnvelope) +func (x *replicationApiBatchSubscribeEnvelopesClient) Recv() (*BatchSubscribeEnvelopesResponse, error) { + m := new(BatchSubscribeEnvelopesResponse) if err := x.ClientStream.RecvMsg(m); err != nil { return nil, err } @@ -84,7 +88,9 @@ func (c *replicationApiClient) QueryEnvelopes(ctx context.Context, in *QueryEnve // All implementations must embed UnimplementedReplicationApiServer // for forward compatibility type ReplicationApiServer interface { - SubscribeEnvelopes(*BatchSubscribeEnvelopesRequest, ReplicationApi_SubscribeEnvelopesServer) error + // Subscribe to envelopes + BatchSubscribeEnvelopes(*BatchSubscribeEnvelopesRequest, ReplicationApi_BatchSubscribeEnvelopesServer) error + // Query envelopes QueryEnvelopes(context.Context, *QueryEnvelopesRequest) (*QueryEnvelopesResponse, error) mustEmbedUnimplementedReplicationApiServer() } @@ -93,8 +99,8 @@ type ReplicationApiServer interface { type UnimplementedReplicationApiServer struct { } -func (UnimplementedReplicationApiServer) SubscribeEnvelopes(*BatchSubscribeEnvelopesRequest, ReplicationApi_SubscribeEnvelopesServer) error { - return status.Errorf(codes.Unimplemented, "method SubscribeEnvelopes not implemented") +func (UnimplementedReplicationApiServer) BatchSubscribeEnvelopes(*BatchSubscribeEnvelopesRequest, ReplicationApi_BatchSubscribeEnvelopesServer) error { + return status.Errorf(codes.Unimplemented, "method BatchSubscribeEnvelopes not implemented") } func (UnimplementedReplicationApiServer) QueryEnvelopes(context.Context, *QueryEnvelopesRequest) (*QueryEnvelopesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method QueryEnvelopes not implemented") @@ -112,24 +118,24 @@ func RegisterReplicationApiServer(s grpc.ServiceRegistrar, srv ReplicationApiSer s.RegisterService(&ReplicationApi_ServiceDesc, srv) } -func _ReplicationApi_SubscribeEnvelopes_Handler(srv interface{}, stream grpc.ServerStream) error { +func _ReplicationApi_BatchSubscribeEnvelopes_Handler(srv interface{}, stream grpc.ServerStream) error { m := new(BatchSubscribeEnvelopesRequest) if err := stream.RecvMsg(m); err != nil { return err } - return srv.(ReplicationApiServer).SubscribeEnvelopes(m, &replicationApiSubscribeEnvelopesServer{stream}) + return srv.(ReplicationApiServer).BatchSubscribeEnvelopes(m, &replicationApiBatchSubscribeEnvelopesServer{stream}) } -type ReplicationApi_SubscribeEnvelopesServer interface { - Send(*GatewayEnvelope) error +type ReplicationApi_BatchSubscribeEnvelopesServer interface { + Send(*BatchSubscribeEnvelopesResponse) error grpc.ServerStream } -type replicationApiSubscribeEnvelopesServer struct { +type replicationApiBatchSubscribeEnvelopesServer struct { grpc.ServerStream } -func (x *replicationApiSubscribeEnvelopesServer) Send(m *GatewayEnvelope) error { +func (x *replicationApiBatchSubscribeEnvelopesServer) Send(m *BatchSubscribeEnvelopesResponse) error { return x.ServerStream.SendMsg(m) } @@ -165,8 +171,8 @@ var ReplicationApi_ServiceDesc = grpc.ServiceDesc{ }, Streams: []grpc.StreamDesc{ { - StreamName: "SubscribeEnvelopes", - Handler: _ReplicationApi_SubscribeEnvelopes_Handler, + StreamName: "BatchSubscribeEnvelopes", + Handler: _ReplicationApi_BatchSubscribeEnvelopes_Handler, ServerStreams: true, }, },