-
Notifications
You must be signed in to change notification settings - Fork 9
/
events.proto
1107 lines (913 loc) · 32.7 KB
/
events.proto
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 = "proto3";
package anytype;
option go_package = "pb";
import "models.proto";
import "google/protobuf/struct.proto";
/*
* Event – type of message, that could be sent from a middleware to the corresponding front-end.
*/
message Event {
repeated Message messages = 1;
string contextId = 2;
anytype.model.Account initiator = 3;
string traceId = 4;
message Message {
oneof value {
Account.Show accountShow = 1;
Account.Details accountDetails = 201;
Account.Config.Update accountConfigUpdate = 202;
Account.Update accountUpdate = 203;
Account.LinkChallenge accountLinkChallenge = 204;
Object.Details.Set objectDetailsSet = 16;
Object.Details.Amend objectDetailsAmend = 50;
Object.Details.Unset objectDetailsUnset = 51;
Object.Relations.Amend objectRelationsAmend = 52;
Object.Relations.Remove objectRelationsRemove = 53;
Object.Remove objectRemove = 54;
Object.Close objectClose = 65;
Object.Restrictions.Set objectRestrictionsSet = 55;
Object.Subscription.Add subscriptionAdd = 60;
Object.Subscription.Remove subscriptionRemove = 61;
Object.Subscription.Position subscriptionPosition = 62;
Object.Subscription.Counters subscriptionCounters = 63;
Object.Subscription.Groups subscriptionGroups = 64;
Block.Add blockAdd = 2;
Block.Delete blockDelete = 3;
Block.FilesUpload filesUpload = 4;
Block.MarksInfo marksInfo = 5;
Block.Set.Fields blockSetFields = 6;
Block.Set.ChildrenIds blockSetChildrenIds = 7;
Block.Set.Restrictions blockSetRestrictions = 8;
Block.Set.BackgroundColor blockSetBackgroundColor = 9;
Block.Set.Text blockSetText = 10;
Block.Set.File blockSetFile = 11;
Block.Set.Link blockSetLink = 13;
Block.Set.Bookmark blockSetBookmark = 14;
Block.Set.Align blockSetAlign = 15;
Block.Set.Div blockSetDiv = 17;
Block.Set.Relation blockSetRelation = 21;
Block.Set.Latex blockSetLatex = 25;
Block.Set.VerticalAlign blockSetVerticalAlign = 36;
Block.Set.TableRow blockSetTableRow = 37;
Block.Set.Widget blockSetWidget = 40;
Block.Dataview.ViewSet blockDataviewViewSet = 19;
Block.Dataview.ViewDelete blockDataviewViewDelete = 20;
Block.Dataview.ViewOrder blockDataviewViewOrder = 29;
Block.Dataview.SourceSet blockDataviewSourceSet = 35; // deprecated, source is no longer used
Block.Dataview.GroupOrderUpdate blockDataViewGroupOrderUpdate = 38;
Block.Dataview.ObjectOrderUpdate blockDataViewObjectOrderUpdate = 39;
Block.Dataview.RelationDelete blockDataviewRelationDelete = 124;
Block.Dataview.RelationSet blockDataviewRelationSet = 123;
Block.Dataview.ViewUpdate blockDataviewViewUpdate = 125;
Block.Dataview.TargetObjectIdSet blockDataviewTargetObjectIdSet = 126;
Block.Dataview.IsCollectionSet blockDataviewIsCollectionSet = 127;
// deprecated
Block.Dataview.OldRelationDelete blockDataviewOldRelationDelete = 24;
// deprecated
Block.Dataview.OldRelationSet blockDataviewOldRelationSet = 23;
User.Block.Join userBlockJoin = 31;
User.Block.Left userBlockLeft = 32;
User.Block.SelectRange userBlockSelectRange = 33;
User.Block.TextRange userBlockTextRange = 34;
Ping ping = 100;
Process.New processNew = 101;
Process.Update processUpdate = 102;
Process.Done processDone = 103;
Status.Thread threadStatus = 110;
File.LimitReached fileLimitReached = 111;
File.SpaceUsage fileSpaceUsage = 112;
File.LocalUsage fileLocalUsage = 113;
File.LimitUpdated fileLimitUpdated = 118;
Notification.Send notificationSend = 114;
Notification.Update notificationUpdate = 115;
Payload.Broadcast payloadBroadcast = 116;
Membership.Update membershipUpdate = 117;
}
}
message Account {
/**
* Message, that will be sent to the front on each account found after an AccountRecoverRequest
*/
message Show {
int32 index = 1; // Number of an account in an all found accounts list
anytype.model.Account account = 2; // An Account, that has been found for the mnemonic
}
message Details {
string profileId = 1;
google.protobuf.Struct details = 2;
}
message Config {
message Update {
anytype.model.Account.Config config = 1;
anytype.model.Account.Status status = 2;
}
}
message Update {
anytype.model.Account.Config config = 1;
anytype.model.Account.Status status = 2;
}
message LinkChallenge {
message ClientInfo {
string processName = 1;
string processPath = 2;
bool signatureVerified = 3;
}
string challenge = 1;
ClientInfo clientInfo = 2;
}
}
message Object {
message Details {
// Amend (i.e. add a new key-value pair or update an existing key-value pair) existing state
message Amend {
message KeyValue {
string key = 1;
google.protobuf.Value value = 2; // should not be null
}
string id = 1; // context objectId
repeated KeyValue details = 2; // slice of changed key-values
repeated string subIds = 3;
}
// Overwrite current state
message Set {
string id = 1; // context objectId
google.protobuf.Struct details = 2; // can not be a partial state. Should replace client details state
repeated string subIds = 3;
}
// Unset existing detail keys
message Unset {
string id = 1; // context objectId
repeated string keys = 2;
repeated string subIds = 3;
}
}
message Subscription {
// Adds new document to subscriptions
message Add {
string id = 1; // object id
string afterId = 2; // id of previous doc in order, empty means first
string subId = 3; // subscription id
}
// Removes document from subscription
message Remove {
string id = 1; // object id
string subId = 2; // subscription id
}
// Indicates new position of document
message Position {
string id = 1; // object id
string afterId = 2; // id of previous doc in order, empty means first
string subId = 3; // subscription id
}
message Counters {
// total available records
int64 total = 1;
// how many records available after
int64 nextCount = 2;
// how many records available before
int64 prevCount = 3;
string subId = 4; // subscription id
}
message Groups {
string subId = 1;
anytype.model.Block.Content.Dataview.Group group = 2;
bool remove = 3;
}
}
message Relations {
message Amend {
string id = 1; // context objectId
repeated anytype.model.RelationLink relationLinks = 2;
}
message Remove {
string id = 1; // context objectId
repeated string relationKeys = 2;
}
}
message Remove {
// notifies that objects were removed
repeated string ids = 1;
}
message Restrictions {
message Set {
string id = 1;
anytype.model.Restrictions restrictions = 2;
}
}
message Close {
string id = 1;
}
}
message Block {
/*
* Event to show internal blocks on a client.
* Example Scenarios
* A. Block Creation
* 1. Block A have been created on a client C1
* 2. Client C2 receives Event.Block.Add(Block A), Event.Block.Update(Page.children)
* B. Partial block load
* 1. Client C1 opens Page1, that contains, for example, 133 blocks.
* 2. M -> F: ShowFullScreen(Root, blocks1-50)
* 3. M -> F: Block.Add(blocks51-100)
* 3. M -> F: Block.Add(blocks101-133)
*/
message Add {
repeated anytype.model.Block blocks = 1; // id -> block
}
/**
* Middleware to front end event message, that will be sent on one of this scenarios:
* Precondition: user A opened a block
* 1. User A drops a set of files/pictures/videos
* 2. User A creates a MediaBlock and drops a single media, that corresponds to its type.
*/
message FilesUpload {
string blockId = 1; // if empty => create new blocks
repeated string filePath = 2; // filepaths to the files
}
/*
*
*/
message Delete {
repeated string blockIds = 1;
}
message MarksInfo {
repeated anytype.model.Block.Content.Text.Mark.Type marksInRange = 1;
}
message Set {
message Relation {
string id = 1;
Key key = 2;
message Key {
string value = 1;
}
}
message Fields {
string id = 1;
google.protobuf.Struct fields = 2;
}
message ChildrenIds {
string id = 1;
repeated string childrenIds = 2;
}
message Restrictions {
string id = 1;
anytype.model.Block.Restrictions restrictions = 2;
}
message BackgroundColor {
string id = 1;
string backgroundColor = 2;
}
message Align {
string id = 1;
anytype.model.Block.Align align = 2;
}
message VerticalAlign {
string id = 1;
anytype.model.Block.VerticalAlign verticalAlign = 2;
}
message Text {
string id = 1;
Text text = 2;
Style style = 3;
Marks marks = 4;
Checked checked = 5;
Color color = 6;
IconEmoji iconEmoji = 7;
IconImage iconImage = 8;
message Text {
string value = 1;
}
message Style {
anytype.model.Block.Content.Text.Style value = 1;
}
message Marks {
anytype.model.Block.Content.Text.Marks value = 1;
}
message Checked {
bool value = 1;
}
message Color {
string value = 1;
}
message IconEmoji {
string value = 1;
}
message IconImage {
string value = 1;
}
}
message Latex {
string id = 1;
Text text = 2;
message Text {
string value = 1;
}
Processor processor = 3;
message Processor {
anytype.model.Block.Content.Latex.Processor value = 1;
}
}
message Div {
string id = 1;
Style style = 2;
message Style {
anytype.model.Block.Content.Div.Style value = 1;
}
}
message File {
string id = 1;
Type type = 2;
State state = 3;
Mime mime = 4;
Hash hash = 5;
Name name = 6;
Size size = 7;
Style style = 8;
TargetObjectId targetObjectId = 9;
message Name {
string value = 1;
}
message Width {
int32 value = 1;
}
message State {
anytype.model.Block.Content.File.State value = 1;
}
message Type {
anytype.model.Block.Content.File.Type value = 1;
}
message Style {
anytype.model.Block.Content.File.Style value = 1;
}
message Hash {
string value = 1;
}
message Mime {
string value = 1;
}
message Size {
int64 value = 1;
}
message TargetObjectId {
string value = 1;
}
}
message Link {
string id = 1;
TargetBlockId targetBlockId = 2;
Style style = 3;
Fields fields = 4;
IconSize iconSize = 5;
CardStyle cardStyle = 6;
Description description = 7;
Relations relations = 8;
message TargetBlockId {
string value = 1;
}
message Style {
anytype.model.Block.Content.Link.Style value = 1;
}
message Fields {
google.protobuf.Struct value = 1;
}
message IconSize {
anytype.model.Block.Content.Link.IconSize value = 1;
}
message CardStyle {
anytype.model.Block.Content.Link.CardStyle value = 1;
}
message Description {
anytype.model.Block.Content.Link.Description value = 1;
}
message Relations {
repeated string value = 1;
}
}
message Bookmark {
string id = 1;
Url url = 2;
Title title = 3;
Description description = 4;
ImageHash imageHash = 5;
FaviconHash faviconHash = 6;
Type type = 7;
TargetObjectId targetObjectId = 8;
State state = 9;
message Url {
string value = 1;
}
message Title {
string value = 1;
}
message Description {
string value = 1;
}
message ImageHash {
string value = 1;
}
message FaviconHash {
string value = 1;
}
message Type {
anytype.model.LinkPreview.Type value = 1;
}
message TargetObjectId {
string value = 1;
}
message State {
anytype.model.Block.Content.Bookmark.State value = 1;
}
}
message TableRow {
string id = 1;
IsHeader isHeader = 2;
message IsHeader {
bool value = 1;
}
}
message Widget {
string id = 1;
Layout layout = 2;
Limit limit = 3;
ViewId viewId = 4;
message Layout {
anytype.model.Block.Content.Widget.Layout value = 1;
}
message Limit {
int32 value = 1;
}
message ViewId {
string value = 1;
}
}
}
message Fill {
message Details {
string id = 1;
google.protobuf.Struct details = 2;
}
message DatabaseRecords {
string id = 1;
repeated google.protobuf.Struct records = 2;
}
message Fields {
string id = 1;
google.protobuf.Struct fields = 2;
}
message ChildrenIds {
string id = 1;
repeated string childrenIds = 2;
}
message Restrictions {
string id = 1;
anytype.model.Block.Restrictions restrictions = 2;
}
message BackgroundColor {
string id = 1;
string backgroundColor = 2;
}
message Align {
string id = 1;
anytype.model.Block.Align align = 2;
}
message Text {
string id = 1;
Text text = 2;
Style style = 3;
Marks marks = 4;
Checked checked = 5;
Color color = 6;
message Text {
string value = 1;
}
message Style {
anytype.model.Block.Content.Text.Style value = 1;
}
message Marks {
anytype.model.Block.Content.Text.Marks value = 1;
}
message Checked {
bool value = 1;
}
message Color {
string value = 1;
}
}
message Div {
string id = 1;
Style style = 2;
message Style {
anytype.model.Block.Content.Div.Style value = 1;
}
}
message File {
string id = 1;
Type type = 2;
State state = 3;
Mime mime = 4;
Hash hash = 5;
Name name = 6;
Size size = 7;
Style style = 8;
message Name {
string value = 1;
}
message Width {
int32 value = 1;
}
message State {
anytype.model.Block.Content.File.State value = 1;
}
message Type {
anytype.model.Block.Content.File.Type value = 1;
}
message Style {
anytype.model.Block.Content.File.Style value = 1;
}
message Hash {
string value = 1;
}
message Mime {
string value = 1;
}
message Size {
int64 value = 1;
}
}
message Link {
string id = 1;
TargetBlockId targetBlockId = 2;
Style style = 3;
Fields fields = 4;
message TargetBlockId {
string value = 1;
}
message Style {
anytype.model.Block.Content.Link.Style value = 1;
}
message Fields {
google.protobuf.Struct value = 1;
}
}
message Bookmark {
string id = 1;
Url url = 2;
Title title = 3;
Description description = 4;
ImageHash imageHash = 5;
FaviconHash faviconHash = 6;
Type type = 7;
TargetObjectId targetObjectId = 8;
message Url {
string value = 1;
}
message Title {
string value = 1;
}
message Description {
string value = 1;
}
message ImageHash {
string value = 1;
}
message FaviconHash {
string value = 1;
}
message Type {
anytype.model.LinkPreview.Type value = 1;
}
message TargetObjectId {
string value = 1;
}
}
}
message Dataview {
// sent when the view have been changed or added
message ViewSet {
string id = 1; // dataview block's id
string viewId = 2; // view id, client should double check this to make sure client doesn't switch the active view in the middle
anytype.model.Block.Content.Dataview.View view = 3;
}
message ViewUpdate {
string id = 1;
string viewId = 2;
repeated Filter filter = 3;
repeated Relation relation = 4;
repeated Sort sort = 5;
Fields fields = 6;
message Fields {
anytype.model.Block.Content.Dataview.View.Type type = 1;
string name = 2;
string coverRelationKey = 3; // Relation used for cover in gallery
bool hideIcon = 4; // Hide icon near name
anytype.model.Block.Content.Dataview.View.Size cardSize = 5; // Gallery card size
bool coverFit = 6; // Image fits container
string groupRelationKey = 7; // Group view by this relationKey
bool groupBackgroundColors = 8; // Enable backgrounds in groups
int32 pageLimit = 9; // Limit of objects shown in widget
string defaultTemplateId = 10; // Id of template object set default for the view
string defaultObjectTypeId = 15; // Default object type that is chosen for new object created within the view
}
message Filter {
oneof operation {
Add add = 1;
Remove remove = 2;
Update update = 3;
Move move = 4;
}
message Add {
string afterId = 1;
repeated anytype.model.Block.Content.Dataview.Filter items = 2;
}
message Remove {
repeated string ids = 1;
}
message Update {
string id = 1;
anytype.model.Block.Content.Dataview.Filter item = 2;
}
message Move {
string afterId = 1;
repeated string ids = 2;
}
}
message Relation {
oneof operation {
Add add = 1;
Remove remove = 2;
Update update = 3;
Move move = 4;
}
message Add {
string afterId = 1;
repeated anytype.model.Block.Content.Dataview.Relation items = 2;
}
message Remove {
repeated string ids = 1;
}
message Update {
string id = 1;
anytype.model.Block.Content.Dataview.Relation item = 2;
}
message Move {
string afterId = 1;
repeated string ids = 2;
}
}
message Sort {
oneof operation {
Add add = 1;
Remove remove = 2;
Update update = 3;
Move move = 4;
}
message Add {
string afterId = 1;
repeated anytype.model.Block.Content.Dataview.Sort items = 2;
}
message Remove {
repeated string ids = 1;
}
message Update {
string id = 1;
anytype.model.Block.Content.Dataview.Sort item = 2;
}
message Move {
string afterId = 1;
repeated string ids = 2;
}
}
}
message ViewDelete {
string id = 1; // dataview block's id
string viewId = 2; // view id to remove
}
message ViewOrder {
string id = 1; // dataview block's id
repeated string viewIds = 2; // view ids in new order
}
message SourceSet {
string id = 1; // dataview block's id
repeated string source = 2;
}
message OldRelationDelete {
string id = 1; // dataview block's id
string relationKey = 2; // relation key to remove
}
// sent when the dataview relation has been changed or added
message OldRelationSet {
string id = 1; // dataview block's id
string relationKey = 2; // relation key to update
anytype.model.Relation relation = 3;
}
message RelationDelete {
string id = 1; // dataview block's id
repeated string relationKeys = 2; // relation key to remove
}
// sent when the dataview relation has been changed or added
message RelationSet {
string id = 1; // dataview block's id
repeated anytype.model.RelationLink relationLinks = 2; // relation id to update
}
message GroupOrderUpdate {
string id = 1; // dataview block's id
anytype.model.Block.Content.Dataview.GroupOrder groupOrder = 2;
}
message ObjectOrderUpdate {
string id = 1; // dataview block's id
string viewId = 2;
string groupId = 3;
repeated SliceChange sliceChanges = 4;
}
message SliceChange {
SliceOperation op = 1;
repeated string ids = 2;
string afterId = 3;
}
enum SliceOperation {
SliceOperationNone = 0; // not used
SliceOperationAdd = 1;
SliceOperationMove = 2;
SliceOperationRemove = 3;
SliceOperationReplace = 4;
}
message TargetObjectIdSet {
string id = 1; // dataview block's id
string targetObjectId = 2;
}
message IsCollectionSet {
string id = 1; // dataview block's id
bool value = 2;
}
}
}
message User {
message Block {
/**
* Middleware to front end event message, that will be sent in this scenario:
* Precondition: user A opened a block
* 1. User B opens the same block
* 2. User A receives a message about p.1
*/
message Join {
Account account = 1; // Account of the user, that opened a block
}
/**
* Middleware to front end event message, that will be sent in this scenario:
* Precondition: user A and user B opened the same block
* 1. User B closes the block
* 2. User A receives a message about p.1
*/
message Left {
Account account = 1; // Account of the user, that left the block
}
/**
* Middleware to front end event message, that will be sent in this scenario:
* Precondition: user A and user B opened the same block
* 1. User B sets cursor or selects a text region into a text block
* 2. User A receives a message about p.1
*/
message TextRange {
Account account = 1; // Account of the user, that selected a text
string blockId = 2; // Id of the text block, that have a selection
anytype.model.Range range = 3; // Range of the selection
}
/**
* Middleware to front end event message, that will be sent in this scenario:
* Precondition: user A and user B opened the same block
* 1. User B selects some inner blocks
* 2. User A receives a message about p.1
*/
message SelectRange {
Account account = 1; // Account of the user, that selected blocks
repeated string blockIdsArray = 2; // Ids of selected blocks.
}
}
}
message Ping {
int32 index = 1;
}
message Process {
message New {
Model.Process process = 1;
}
message Update {
Model.Process process = 1;
}
message Done {
Model.Process process = 1;
}
}
message Status {
message Thread {
Summary summary = 1;
Cafe cafe = 2;
repeated Account accounts = 3;
message Summary {
SyncStatus status = 1;
}
message Cafe {
SyncStatus status = 1;
int64 lastPulled = 2;
bool lastPushSucceed = 3;
PinStatus files = 4;
message PinStatus {
int32 pinning = 1;
int32 pinned = 2;
int32 failed = 3;
int64 updated = 4;
}
}