1+ package social.boq.notifications.gmscoreapi ;
2+
3+ option java_outer_classname = "GunsGmscoreApiService" ;
4+ option java_package = "org.microg.gms.gcm" ;
5+
6+ service GunsGmscoreApiService {
7+ rpc GmsGnotsFetchByIdentifier (FetchByIdentifierRequest ) returns (FetchByIdentifierResponse );
8+ rpc GmsGnotsSetReadStates (GmsGnotsSetReadStatesRequest ) returns (GmsGnotsSetReadStatesResponse );
9+ }
10+
11+ message FetchByIdentifierRequest {
12+ optional GmsConfig config = 1 ;
13+ optional NotificationIdentifierList identifiers = 2 ;
14+ }
15+
16+ message GmsConfig {
17+ message GmsVersionInfo {
18+ optional int32 version = 10 ;
19+ }
20+ optional GmsVersionInfo versionInfo = 3 ;
21+ }
22+
23+ message NotificationIdentifierList {
24+ repeated NotificationIdentifier notifications = 1 ;
25+ optional DeviceInfo deviceInfo = 2 ;
26+ }
27+
28+ message FetchByIdentifierResponse {
29+ optional NotificationList notifications = 2 ;
30+ }
31+
32+ message NotificationList {
33+ repeated NotificationData notifications = 1 ;
34+ optional uint64 serverTime = 3 ;
35+ }
36+
37+ message NotificationData {
38+ optional UserInfo userInfo = 1 ;
39+ optional NotificationIdentifier identifier = 2 ;
40+ optional bool isActive = 3 ;
41+ optional NotificationContent content = 4 ;
42+ optional NotificationAction action = 5 ;
43+ optional DeviceInfo deviceInfo = 6 ;
44+ optional uint64 createTime = 7 ;
45+ optional IntentActions intentActions = 8 ;
46+ optional uint64 expiryTime = 9 ;
47+ optional BinaryPayload binaryPayload = 10 ;
48+ }
49+
50+ message IntentActions {
51+ optional IntentPayload primaryPayload = 1 ;
52+ optional IntentPayload secondaryPayload = 2 ;
53+ }
54+
55+ message UserInfo {
56+ optional string userId = 1 ;
57+ }
58+
59+ message NotificationIdentifier {
60+ optional string type = 1 ;
61+ optional string uniqueId = 2 ;
62+ optional uint64 timestamp = 3 ;
63+ optional string source = 4 ;
64+ optional string registrationId = 5 ;
65+ optional int64 receivedTime = 6 ;
66+ optional bytes payload = 7 ;
67+ }
68+
69+ message NotificationContent {
70+ optional int32 priority = 1 ;
71+ optional IconInfo icon = 2 ;
72+ optional string title = 3 ;
73+ optional string accountName = 4 ;
74+ optional string email = 5 ;
75+ optional string description = 6 ;
76+ optional string additionalText = 7 ;
77+ optional string eventType = 8 ;
78+ optional string errorMessage = 9 ;
79+ optional bool isDismissible = 10 ;
80+ optional bool requiresAuth = 11 ;
81+ optional bool isUserVisible = 12 ;
82+ optional bool isAutoCancel = 13 ;
83+ optional ActionButtons buttons = 14 ;
84+ optional bool isPersistent = 15 ;
85+ optional string tickerText = 16 ;
86+ repeated NotificationButton actionButtons = 17 ;
87+ optional NotificationChannelInfo channelInfo = 18 ;
88+ optional string groupKey = 19 ;
89+ optional string sortKey = 20 ;
90+ }
91+
92+ message NotificationChannelInfo {
93+ optional string id = 1 ;
94+ optional string description = 2 ;
95+ optional string groupId = 3 ;
96+ optional string groupName = 4 ;
97+ optional int32 importance = 5 ;
98+ optional string name = 6 ;
99+ }
100+
101+ message IconInfo {
102+ optional string iconUrl = 1 ;
103+ }
104+
105+ message ActionButtons {
106+ optional string primaryText = 1 ;
107+ optional string secondaryText = 2 ;
108+ }
109+
110+ message NotificationButton {
111+ optional string text = 1 ;
112+ optional NotificationAction action = 2 ;
113+ optional string icon = 3 ;
114+ optional bool isEnabled = 4 ;
115+ optional int32 buttonType = 6 ;
116+ }
117+
118+ message NotificationAction {
119+ optional ActionMetadata metadata = 1 ;
120+ optional ActionIntent intent = 2 ;
121+ }
122+
123+ message ActionMetadata {
124+ optional string actionUrl = 1 ;
125+ optional bool value = 2 ;
126+ }
127+
128+ message ActionIntent {
129+ optional IntentPayload intentPayload = 4 ;
130+ }
131+
132+ message IntentPayload {
133+ optional string className = 1 ;
134+ optional string action = 2 ;
135+ optional int32 launchType = 3 ;
136+ repeated IntentExtra extras = 4 ;
137+ optional int32 flags = 5 ;
138+ }
139+
140+ message IntentExtra {
141+ optional string key = 1 ;
142+ optional string value = 2 ;
143+ }
144+
145+ message GmsGnotsSetReadStatesRequest {
146+ optional GmsConfig config = 1 ;
147+ optional ReadStateList readStates = 2 ;
148+ }
149+
150+ message ReadStateList {
151+ repeated ReadStateItem items = 1 ;
152+ }
153+
154+ message ReadStateItem {
155+ optional NotificationIdentifier notification = 1 ;
156+ optional string state = 3 ;
157+ optional int32 status = 4 ;
158+ }
159+
160+ message GmsGnotsSetReadStatesResponse {
161+ }
162+
163+ message DeviceInfo {
164+ optional DensityQualifier densityQualifier = 1 ;
165+ enum DensityQualifier {
166+ MDPI = 0 ;
167+ TVDPI = 1 ;
168+ XHDPI = 2 ;
169+ XXHDPI = 3 ;
170+ HDPI = 4 ;
171+ XXXHDPI = 5 ;
172+ }
173+ optional string localeTag = 2 ;
174+ optional int32 sdkVersion = 3 ;
175+ optional float density = 4 ;
176+ optional string timeZoneId = 5 ;
177+ repeated NotificationChannelInfo notificationChannels = 6 ;
178+ }
179+
180+ message BinaryPayload {
181+ required string type = 1 ;
182+ required bytes data = 2 ;
183+ }
0 commit comments