xmtp_proto/gen/
xmtp.mls.message_contents.rs

1// This file is @generated by prost-build.
2/// PlaintextCommitLogEntry indicates whether a commit was successful or not,
3/// when applied on top of the indicated `last_epoch_authenticator`.
4#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
5pub struct PlaintextCommitLogEntry {
6    /// The group_id of the group that the commit belongs to.
7    #[prost(bytes = "vec", tag = "1")]
8    pub group_id: ::prost::alloc::vec::Vec<u8>,
9    /// The sequence ID of the commit payload being validated.
10    #[prost(uint64, tag = "2")]
11    pub commit_sequence_id: u64,
12    /// The encryption state before the commit was applied.
13    #[prost(bytes = "vec", tag = "3")]
14    pub last_epoch_authenticator: ::prost::alloc::vec::Vec<u8>,
15    /// Indicates whether the commit was successful, or why it failed.
16    #[prost(enumeration = "CommitResult", tag = "4")]
17    pub commit_result: i32,
18    /// The epoch number after the commit was applied, if successful.
19    #[prost(uint64, tag = "5")]
20    pub applied_epoch_number: u64,
21    /// The encryption state after the commit was applied, if successful.
22    #[prost(bytes = "vec", tag = "6")]
23    pub applied_epoch_authenticator: ::prost::alloc::vec::Vec<u8>,
24}
25impl ::prost::Name for PlaintextCommitLogEntry {
26    const NAME: &'static str = "PlaintextCommitLogEntry";
27    const PACKAGE: &'static str = "xmtp.mls.message_contents";
28    fn full_name() -> ::prost::alloc::string::String {
29        "xmtp.mls.message_contents.PlaintextCommitLogEntry".into()
30    }
31    fn type_url() -> ::prost::alloc::string::String {
32        "/xmtp.mls.message_contents.PlaintextCommitLogEntry".into()
33    }
34}
35#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
36pub struct CommitLogEntry {
37    #[prost(uint64, tag = "1")]
38    pub sequence_id: u64,
39    #[prost(bytes = "vec", tag = "2")]
40    pub serialized_commit_log_entry: ::prost::alloc::vec::Vec<u8>,
41    #[prost(message, optional, tag = "3")]
42    pub signature: ::core::option::Option<
43        super::super::identity::associations::RecoverableEd25519Signature,
44    >,
45}
46impl ::prost::Name for CommitLogEntry {
47    const NAME: &'static str = "CommitLogEntry";
48    const PACKAGE: &'static str = "xmtp.mls.message_contents";
49    fn full_name() -> ::prost::alloc::string::String {
50        "xmtp.mls.message_contents.CommitLogEntry".into()
51    }
52    fn type_url() -> ::prost::alloc::string::String {
53        "/xmtp.mls.message_contents.CommitLogEntry".into()
54    }
55}
56#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
57#[repr(i32)]
58pub enum CommitResult {
59    Unspecified = 0,
60    Applied = 1,
61    WrongEpoch = 2,
62    Undecryptable = 3,
63    Invalid = 4,
64}
65impl CommitResult {
66    /// String value of the enum field names used in the ProtoBuf definition.
67    ///
68    /// The values are not transformed in any way and thus are considered stable
69    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
70    pub fn as_str_name(&self) -> &'static str {
71        match self {
72            Self::Unspecified => "COMMIT_RESULT_UNSPECIFIED",
73            Self::Applied => "COMMIT_RESULT_APPLIED",
74            Self::WrongEpoch => "COMMIT_RESULT_WRONG_EPOCH",
75            Self::Undecryptable => "COMMIT_RESULT_UNDECRYPTABLE",
76            Self::Invalid => "COMMIT_RESULT_INVALID",
77        }
78    }
79    /// Creates an enum from field names used in the ProtoBuf definition.
80    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
81        match value {
82            "COMMIT_RESULT_UNSPECIFIED" => Some(Self::Unspecified),
83            "COMMIT_RESULT_APPLIED" => Some(Self::Applied),
84            "COMMIT_RESULT_WRONG_EPOCH" => Some(Self::WrongEpoch),
85            "COMMIT_RESULT_UNDECRYPTABLE" => Some(Self::Undecryptable),
86            "COMMIT_RESULT_INVALID" => Some(Self::Invalid),
87            _ => None,
88        }
89    }
90}
91/// A WelcomePointer is used to point to the welcome message for several installations at once to save overhead
92#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
93pub struct WelcomePointer {
94    #[prost(oneof = "welcome_pointer::Version", tags = "1")]
95    pub version: ::core::option::Option<welcome_pointer::Version>,
96}
97/// Nested message and enum types in `WelcomePointer`.
98pub mod welcome_pointer {
99    /// Points to a V1 WelcomeMessage
100    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
101    pub struct WelcomeV1Pointer {
102        /// The topic of the welcome message. For V1, this means that it will be the first message in the topic, so no other identifier is required
103        #[prost(bytes = "vec", tag = "1")]
104        pub destination: ::prost::alloc::vec::Vec<u8>,
105        /// The algorithm used to encrypt the welcome pointer
106        #[prost(enumeration = "super::WelcomePointeeEncryptionAeadType", tag = "2")]
107        pub aead_type: i32,
108        /// The encryption key of the welcome message. Must match key size specified by the aead_type.
109        #[prost(bytes = "vec", tag = "3")]
110        pub encryption_key: ::prost::alloc::vec::Vec<u8>,
111        /// Nonce used to encrypt the data field. Must match nonce size specified by the aead_type.
112        #[prost(bytes = "vec", tag = "4")]
113        pub data_nonce: ::prost::alloc::vec::Vec<u8>,
114        /// Nonce used to encrypt the welcome_metadata field. Must match nonce size specified by the aead_type.
115        #[prost(bytes = "vec", tag = "5")]
116        pub welcome_metadata_nonce: ::prost::alloc::vec::Vec<u8>,
117    }
118    impl ::prost::Name for WelcomeV1Pointer {
119        const NAME: &'static str = "WelcomeV1Pointer";
120        const PACKAGE: &'static str = "xmtp.mls.message_contents";
121        fn full_name() -> ::prost::alloc::string::String {
122            "xmtp.mls.message_contents.WelcomePointer.WelcomeV1Pointer".into()
123        }
124        fn type_url() -> ::prost::alloc::string::String {
125            "/xmtp.mls.message_contents.WelcomePointer.WelcomeV1Pointer".into()
126        }
127    }
128    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
129    pub enum Version {
130        #[prost(message, tag = "1")]
131        WelcomeV1Pointer(WelcomeV1Pointer),
132    }
133}
134impl ::prost::Name for WelcomePointer {
135    const NAME: &'static str = "WelcomePointer";
136    const PACKAGE: &'static str = "xmtp.mls.message_contents";
137    fn full_name() -> ::prost::alloc::string::String {
138        "xmtp.mls.message_contents.WelcomePointer".into()
139    }
140    fn type_url() -> ::prost::alloc::string::String {
141        "/xmtp.mls.message_contents.WelcomePointer".into()
142    }
143}
144/// Extension message that indicates the types of encryption supported by a client
145#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
146pub struct WelcomePointeeEncryptionAeadTypesExtension {
147    #[prost(enumeration = "WelcomePointeeEncryptionAeadType", repeated, tag = "1")]
148    pub supported_aead_types: ::prost::alloc::vec::Vec<i32>,
149}
150impl ::prost::Name for WelcomePointeeEncryptionAeadTypesExtension {
151    const NAME: &'static str = "WelcomePointeeEncryptionAeadTypesExtension";
152    const PACKAGE: &'static str = "xmtp.mls.message_contents";
153    fn full_name() -> ::prost::alloc::string::String {
154        "xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtension".into()
155    }
156    fn type_url() -> ::prost::alloc::string::String {
157        "/xmtp.mls.message_contents.WelcomePointeeEncryptionAeadTypesExtension".into()
158    }
159}
160#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
161#[repr(i32)]
162pub enum WelcomePointeeEncryptionAeadType {
163    Unspecified = 0,
164    /// Use same encoding as openmls::AeadType
165    Chacha20Poly1305 = 3,
166}
167impl WelcomePointeeEncryptionAeadType {
168    /// String value of the enum field names used in the ProtoBuf definition.
169    ///
170    /// The values are not transformed in any way and thus are considered stable
171    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
172    pub fn as_str_name(&self) -> &'static str {
173        match self {
174            Self::Unspecified => "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED",
175            Self::Chacha20Poly1305 => {
176                "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_CHACHA20_POLY1305"
177            }
178        }
179    }
180    /// Creates an enum from field names used in the ProtoBuf definition.
181    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
182        match value {
183            "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
184            "WELCOME_POINTEE_ENCRYPTION_AEAD_TYPE_CHACHA20_POLY1305" => {
185                Some(Self::Chacha20Poly1305)
186            }
187            _ => None,
188        }
189    }
190}
191/// MUST match the WelcomeWrapperAlgorithm enum values without 25519 so that the i32 transformations are compatible
192#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
193#[repr(i32)]
194pub enum WelcomePointerWrapperAlgorithm {
195    Unspecified = 0,
196    XwingMlkem768Draft6 = 2,
197}
198impl WelcomePointerWrapperAlgorithm {
199    /// String value of the enum field names used in the ProtoBuf definition.
200    ///
201    /// The values are not transformed in any way and thus are considered stable
202    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
203    pub fn as_str_name(&self) -> &'static str {
204        match self {
205            Self::Unspecified => "WELCOME_POINTER_WRAPPER_ALGORITHM_UNSPECIFIED",
206            Self::XwingMlkem768Draft6 => {
207                "WELCOME_POINTER_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6"
208            }
209        }
210    }
211    /// Creates an enum from field names used in the ProtoBuf definition.
212    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
213        match value {
214            "WELCOME_POINTER_WRAPPER_ALGORITHM_UNSPECIFIED" => Some(Self::Unspecified),
215            "WELCOME_POINTER_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6" => {
216                Some(Self::XwingMlkem768Draft6)
217            }
218            _ => None,
219        }
220    }
221}
222/// The KeyPackageExtension that stores the PubKey and the WelcomeWrapperEncryption
223#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
224pub struct WelcomeWrapperEncryption {
225    #[prost(bytes = "vec", tag = "1")]
226    pub pub_key: ::prost::alloc::vec::Vec<u8>,
227    #[prost(enumeration = "WelcomeWrapperAlgorithm", tag = "2")]
228    pub algorithm: i32,
229}
230impl ::prost::Name for WelcomeWrapperEncryption {
231    const NAME: &'static str = "WelcomeWrapperEncryption";
232    const PACKAGE: &'static str = "xmtp.mls.message_contents";
233    fn full_name() -> ::prost::alloc::string::String {
234        "xmtp.mls.message_contents.WelcomeWrapperEncryption".into()
235    }
236    fn type_url() -> ::prost::alloc::string::String {
237        "/xmtp.mls.message_contents.WelcomeWrapperEncryption".into()
238    }
239}
240/// Describes the algorithm used to encrypt the Welcome Wrapper
241#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
242#[repr(i32)]
243pub enum WelcomeWrapperAlgorithm {
244    Unspecified = 0,
245    Curve25519 = 1,
246    XwingMlkem768Draft6 = 2,
247    /// Only used for WelcomePointee's
248    SymmetricKey = 3,
249}
250impl WelcomeWrapperAlgorithm {
251    /// String value of the enum field names used in the ProtoBuf definition.
252    ///
253    /// The values are not transformed in any way and thus are considered stable
254    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
255    pub fn as_str_name(&self) -> &'static str {
256        match self {
257            Self::Unspecified => "WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED",
258            Self::Curve25519 => "WELCOME_WRAPPER_ALGORITHM_CURVE25519",
259            Self::XwingMlkem768Draft6 => {
260                "WELCOME_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6"
261            }
262            Self::SymmetricKey => "WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY",
263        }
264    }
265    /// Creates an enum from field names used in the ProtoBuf definition.
266    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
267        match value {
268            "WELCOME_WRAPPER_ALGORITHM_UNSPECIFIED" => Some(Self::Unspecified),
269            "WELCOME_WRAPPER_ALGORITHM_CURVE25519" => Some(Self::Curve25519),
270            "WELCOME_WRAPPER_ALGORITHM_XWING_MLKEM_768_DRAFT_6" => {
271                Some(Self::XwingMlkem768Draft6)
272            }
273            "WELCOME_WRAPPER_ALGORITHM_SYMMETRIC_KEY" => Some(Self::SymmetricKey),
274            _ => None,
275        }
276    }
277}
278/// ContentTypeId is used to identify the type of content stored in a Message.
279#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
280pub struct ContentTypeId {
281    /// authority governing this content type
282    #[prost(string, tag = "1")]
283    pub authority_id: ::prost::alloc::string::String,
284    /// type identifier
285    #[prost(string, tag = "2")]
286    pub type_id: ::prost::alloc::string::String,
287    /// major version of the type
288    #[prost(uint32, tag = "3")]
289    pub version_major: u32,
290    /// minor version of the type
291    #[prost(uint32, tag = "4")]
292    pub version_minor: u32,
293}
294impl ::prost::Name for ContentTypeId {
295    const NAME: &'static str = "ContentTypeId";
296    const PACKAGE: &'static str = "xmtp.mls.message_contents";
297    fn full_name() -> ::prost::alloc::string::String {
298        "xmtp.mls.message_contents.ContentTypeId".into()
299    }
300    fn type_url() -> ::prost::alloc::string::String {
301        "/xmtp.mls.message_contents.ContentTypeId".into()
302    }
303}
304/// EncodedContent bundles the content with metadata identifying its type
305/// and parameters required for correct decoding and presentation of the content.
306#[derive(Clone, PartialEq, ::prost::Message)]
307pub struct EncodedContent {
308    /// content type identifier used to match the payload with
309    /// the correct decoding machinery
310    #[prost(message, optional, tag = "1")]
311    pub r#type: ::core::option::Option<ContentTypeId>,
312    /// optional encoding parameters required to correctly decode the content
313    #[prost(map = "string, string", tag = "2")]
314    pub parameters: ::std::collections::HashMap<
315        ::prost::alloc::string::String,
316        ::prost::alloc::string::String,
317    >,
318    /// optional fallback description of the content that can be used in case
319    /// the client cannot decode or render the content
320    #[prost(string, optional, tag = "3")]
321    pub fallback: ::core::option::Option<::prost::alloc::string::String>,
322    /// optional compression; the value indicates algorithm used to
323    /// compress the encoded content bytes
324    #[prost(enumeration = "Compression", optional, tag = "5")]
325    pub compression: ::core::option::Option<i32>,
326    /// encoded content itself
327    #[prost(bytes = "vec", tag = "4")]
328    pub content: ::prost::alloc::vec::Vec<u8>,
329}
330impl ::prost::Name for EncodedContent {
331    const NAME: &'static str = "EncodedContent";
332    const PACKAGE: &'static str = "xmtp.mls.message_contents";
333    fn full_name() -> ::prost::alloc::string::String {
334        "xmtp.mls.message_contents.EncodedContent".into()
335    }
336    fn type_url() -> ::prost::alloc::string::String {
337        "/xmtp.mls.message_contents.EncodedContent".into()
338    }
339}
340/// A PlaintextEnvelope is the outermost payload that gets encrypted by MLS
341#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
342pub struct PlaintextEnvelope {
343    /// Selector which declares which version of the EncodedContent this
344    /// PlaintextEnvelope is
345    #[prost(oneof = "plaintext_envelope::Content", tags = "1, 2")]
346    pub content: ::core::option::Option<plaintext_envelope::Content>,
347}
348/// Nested message and enum types in `PlaintextEnvelope`.
349pub mod plaintext_envelope {
350    /// Version 1 of the encrypted envelope
351    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
352    pub struct V1 {
353        /// Expected to be EncodedContent
354        #[prost(bytes = "vec", tag = "1")]
355        pub content: ::prost::alloc::vec::Vec<u8>,
356        /// A unique value that can be used to ensure that the same content can
357        /// produce different hashes. May be the sender timestamp.
358        #[prost(string, tag = "2")]
359        pub idempotency_key: ::prost::alloc::string::String,
360    }
361    impl ::prost::Name for V1 {
362        const NAME: &'static str = "V1";
363        const PACKAGE: &'static str = "xmtp.mls.message_contents";
364        fn full_name() -> ::prost::alloc::string::String {
365            "xmtp.mls.message_contents.PlaintextEnvelope.V1".into()
366        }
367        fn type_url() -> ::prost::alloc::string::String {
368            "/xmtp.mls.message_contents.PlaintextEnvelope.V1".into()
369        }
370    }
371    /// Version 2 of the encrypted envelope
372    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
373    pub struct V2 {
374        /// A unique value that can be used to ensure that the same content can
375        /// produce different hashes. May be the sender timestamp.
376        #[prost(string, tag = "1")]
377        pub idempotency_key: ::prost::alloc::string::String,
378        #[prost(oneof = "v2::MessageType", tags = "2, 3, 4, 5")]
379        pub message_type: ::core::option::Option<v2::MessageType>,
380    }
381    /// Nested message and enum types in `V2`.
382    pub mod v2 {
383        #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
384        pub enum MessageType {
385            /// Expected to be EncodedContent
386            #[prost(bytes, tag = "2")]
387            Content(::prost::alloc::vec::Vec<u8>),
388            /// Initiator sends a request to receive sync payload
389            #[prost(message, tag = "3")]
390            DeviceSyncRequest(
391                super::super::super::super::device_sync::content::DeviceSyncRequest,
392            ),
393            /// Some other authorized installation sends a reply with a link to payload
394            #[prost(message, tag = "4")]
395            DeviceSyncReply(
396                super::super::super::super::device_sync::content::DeviceSyncReply,
397            ),
398            /// A serialized user preference update
399            #[prost(message, tag = "5")]
400            UserPreferenceUpdate(
401                super::super::super::super::device_sync::content::V1UserPreferenceUpdate,
402            ),
403        }
404    }
405    impl ::prost::Name for V2 {
406        const NAME: &'static str = "V2";
407        const PACKAGE: &'static str = "xmtp.mls.message_contents";
408        fn full_name() -> ::prost::alloc::string::String {
409            "xmtp.mls.message_contents.PlaintextEnvelope.V2".into()
410        }
411        fn type_url() -> ::prost::alloc::string::String {
412            "/xmtp.mls.message_contents.PlaintextEnvelope.V2".into()
413        }
414    }
415    /// Selector which declares which version of the EncodedContent this
416    /// PlaintextEnvelope is
417    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
418    pub enum Content {
419        #[prost(message, tag = "1")]
420        V1(V1),
421        #[prost(message, tag = "2")]
422        V2(V2),
423    }
424}
425impl ::prost::Name for PlaintextEnvelope {
426    const NAME: &'static str = "PlaintextEnvelope";
427    const PACKAGE: &'static str = "xmtp.mls.message_contents";
428    fn full_name() -> ::prost::alloc::string::String {
429        "xmtp.mls.message_contents.PlaintextEnvelope".into()
430    }
431    fn type_url() -> ::prost::alloc::string::String {
432        "/xmtp.mls.message_contents.PlaintextEnvelope".into()
433    }
434}
435/// Recognized compression algorithms
436/// protolint:disable ENUM_FIELD_NAMES_ZERO_VALUE_END_WITH
437#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
438#[repr(i32)]
439pub enum Compression {
440    Deflate = 0,
441    Gzip = 1,
442}
443impl Compression {
444    /// String value of the enum field names used in the ProtoBuf definition.
445    ///
446    /// The values are not transformed in any way and thus are considered stable
447    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
448    pub fn as_str_name(&self) -> &'static str {
449        match self {
450            Self::Deflate => "COMPRESSION_DEFLATE",
451            Self::Gzip => "COMPRESSION_GZIP",
452        }
453    }
454    /// Creates an enum from field names used in the ProtoBuf definition.
455    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
456        match value {
457            "COMPRESSION_DEFLATE" => Some(Self::Deflate),
458            "COMPRESSION_GZIP" => Some(Self::Gzip),
459            _ => None,
460        }
461    }
462}
463/// Contains a mapping of `inbox_id` -> `sequence_id` for all members of a group.
464/// Designed to be stored in the group context extension of the MLS group
465#[derive(Clone, PartialEq, ::prost::Message)]
466pub struct GroupMembership {
467    #[prost(map = "string, uint64", tag = "1")]
468    pub members: ::std::collections::HashMap<::prost::alloc::string::String, u64>,
469    /// List of installations that failed to be added due to errors encountered during the evaluation process.
470    #[prost(bytes = "vec", repeated, tag = "2")]
471    pub failed_installations: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
472}
473impl ::prost::Name for GroupMembership {
474    const NAME: &'static str = "GroupMembership";
475    const PACKAGE: &'static str = "xmtp.mls.message_contents";
476    fn full_name() -> ::prost::alloc::string::String {
477        "xmtp.mls.message_contents.GroupMembership".into()
478    }
479    fn type_url() -> ::prost::alloc::string::String {
480        "/xmtp.mls.message_contents.GroupMembership".into()
481    }
482}
483#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
484pub struct OneshotMessage {
485    #[prost(oneof = "oneshot_message::MessageType", tags = "1")]
486    pub message_type: ::core::option::Option<oneshot_message::MessageType>,
487}
488/// Nested message and enum types in `OneshotMessage`.
489pub mod oneshot_message {
490    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Oneof)]
491    pub enum MessageType {
492        #[prost(message, tag = "1")]
493        ReaddRequest(super::ReaddRequest),
494    }
495}
496impl ::prost::Name for OneshotMessage {
497    const NAME: &'static str = "OneshotMessage";
498    const PACKAGE: &'static str = "xmtp.mls.message_contents";
499    fn full_name() -> ::prost::alloc::string::String {
500        "xmtp.mls.message_contents.OneshotMessage".into()
501    }
502    fn type_url() -> ::prost::alloc::string::String {
503        "/xmtp.mls.message_contents.OneshotMessage".into()
504    }
505}
506/// A request sent by an installation to recover from a fork. Other members
507/// may remove and readd that installation from the group.
508/// XIP: <https://community.xmtp.org/t/xip-68-draft-automated-fork-recovery/951>
509#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
510pub struct ReaddRequest {
511    #[prost(bytes = "vec", tag = "1")]
512    pub group_id: ::prost::alloc::vec::Vec<u8>,
513    /// The sequence ID of the latest commit log entry at the time the request
514    /// is sent; used to disambiguate cases where an installation forks
515    /// and is readded multiple times.
516    #[prost(uint64, tag = "2")]
517    pub latest_commit_sequence_id: u64,
518}
519impl ::prost::Name for ReaddRequest {
520    const NAME: &'static str = "ReaddRequest";
521    const PACKAGE: &'static str = "xmtp.mls.message_contents";
522    fn full_name() -> ::prost::alloc::string::String {
523        "xmtp.mls.message_contents.ReaddRequest".into()
524    }
525    fn type_url() -> ::prost::alloc::string::String {
526        "/xmtp.mls.message_contents.ReaddRequest".into()
527    }
528}
529/// Parent message for group metadata
530#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
531pub struct GroupMetadataV1 {
532    #[prost(enumeration = "ConversationType", tag = "1")]
533    pub conversation_type: i32,
534    /// This will be removed soon
535    #[prost(string, tag = "2")]
536    pub creator_account_address: ::prost::alloc::string::String,
537    #[prost(string, tag = "3")]
538    pub creator_inbox_id: ::prost::alloc::string::String,
539    /// Should only be present for CONVERSATION_TYPE_DM
540    #[prost(message, optional, tag = "4")]
541    pub dm_members: ::core::option::Option<DmMembers>,
542    /// Should only be present for CONVERSATION_TYPE_ONESHOT
543    #[prost(message, optional, tag = "5")]
544    pub oneshot_message: ::core::option::Option<OneshotMessage>,
545}
546impl ::prost::Name for GroupMetadataV1 {
547    const NAME: &'static str = "GroupMetadataV1";
548    const PACKAGE: &'static str = "xmtp.mls.message_contents";
549    fn full_name() -> ::prost::alloc::string::String {
550        "xmtp.mls.message_contents.GroupMetadataV1".into()
551    }
552    fn type_url() -> ::prost::alloc::string::String {
553        "/xmtp.mls.message_contents.GroupMetadataV1".into()
554    }
555}
556/// Wrapper around an Inbox Id
557#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
558pub struct Inbox {
559    #[prost(string, tag = "1")]
560    pub inbox_id: ::prost::alloc::string::String,
561}
562impl ::prost::Name for Inbox {
563    const NAME: &'static str = "Inbox";
564    const PACKAGE: &'static str = "xmtp.mls.message_contents";
565    fn full_name() -> ::prost::alloc::string::String {
566        "xmtp.mls.message_contents.Inbox".into()
567    }
568    fn type_url() -> ::prost::alloc::string::String {
569        "/xmtp.mls.message_contents.Inbox".into()
570    }
571}
572/// Ordering does not matter here
573#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
574pub struct DmMembers {
575    #[prost(message, optional, tag = "1")]
576    pub dm_member_one: ::core::option::Option<Inbox>,
577    #[prost(message, optional, tag = "2")]
578    pub dm_member_two: ::core::option::Option<Inbox>,
579}
580impl ::prost::Name for DmMembers {
581    const NAME: &'static str = "DmMembers";
582    const PACKAGE: &'static str = "xmtp.mls.message_contents";
583    fn full_name() -> ::prost::alloc::string::String {
584        "xmtp.mls.message_contents.DmMembers".into()
585    }
586    fn type_url() -> ::prost::alloc::string::String {
587        "/xmtp.mls.message_contents.DmMembers".into()
588    }
589}
590/// Defines the type of conversation
591#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
592#[repr(i32)]
593pub enum ConversationType {
594    Unspecified = 0,
595    Group = 1,
596    Dm = 2,
597    Sync = 3,
598    Oneshot = 4,
599}
600impl ConversationType {
601    /// String value of the enum field names used in the ProtoBuf definition.
602    ///
603    /// The values are not transformed in any way and thus are considered stable
604    /// (if the ProtoBuf definition does not change) and safe for programmatic use.
605    pub fn as_str_name(&self) -> &'static str {
606        match self {
607            Self::Unspecified => "CONVERSATION_TYPE_UNSPECIFIED",
608            Self::Group => "CONVERSATION_TYPE_GROUP",
609            Self::Dm => "CONVERSATION_TYPE_DM",
610            Self::Sync => "CONVERSATION_TYPE_SYNC",
611            Self::Oneshot => "CONVERSATION_TYPE_ONESHOT",
612        }
613    }
614    /// Creates an enum from field names used in the ProtoBuf definition.
615    pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
616        match value {
617            "CONVERSATION_TYPE_UNSPECIFIED" => Some(Self::Unspecified),
618            "CONVERSATION_TYPE_GROUP" => Some(Self::Group),
619            "CONVERSATION_TYPE_DM" => Some(Self::Dm),
620            "CONVERSATION_TYPE_SYNC" => Some(Self::Sync),
621            "CONVERSATION_TYPE_ONESHOT" => Some(Self::Oneshot),
622            _ => None,
623        }
624    }
625}
626/// Message for group mutable metadata
627#[derive(Clone, PartialEq, ::prost::Message)]
628pub struct GroupMutableMetadataV1 {
629    /// Map to store various metadata attributes (Group name, etc.)
630    #[prost(map = "string, string", tag = "1")]
631    pub attributes: ::std::collections::HashMap<
632        ::prost::alloc::string::String,
633        ::prost::alloc::string::String,
634    >,
635    #[prost(message, optional, tag = "2")]
636    pub admin_list: ::core::option::Option<Inboxes>,
637    /// Creator starts as only super_admin
638    /// Only super_admin can add/remove other super_admin
639    #[prost(message, optional, tag = "3")]
640    pub super_admin_list: ::core::option::Option<Inboxes>,
641}
642impl ::prost::Name for GroupMutableMetadataV1 {
643    const NAME: &'static str = "GroupMutableMetadataV1";
644    const PACKAGE: &'static str = "xmtp.mls.message_contents";
645    fn full_name() -> ::prost::alloc::string::String {
646        "xmtp.mls.message_contents.GroupMutableMetadataV1".into()
647    }
648    fn type_url() -> ::prost::alloc::string::String {
649        "/xmtp.mls.message_contents.GroupMutableMetadataV1".into()
650    }
651}
652/// Wrapper around a list of repeated Inbox Ids
653#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
654pub struct Inboxes {
655    #[prost(string, repeated, tag = "1")]
656    pub inbox_ids: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
657}
658impl ::prost::Name for Inboxes {
659    const NAME: &'static str = "Inboxes";
660    const PACKAGE: &'static str = "xmtp.mls.message_contents";
661    fn full_name() -> ::prost::alloc::string::String {
662        "xmtp.mls.message_contents.Inboxes".into()
663    }
664    fn type_url() -> ::prost::alloc::string::String {
665        "/xmtp.mls.message_contents.Inboxes".into()
666    }
667}
668/// Message for group mutable metadata
669#[derive(Clone, PartialEq, ::prost::Message)]
670pub struct GroupMutablePermissionsV1 {
671    #[prost(message, optional, tag = "1")]
672    pub policies: ::core::option::Option<PolicySet>,
673}
674impl ::prost::Name for GroupMutablePermissionsV1 {
675    const NAME: &'static str = "GroupMutablePermissionsV1";
676    const PACKAGE: &'static str = "xmtp.mls.message_contents";
677    fn full_name() -> ::prost::alloc::string::String {
678        "xmtp.mls.message_contents.GroupMutablePermissionsV1".into()
679    }
680    fn type_url() -> ::prost::alloc::string::String {
681        "/xmtp.mls.message_contents.GroupMutablePermissionsV1".into()
682    }
683}
684/// The set of policies that govern the group
685#[derive(Clone, PartialEq, ::prost::Message)]
686pub struct PolicySet {
687    #[prost(message, optional, tag = "1")]
688    pub add_member_policy: ::core::option::Option<MembershipPolicy>,
689    #[prost(message, optional, tag = "2")]
690    pub remove_member_policy: ::core::option::Option<MembershipPolicy>,
691    #[prost(map = "string, message", tag = "3")]
692    pub update_metadata_policy: ::std::collections::HashMap<
693        ::prost::alloc::string::String,
694        MetadataPolicy,
695    >,
696    #[prost(message, optional, tag = "4")]
697    pub add_admin_policy: ::core::option::Option<PermissionsUpdatePolicy>,
698    #[prost(message, optional, tag = "5")]
699    pub remove_admin_policy: ::core::option::Option<PermissionsUpdatePolicy>,
700    #[prost(message, optional, tag = "6")]
701    pub update_permissions_policy: ::core::option::Option<PermissionsUpdatePolicy>,
702}
703impl ::prost::Name for PolicySet {
704    const NAME: &'static str = "PolicySet";
705    const PACKAGE: &'static str = "xmtp.mls.message_contents";
706    fn full_name() -> ::prost::alloc::string::String {
707        "xmtp.mls.message_contents.PolicySet".into()
708    }
709    fn type_url() -> ::prost::alloc::string::String {
710        "/xmtp.mls.message_contents.PolicySet".into()
711    }
712}
713/// A policy that governs adding/removing members or installations
714#[derive(Clone, PartialEq, ::prost::Message)]
715pub struct MembershipPolicy {
716    #[prost(oneof = "membership_policy::Kind", tags = "1, 2, 3")]
717    pub kind: ::core::option::Option<membership_policy::Kind>,
718}
719/// Nested message and enum types in `MembershipPolicy`.
720pub mod membership_policy {
721    /// Combine multiple policies. All must evaluate to true
722    #[derive(Clone, PartialEq, ::prost::Message)]
723    pub struct AndCondition {
724        #[prost(message, repeated, tag = "1")]
725        pub policies: ::prost::alloc::vec::Vec<super::MembershipPolicy>,
726    }
727    impl ::prost::Name for AndCondition {
728        const NAME: &'static str = "AndCondition";
729        const PACKAGE: &'static str = "xmtp.mls.message_contents";
730        fn full_name() -> ::prost::alloc::string::String {
731            "xmtp.mls.message_contents.MembershipPolicy.AndCondition".into()
732        }
733        fn type_url() -> ::prost::alloc::string::String {
734            "/xmtp.mls.message_contents.MembershipPolicy.AndCondition".into()
735        }
736    }
737    /// Combine multiple policies. Any must evaluate to true
738    #[derive(Clone, PartialEq, ::prost::Message)]
739    pub struct AnyCondition {
740        #[prost(message, repeated, tag = "1")]
741        pub policies: ::prost::alloc::vec::Vec<super::MembershipPolicy>,
742    }
743    impl ::prost::Name for AnyCondition {
744        const NAME: &'static str = "AnyCondition";
745        const PACKAGE: &'static str = "xmtp.mls.message_contents";
746        fn full_name() -> ::prost::alloc::string::String {
747            "xmtp.mls.message_contents.MembershipPolicy.AnyCondition".into()
748        }
749        fn type_url() -> ::prost::alloc::string::String {
750            "/xmtp.mls.message_contents.MembershipPolicy.AnyCondition".into()
751        }
752    }
753    /// Base policy
754    #[derive(
755        Clone,
756        Copy,
757        Debug,
758        PartialEq,
759        Eq,
760        Hash,
761        PartialOrd,
762        Ord,
763        ::prost::Enumeration
764    )]
765    #[repr(i32)]
766    pub enum BasePolicy {
767        Unspecified = 0,
768        Allow = 1,
769        Deny = 2,
770        AllowIfAdminOrSuperAdmin = 3,
771        AllowIfSuperAdmin = 4,
772    }
773    impl BasePolicy {
774        /// String value of the enum field names used in the ProtoBuf definition.
775        ///
776        /// The values are not transformed in any way and thus are considered stable
777        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
778        pub fn as_str_name(&self) -> &'static str {
779            match self {
780                Self::Unspecified => "BASE_POLICY_UNSPECIFIED",
781                Self::Allow => "BASE_POLICY_ALLOW",
782                Self::Deny => "BASE_POLICY_DENY",
783                Self::AllowIfAdminOrSuperAdmin => {
784                    "BASE_POLICY_ALLOW_IF_ADMIN_OR_SUPER_ADMIN"
785                }
786                Self::AllowIfSuperAdmin => "BASE_POLICY_ALLOW_IF_SUPER_ADMIN",
787            }
788        }
789        /// Creates an enum from field names used in the ProtoBuf definition.
790        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
791            match value {
792                "BASE_POLICY_UNSPECIFIED" => Some(Self::Unspecified),
793                "BASE_POLICY_ALLOW" => Some(Self::Allow),
794                "BASE_POLICY_DENY" => Some(Self::Deny),
795                "BASE_POLICY_ALLOW_IF_ADMIN_OR_SUPER_ADMIN" => {
796                    Some(Self::AllowIfAdminOrSuperAdmin)
797                }
798                "BASE_POLICY_ALLOW_IF_SUPER_ADMIN" => Some(Self::AllowIfSuperAdmin),
799                _ => None,
800            }
801        }
802    }
803    #[derive(Clone, PartialEq, ::prost::Oneof)]
804    pub enum Kind {
805        #[prost(enumeration = "BasePolicy", tag = "1")]
806        Base(i32),
807        #[prost(message, tag = "2")]
808        AndCondition(AndCondition),
809        #[prost(message, tag = "3")]
810        AnyCondition(AnyCondition),
811    }
812}
813impl ::prost::Name for MembershipPolicy {
814    const NAME: &'static str = "MembershipPolicy";
815    const PACKAGE: &'static str = "xmtp.mls.message_contents";
816    fn full_name() -> ::prost::alloc::string::String {
817        "xmtp.mls.message_contents.MembershipPolicy".into()
818    }
819    fn type_url() -> ::prost::alloc::string::String {
820        "/xmtp.mls.message_contents.MembershipPolicy".into()
821    }
822}
823/// A policy that governs updating metadata
824#[derive(Clone, PartialEq, ::prost::Message)]
825pub struct MetadataPolicy {
826    #[prost(oneof = "metadata_policy::Kind", tags = "1, 2, 3")]
827    pub kind: ::core::option::Option<metadata_policy::Kind>,
828}
829/// Nested message and enum types in `MetadataPolicy`.
830pub mod metadata_policy {
831    /// Combine multiple policies. All must evaluate to true
832    #[derive(Clone, PartialEq, ::prost::Message)]
833    pub struct AndCondition {
834        #[prost(message, repeated, tag = "1")]
835        pub policies: ::prost::alloc::vec::Vec<super::MetadataPolicy>,
836    }
837    impl ::prost::Name for AndCondition {
838        const NAME: &'static str = "AndCondition";
839        const PACKAGE: &'static str = "xmtp.mls.message_contents";
840        fn full_name() -> ::prost::alloc::string::String {
841            "xmtp.mls.message_contents.MetadataPolicy.AndCondition".into()
842        }
843        fn type_url() -> ::prost::alloc::string::String {
844            "/xmtp.mls.message_contents.MetadataPolicy.AndCondition".into()
845        }
846    }
847    /// Combine multiple policies. Any must evaluate to true
848    #[derive(Clone, PartialEq, ::prost::Message)]
849    pub struct AnyCondition {
850        #[prost(message, repeated, tag = "1")]
851        pub policies: ::prost::alloc::vec::Vec<super::MetadataPolicy>,
852    }
853    impl ::prost::Name for AnyCondition {
854        const NAME: &'static str = "AnyCondition";
855        const PACKAGE: &'static str = "xmtp.mls.message_contents";
856        fn full_name() -> ::prost::alloc::string::String {
857            "xmtp.mls.message_contents.MetadataPolicy.AnyCondition".into()
858        }
859        fn type_url() -> ::prost::alloc::string::String {
860            "/xmtp.mls.message_contents.MetadataPolicy.AnyCondition".into()
861        }
862    }
863    /// Base policy
864    #[derive(
865        Clone,
866        Copy,
867        Debug,
868        PartialEq,
869        Eq,
870        Hash,
871        PartialOrd,
872        Ord,
873        ::prost::Enumeration
874    )]
875    #[repr(i32)]
876    pub enum MetadataBasePolicy {
877        Unspecified = 0,
878        Allow = 1,
879        Deny = 2,
880        AllowIfAdmin = 3,
881        AllowIfSuperAdmin = 4,
882    }
883    impl MetadataBasePolicy {
884        /// String value of the enum field names used in the ProtoBuf definition.
885        ///
886        /// The values are not transformed in any way and thus are considered stable
887        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
888        pub fn as_str_name(&self) -> &'static str {
889            match self {
890                Self::Unspecified => "METADATA_BASE_POLICY_UNSPECIFIED",
891                Self::Allow => "METADATA_BASE_POLICY_ALLOW",
892                Self::Deny => "METADATA_BASE_POLICY_DENY",
893                Self::AllowIfAdmin => "METADATA_BASE_POLICY_ALLOW_IF_ADMIN",
894                Self::AllowIfSuperAdmin => "METADATA_BASE_POLICY_ALLOW_IF_SUPER_ADMIN",
895            }
896        }
897        /// Creates an enum from field names used in the ProtoBuf definition.
898        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
899            match value {
900                "METADATA_BASE_POLICY_UNSPECIFIED" => Some(Self::Unspecified),
901                "METADATA_BASE_POLICY_ALLOW" => Some(Self::Allow),
902                "METADATA_BASE_POLICY_DENY" => Some(Self::Deny),
903                "METADATA_BASE_POLICY_ALLOW_IF_ADMIN" => Some(Self::AllowIfAdmin),
904                "METADATA_BASE_POLICY_ALLOW_IF_SUPER_ADMIN" => {
905                    Some(Self::AllowIfSuperAdmin)
906                }
907                _ => None,
908            }
909        }
910    }
911    #[derive(Clone, PartialEq, ::prost::Oneof)]
912    pub enum Kind {
913        #[prost(enumeration = "MetadataBasePolicy", tag = "1")]
914        Base(i32),
915        #[prost(message, tag = "2")]
916        AndCondition(AndCondition),
917        #[prost(message, tag = "3")]
918        AnyCondition(AnyCondition),
919    }
920}
921impl ::prost::Name for MetadataPolicy {
922    const NAME: &'static str = "MetadataPolicy";
923    const PACKAGE: &'static str = "xmtp.mls.message_contents";
924    fn full_name() -> ::prost::alloc::string::String {
925        "xmtp.mls.message_contents.MetadataPolicy".into()
926    }
927    fn type_url() -> ::prost::alloc::string::String {
928        "/xmtp.mls.message_contents.MetadataPolicy".into()
929    }
930}
931/// A policy that governs updating permissions
932#[derive(Clone, PartialEq, ::prost::Message)]
933pub struct PermissionsUpdatePolicy {
934    #[prost(oneof = "permissions_update_policy::Kind", tags = "1, 2, 3")]
935    pub kind: ::core::option::Option<permissions_update_policy::Kind>,
936}
937/// Nested message and enum types in `PermissionsUpdatePolicy`.
938pub mod permissions_update_policy {
939    /// Combine multiple policies. All must evaluate to true
940    #[derive(Clone, PartialEq, ::prost::Message)]
941    pub struct AndCondition {
942        #[prost(message, repeated, tag = "1")]
943        pub policies: ::prost::alloc::vec::Vec<super::PermissionsUpdatePolicy>,
944    }
945    impl ::prost::Name for AndCondition {
946        const NAME: &'static str = "AndCondition";
947        const PACKAGE: &'static str = "xmtp.mls.message_contents";
948        fn full_name() -> ::prost::alloc::string::String {
949            "xmtp.mls.message_contents.PermissionsUpdatePolicy.AndCondition".into()
950        }
951        fn type_url() -> ::prost::alloc::string::String {
952            "/xmtp.mls.message_contents.PermissionsUpdatePolicy.AndCondition".into()
953        }
954    }
955    /// Combine multiple policies. Any must evaluate to true
956    #[derive(Clone, PartialEq, ::prost::Message)]
957    pub struct AnyCondition {
958        #[prost(message, repeated, tag = "1")]
959        pub policies: ::prost::alloc::vec::Vec<super::PermissionsUpdatePolicy>,
960    }
961    impl ::prost::Name for AnyCondition {
962        const NAME: &'static str = "AnyCondition";
963        const PACKAGE: &'static str = "xmtp.mls.message_contents";
964        fn full_name() -> ::prost::alloc::string::String {
965            "xmtp.mls.message_contents.PermissionsUpdatePolicy.AnyCondition".into()
966        }
967        fn type_url() -> ::prost::alloc::string::String {
968            "/xmtp.mls.message_contents.PermissionsUpdatePolicy.AnyCondition".into()
969        }
970    }
971    /// Base policy
972    #[derive(
973        Clone,
974        Copy,
975        Debug,
976        PartialEq,
977        Eq,
978        Hash,
979        PartialOrd,
980        Ord,
981        ::prost::Enumeration
982    )]
983    #[repr(i32)]
984    pub enum PermissionsBasePolicy {
985        Unspecified = 0,
986        Deny = 1,
987        AllowIfAdmin = 2,
988        AllowIfSuperAdmin = 3,
989    }
990    impl PermissionsBasePolicy {
991        /// String value of the enum field names used in the ProtoBuf definition.
992        ///
993        /// The values are not transformed in any way and thus are considered stable
994        /// (if the ProtoBuf definition does not change) and safe for programmatic use.
995        pub fn as_str_name(&self) -> &'static str {
996            match self {
997                Self::Unspecified => "PERMISSIONS_BASE_POLICY_UNSPECIFIED",
998                Self::Deny => "PERMISSIONS_BASE_POLICY_DENY",
999                Self::AllowIfAdmin => "PERMISSIONS_BASE_POLICY_ALLOW_IF_ADMIN",
1000                Self::AllowIfSuperAdmin => "PERMISSIONS_BASE_POLICY_ALLOW_IF_SUPER_ADMIN",
1001            }
1002        }
1003        /// Creates an enum from field names used in the ProtoBuf definition.
1004        pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1005            match value {
1006                "PERMISSIONS_BASE_POLICY_UNSPECIFIED" => Some(Self::Unspecified),
1007                "PERMISSIONS_BASE_POLICY_DENY" => Some(Self::Deny),
1008                "PERMISSIONS_BASE_POLICY_ALLOW_IF_ADMIN" => Some(Self::AllowIfAdmin),
1009                "PERMISSIONS_BASE_POLICY_ALLOW_IF_SUPER_ADMIN" => {
1010                    Some(Self::AllowIfSuperAdmin)
1011                }
1012                _ => None,
1013            }
1014        }
1015    }
1016    #[derive(Clone, PartialEq, ::prost::Oneof)]
1017    pub enum Kind {
1018        #[prost(enumeration = "PermissionsBasePolicy", tag = "1")]
1019        Base(i32),
1020        #[prost(message, tag = "2")]
1021        AndCondition(AndCondition),
1022        #[prost(message, tag = "3")]
1023        AnyCondition(AnyCondition),
1024    }
1025}
1026impl ::prost::Name for PermissionsUpdatePolicy {
1027    const NAME: &'static str = "PermissionsUpdatePolicy";
1028    const PACKAGE: &'static str = "xmtp.mls.message_contents";
1029    fn full_name() -> ::prost::alloc::string::String {
1030        "xmtp.mls.message_contents.PermissionsUpdatePolicy".into()
1031    }
1032    fn type_url() -> ::prost::alloc::string::String {
1033        "/xmtp.mls.message_contents.PermissionsUpdatePolicy".into()
1034    }
1035}
1036/// A group member and affected installation IDs
1037#[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1038pub struct MembershipChange {
1039    #[prost(bytes = "vec", repeated, tag = "1")]
1040    pub installation_ids: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
1041    #[prost(string, tag = "2")]
1042    pub account_address: ::prost::alloc::string::String,
1043    #[prost(string, tag = "3")]
1044    pub initiated_by_account_address: ::prost::alloc::string::String,
1045}
1046impl ::prost::Name for MembershipChange {
1047    const NAME: &'static str = "MembershipChange";
1048    const PACKAGE: &'static str = "xmtp.mls.message_contents";
1049    fn full_name() -> ::prost::alloc::string::String {
1050        "xmtp.mls.message_contents.MembershipChange".into()
1051    }
1052    fn type_url() -> ::prost::alloc::string::String {
1053        "/xmtp.mls.message_contents.MembershipChange".into()
1054    }
1055}
1056/// The group membership change proto
1057///
1058/// protolint:disable REPEATED_FIELD_NAMES_PLURALIZED
1059#[derive(Clone, PartialEq, ::prost::Message)]
1060pub struct GroupMembershipChanges {
1061    /// Members that have been added in the commit
1062    #[prost(message, repeated, tag = "1")]
1063    pub members_added: ::prost::alloc::vec::Vec<MembershipChange>,
1064    /// Members that have been removed in the commit
1065    #[prost(message, repeated, tag = "2")]
1066    pub members_removed: ::prost::alloc::vec::Vec<MembershipChange>,
1067    /// Installations that have been added in the commit, grouped by member
1068    #[prost(message, repeated, tag = "3")]
1069    pub installations_added: ::prost::alloc::vec::Vec<MembershipChange>,
1070    /// Installations removed in the commit, grouped by member
1071    #[prost(message, repeated, tag = "4")]
1072    pub installations_removed: ::prost::alloc::vec::Vec<MembershipChange>,
1073}
1074impl ::prost::Name for GroupMembershipChanges {
1075    const NAME: &'static str = "GroupMembershipChanges";
1076    const PACKAGE: &'static str = "xmtp.mls.message_contents";
1077    fn full_name() -> ::prost::alloc::string::String {
1078        "xmtp.mls.message_contents.GroupMembershipChanges".into()
1079    }
1080    fn type_url() -> ::prost::alloc::string::String {
1081        "/xmtp.mls.message_contents.GroupMembershipChanges".into()
1082    }
1083}
1084/// A summary of the changes in a commit.
1085/// Includes added/removed inboxes and changes to metadata
1086#[derive(Clone, PartialEq, ::prost::Message)]
1087pub struct GroupUpdated {
1088    #[prost(string, tag = "1")]
1089    pub initiated_by_inbox_id: ::prost::alloc::string::String,
1090    /// The inboxes added in the commit
1091    #[prost(message, repeated, tag = "2")]
1092    pub added_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1093    /// The inboxes removed in the commit
1094    #[prost(message, repeated, tag = "3")]
1095    pub removed_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1096    /// The metadata changes in the commit
1097    #[prost(message, repeated, tag = "4")]
1098    pub metadata_field_changes: ::prost::alloc::vec::Vec<
1099        group_updated::MetadataFieldChange,
1100    >,
1101    /// / The inboxes that were removed from the group in response to pending-remove/self-remove requests
1102    #[prost(message, repeated, tag = "5")]
1103    pub left_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1104    /// The inboxes that were added to admin list in the commit
1105    #[prost(message, repeated, tag = "6")]
1106    pub added_admin_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1107    /// The inboxes that were removed from admin list in the commit
1108    #[prost(message, repeated, tag = "7")]
1109    pub removed_admin_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1110    /// The inboxes that were added to super admin list in the commit
1111    #[prost(message, repeated, tag = "8")]
1112    pub added_super_admin_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1113    /// The inboxes that were removed from super admin list in the commit
1114    #[prost(message, repeated, tag = "9")]
1115    pub removed_super_admin_inboxes: ::prost::alloc::vec::Vec<group_updated::Inbox>,
1116}
1117/// Nested message and enum types in `GroupUpdated`.
1118pub mod group_updated {
1119    /// An inbox that was added or removed in this commit
1120    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1121    pub struct Inbox {
1122        #[prost(string, tag = "1")]
1123        pub inbox_id: ::prost::alloc::string::String,
1124    }
1125    impl ::prost::Name for Inbox {
1126        const NAME: &'static str = "Inbox";
1127        const PACKAGE: &'static str = "xmtp.mls.message_contents";
1128        fn full_name() -> ::prost::alloc::string::String {
1129            "xmtp.mls.message_contents.GroupUpdated.Inbox".into()
1130        }
1131        fn type_url() -> ::prost::alloc::string::String {
1132            "/xmtp.mls.message_contents.GroupUpdated.Inbox".into()
1133        }
1134    }
1135    /// A summary of a change to the mutable metadata
1136    #[derive(Clone, PartialEq, Eq, Hash, ::prost::Message)]
1137    pub struct MetadataFieldChange {
1138        /// The field that was changed
1139        #[prost(string, tag = "1")]
1140        pub field_name: ::prost::alloc::string::String,
1141        /// The previous value
1142        #[prost(string, optional, tag = "2")]
1143        pub old_value: ::core::option::Option<::prost::alloc::string::String>,
1144        /// The updated value
1145        #[prost(string, optional, tag = "3")]
1146        pub new_value: ::core::option::Option<::prost::alloc::string::String>,
1147    }
1148    impl ::prost::Name for MetadataFieldChange {
1149        const NAME: &'static str = "MetadataFieldChange";
1150        const PACKAGE: &'static str = "xmtp.mls.message_contents";
1151        fn full_name() -> ::prost::alloc::string::String {
1152            "xmtp.mls.message_contents.GroupUpdated.MetadataFieldChange".into()
1153        }
1154        fn type_url() -> ::prost::alloc::string::String {
1155            "/xmtp.mls.message_contents.GroupUpdated.MetadataFieldChange".into()
1156        }
1157    }
1158}
1159impl ::prost::Name for GroupUpdated {
1160    const NAME: &'static str = "GroupUpdated";
1161    const PACKAGE: &'static str = "xmtp.mls.message_contents";
1162    fn full_name() -> ::prost::alloc::string::String {
1163        "xmtp.mls.message_contents.GroupUpdated".into()
1164    }
1165    fn type_url() -> ::prost::alloc::string::String {
1166        "/xmtp.mls.message_contents.GroupUpdated".into()
1167    }
1168}