@fivenet-app/gen 2025.5.3 → 2026.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (195) hide show
  1. package/README.md +1 -1
  2. package/buf/validate/validate.ts +11301 -0
  3. package/clients.ts +193 -154
  4. package/codegen/dbscanner/dbscanner.ts +91 -0
  5. package/codegen/perms/perms.ts +287 -0
  6. package/codegen/sanitizer/sanitizer.ts +113 -0
  7. package/google/protobuf/any.ts +4 -3
  8. package/google/protobuf/descriptor.ts +393 -239
  9. package/google/protobuf/duration.ts +4 -3
  10. package/google/protobuf/struct.ts +485 -0
  11. package/google/protobuf/timestamp.ts +4 -3
  12. package/package.json +3 -3
  13. package/perms.ts +217 -160
  14. package/resources/accounts/accounts.ts +115 -47
  15. package/resources/accounts/{oauth2.ts → oauth2/oauth2.ts} +33 -32
  16. package/resources/audit/audit.ts +172 -53
  17. package/resources/calendar/{access.ts → access/access.ts} +72 -71
  18. package/resources/calendar/calendar.ts +79 -543
  19. package/resources/calendar/entries/entries.ts +474 -0
  20. package/resources/centrum/access/access.ts +345 -0
  21. package/resources/centrum/dispatchers/dispatchers.ts +149 -0
  22. package/resources/centrum/{dispatches.ts → dispatches/dispatches.ts} +267 -164
  23. package/resources/centrum/joblist.ts +136 -0
  24. package/resources/centrum/settings/settings.ts +657 -0
  25. package/resources/centrum/{units_access.ts → units/access/access.ts} +78 -79
  26. package/resources/centrum/{units.ts → units/units.ts} +230 -130
  27. package/resources/clientconfig/clientconfig.ts +1015 -0
  28. package/resources/collab/collab.ts +805 -0
  29. package/resources/common/content/content.ts +169 -63
  30. package/resources/common/content/diff_activity.ts +267 -0
  31. package/resources/common/database/database.ts +92 -35
  32. package/resources/common/error.ts +17 -16
  33. package/resources/common/i18n.ts +20 -24
  34. package/resources/common/id_mapping.ts +69 -0
  35. package/resources/common/tests/objects.ts +4 -3
  36. package/resources/{common/cron → cron}/cron.ts +77 -65
  37. package/resources/discord/discord.ts +209 -0
  38. package/resources/documents/{access.ts → access/access.ts} +75 -76
  39. package/resources/documents/{activity.ts → activity/activity.ts} +349 -124
  40. package/resources/documents/approval/approval.ts +945 -0
  41. package/resources/documents/{category.ts → category/category.ts} +25 -32
  42. package/resources/documents/{comment.ts → comment/comment.ts} +35 -34
  43. package/resources/documents/data/data.ts +303 -0
  44. package/resources/documents/documents.ts +374 -686
  45. package/resources/{common/uuid.ts → documents/forms/forms.ts} +22 -21
  46. package/resources/documents/pins/pins.ts +127 -0
  47. package/resources/documents/references/references.ts +187 -0
  48. package/resources/documents/relations/relations.ts +184 -0
  49. package/resources/documents/{requests.ts → requests/requests.ts} +45 -44
  50. package/resources/documents/stamps/stamp.ts +355 -0
  51. package/resources/documents/{templates.ts → templates/templates.ts} +524 -199
  52. package/resources/documents/workflow/workflow.ts +600 -0
  53. package/resources/file/file.ts +152 -0
  54. package/{services/settings → resources/file}/filestore.ts +179 -165
  55. package/resources/file/meta.ts +148 -0
  56. package/resources/{common/grpcws → grpcws}/grpcws.ts +66 -65
  57. package/resources/jobs/{activity.ts → colleagues/activity/activity.ts} +83 -86
  58. package/resources/jobs/{colleagues.ts → colleagues/colleagues.ts} +76 -80
  59. package/resources/jobs/{conduct.ts → conduct/conduct.ts} +86 -62
  60. package/resources/jobs/jobs.ts +14 -13
  61. package/resources/jobs/{labels.ts → labels/labels.ts} +36 -37
  62. package/resources/jobs/{job_props.ts → props/props.ts} +63 -65
  63. package/resources/jobs/{job_settings.ts → settings/settings.ts} +89 -96
  64. package/resources/jobs/{timeclock.ts → timeclock/timeclock.ts} +42 -41
  65. package/resources/laws/laws.ts +40 -49
  66. package/resources/livemap/coords.ts +81 -0
  67. package/resources/livemap/heatmap/heatmap.ts +93 -0
  68. package/resources/livemap/{livemap.ts → markers/marker_marker.ts} +68 -335
  69. package/resources/livemap/markers/user_marker.ts +377 -0
  70. package/resources/mailer/{access.ts → access/access.ts} +119 -118
  71. package/resources/mailer/{email.ts → emails/email.ts} +38 -41
  72. package/resources/mailer/{events.ts → events/events.ts} +44 -43
  73. package/resources/mailer/{message.ts → messages/message.ts} +69 -74
  74. package/resources/mailer/{settings.ts → settings/settings.ts} +23 -25
  75. package/resources/mailer/{template.ts → templates/template.ts} +37 -40
  76. package/resources/mailer/{thread.ts → threads/thread.ts} +93 -94
  77. package/resources/notifications/clientview/clientview.ts +239 -0
  78. package/resources/notifications/{events.ts → events/events.ts} +67 -130
  79. package/resources/notifications/notifications.ts +55 -60
  80. package/resources/permissions/{attributes.ts → attributes/attributes.ts} +94 -237
  81. package/resources/permissions/events/events.ts +149 -0
  82. package/resources/permissions/{permissions.ts → permissions/permissions.ts} +127 -47
  83. package/resources/qualifications/{access.ts → access/access.ts} +43 -42
  84. package/resources/qualifications/{exam.ts → exam/exam.ts} +419 -229
  85. package/resources/qualifications/qualifications.ts +327 -388
  86. package/resources/settings/banner.ts +14 -21
  87. package/resources/settings/config.ts +663 -79
  88. package/resources/settings/data.ts +90 -0
  89. package/resources/settings/perms.ts +151 -0
  90. package/resources/settings/status.ts +533 -0
  91. package/resources/stats/stats.ts +382 -2
  92. package/resources/sync/{activity.ts → activity/activity.ts} +126 -46
  93. package/resources/sync/data/data.ts +1001 -0
  94. package/resources/sync/data/v2/data.ts +220 -0
  95. package/resources/timestamp/timestamp.ts +3 -2
  96. package/resources/{centrum/user_unit.ts → tracker/mapping.ts} +44 -44
  97. package/resources/userinfo/userinfo.ts +442 -0
  98. package/resources/users/{activity.ts → activity/activity.ts} +182 -166
  99. package/resources/users/{labels.ts → labels/labels.ts} +27 -30
  100. package/resources/users/{licenses.ts → licenses/licenses.ts} +18 -17
  101. package/resources/users/{props.ts → props/props.ts} +109 -77
  102. package/resources/users/short/user.ts +184 -0
  103. package/resources/users/user.ts +528 -0
  104. package/resources/vehicles/activity/activity.ts +231 -0
  105. package/resources/vehicles/props/props.ts +125 -0
  106. package/resources/vehicles/vehicles.ts +43 -18
  107. package/resources/wiki/{access.ts → access/access.ts} +72 -71
  108. package/resources/wiki/{activity.ts → activity/activity.ts} +218 -102
  109. package/resources/wiki/page.ts +164 -93
  110. package/services/auth/auth.client.ts +45 -35
  111. package/services/auth/auth.ts +498 -288
  112. package/services/calendar/calendar.client.ts +32 -91
  113. package/services/calendar/calendar.ts +157 -134
  114. package/services/centrum/centrum.client.ts +97 -137
  115. package/services/centrum/centrum.ts +755 -352
  116. package/services/citizens/citizens.client.ts +70 -39
  117. package/services/citizens/citizens.ts +226 -112
  118. package/services/completor/completor.client.ts +16 -35
  119. package/services/completor/completor.ts +95 -54
  120. package/services/documents/approval.client.ts +188 -0
  121. package/services/documents/approval.ts +1776 -0
  122. package/services/documents/collab.client.ts +46 -0
  123. package/services/documents/collab.ts +13 -0
  124. package/services/documents/documents.client.ts +88 -217
  125. package/services/documents/documents.ts +579 -619
  126. package/services/documents/forms.client.ts +51 -0
  127. package/services/documents/forms.ts +232 -0
  128. package/services/documents/stamps.client.ts +77 -0
  129. package/services/documents/stamps.ts +481 -0
  130. package/services/documents/stats.client.ts +38 -0
  131. package/services/documents/stats.ts +245 -0
  132. package/services/filestore/filestore.client.ts +86 -0
  133. package/services/filestore/filestore.ts +262 -0
  134. package/services/jobs/conduct.client.ts +40 -28
  135. package/services/jobs/conduct.ts +183 -56
  136. package/services/jobs/jobs.client.ts +22 -61
  137. package/services/jobs/jobs.ts +138 -121
  138. package/services/jobs/stats.client.ts +38 -0
  139. package/services/jobs/stats.ts +207 -0
  140. package/services/jobs/timeclock.client.ts +8 -19
  141. package/services/jobs/timeclock.ts +76 -75
  142. package/services/livemap/livemap.client.ts +8 -19
  143. package/services/livemap/livemap.ts +297 -126
  144. package/services/mailer/mailer.client.ts +44 -127
  145. package/services/mailer/mailer.ts +266 -269
  146. package/services/notifications/notifications.client.ts +65 -0
  147. package/services/{notificator/notificator.ts → notifications/notifications.ts} +126 -83
  148. package/services/qualifications/qualifications.client.ts +46 -91
  149. package/services/qualifications/qualifications.ts +250 -209
  150. package/services/settings/accounts.client.ts +31 -33
  151. package/services/settings/accounts.ts +251 -67
  152. package/services/settings/config.client.ts +6 -13
  153. package/services/settings/config.ts +8 -7
  154. package/services/settings/cron.client.ts +4 -7
  155. package/services/settings/cron.ts +7 -6
  156. package/services/settings/laws.client.ts +10 -25
  157. package/services/settings/laws.ts +30 -29
  158. package/services/settings/settings.client.ts +57 -103
  159. package/services/settings/settings.ts +237 -633
  160. package/services/settings/system.client.ts +103 -0
  161. package/services/settings/system.ts +718 -0
  162. package/services/stats/stats.client.ts +9 -8
  163. package/services/stats/stats.ts +27 -26
  164. package/services/sync/sync.client.ts +16 -15
  165. package/services/sync/sync.ts +174 -97
  166. package/services/sync/v2/sync.client.ts +331 -0
  167. package/services/sync/v2/sync.ts +1766 -0
  168. package/services/vehicles/vehicles.client.ts +17 -7
  169. package/services/vehicles/vehicles.ts +170 -25
  170. package/services/wiki/collab.client.ts +46 -0
  171. package/services/wiki/collab.ts +13 -0
  172. package/services/wiki/wiki.client.ts +28 -37
  173. package/services/wiki/wiki.ts +97 -67
  174. package/svcs.ts +174 -106
  175. package/resources/centrum/attributes.ts +0 -186
  176. package/resources/centrum/disponents.ts +0 -81
  177. package/resources/centrum/settings.ts +0 -307
  178. package/resources/documents/workflow.ts +0 -351
  179. package/resources/filestore/file.ts +0 -204
  180. package/resources/internet/access.ts +0 -358
  181. package/resources/internet/ads.ts +0 -257
  182. package/resources/internet/domain.ts +0 -328
  183. package/resources/internet/page.ts +0 -428
  184. package/resources/internet/search.ts +0 -128
  185. package/resources/livemap/tracker.ts +0 -81
  186. package/resources/sync/data.ts +0 -587
  187. package/resources/users/users.ts +0 -435
  188. package/services/internet/ads.client.ts +0 -41
  189. package/services/internet/ads.ts +0 -145
  190. package/services/internet/domain.client.ts +0 -109
  191. package/services/internet/domain.ts +0 -658
  192. package/services/internet/internet.client.ts +0 -58
  193. package/services/internet/internet.ts +0 -268
  194. package/services/notificator/notificator.client.ts +0 -76
  195. package/services/settings/filestore.client.ts +0 -75
@@ -1,6 +1,9 @@
1
- // @generated by protobuf-ts 2.10.0 with parameter optimize_speed,long_type_number,force_server_none
1
+ // @generated by protobuf-ts 2.11.1 with parameter force_server_none,long_type_number,optimize_speed,ts_nocheck
2
2
  // @generated from protobuf file "services/citizens/citizens.proto" (package "services.citizens", syntax proto3)
3
+ // tslint:disable
3
4
  // @ts-nocheck
5
+ import { UploadFileResponse } from "../../resources/file/filestore";
6
+ import { UploadFileRequest } from "../../resources/file/filestore";
4
7
  import { ServiceType } from "@protobuf-ts/runtime-rpc";
5
8
  import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
6
9
  import type { IBinaryWriter } from "@protobuf-ts/runtime";
@@ -11,12 +14,11 @@ import { UnknownFieldHandler } from "@protobuf-ts/runtime";
11
14
  import type { PartialMessage } from "@protobuf-ts/runtime";
12
15
  import { reflectionMergePartial } from "@protobuf-ts/runtime";
13
16
  import { MessageType } from "@protobuf-ts/runtime";
14
- import { Label } from "../../resources/users/labels";
15
- import { File } from "../../resources/filestore/file";
16
- import { UserProps } from "../../resources/users/props";
17
- import { UserActivity } from "../../resources/users/activity";
18
- import { UserActivityType } from "../../resources/users/activity";
19
- import { User } from "../../resources/users/users";
17
+ import { Label } from "../../resources/users/labels/labels";
18
+ import { UserProps } from "../../resources/users/props/props";
19
+ import { UserActivity } from "../../resources/users/activity/activity";
20
+ import { UserActivityType } from "../../resources/users/activity/activity";
21
+ import { User } from "../../resources/users/user";
20
22
  import { PaginationResponse } from "../../resources/common/database/database";
21
23
  import { Sort } from "../../resources/common/database/database";
22
24
  import { PaginationRequest } from "../../resources/common/database/database";
@@ -25,50 +27,60 @@ import { PaginationRequest } from "../../resources/common/database/database";
25
27
  */
26
28
  export interface ListCitizensRequest {
27
29
  /**
28
- * @generated from protobuf field: resources.common.database.PaginationRequest pagination = 1;
30
+ * @generated from protobuf field: resources.common.database.PaginationRequest pagination = 1
29
31
  */
30
32
  pagination?: PaginationRequest;
31
33
  /**
32
- * @generated from protobuf field: optional resources.common.database.Sort sort = 2;
34
+ * @generated from protobuf field: optional resources.common.database.Sort sort = 2
33
35
  */
34
36
  sort?: Sort;
35
37
  /**
36
38
  * Search params
37
39
  *
38
- * @generated from protobuf field: string search = 3;
40
+ * @generated from protobuf field: string search = 3
39
41
  */
40
42
  search: string;
41
43
  /**
42
- * @generated from protobuf field: optional bool wanted = 4;
44
+ * @generated from protobuf field: optional bool wanted = 4
43
45
  */
44
46
  wanted?: boolean;
45
47
  /**
46
- * @generated from protobuf field: optional string phone_number = 5;
48
+ * @generated from protobuf field: optional string phone_number = 5
47
49
  */
48
50
  phoneNumber?: string;
49
51
  /**
50
- * @generated from protobuf field: optional uint32 traffic_infraction_points = 6;
52
+ * @generated from protobuf field: optional uint32 traffic_infraction_points = 6
51
53
  */
52
54
  trafficInfractionPoints?: number;
53
55
  /**
54
- * @generated from protobuf field: optional string dateofbirth = 7;
56
+ * @generated from protobuf field: optional string dateofbirth = 7
55
57
  */
56
58
  dateofbirth?: string;
57
59
  /**
58
- * @generated from protobuf field: optional uint64 open_fines = 8;
60
+ * @generated from protobuf field: optional int64 open_fines = 8
59
61
  */
60
62
  openFines?: number;
63
+ /**
64
+ * Height range search (in cm)
65
+ *
66
+ * @generated from protobuf field: optional float min_height = 9
67
+ */
68
+ minHeight?: number;
69
+ /**
70
+ * @generated from protobuf field: optional float max_height = 10
71
+ */
72
+ maxHeight?: number;
61
73
  }
62
74
  /**
63
75
  * @generated from protobuf message services.citizens.ListCitizensResponse
64
76
  */
65
77
  export interface ListCitizensResponse {
66
78
  /**
67
- * @generated from protobuf field: resources.common.database.PaginationResponse pagination = 1;
79
+ * @generated from protobuf field: resources.common.database.PaginationResponse pagination = 1
68
80
  */
69
81
  pagination?: PaginationResponse;
70
82
  /**
71
- * @generated from protobuf field: repeated resources.users.User users = 2;
83
+ * @generated from protobuf field: repeated resources.users.User users = 2
72
84
  */
73
85
  users: User[];
74
86
  }
@@ -77,11 +89,11 @@ export interface ListCitizensResponse {
77
89
  */
78
90
  export interface GetUserRequest {
79
91
  /**
80
- * @generated from protobuf field: int32 user_id = 1;
92
+ * @generated from protobuf field: int32 user_id = 1
81
93
  */
82
94
  userId: number;
83
95
  /**
84
- * @generated from protobuf field: optional bool info_only = 2;
96
+ * @generated from protobuf field: optional bool info_only = 2
85
97
  */
86
98
  infoOnly?: boolean;
87
99
  }
@@ -90,7 +102,7 @@ export interface GetUserRequest {
90
102
  */
91
103
  export interface GetUserResponse {
92
104
  /**
93
- * @generated from protobuf field: resources.users.User user = 1;
105
+ * @generated from protobuf field: resources.users.User user = 1
94
106
  */
95
107
  user?: User;
96
108
  }
@@ -99,21 +111,21 @@ export interface GetUserResponse {
99
111
  */
100
112
  export interface ListUserActivityRequest {
101
113
  /**
102
- * @generated from protobuf field: resources.common.database.PaginationRequest pagination = 1;
114
+ * @generated from protobuf field: resources.common.database.PaginationRequest pagination = 1
103
115
  */
104
116
  pagination?: PaginationRequest;
105
117
  /**
106
- * @generated from protobuf field: optional resources.common.database.Sort sort = 2;
118
+ * @generated from protobuf field: optional resources.common.database.Sort sort = 2
107
119
  */
108
120
  sort?: Sort;
109
121
  /**
110
122
  * Search params
111
123
  *
112
- * @generated from protobuf field: int32 user_id = 3;
124
+ * @generated from protobuf field: int32 user_id = 3
113
125
  */
114
126
  userId: number;
115
127
  /**
116
- * @generated from protobuf field: repeated resources.users.UserActivityType types = 4;
128
+ * @generated from protobuf field: repeated resources.users.activity.UserActivityType types = 4
117
129
  */
118
130
  types: UserActivityType[];
119
131
  }
@@ -122,11 +134,11 @@ export interface ListUserActivityRequest {
122
134
  */
123
135
  export interface ListUserActivityResponse {
124
136
  /**
125
- * @generated from protobuf field: resources.common.database.PaginationResponse pagination = 1;
137
+ * @generated from protobuf field: resources.common.database.PaginationResponse pagination = 1
126
138
  */
127
139
  pagination?: PaginationResponse;
128
140
  /**
129
- * @generated from protobuf field: repeated resources.users.UserActivity activity = 2;
141
+ * @generated from protobuf field: repeated resources.users.activity.UserActivity activity = 2
130
142
  */
131
143
  activity: UserActivity[];
132
144
  }
@@ -135,13 +147,11 @@ export interface ListUserActivityResponse {
135
147
  */
136
148
  export interface SetUserPropsRequest {
137
149
  /**
138
- * @generated from protobuf field: resources.users.UserProps props = 1;
150
+ * @generated from protobuf field: resources.users.props.UserProps props = 1
139
151
  */
140
152
  props?: UserProps;
141
153
  /**
142
- * @sanitize
143
- *
144
- * @generated from protobuf field: string reason = 2;
154
+ * @generated from protobuf field: string reason = 2
145
155
  */
146
156
  reason: string;
147
157
  }
@@ -150,34 +160,44 @@ export interface SetUserPropsRequest {
150
160
  */
151
161
  export interface SetUserPropsResponse {
152
162
  /**
153
- * @generated from protobuf field: resources.users.UserProps props = 1;
163
+ * @generated from protobuf field: resources.users.props.UserProps props = 1
154
164
  */
155
165
  props?: UserProps;
156
166
  }
157
167
  /**
158
- * @generated from protobuf message services.citizens.SetProfilePictureRequest
168
+ * @generated from protobuf message services.citizens.DeleteAvatarRequest
159
169
  */
160
- export interface SetProfilePictureRequest {
161
- /**
162
- * @generated from protobuf field: resources.filestore.File avatar = 1;
163
- */
164
- avatar?: File;
170
+ export interface DeleteAvatarRequest {
171
+ }
172
+ /**
173
+ * @generated from protobuf message services.citizens.DeleteAvatarResponse
174
+ */
175
+ export interface DeleteAvatarResponse {
165
176
  }
166
177
  /**
167
- * @generated from protobuf message services.citizens.SetProfilePictureResponse
178
+ * @generated from protobuf message services.citizens.DeleteMugshotRequest
168
179
  */
169
- export interface SetProfilePictureResponse {
180
+ export interface DeleteMugshotRequest {
181
+ /**
182
+ * @generated from protobuf field: int32 user_id = 1
183
+ */
184
+ userId: number;
170
185
  /**
171
- * @generated from protobuf field: resources.filestore.File avatar = 1;
186
+ * @generated from protobuf field: string reason = 2
172
187
  */
173
- avatar?: File;
188
+ reason: string;
189
+ }
190
+ /**
191
+ * @generated from protobuf message services.citizens.DeleteMugshotResponse
192
+ */
193
+ export interface DeleteMugshotResponse {
174
194
  }
175
195
  /**
176
196
  * @generated from protobuf message services.citizens.ManageLabelsRequest
177
197
  */
178
198
  export interface ManageLabelsRequest {
179
199
  /**
180
- * @generated from protobuf field: repeated resources.users.Label labels = 1;
200
+ * @generated from protobuf field: repeated resources.users.labels.Label labels = 1
181
201
  */
182
202
  labels: Label[];
183
203
  }
@@ -186,7 +206,7 @@ export interface ManageLabelsRequest {
186
206
  */
187
207
  export interface ManageLabelsResponse {
188
208
  /**
189
- * @generated from protobuf field: repeated resources.users.Label labels = 1;
209
+ * @generated from protobuf field: repeated resources.users.labels.Label labels = 1
190
210
  */
191
211
  labels: Label[];
192
212
  }
@@ -194,14 +214,16 @@ export interface ManageLabelsResponse {
194
214
  class ListCitizensRequest$Type extends MessageType<ListCitizensRequest> {
195
215
  constructor() {
196
216
  super("services.citizens.ListCitizensRequest", [
197
- { no: 1, name: "pagination", kind: "message", T: () => PaginationRequest, options: { "validate.rules": { message: { required: true } } } },
217
+ { no: 1, name: "pagination", kind: "message", T: () => PaginationRequest, options: { "buf.validate.field": { required: true } } },
198
218
  { no: 2, name: "sort", kind: "message", T: () => Sort },
199
- { no: 3, name: "search", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { maxLen: "64" } } } },
219
+ { no: 3, name: "search", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "64" } } } },
200
220
  { no: 4, name: "wanted", kind: "scalar", opt: true, T: 8 /*ScalarType.BOOL*/ },
201
- { no: 5, name: "phone_number", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { maxLen: "20" } } } },
221
+ { no: 5, name: "phone_number", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "20" } } } },
202
222
  { no: 6, name: "traffic_infraction_points", kind: "scalar", opt: true, T: 13 /*ScalarType.UINT32*/ },
203
- { no: 7, name: "dateofbirth", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { maxLen: "10" } } } },
204
- { no: 8, name: "open_fines", kind: "scalar", opt: true, T: 4 /*ScalarType.UINT64*/, L: 2 /*LongType.NUMBER*/ }
223
+ { no: 7, name: "dateofbirth", kind: "scalar", opt: true, T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { string: { maxLen: "10" } } } },
224
+ { no: 8, name: "open_fines", kind: "scalar", opt: true, T: 3 /*ScalarType.INT64*/, L: 2 /*LongType.NUMBER*/ },
225
+ { no: 9, name: "min_height", kind: "scalar", opt: true, T: 2 /*ScalarType.FLOAT*/ },
226
+ { no: 10, name: "max_height", kind: "scalar", opt: true, T: 2 /*ScalarType.FLOAT*/ }
205
227
  ]);
206
228
  }
207
229
  create(value?: PartialMessage<ListCitizensRequest>): ListCitizensRequest {
@@ -237,8 +259,14 @@ class ListCitizensRequest$Type extends MessageType<ListCitizensRequest> {
237
259
  case /* optional string dateofbirth */ 7:
238
260
  message.dateofbirth = reader.string();
239
261
  break;
240
- case /* optional uint64 open_fines */ 8:
241
- message.openFines = reader.uint64().toNumber();
262
+ case /* optional int64 open_fines */ 8:
263
+ message.openFines = reader.int64().toNumber();
264
+ break;
265
+ case /* optional float min_height */ 9:
266
+ message.minHeight = reader.float();
267
+ break;
268
+ case /* optional float max_height */ 10:
269
+ message.maxHeight = reader.float();
242
270
  break;
243
271
  default:
244
272
  let u = options.readUnknownField;
@@ -273,9 +301,15 @@ class ListCitizensRequest$Type extends MessageType<ListCitizensRequest> {
273
301
  /* optional string dateofbirth = 7; */
274
302
  if (message.dateofbirth !== undefined)
275
303
  writer.tag(7, WireType.LengthDelimited).string(message.dateofbirth);
276
- /* optional uint64 open_fines = 8; */
304
+ /* optional int64 open_fines = 8; */
277
305
  if (message.openFines !== undefined)
278
- writer.tag(8, WireType.Varint).uint64(message.openFines);
306
+ writer.tag(8, WireType.Varint).int64(message.openFines);
307
+ /* optional float min_height = 9; */
308
+ if (message.minHeight !== undefined)
309
+ writer.tag(9, WireType.Bit32).float(message.minHeight);
310
+ /* optional float max_height = 10; */
311
+ if (message.maxHeight !== undefined)
312
+ writer.tag(10, WireType.Bit32).float(message.maxHeight);
279
313
  let u = options.writeUnknownFields;
280
314
  if (u !== false)
281
315
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
@@ -290,8 +324,8 @@ export const ListCitizensRequest = new ListCitizensRequest$Type();
290
324
  class ListCitizensResponse$Type extends MessageType<ListCitizensResponse> {
291
325
  constructor() {
292
326
  super("services.citizens.ListCitizensResponse", [
293
- { no: 1, name: "pagination", kind: "message", T: () => PaginationResponse },
294
- { no: 2, name: "users", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => User }
327
+ { no: 1, name: "pagination", kind: "message", T: () => PaginationResponse, options: { "buf.validate.field": { required: true } } },
328
+ { no: 2, name: "users", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => User, options: { "codegen.itemslen.enabled": true } }
295
329
  ]);
296
330
  }
297
331
  create(value?: PartialMessage<ListCitizensResponse>): ListCitizensResponse {
@@ -344,7 +378,7 @@ export const ListCitizensResponse = new ListCitizensResponse$Type();
344
378
  class GetUserRequest$Type extends MessageType<GetUserRequest> {
345
379
  constructor() {
346
380
  super("services.citizens.GetUserRequest", [
347
- { no: 1, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "validate.rules": { int32: { gt: 0 } } } },
381
+ { no: 1, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "buf.validate.field": { int32: { gt: 0 } } } },
348
382
  { no: 2, name: "info_only", kind: "scalar", opt: true, T: 8 /*ScalarType.BOOL*/ }
349
383
  ]);
350
384
  }
@@ -444,10 +478,10 @@ export const GetUserResponse = new GetUserResponse$Type();
444
478
  class ListUserActivityRequest$Type extends MessageType<ListUserActivityRequest> {
445
479
  constructor() {
446
480
  super("services.citizens.ListUserActivityRequest", [
447
- { no: 1, name: "pagination", kind: "message", T: () => PaginationRequest, options: { "validate.rules": { message: { required: true } } } },
481
+ { no: 1, name: "pagination", kind: "message", T: () => PaginationRequest, options: { "buf.validate.field": { required: true } } },
448
482
  { no: 2, name: "sort", kind: "message", T: () => Sort },
449
- { no: 3, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "validate.rules": { int32: { gt: 0 } } } },
450
- { no: 4, name: "types", kind: "enum", repeat: 1 /*RepeatType.PACKED*/, T: () => ["resources.users.UserActivityType", UserActivityType, "USER_ACTIVITY_TYPE_"], options: { "validate.rules": { repeated: { maxItems: "20" } } } }
483
+ { no: 3, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "buf.validate.field": { int32: { gt: 0 } } } },
484
+ { no: 4, name: "types", kind: "enum", repeat: 1 /*RepeatType.PACKED*/, T: () => ["resources.users.activity.UserActivityType", UserActivityType, "USER_ACTIVITY_TYPE_"], options: { "buf.validate.field": { repeated: { maxItems: "20" } } } }
451
485
  ]);
452
486
  }
453
487
  create(value?: PartialMessage<ListUserActivityRequest>): ListUserActivityRequest {
@@ -472,7 +506,7 @@ class ListUserActivityRequest$Type extends MessageType<ListUserActivityRequest>
472
506
  case /* int32 user_id */ 3:
473
507
  message.userId = reader.int32();
474
508
  break;
475
- case /* repeated resources.users.UserActivityType types */ 4:
509
+ case /* repeated resources.users.activity.UserActivityType types */ 4:
476
510
  if (wireType === WireType.LengthDelimited)
477
511
  for (let e = reader.int32() + reader.pos; reader.pos < e;)
478
512
  message.types.push(reader.int32());
@@ -500,7 +534,7 @@ class ListUserActivityRequest$Type extends MessageType<ListUserActivityRequest>
500
534
  /* int32 user_id = 3; */
501
535
  if (message.userId !== 0)
502
536
  writer.tag(3, WireType.Varint).int32(message.userId);
503
- /* repeated resources.users.UserActivityType types = 4; */
537
+ /* repeated resources.users.activity.UserActivityType types = 4; */
504
538
  if (message.types.length) {
505
539
  writer.tag(4, WireType.LengthDelimited).fork();
506
540
  for (let i = 0; i < message.types.length; i++)
@@ -521,8 +555,8 @@ export const ListUserActivityRequest = new ListUserActivityRequest$Type();
521
555
  class ListUserActivityResponse$Type extends MessageType<ListUserActivityResponse> {
522
556
  constructor() {
523
557
  super("services.citizens.ListUserActivityResponse", [
524
- { no: 1, name: "pagination", kind: "message", T: () => PaginationResponse },
525
- { no: 2, name: "activity", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => UserActivity }
558
+ { no: 1, name: "pagination", kind: "message", T: () => PaginationResponse, options: { "buf.validate.field": { required: true } } },
559
+ { no: 2, name: "activity", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => UserActivity, options: { "codegen.itemslen.enabled": true } }
526
560
  ]);
527
561
  }
528
562
  create(value?: PartialMessage<ListUserActivityResponse>): ListUserActivityResponse {
@@ -540,7 +574,7 @@ class ListUserActivityResponse$Type extends MessageType<ListUserActivityResponse
540
574
  case /* resources.common.database.PaginationResponse pagination */ 1:
541
575
  message.pagination = PaginationResponse.internalBinaryRead(reader, reader.uint32(), options, message.pagination);
542
576
  break;
543
- case /* repeated resources.users.UserActivity activity */ 2:
577
+ case /* repeated resources.users.activity.UserActivity activity */ 2:
544
578
  message.activity.push(UserActivity.internalBinaryRead(reader, reader.uint32(), options));
545
579
  break;
546
580
  default:
@@ -558,7 +592,7 @@ class ListUserActivityResponse$Type extends MessageType<ListUserActivityResponse
558
592
  /* resources.common.database.PaginationResponse pagination = 1; */
559
593
  if (message.pagination)
560
594
  PaginationResponse.internalBinaryWrite(message.pagination, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
561
- /* repeated resources.users.UserActivity activity = 2; */
595
+ /* repeated resources.users.activity.UserActivity activity = 2; */
562
596
  for (let i = 0; i < message.activity.length; i++)
563
597
  UserActivity.internalBinaryWrite(message.activity[i], writer.tag(2, WireType.LengthDelimited).fork(), options).join();
564
598
  let u = options.writeUnknownFields;
@@ -575,8 +609,8 @@ export const ListUserActivityResponse = new ListUserActivityResponse$Type();
575
609
  class SetUserPropsRequest$Type extends MessageType<SetUserPropsRequest> {
576
610
  constructor() {
577
611
  super("services.citizens.SetUserPropsRequest", [
578
- { no: 1, name: "props", kind: "message", T: () => UserProps, options: { "validate.rules": { message: { required: true } } } },
579
- { no: 2, name: "reason", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "validate.rules": { string: { minLen: "3", maxLen: "255", ignoreEmpty: true } } } }
612
+ { no: 1, name: "props", kind: "message", T: () => UserProps, options: { "buf.validate.field": { required: true } } },
613
+ { no: 2, name: "reason", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { ignore: "IGNORE_IF_ZERO_VALUE", string: { minLen: "3", maxLen: "255" } }, "codegen.sanitizer.sanitizer": { enabled: true } } }
580
614
  ]);
581
615
  }
582
616
  create(value?: PartialMessage<SetUserPropsRequest>): SetUserPropsRequest {
@@ -591,7 +625,7 @@ class SetUserPropsRequest$Type extends MessageType<SetUserPropsRequest> {
591
625
  while (reader.pos < end) {
592
626
  let [fieldNo, wireType] = reader.tag();
593
627
  switch (fieldNo) {
594
- case /* resources.users.UserProps props */ 1:
628
+ case /* resources.users.props.UserProps props */ 1:
595
629
  message.props = UserProps.internalBinaryRead(reader, reader.uint32(), options, message.props);
596
630
  break;
597
631
  case /* string reason */ 2:
@@ -609,7 +643,7 @@ class SetUserPropsRequest$Type extends MessageType<SetUserPropsRequest> {
609
643
  return message;
610
644
  }
611
645
  internalBinaryWrite(message: SetUserPropsRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
612
- /* resources.users.UserProps props = 1; */
646
+ /* resources.users.props.UserProps props = 1; */
613
647
  if (message.props)
614
648
  UserProps.internalBinaryWrite(message.props, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
615
649
  /* string reason = 2; */
@@ -643,7 +677,7 @@ class SetUserPropsResponse$Type extends MessageType<SetUserPropsResponse> {
643
677
  while (reader.pos < end) {
644
678
  let [fieldNo, wireType] = reader.tag();
645
679
  switch (fieldNo) {
646
- case /* resources.users.UserProps props */ 1:
680
+ case /* resources.users.props.UserProps props */ 1:
647
681
  message.props = UserProps.internalBinaryRead(reader, reader.uint32(), options, message.props);
648
682
  break;
649
683
  default:
@@ -658,7 +692,7 @@ class SetUserPropsResponse$Type extends MessageType<SetUserPropsResponse> {
658
692
  return message;
659
693
  }
660
694
  internalBinaryWrite(message: SetUserPropsResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
661
- /* resources.users.UserProps props = 1; */
695
+ /* resources.users.props.UserProps props = 1; */
662
696
  if (message.props)
663
697
  UserProps.internalBinaryWrite(message.props, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
664
698
  let u = options.writeUnknownFields;
@@ -672,26 +706,59 @@ class SetUserPropsResponse$Type extends MessageType<SetUserPropsResponse> {
672
706
  */
673
707
  export const SetUserPropsResponse = new SetUserPropsResponse$Type();
674
708
  // @generated message type with reflection information, may provide speed optimized methods
675
- class SetProfilePictureRequest$Type extends MessageType<SetProfilePictureRequest> {
709
+ class DeleteAvatarRequest$Type extends MessageType<DeleteAvatarRequest> {
676
710
  constructor() {
677
- super("services.citizens.SetProfilePictureRequest", [
678
- { no: 1, name: "avatar", kind: "message", T: () => File }
679
- ]);
711
+ super("services.citizens.DeleteAvatarRequest", []);
680
712
  }
681
- create(value?: PartialMessage<SetProfilePictureRequest>): SetProfilePictureRequest {
713
+ create(value?: PartialMessage<DeleteAvatarRequest>): DeleteAvatarRequest {
682
714
  const message = globalThis.Object.create((this.messagePrototype!));
683
715
  if (value !== undefined)
684
- reflectionMergePartial<SetProfilePictureRequest>(this, message, value);
716
+ reflectionMergePartial<DeleteAvatarRequest>(this, message, value);
685
717
  return message;
686
718
  }
687
- internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SetProfilePictureRequest): SetProfilePictureRequest {
719
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteAvatarRequest): DeleteAvatarRequest {
720
+ let message = target ?? this.create(), end = reader.pos + length;
721
+ while (reader.pos < end) {
722
+ let [fieldNo, wireType] = reader.tag();
723
+ switch (fieldNo) {
724
+ default:
725
+ let u = options.readUnknownField;
726
+ if (u === "throw")
727
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
728
+ let d = reader.skip(wireType);
729
+ if (u !== false)
730
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
731
+ }
732
+ }
733
+ return message;
734
+ }
735
+ internalBinaryWrite(message: DeleteAvatarRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
736
+ let u = options.writeUnknownFields;
737
+ if (u !== false)
738
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
739
+ return writer;
740
+ }
741
+ }
742
+ /**
743
+ * @generated MessageType for protobuf message services.citizens.DeleteAvatarRequest
744
+ */
745
+ export const DeleteAvatarRequest = new DeleteAvatarRequest$Type();
746
+ // @generated message type with reflection information, may provide speed optimized methods
747
+ class DeleteAvatarResponse$Type extends MessageType<DeleteAvatarResponse> {
748
+ constructor() {
749
+ super("services.citizens.DeleteAvatarResponse", []);
750
+ }
751
+ create(value?: PartialMessage<DeleteAvatarResponse>): DeleteAvatarResponse {
752
+ const message = globalThis.Object.create((this.messagePrototype!));
753
+ if (value !== undefined)
754
+ reflectionMergePartial<DeleteAvatarResponse>(this, message, value);
755
+ return message;
756
+ }
757
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteAvatarResponse): DeleteAvatarResponse {
688
758
  let message = target ?? this.create(), end = reader.pos + length;
689
759
  while (reader.pos < end) {
690
760
  let [fieldNo, wireType] = reader.tag();
691
761
  switch (fieldNo) {
692
- case /* resources.filestore.File avatar */ 1:
693
- message.avatar = File.internalBinaryRead(reader, reader.uint32(), options, message.avatar);
694
- break;
695
762
  default:
696
763
  let u = options.readUnknownField;
697
764
  if (u === "throw")
@@ -703,10 +770,7 @@ class SetProfilePictureRequest$Type extends MessageType<SetProfilePictureRequest
703
770
  }
704
771
  return message;
705
772
  }
706
- internalBinaryWrite(message: SetProfilePictureRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
707
- /* resources.filestore.File avatar = 1; */
708
- if (message.avatar)
709
- File.internalBinaryWrite(message.avatar, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
773
+ internalBinaryWrite(message: DeleteAvatarResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
710
774
  let u = options.writeUnknownFields;
711
775
  if (u !== false)
712
776
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
@@ -714,29 +778,35 @@ class SetProfilePictureRequest$Type extends MessageType<SetProfilePictureRequest
714
778
  }
715
779
  }
716
780
  /**
717
- * @generated MessageType for protobuf message services.citizens.SetProfilePictureRequest
781
+ * @generated MessageType for protobuf message services.citizens.DeleteAvatarResponse
718
782
  */
719
- export const SetProfilePictureRequest = new SetProfilePictureRequest$Type();
783
+ export const DeleteAvatarResponse = new DeleteAvatarResponse$Type();
720
784
  // @generated message type with reflection information, may provide speed optimized methods
721
- class SetProfilePictureResponse$Type extends MessageType<SetProfilePictureResponse> {
785
+ class DeleteMugshotRequest$Type extends MessageType<DeleteMugshotRequest> {
722
786
  constructor() {
723
- super("services.citizens.SetProfilePictureResponse", [
724
- { no: 1, name: "avatar", kind: "message", T: () => File }
787
+ super("services.citizens.DeleteMugshotRequest", [
788
+ { no: 1, name: "user_id", kind: "scalar", T: 5 /*ScalarType.INT32*/, options: { "buf.validate.field": { int32: { gt: 0 } } } },
789
+ { no: 2, name: "reason", kind: "scalar", T: 9 /*ScalarType.STRING*/, options: { "buf.validate.field": { ignore: "IGNORE_IF_ZERO_VALUE", string: { minLen: "3", maxLen: "255" } }, "codegen.sanitizer.sanitizer": { enabled: true } } }
725
790
  ]);
726
791
  }
727
- create(value?: PartialMessage<SetProfilePictureResponse>): SetProfilePictureResponse {
792
+ create(value?: PartialMessage<DeleteMugshotRequest>): DeleteMugshotRequest {
728
793
  const message = globalThis.Object.create((this.messagePrototype!));
794
+ message.userId = 0;
795
+ message.reason = "";
729
796
  if (value !== undefined)
730
- reflectionMergePartial<SetProfilePictureResponse>(this, message, value);
797
+ reflectionMergePartial<DeleteMugshotRequest>(this, message, value);
731
798
  return message;
732
799
  }
733
- internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: SetProfilePictureResponse): SetProfilePictureResponse {
800
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteMugshotRequest): DeleteMugshotRequest {
734
801
  let message = target ?? this.create(), end = reader.pos + length;
735
802
  while (reader.pos < end) {
736
803
  let [fieldNo, wireType] = reader.tag();
737
804
  switch (fieldNo) {
738
- case /* resources.filestore.File avatar */ 1:
739
- message.avatar = File.internalBinaryRead(reader, reader.uint32(), options, message.avatar);
805
+ case /* int32 user_id */ 1:
806
+ message.userId = reader.int32();
807
+ break;
808
+ case /* string reason */ 2:
809
+ message.reason = reader.string();
740
810
  break;
741
811
  default:
742
812
  let u = options.readUnknownField;
@@ -749,10 +819,51 @@ class SetProfilePictureResponse$Type extends MessageType<SetProfilePictureRespon
749
819
  }
750
820
  return message;
751
821
  }
752
- internalBinaryWrite(message: SetProfilePictureResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
753
- /* resources.filestore.File avatar = 1; */
754
- if (message.avatar)
755
- File.internalBinaryWrite(message.avatar, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
822
+ internalBinaryWrite(message: DeleteMugshotRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
823
+ /* int32 user_id = 1; */
824
+ if (message.userId !== 0)
825
+ writer.tag(1, WireType.Varint).int32(message.userId);
826
+ /* string reason = 2; */
827
+ if (message.reason !== "")
828
+ writer.tag(2, WireType.LengthDelimited).string(message.reason);
829
+ let u = options.writeUnknownFields;
830
+ if (u !== false)
831
+ (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
832
+ return writer;
833
+ }
834
+ }
835
+ /**
836
+ * @generated MessageType for protobuf message services.citizens.DeleteMugshotRequest
837
+ */
838
+ export const DeleteMugshotRequest = new DeleteMugshotRequest$Type();
839
+ // @generated message type with reflection information, may provide speed optimized methods
840
+ class DeleteMugshotResponse$Type extends MessageType<DeleteMugshotResponse> {
841
+ constructor() {
842
+ super("services.citizens.DeleteMugshotResponse", []);
843
+ }
844
+ create(value?: PartialMessage<DeleteMugshotResponse>): DeleteMugshotResponse {
845
+ const message = globalThis.Object.create((this.messagePrototype!));
846
+ if (value !== undefined)
847
+ reflectionMergePartial<DeleteMugshotResponse>(this, message, value);
848
+ return message;
849
+ }
850
+ internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: DeleteMugshotResponse): DeleteMugshotResponse {
851
+ let message = target ?? this.create(), end = reader.pos + length;
852
+ while (reader.pos < end) {
853
+ let [fieldNo, wireType] = reader.tag();
854
+ switch (fieldNo) {
855
+ default:
856
+ let u = options.readUnknownField;
857
+ if (u === "throw")
858
+ throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
859
+ let d = reader.skip(wireType);
860
+ if (u !== false)
861
+ (u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
862
+ }
863
+ }
864
+ return message;
865
+ }
866
+ internalBinaryWrite(message: DeleteMugshotResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
756
867
  let u = options.writeUnknownFields;
757
868
  if (u !== false)
758
869
  (u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
@@ -760,14 +871,14 @@ class SetProfilePictureResponse$Type extends MessageType<SetProfilePictureRespon
760
871
  }
761
872
  }
762
873
  /**
763
- * @generated MessageType for protobuf message services.citizens.SetProfilePictureResponse
874
+ * @generated MessageType for protobuf message services.citizens.DeleteMugshotResponse
764
875
  */
765
- export const SetProfilePictureResponse = new SetProfilePictureResponse$Type();
876
+ export const DeleteMugshotResponse = new DeleteMugshotResponse$Type();
766
877
  // @generated message type with reflection information, may provide speed optimized methods
767
878
  class ManageLabelsRequest$Type extends MessageType<ManageLabelsRequest> {
768
879
  constructor() {
769
880
  super("services.citizens.ManageLabelsRequest", [
770
- { no: 1, name: "labels", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Label }
881
+ { no: 1, name: "labels", kind: "message", repeat: 2 /*RepeatType.UNPACKED*/, T: () => Label, options: { "buf.validate.field": { repeated: { maxItems: "50" } } } }
771
882
  ]);
772
883
  }
773
884
  create(value?: PartialMessage<ManageLabelsRequest>): ManageLabelsRequest {
@@ -782,7 +893,7 @@ class ManageLabelsRequest$Type extends MessageType<ManageLabelsRequest> {
782
893
  while (reader.pos < end) {
783
894
  let [fieldNo, wireType] = reader.tag();
784
895
  switch (fieldNo) {
785
- case /* repeated resources.users.Label labels */ 1:
896
+ case /* repeated resources.users.labels.Label labels */ 1:
786
897
  message.labels.push(Label.internalBinaryRead(reader, reader.uint32(), options));
787
898
  break;
788
899
  default:
@@ -797,7 +908,7 @@ class ManageLabelsRequest$Type extends MessageType<ManageLabelsRequest> {
797
908
  return message;
798
909
  }
799
910
  internalBinaryWrite(message: ManageLabelsRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
800
- /* repeated resources.users.Label labels = 1; */
911
+ /* repeated resources.users.labels.Label labels = 1; */
801
912
  for (let i = 0; i < message.labels.length; i++)
802
913
  Label.internalBinaryWrite(message.labels[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
803
914
  let u = options.writeUnknownFields;
@@ -829,7 +940,7 @@ class ManageLabelsResponse$Type extends MessageType<ManageLabelsResponse> {
829
940
  while (reader.pos < end) {
830
941
  let [fieldNo, wireType] = reader.tag();
831
942
  switch (fieldNo) {
832
- case /* repeated resources.users.Label labels */ 1:
943
+ case /* repeated resources.users.labels.Label labels */ 1:
833
944
  message.labels.push(Label.internalBinaryRead(reader, reader.uint32(), options));
834
945
  break;
835
946
  default:
@@ -844,7 +955,7 @@ class ManageLabelsResponse$Type extends MessageType<ManageLabelsResponse> {
844
955
  return message;
845
956
  }
846
957
  internalBinaryWrite(message: ManageLabelsResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter {
847
- /* repeated resources.users.Label labels = 1; */
958
+ /* repeated resources.users.labels.Label labels = 1; */
848
959
  for (let i = 0; i < message.labels.length; i++)
849
960
  Label.internalBinaryWrite(message.labels[i], writer.tag(1, WireType.LengthDelimited).fork(), options).join();
850
961
  let u = options.writeUnknownFields;
@@ -861,10 +972,13 @@ export const ManageLabelsResponse = new ManageLabelsResponse$Type();
861
972
  * @generated ServiceType for protobuf service services.citizens.CitizensService
862
973
  */
863
974
  export const CitizensService = new ServiceType("services.citizens.CitizensService", [
864
- { name: "ListCitizens", options: {}, I: ListCitizensRequest, O: ListCitizensResponse },
865
- { name: "GetUser", options: {}, I: GetUserRequest, O: GetUserResponse },
866
- { name: "ListUserActivity", options: {}, I: ListUserActivityRequest, O: ListUserActivityResponse },
867
- { name: "SetUserProps", options: {}, I: SetUserPropsRequest, O: SetUserPropsResponse },
868
- { name: "SetProfilePicture", options: {}, I: SetProfilePictureRequest, O: SetProfilePictureResponse },
869
- { name: "ManageLabels", options: {}, I: ManageLabelsRequest, O: ManageLabelsResponse }
870
- ]);
975
+ { name: "ListCitizens", options: { "codegen.perms.perms": { enabled: true, attrs: [{ key: "Fields", type: "ATTRIBUTE_TYPE_STRING_LIST", validStringList: ["PhoneNumber", "Licenses", "UserProps.Wanted", "UserProps.Job", "UserProps.TrafficInfractionPoints", "UserProps.OpenFines", "UserProps.BloodType", "UserProps.Mugshot", "UserProps.Labels", "UserProps.Email"] }] } }, I: ListCitizensRequest, O: ListCitizensResponse },
976
+ { name: "GetUser", options: { "codegen.perms.perms": { enabled: true, attrs: [{ key: "Jobs", type: "ATTRIBUTE_TYPE_JOB_GRADE_LIST" }] } }, I: GetUserRequest, O: GetUserResponse },
977
+ { name: "ListUserActivity", options: { "codegen.perms.perms": { enabled: true, attrs: [{ key: "Fields", type: "ATTRIBUTE_TYPE_STRING_LIST", validStringList: ["SourceUser", "Own"] }] } }, I: ListUserActivityRequest, O: ListUserActivityResponse },
978
+ { name: "SetUserProps", options: { "codegen.perms.perms": { enabled: true, attrs: [{ key: "Fields", type: "ATTRIBUTE_TYPE_STRING_LIST", validStringList: ["Wanted", "Job", "TrafficInfractionPoints", "Mugshot", "Labels"] }] } }, I: SetUserPropsRequest, O: SetUserPropsResponse },
979
+ { name: "UploadAvatar", clientStreaming: true, options: { "codegen.perms.perms": { enabled: true, name: "Any" } }, I: UploadFileRequest, O: UploadFileResponse },
980
+ { name: "DeleteAvatar", options: { "codegen.perms.perms": { enabled: true, name: "Any" } }, I: DeleteAvatarRequest, O: DeleteAvatarResponse },
981
+ { name: "UploadMugshot", clientStreaming: true, options: { "codegen.perms.perms": { enabled: true, name: "SetUserProps" } }, I: UploadFileRequest, O: UploadFileResponse },
982
+ { name: "DeleteMugshot", options: { "codegen.perms.perms": { enabled: true, name: "SetUserProps" } }, I: DeleteMugshotRequest, O: DeleteMugshotResponse },
983
+ { name: "ManageLabels", options: { "codegen.perms.perms": { enabled: true } }, I: ManageLabelsRequest, O: ManageLabelsResponse }
984
+ ], { "codegen.perms.perms_svc": { order: 30, icon: "i-mdi-account-multiple-outline" } });