-
-
Notifications
You must be signed in to change notification settings - Fork 15
Expand file tree
/
Copy pathgooglechat.proto
More file actions
3278 lines (2911 loc) · 88.9 KB
/
googlechat.proto
File metadata and controls
3278 lines (2911 loc) · 88.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
syntax = "proto2";
// Hand-coded reverse-engineered protobuf, based on info extracted from Android and iOS Gmail and Google Talk apps
//
// Most messages normally start with DYNProto but that got boring, so I stripped that all out
//
// oneof's have been commented out because they're a pain in the butt with protobuf-c, but I've tried to keep them in there in case other non-silly protobuf libraries want to take advantage of them
//
// Feel free to use this .proto for whatever you want to, under whatever license you want.
//
// https://github.com/EionRobb/purple-googlechat/
enum UserType {
HUMAN = 0;
BOT = 1;
}
message UserId {
optional string id = 1;
optional UserType type = 2;
optional AppId origin_app_id = 3;
optional string acting_user_id = 4;
}
enum UserProfileVisibility {
UNKNOWN_USER_PROFILE_VISIBILITY = 0;
FULL_PROFILE = 1;
PRIMARY_MAIL = 2;
INVITEE_EMAIL = 3;
DELETED_USER = 4;
UNKNOWN_USER = 5;
}
message CustomerId {
optional string customer_id = 1;
}
message OrganizationInfo {
message ConsumerInfo {
}
optional ConsumerInfo consumer_info = 1;
message CustomerInfo {
optional CustomerId customer_id = 1;
}
optional CustomerInfo customer_info = 2;
}
message BotInfo {
optional string user_visible_developer_identity = 1;
optional string description = 2;
enum Status {
UNKNOWN_STATUS = 0;
ENABLED = 1;
DISABLED_BY_DEVELOPER = 2;
}
optional Status status = 3;
message SupportUrls {
optional string tos_url = 1;
optional string privacy_policy_url = 2;
optional string support_url = 3;
optional string setup_url = 4;
optional string admin_config_url = 5;
optional string deletion_policy_url = 6;
optional string gwm_url = 7;
}
optional SupportUrls support_urls = 4;
optional string bot_avatar_url = 5;
optional string bot_name = 6;
enum SupportedUses {
UNKNOWN = 0;
CAN_ADD_TO_DM = 1;
CAN_ADD_TO_ROOM = 2;
CAN_ADD_TO_HUMAN_DM = 3;
}
repeated SupportedUses supported_uses = 7;
optional string market_place_banner_url = 8;
enum AppAllowlistStatus {
UNSPECIFIED_STATUS = 0;
ALLOWED = 1;
ALL_APPS_DISABLED_BY_ADMIN = 2;
APP_NOT_ALLOWLISTED_BY_ADMIN = 3;
}
optional AppAllowlistStatus app_allowlist_status = 9;
optional AppId app_id = 10;
optional bool support_home_screen = 11;
enum UninstallCapability {
UNSPECIFIED_UNINSTALL_CAPABILITY = 0;
ALWAYS_ALLOWED = 1;
NEVER_ALLOWED = 2;
}
optional UninstallCapability uninstall_capability = 12;
enum AppPromptConfig {
APP_PROMPT_CONFIG_UNSPECIFIED = 0;
APP_PROMPTS_DISABLED = 1;
STATIC_APP_PROMPTS_ENABLED = 2;
DYNAMIC_APP_PROMPTS_ENABLED = 3;
}
optional AppPromptConfig app_prompt_config = 13;
enum GwmPublishStatus {
UNKNOWN_GWM_STATUS = 0;
PUBLIC = 1;
PRIVATE = 2;
}
optional GwmPublishStatus gwm_publish_status = 14;
}
message PhoneNumber {
optional string value = 1;
optional string type = 2;
}
message User {
optional UserId user_id = 1;
optional string name = 2;
optional string avatar_url = 3;
optional string email = 4;
optional string first_name = 5;
optional string last_name = 6;
optional bool deleted = 7;
optional bool is_anonymous = 8;
optional BotInfo bot_info = 9;
optional string gender = 10;
optional UserAccountState user_account_state = 11;
optional UserProfileVisibility user_profile_visibility = 15;
optional OrganizationInfo organization_info = 12;
optional UserBlockRelationship block_relationship = 13;
repeated PhoneNumber phone_number = 14;
//optional enum user_account_type = 17;
//optional UserActivityMetadata user_activity_metadata = 18;
//optional enum profile_state = 19;
}
message UserBlockRelationship {
optional bool is_blocked_by_requester = 1;
optional bool has_blocked_requester = 2;
}
message DndSettings {
enum DndState_State {
UNKNOWN = 0;
AVAILABLE = 1;
DND = 2;
}
optional DndState_State dnd_state = 1;
optional int64 dnd_expiry_time_usec = 2;
optional int64 state_remaining_duration_usec = 3;
}
enum EmojiState {
EMOJI_STATE_UNSPECIFIED = 0;
EMOJI_ENABLED = 1;
EMOJI_SYSTEM_DISABLED = 2;
EMOJI_HIDDEN = 3;
EMOJI_DELETED = 4;
}
message CustomEmoji {
optional string uuid = 1;
optional string shortcode = 3;
optional EmojiState state = 4;
optional UserId creator_user_id = 5;
optional CustomerId owner_customer_id = 6;
optional string blob_id = 7;
optional int64 create_time_micros = 8;
optional string read_token = 9;
optional int64 update_time_micros = 10;
optional string ephemeral_url = 11;
optional string content_type = 12;
optional int64 delete_time_micros = 13;
}
message Emoji {
//oneof Content {
optional string unicode = 1;
optional CustomEmoji custom_emoji = 2;
//}
}
message CustomEmojiMetadata {
optional CustomEmoji custom_emoji = 1;
}
message CreateCustomEmojiRequest {
optional string shortcode = 2;
//optional CustomEmojiUploadResult custom_emoji_upload_result = 3;
optional RequestHeader request_header = 100;
}
message CreateCustomEmojiResponse {
optional CustomEmoji custom_emoji = 1;
}
message CustomStatus {
optional string status_text = 1;
optional string status_emoji = 2;
optional int64 state_expiry_timestamp_usec = 3;
optional Emoji emoji = 4;
}
message UserStatus {
optional UserId user_id = 1;
optional DndSettings dnd_settings = 2;
optional int64 update_timestamp_usec = 3;
optional int64 dnd_settings_update_timestamp_usec = 7;
optional int64 status_timestamp_usec = 4;
optional bool presence_shared = 5;
optional CustomStatus custom_status = 6;
optional int64 custom_status_update_timestamp_usec = 8;
}
message UserStatusUpdatedEvent {
optional UserStatus user_status = 1;
}
message GetUserStatusRequest {
repeated UserId user_ids = 1;
optional RequestHeader request_header = 100;
}
message GetUserStatusResponse {
repeated UserStatus user_statuses = 1;
}
message GetSelfUserStatusRequest {
optional RequestHeader request_header = 100;
}
message GetSelfUserStatusResponse {
optional UserStatus user_status = 1;
optional ReadRevision user_revision = 2;
}
message ClientFeatureCapabilities {
enum CapabilityLevel {
UNSUPPORTED = 0;
DATA_SUPPORTED = 1;
FULLY_SUPPORTED = 2;
}
optional bool enable_all_features = 1;
optional CapabilityLevel spaces_level_for_testing = 2;
optional CapabilityLevel dms_level_for_testing = 3;
optional CapabilityLevel post_rooms_level = 4;
optional CapabilityLevel spam_room_invites_level = 5;
optional CapabilityLevel tombstone_level = 6;
optional CapabilityLevel rich_text_viewing_level = 7;
optional CapabilityLevel threaded_spaces_level = 8;
optional CapabilityLevel flat_named_room_topic_ordering_by_creation_time_level = 9;
optional CapabilityLevel target_audience_level = 10;
optional CapabilityLevel group_scoped_capabilities_level = 11;
optional CapabilityLevel activity_feed_level = 12;
optional CapabilityLevel roster_as_member_support_level = 16;
optional CapabilityLevel tombstone_in_dms_and_ufrs_level = 17;
optional CapabilityLevel quoted_message_support_level = 18;
optional CapabilityLevel render_announcement_spaces_level = 19;
optional CapabilityLevel dark_launch_space_support = 20;
optional CapabilityLevel avoid_http_400_error_support_level = 21;
optional CapabilityLevel custom_hyperlink_level = 22;
optional CapabilityLevel snippets_for_named_rooms = 23;
optional CapabilityLevel can_add_continuous_direct_add_groups = 24;
optional CapabilityLevel drive_smart_chip_level = 25;
optional CapabilityLevel gsuite_integration_in_native_renderer_level = 26;
optional CapabilityLevel mentions_shortcut_level = 27;
optional CapabilityLevel starred_shortcut_level = 28;
optional CapabilityLevel search_snippet_and_keyword_highlight_level = 29;
optional CapabilityLevel app_section_level = 30;
optional CapabilityLevel create_thread_on_message_send_level = 31;
optional CapabilityLevel can_handle_batch_reaction_update = 32;
optional CapabilityLevel longer_group_snippets_level = 33;
optional CapabilityLevel muting_groups_level = 34;
optional CapabilityLevel muting_write_level = 35;
optional CapabilityLevel add_existing_members_level = 36;
optional CapabilityLevel request_to_join_level = 37;
optional CapabilityLevel threads_in_home_level = 38;
}
message RequestHeader {
optional int64 trace_id = 1;
enum ClientType {
UNKNOWN = 0;
ANDROID = 1;
IOS = 2;
WEB = 3;
CLASSIC_INTEROP = 4;
INTERNAL_TESTING = 5;
WEB_DESKTOP = 6;
WEB_GMAIL = 7;
WEB_COMPANION = 9;
WEB_CRX = 10;
WEB_PWA = 11;
WEB_DYNTO = 12;
WEB_DYNTO_PWA = 13;
WEB_GMAIL_DARK_LAUNCH = 14;
STREAM_IN_MEET = 15;
WEB_ADMIN_CONSOLE = 16;
FRAMELESS_CHAT = 17;
FRAMELESS_CHAT_PWA = 18;
EMBEDDED_STREAM_DARK_LAUNCH = 19;
}
optional ClientType client_type = 2;
optional int64 client_version = 3;
optional string locale = 4;
optional ClientFeatureCapabilities client_feature_capabilities = 5;
}
enum InviteCategory {
UNKNOWN_INVITE = 0;
REGULAR_INVITE = 1;
SPAM_INVITE = 2;
}
enum MemberType {
MEMBER_TYPE_UNSPECIFIED = 0;
HUMAN_USER = 1;
ROSTER_MEMBER = 2;
}
message SegmentedMembershipCount {
optional int32 membership_count = 1;
optional MemberType member_type = 2;
optional MembershipState membership_state = 3;
}
message SegmentedMembershipCounts {
repeated SegmentedMembershipCount value = 1;
}
enum RosterState {
ROSTER_STATE_UNKNOWN = 0;
ROSTER_ACTIVE = 1;
ROSTER_DELETED = 2;
}
message Roster {
optional RosterId id = 1;
optional string name = 2;
optional string avatar_url = 3;
optional int32 membership_count = 4;
optional string roster_gaia_key = 5;
optional RosterState roster_state = 6;
optional SegmentedMembershipCounts segmented_membership_counts = 7;
optional bool is_membership_visible_to_caller = 8;
}
message RosterId {
optional string id = 1;
}
message Member {
//oneof Profile {
optional User user = 1;
optional Roster roster = 2;
//}
}
message MemberId {
//oneof Id {
optional UserId user_id = 1;
optional RosterId roster_id = 2;
//}
optional string email = 3;
}
message MembershipId {
optional MemberId member_id = 1;
optional SpaceId space_id = 2;
optional GroupId group_id = 3;
}
message Membership {
optional MembershipId id = 1;
optional int64 create_time = 2;
optional MembershipState membership_state = 3;
optional InviteCategory invite_category = 4;
optional MembershipRole membership_role = 5;
//optional AbuseLabels abuse_labels = 6;
}
message MemberProfile {
optional MembershipId id = 1;
optional Member member = 2;
}
message GetMembersRequest {
optional RequestHeader request_header = 100;
repeated MemberId member_ids = 1;
repeated MembershipId membership_ids = 2;
}
message GetMembersResponse {
repeated Member members = 1;
repeated MemberProfile member_profiles = 2;
}
enum Presence {
UNDEFINED_PRESENCE = 0;
ACTIVE = 1;
INACTIVE = 2;
UNKNOWN = 3;
SHARING_DISABLED = 4;
}
enum DndState_State {
DND_STATE_STATE_UNKNOWN = 0;
AVAILABLE = 1;
DND = 2;
}
// Needs the DYNProto prefix to not clash with winnt headers
message DYNProtoUserPresence {
optional UserId user_id = 1;
optional Presence presence = 2;
optional int64 active_until = 4;
optional DndState_State dnd_state = 3;
optional UserStatus user_status = 5;
}
message GetUserPresenceRequest {
optional RequestHeader request_header = 100;
repeated UserId user_ids = 1;
optional bool include_active_until = 2;
optional bool include_user_status = 3;
}
message GetUserPresenceResponse {
repeated DYNProtoUserPresence user_presences = 1;
}
message JAddOnsIdentifier {
optional string id = 1;
}
message JAddOnsFormattedText {
enum TextAlign {
LEFT = 0;
CENTER = 1;
RIGHT = 2;
}
message FormattedTextElement {
message DateTime {
optional int64 time_millis = 1;
optional int32 time_zone_offset_minutes = 2;
optional bool date_only = 3;
optional bool floating_time = 4;
}
message StyledText {
enum Style {
NONE = 0;
BOLD_DEPRECATED = 1;
ITALIC = 2;
UNDERLINE = 3;
STRIKETHROUGH = 4;
BR = 5;
UPPERCASE = 6;
}
enum FontWeight {
REGULAR = 0;
LIGHT = 1;
MEDIUM = 2;
BOLD = 3;
}
optional string text = 1;
optional DateTime datetime = 4;
repeated Style styles = 2;
optional FontWeight font_weight = 5;
optional int32 color = 3;
optional JAddOnsThemeColors theme_colors = 7;
}
message HyperLink {
optional string link = 1;
optional string original_link = 3;
optional string text = 2;
}
//oneof Element {
optional StyledText styled_text = 1;
optional HyperLink hyperlink = 2;
//}
}
optional JAddOnsIdentifier id = 4;
optional string original_text = 1;
repeated FormattedTextElement formatted_text_elements = 2;
optional TextAlign text_align = 3;
}
message JAddOnsImageCropStyle {
enum ImageCropType {
CROP_TYPE_NOT_SET = 0;
SQUARE = 1;
CIRCLE = 2;
RECTANGLE_CUSTOM = 3;
RECTANGLE_4_3 = 4;
}
optional ImageCropType type = 1;
optional double aspect_ratio = 2;
}
message JAddOnsThemeColors {
optional int32 light_theme_color = 1;
optional int32 dark_theme_color = 2;
}
message JAddOnsOpenLink {
enum OpenAs {
FULL_SIZE = 0;
OVERLAY = 1;
}
enum OnClose {
NOTHING = 0;
RELOAD_ADD_ON = 1;
}
enum LoadIndicator {
NONE = 0;
SPINNER = 1;
}
optional string url = 1;
optional string original_link = 5;
optional OpenAs open_as = 2;
optional OnClose on_close = 3;
optional LoadIndicator load_indicator = 4;
}
message JAddOnsCardItem {
message CardItemHeader {
optional JAddOnsFormattedText title = 1;
optional JAddOnsFormattedText subtitle = 2;
optional JAddOnsImageCropStyle.ImageCropType image_style = 3;
optional string image_url = 4;
optional string image_alt_text = 5;
}
message CardItemSection {
optional JAddOnsIdentifier id = 6;
optional string description = 1;
optional JAddOnsFormattedText header = 5;
repeated JAddOnsWidget widgets = 2;
optional bool collapsable = 3;
optional int32 num_uncollapsable_widgets = 4;
}
message CardItemAction {
optional string action_label = 1;
optional JAddOnsOnClick on_click = 2;
}
message CardItemFixedFooter {
repeated JAddOnsWidget.Button buttons = 1;
optional JAddOnsWidget.TextButton primary_button = 2;
optional JAddOnsWidget.TextButton secondary_button = 3;
}
message CardItemRefreshAction {
optional JAddOnsFormAction method = 1;
}
enum DisplayStyle {
DISPLAY_STYLE_UNSPECIFIED = 0;
PEEK = 1;
REPLACE = 2;
}
enum DividerStyle {
DIVIDER_STYLE_UNSPECIFIED = 0;
SOLID_DIVIDER = 1;
NO_DIVIDER = 2;
}
optional CardItemHeader header = 1;
repeated CardItemSection sections = 2;
repeated CardItemAction card_actions = 3;
optional string name = 4;
optional CardItemFixedFooter fixed_footer = 5;
optional CardItemRefreshAction refresh_action = 6;
optional DisplayStyle display_style = 7;
optional CardItemHeader peek_card_header = 8;
optional JAddOnsThemeColors background_theme_colors = 9;
repeated int32 feature_capabilities = 10;
optional JAddOnsBorderStyle border_style = 11;
optional bool is_gsuite_card = 12;
optional DividerStyle section_divider_style = 13;
}
message JAddOnsPushCard {
optional JAddOnsCardItem card = 1;
}
message ChatActions {
// optional GsuiteTasksActions gsuite_tasks_actions = 2;
message GsuiteCallActions {
optional string meeting_url = 1;
}
optional GsuiteCallActions gsuite_call_actions = 3;
// optional GsuiteFallbackActions gsuite_fallback_actions = 4;
}
message HostAppAction {
// optional GmailActions gmail_action = 1;
// optional CalendarActions calendar_action = 2;
// optional DriveActions drive_action = 3;
// optional SheetsActions sheets_action = 4;
// optional EditorActions editor_action = 5;
optional ChatActions chat_action = 6;
// optional WorkflowActions workflow_action = 7;
// optional DuetAiAction duet_ai_action = 8;
}
message JAddOnsOnClick {
//oneof DataCase {
optional string link = 1;
optional JAddOnsFormAction action = 2;
optional JAddOnsOpenLink open_link = 5;
optional JAddOnsFormAction open_link_action = 7;
optional JAddOnsPushCard push_card = 8;
optional HostAppAction host_app_action = 9;
// optional DialogCard dialog_card = 12;
// optional OpenGwm open_gwm = 13;
// optional OptOutSuggestion opt_out_suggestion = 14;
// optional OverflowMenu overflow_menu = 15;
// repeated LoggingInfo logging_info = 16;
//}
}
message JAddOnsTextWidget {
repeated string line = 1;
}
message JAddOnsImageComponent {
optional string image_url = 1;
optional string alt_text = 2;
optional JAddOnsImageCropStyle crop_style = 3;
optional JAddOnsBorderStyle border_style = 4;
}
message JAddOnsGrid {
message GridItem {
enum GridItemLayout {
NOT_SET = 0;
TEXT_BELOW = 1;
TEXT_ABOVE = 2;
}
optional string identifier = 1;
optional JAddOnsImageComponent image = 2;
optional string title = 3;
optional string subtitle = 4;
optional JAddOnsWidget.HorizontalAlign text_alignment = 5;
optional GridItemLayout layout = 9;
optional JAddOnsOnClick on_click = 10;
}
optional JAddOnsIdentifier id = 1;
optional string title = 2;
repeated GridItem items = 3;
optional JAddOnsBorderStyle border_style = 4;
optional int32 num_columns = 5;
optional JAddOnsOnClick on_click = 6;
}
message JAddOnsBorderStyle {
enum BorderType {
BORDER_TYPE_NOT_SET = 0;
NO_BORDER = 1;
STROKE = 2;
}
optional BorderType type = 1;
optional JAddOnsThemeColors stroke_color = 2;
optional int32 corner_radius = 3;
}
message JAddOnsLabelContentPair {
optional string label = 1;
optional string content = 2;
}
message JAddOnsLabelContentPairWidget {
repeated JAddOnsLabelContentPair label_content_pair = 1;
}
message JAddOnsWidget {
message TextParagraph {
optional JAddOnsFormattedText text = 1;
}
message TextKeyValue {
optional JAddOnsFormattedText key = 1;
optional JAddOnsFormattedText text = 2;
optional JAddOnsOnClick on_click = 3;
}
message ImageKeyValue {
optional string icon_url = 1;
optional JAddOnsFormattedText text = 2;
optional JAddOnsOnClick on_click = 3;
}
message Image {
optional JAddOnsIdentifier id = 5;
optional string fife_image_url = 1;
optional JAddOnsOnClick on_click = 2;
optional double aspect_ratio = 3;
optional string alt_text = 4;
}
message Icon {
optional string icon_url = 1;
optional string alt_text = 2;
optional JAddOnsImageCropStyle.ImageCropType image_style = 3;
}
message KeyValue {
message SwitchWidget {
enum ControlType {
UNSPECIFIED = 0;
SWITCH = 1;
CHECKBOX = 2;
}
optional JAddOnsIdentifier id = 5;
optional string name = 1;
optional string value = 2;
optional bool selected = 3;
optional JAddOnsFormAction on_change = 4;
optional ControlType control_type = 6;
}
optional string icon_url = 1;
optional string icon_alt_text = 9;
optional JAddOnsImageCropStyle.ImageCropType image_style = 10;
optional Icon start_icon = 11;
optional JAddOnsFormattedText top_label = 2;
optional JAddOnsFormattedText content = 3;
optional bool content_multiline = 8;
optional JAddOnsFormattedText bottom_label = 4;
optional JAddOnsOnClick on_click = 5;
//oneof Control {
optional Button button = 6;
optional SwitchWidget switch_widget = 7;
optional Icon end_icon = 12;
//}
}
message Divider {
// This protobuf intentionally left blank
}
message Menu {
message MenuItem {
optional string text = 1;
optional string value = 4;
optional bool selected = 3;
}
optional string name = 1;
repeated MenuItem items = 2;
optional JAddOnsFormAction on_change = 4;
optional string label = 5;
}
message AutoComplete {
message AutoCompleteItem {
optional string text = 1;
}
repeated AutoCompleteItem items = 1;
}
message TextField {
enum TextFieldType {
REGULAR = 0;
FLOATING = 1;
}
enum LineType {
SINGLE = 0;
MULTIPLE = 1;
}
optional JAddOnsIdentifier id = 11;
optional string name = 1;
optional int32 max_lines = 2;
optional TextFieldType type = 5;
optional string label = 3;
optional string hint_text = 4;
optional string value = 6;
optional LineType line_type = 7;
optional JAddOnsFormAction on_change = 8;
optional AutoComplete auto_complete = 9;
optional JAddOnsFormAction auto_complete_callback = 10;
optional bool auto_complete_multiple_selections = 12;
}
message SelectionControl {
enum SelectionType {
CHECK_BOX = 0;
RADIO_BUTTON = 1;
SWITCH = 2;
DROPDOWN = 3;
}
message SelectionItem {
optional JAddOnsIdentifier id = 4;
optional string text = 1;
optional bool selected = 2;
optional string value = 3;
}
optional JAddOnsIdentifier id = 6;
optional string name = 1;
optional SelectionType type = 2;
repeated SelectionItem items = 3;
optional JAddOnsFormAction on_change = 4;
optional string label = 5;
}
message DateTimePicker {
enum DateTimePickerType {
UNSPECIFIED_TYPE = 0;
DATE_AND_TIME = 1;
DATE_ONLY = 2;
TIME_ONLY = 3;
}
optional string name = 1;
optional string label = 2;
optional DateTimePickerType type = 3;
optional int64 value_ms_epoch = 4;
optional int32 timezone_offset_date = 5;
optional JAddOnsFormAction on_change = 6;
optional int32 color = 7;
optional JAddOnsThemeColors theme_colors = 8;
}
message TextButton {
enum Style {
UNSPECIFIED = 0;
TEXT = 1;
FILLED = 2;
}
optional JAddOnsIdentifier id = 3;
optional JAddOnsFormattedText text = 1;
optional JAddOnsOnClick on_click = 2;
optional bool disabled = 4;
optional Style style = 5;
optional int32 background_color = 6;
optional JAddOnsThemeColors background_theme_colors = 7;
optional string alt_text = 8;
optional string icon_url = 9;
optional MaterialIcon material_icon = 10;
}
message ImageButton {
optional JAddOnsIdentifier id = 4;
optional string icon_url = 1;
optional JAddOnsOnClick on_click = 2;
optional string name = 3;
}
message Button {
//oneof Type {
optional TextButton text_button = 1;
optional ImageButton image_button = 2;
//}
}
enum HorizontalAlign {
NOT_SET = 0;
START = 1;
CENTER = 2;
END = 3;
}
message MaterialIcon {
optional string name = 1;
optional bool fill = 2;
optional int32 weight = 3;
optional int32 grade = 4;
}
//oneof Data {
optional JAddOnsTextWidget text_widget = 1;
optional JAddOnsLabelContentPairWidget label_content_pair_widget = 2;
optional TextParagraph text_paragraph = 3;
optional TextKeyValue text_key_value = 4;
optional ImageKeyValue image_key_value = 5;
optional Image image = 9;
optional KeyValue key_value = 13;
optional Divider divider = 16;
optional JAddOnsGrid grid = 17;
optional Menu menu = 10;
optional TextField text_field = 11;
optional SelectionControl selection_control = 12;
optional DateTimePicker date_time_picker = 14;
//}
repeated Button buttons = 8;
optional HorizontalAlign horizontal_align = 15;
}
message JAddOnsFormAction {
message ActionParameter {
optional string key = 1;
optional string value = 2;
}
enum LoadIndicator {
SPINNER = 0;
NONE = 1;
}
enum Interaction {
INTERACTION_UNSPECIFIED = 0;
OPEN_DIALOG = 1;
}
optional string action_method_name = 1;
repeated ActionParameter parameters = 4;
repeated string parameters_deprecated = 3;
optional string encrypted_action = 7;
optional LoadIndicator load_indicator = 5;
optional bool persist_values = 6;
optional Interaction interaction = 8;
repeated string required_widget_ids = 9;
optional bool all_widgets_are_required = 10;
}
message JAddOnsContextualAddOn {
message Toolbar {
optional JAddOnsFormattedText name = 1;
optional string icon_url = 2;
optional int32 color = 3;
optional JAddOnsThemeColors theme_colors = 4;
}
optional Toolbar toolbar = 1;
message Card {
message CardHeader {
optional JAddOnsFormattedText title = 1;
optional JAddOnsFormattedText subtitle = 2;
optional JAddOnsImageCropStyle.ImageCropType image_style = 3;
optional string image_url = 4;
optional string image_alt_text = 5;
}
optional CardHeader header = 1;
message Section {
optional JAddOnsIdentifier id = 6;
optional string description = 1;
optional JAddOnsFormattedText header = 5;
repeated JAddOnsWidget widgets = 2;
optional bool collapsable = 3;
optional int32 num_uncollapsable_widgets = 4;
}
repeated Section sections = 2;
message CardAction {
optional string action_label = 1;
optional JAddOnsOnClick on_click = 2;
}
repeated CardAction card_actions = 3;
optional string name = 4;
message FixedFooter {
repeated JAddOnsWidget.Button buttons = 1;
optional JAddOnsWidget.TextButton primary_button = 2;
optional JAddOnsWidget.TextButton secondary_button = 3;
}
optional FixedFooter fixed_footer = 5;
message RefreshAction {
optional JAddOnsFormAction method = 1;
}
optional RefreshAction refresh_action = 6;
optional JAddOnsThemeColors background_theme_colors = 7;
}
repeated Card cards = 2;
}
message Html { //ComGoogleCommonHtmlTypesSafeHtmlProto
//private_do_not_access_or_else_safe_html_wrapped_value
optional string html = 2;
}
message HtmlAttachment {
optional Html html = 2;
}
message Attachment {
//oneof Type {
optional HtmlAttachment html = 1;
optional JAddOnsContextualAddOn add_on_data = 2;
//}
optional UserId app_id = 5;
optional User app_user = 6;
optional JAddOnsCardItem card_add_on_data = 7;
optional string attachment_id = 8;
//optional MessageComponentSearchInfo component_search_info = 9;
}
message Reaction {
optional Emoji emoji = 1;
optional int32 count = 2;
optional bool current_user_participated = 3;
optional int64 create_timestamp = 4;
}
message MessageParentId {