• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1syntax = "proto2";
2package copresence;
3option optimize_for = LITE_RUNTIME;
4import "enums.proto";
5import "identity.proto";
6message ClientVersion {
7  optional string client = 1;
8  optional string version_name = 2;
9  optional int64 version_code = 3;
10  optional string certificate_fingerprint = 4;
11}
12message Status {
13  optional StatusCode code = 1;
14  optional string message = 2;
15}
16message PushServiceRegistration {
17  optional PushService service = 1;
18}
19message DeviceIdentifiers {
20  optional int32 ulr_device_id = 1;
21  optional DeviceIdentity device_identity = 2;
22  optional Identity registrant = 3;
23}
24message Token {
25  message Debug {
26    repeated string email = 2;
27  }
28  optional string id = 1;
29  optional TokenStatus status = 3;
30  optional Debug debug = 4;
31}
32message DeviceFingerprint {
33  optional string manufacturer = 1;
34  optional string model = 2;
35  optional PlatformType type = 3;
36  optional string platform_version = 4;
37}
38message TokenTechnology {
39  optional TokenMedium medium = 1;
40  repeated TokenInstructionType instruction_type = 2;
41}
42message DeviceCapabilities {
43  repeated TokenTechnology token_technology = 2;
44}
45message TokenInstruction {
46  optional TokenInstructionType token_instruction_type = 1;
47  optional TokenMedium medium = 2;
48  optional string token_id = 4;
49}
50message Directive {
51  optional InstructionType instruction_type = 1;
52  optional TokenInstruction token_instruction = 2;
53  optional int64 delay_millis = 3;
54  optional int64 ttl_millis = 4;
55  optional string published_message_id = 5;
56  optional string subscription_id = 6;
57}
58message DeviceState {
59  optional DeviceCapabilities capabilities = 1;
60  repeated Directive active_directive = 2;
61}
62message DebugInfo {
63  optional string served_by_task = 1;
64  repeated string token_id = 3;
65  optional int64 request_time_millis = 4;
66}
67message TokenObservation {
68  optional string token_id = 1;
69  repeated TokenSignals signals = 2;
70}
71message TokenSignals {
72  optional TokenMedium medium = 1;
73  optional int32 rssi = 2;
74  optional int64 observed_time_millis = 3;
75}
76message AccessPolicy {
77  optional int64 ttl_millis = 1;
78  optional Acl acl = 2;
79}
80message Acl {
81  optional AclType acl_type = 1;
82  optional string named_acl_name = 2;
83  optional bytes referenced_acl_consistency_token = 5;
84}
85message PublishedMessage {
86  optional string id = 1;
87  optional AccessPolicy access_policy = 2;
88  optional Message message = 3;
89  optional TokenExchangeStrategy token_exchange_strategy = 5;
90  optional OptInStateFilter opt_in_state_filter = 6;
91}
92message TokenExchangeStrategy {
93  optional AudioConfiguration audio_configuration = 1;
94  optional BroadcastScanConfiguration broadcast_scan_configuration = 2;
95}
96message SubscribedMessage {
97  message Debug {
98    optional string published_message_id = 1;
99    optional string publisher_identity_id = 2;
100    optional string publisher_device_id = 3;
101    optional int64 creation_timestamp_millis = 4;
102    optional int64 ttl_millis = 5;
103    optional TokenExchangeStrategy token_exchange_strategy = 7;
104  }
105  repeated string subscription_id = 1;
106  optional Message published_message = 2;
107  optional Debug debug = 3;
108}
109message Message {
110  optional MessageType type = 2;
111  optional bytes payload = 3;
112}
113message MessageType {
114  optional string type = 2;
115}
116message Subscription {
117  optional string id = 1;
118  optional int64 ttl_millis = 3;
119  optional MessageType message_type = 4;
120  optional TokenExchangeStrategy token_exchange_strategy = 7;
121  optional OptInStateFilter opt_in_state_filter = 8;
122}
123message MessageResult {
124  optional string published_message_id = 1;
125}
126message SubscriptionResult {
127  optional string subscription_id = 1;
128}
129message OptInStateFilter {
130  repeated OptInState allowed_opt_in_state = 1;
131}
132