@pidgr/proto 0.36.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.
@@ -0,0 +1,904 @@
1
+ // @generated by protoc-gen-es v2.11.0 with parameter "target=ts"
2
+ // @generated from file pidgr/v1/common.proto (package pidgr.v1, syntax proto3)
3
+ /* eslint-disable */
4
+
5
+ import type { GenEnum, GenFile, GenMessage } from "@bufbuild/protobuf/codegenv2";
6
+ import { enumDesc, fileDesc, messageDesc } from "@bufbuild/protobuf/codegenv2";
7
+ import type { Timestamp } from "@bufbuild/protobuf/wkt";
8
+ import { file_google_protobuf_timestamp } from "@bufbuild/protobuf/wkt";
9
+ import type { Message as Message$1 } from "@bufbuild/protobuf";
10
+
11
+ /**
12
+ * Describes the file pidgr/v1/common.proto.
13
+ */
14
+ export const file_pidgr_v1_common: GenFile = /*@__PURE__*/
15
+ fileDesc("ChVwaWRnci92MS9jb21tb24ucHJvdG8SCHBpZGdyLnYxIoABCgRSb2xlEgoKAmlkGAEgASgJEgwKBHNsdWcYAiABKAkSDAoEbmFtZRgDIAEoCRISCgppc19kZWZhdWx0GAQgASgIEikKC3Blcm1pc3Npb25zGAUgAygOMhQucGlkZ3IudjEuUGVybWlzc2lvbhIRCglpc19zeXN0ZW0YBiABKAgiMwoKUGFnaW5hdGlvbhIRCglwYWdlX3NpemUYASABKAUSEgoKcGFnZV90b2tlbhgCIAEoCSI+Cg5QYWdpbmF0aW9uTWV0YRIXCg9uZXh0X3BhZ2VfdG9rZW4YASABKAkSEwoLdG90YWxfY291bnQYAiABKAUiTgoNTWVzc2FnZUFjdGlvbhIKCgJpZBgBIAEoCRIiCgR0eXBlGAIgASgOMhQucGlkZ3IudjEuQWN0aW9uVHlwZRINCgVsYWJlbBgDIAEoCSLyAQoHTWVzc2FnZRISCgpjb250ZW50X2lkGAEgASgJEhMKC2NhbXBhaWduX2lkGAIgASgJEhMKC3NlbmRlcl9uYW1lGAMgASgJEg8KB3N1bW1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UWVBFX0FDSxABKrgBCghTdGVwVHlwZRIZChVTVEVQX1RZUEVfVU5TUEVDSUZJRUQQABIfChtTVEVQX1RZUEVfU0VORF9OT1RJRklDQVRJT04QARIcChhTVEVQX1RZUEVfREVBRExJTkVfQ0hFQ0sQAhIbChdTVEVQX1RZUEVfU0VORF9SRU1JTkRFUhADEhoKFlNURVBfVFlQRV9DQUxMX1dFQkhPT0sQBBIZChVTVEVQX1RZUEVfTUFSS19NSVNTRUQQBUI2WjRnaXRodWIuY29tL3BpZGdyL3BpZGdyLXByb3RvL2dlbi9nby9waWRnci92MTtwaWRncnYxYgZwcm90bzM", [file_google_protobuf_timestamp]);
16
+
17
+ /**
18
+ * A named role within an organization with a set of permissions.
19
+ *
20
+ * @generated from message pidgr.v1.Role
21
+ */
22
+ export type Role = Message$1<"pidgr.v1.Role"> & {
23
+ /**
24
+ * Unique identifier for the role.
25
+ *
26
+ * @generated from field: string id = 1;
27
+ */
28
+ id: string;
29
+
30
+ /**
31
+ * URL-safe slug (unique within the organization, e.g. "admin", "manager").
32
+ *
33
+ * @generated from field: string slug = 2;
34
+ */
35
+ slug: string;
36
+
37
+ /**
38
+ * Human-readable display name.
39
+ *
40
+ * @generated from field: string name = 3;
41
+ */
42
+ name: string;
43
+
44
+ /**
45
+ * Whether this role was seeded by the system on organization creation.
46
+ *
47
+ * @generated from field: bool is_default = 4;
48
+ */
49
+ isDefault: boolean;
50
+
51
+ /**
52
+ * Permissions granted to users with this role.
53
+ *
54
+ * @generated from field: repeated pidgr.v1.Permission permissions = 5;
55
+ */
56
+ permissions: Permission[];
57
+
58
+ /**
59
+ * Whether this role is system-managed and immutable (e.g. super_admin).
60
+ *
61
+ * @generated from field: bool is_system = 6;
62
+ */
63
+ isSystem: boolean;
64
+ };
65
+
66
+ /**
67
+ * Describes the message pidgr.v1.Role.
68
+ * Use `create(RoleSchema)` to create a new message.
69
+ */
70
+ export const RoleSchema: GenMessage<Role> = /*@__PURE__*/
71
+ messageDesc(file_pidgr_v1_common, 0);
72
+
73
+ /**
74
+ * Cursor-based pagination parameters for list requests.
75
+ *
76
+ * @generated from message pidgr.v1.Pagination
77
+ */
78
+ export type Pagination = Message$1<"pidgr.v1.Pagination"> & {
79
+ /**
80
+ * Maximum number of items to return per page.
81
+ *
82
+ * @generated from field: int32 page_size = 1;
83
+ */
84
+ pageSize: number;
85
+
86
+ /**
87
+ * Opaque token from a previous response to fetch the next page.
88
+ *
89
+ * @generated from field: string page_token = 2;
90
+ */
91
+ pageToken: string;
92
+ };
93
+
94
+ /**
95
+ * Describes the message pidgr.v1.Pagination.
96
+ * Use `create(PaginationSchema)` to create a new message.
97
+ */
98
+ export const PaginationSchema: GenMessage<Pagination> = /*@__PURE__*/
99
+ messageDesc(file_pidgr_v1_common, 1);
100
+
101
+ /**
102
+ * Pagination metadata returned alongside list responses.
103
+ *
104
+ * @generated from message pidgr.v1.PaginationMeta
105
+ */
106
+ export type PaginationMeta = Message$1<"pidgr.v1.PaginationMeta"> & {
107
+ /**
108
+ * Token to pass in the next request to get the following page. Empty if no more pages.
109
+ *
110
+ * @generated from field: string next_page_token = 1;
111
+ */
112
+ nextPageToken: string;
113
+
114
+ /**
115
+ * Total number of items matching the query (across all pages).
116
+ *
117
+ * @generated from field: int32 total_count = 2;
118
+ */
119
+ totalCount: number;
120
+ };
121
+
122
+ /**
123
+ * Describes the message pidgr.v1.PaginationMeta.
124
+ * Use `create(PaginationMetaSchema)` to create a new message.
125
+ */
126
+ export const PaginationMetaSchema: GenMessage<PaginationMeta> = /*@__PURE__*/
127
+ messageDesc(file_pidgr_v1_common, 2);
128
+
129
+ /**
130
+ * An action button attached to a message that a recipient can interact with.
131
+ *
132
+ * @generated from message pidgr.v1.MessageAction
133
+ */
134
+ export type MessageAction = Message$1<"pidgr.v1.MessageAction"> & {
135
+ /**
136
+ * Unique identifier for this action within the message.
137
+ *
138
+ * @generated from field: string id = 1;
139
+ */
140
+ id: string;
141
+
142
+ /**
143
+ * The type of action (e.g. ACK).
144
+ *
145
+ * @generated from field: pidgr.v1.ActionType type = 2;
146
+ */
147
+ type: ActionType;
148
+
149
+ /**
150
+ * Display label shown to the recipient (e.g. "Got it").
151
+ * Constraints: Max length 50 characters.
152
+ *
153
+ * @generated from field: string label = 3;
154
+ */
155
+ label: string;
156
+ };
157
+
158
+ /**
159
+ * Describes the message pidgr.v1.MessageAction.
160
+ * Use `create(MessageActionSchema)` to create a new message.
161
+ */
162
+ export const MessageActionSchema: GenMessage<MessageAction> = /*@__PURE__*/
163
+ messageDesc(file_pidgr_v1_common, 3);
164
+
165
+ /**
166
+ * Canonical message type used across rendering, inbox, and delivery.
167
+ * Represents the fully rendered content delivered to a recipient.
168
+ *
169
+ * @generated from message pidgr.v1.Message
170
+ */
171
+ export type Message = Message$1<"pidgr.v1.Message"> & {
172
+ /**
173
+ * SHA-256 hash of the rendered content, used as a content-addressable ID.
174
+ *
175
+ * @generated from field: string content_id = 1;
176
+ */
177
+ contentId: string;
178
+
179
+ /**
180
+ * ID of the campaign this message belongs to.
181
+ *
182
+ * @generated from field: string campaign_id = 2;
183
+ */
184
+ campaignId: string;
185
+
186
+ /**
187
+ * Display name of the sender (e.g. organization or campaign name).
188
+ * Constraints: Max length 200 characters.
189
+ *
190
+ * @generated from field: string sender_name = 3;
191
+ */
192
+ senderName: string;
193
+
194
+ /**
195
+ * Short one-line summary shown in notification banners.
196
+ * Constraints: Max length 500 characters.
197
+ *
198
+ * @generated from field: string summary = 4;
199
+ */
200
+ summary: string;
201
+
202
+ /**
203
+ * Preview text shown in inbox list views.
204
+ * Constraints: Max length 500 characters.
205
+ *
206
+ * @generated from field: string preview = 5;
207
+ */
208
+ preview: string;
209
+
210
+ /**
211
+ * Full message body content.
212
+ * Constraints: Max length 100000 characters.
213
+ *
214
+ * @generated from field: string body = 6;
215
+ */
216
+ body: string;
217
+
218
+ /**
219
+ * Whether this message requires immediate attention from the recipient.
220
+ *
221
+ * @generated from field: bool critical = 7;
222
+ */
223
+ critical: boolean;
224
+
225
+ /**
226
+ * Actions available to the recipient (e.g. acknowledge button).
227
+ *
228
+ * @generated from field: repeated pidgr.v1.MessageAction actions = 8;
229
+ */
230
+ actions: MessageAction[];
231
+
232
+ /**
233
+ * Timestamp when the message was created.
234
+ *
235
+ * @generated from field: google.protobuf.Timestamp created_at = 9;
236
+ */
237
+ createdAt?: Timestamp;
238
+
239
+ /**
240
+ * User-facing title of the message (resolved from campaign or template).
241
+ * Constraints: Max length 200 characters.
242
+ *
243
+ * @generated from field: string title = 10;
244
+ */
245
+ title: string;
246
+ };
247
+
248
+ /**
249
+ * Describes the message pidgr.v1.Message.
250
+ * Use `create(MessageSchema)` to create a new message.
251
+ */
252
+ export const MessageSchema: GenMessage<Message> = /*@__PURE__*/
253
+ messageDesc(file_pidgr_v1_common, 4);
254
+
255
+ /**
256
+ * A data-driven workflow represented as a directed acyclic graph (DAG) of steps.
257
+ * Defines the automation logic for a campaign's lifecycle.
258
+ * Backend MUST validate the graph is a DAG (no cycles) before execution.
259
+ *
260
+ * @generated from message pidgr.v1.WorkflowDefinition
261
+ */
262
+ export type WorkflowDefinition = Message$1<"pidgr.v1.WorkflowDefinition"> & {
263
+ /**
264
+ * Ordered list of steps in the workflow DAG.
265
+ * Constraints: Max 100 steps. Backend MUST validate the graph is a DAG (no cycles).
266
+ *
267
+ * @generated from field: repeated pidgr.v1.WorkflowStep steps = 1;
268
+ */
269
+ steps: WorkflowStep[];
270
+ };
271
+
272
+ /**
273
+ * Describes the message pidgr.v1.WorkflowDefinition.
274
+ * Use `create(WorkflowDefinitionSchema)` to create a new message.
275
+ */
276
+ export const WorkflowDefinitionSchema: GenMessage<WorkflowDefinition> = /*@__PURE__*/
277
+ messageDesc(file_pidgr_v1_common, 5);
278
+
279
+ /**
280
+ * A single step in a workflow DAG with typed configuration and transitions.
281
+ *
282
+ * @generated from message pidgr.v1.WorkflowStep
283
+ */
284
+ export type WorkflowStep = Message$1<"pidgr.v1.WorkflowStep"> & {
285
+ /**
286
+ * Unique identifier for this step within the workflow.
287
+ *
288
+ * @generated from field: string id = 1;
289
+ */
290
+ id: string;
291
+
292
+ /**
293
+ * The type of operation this step performs.
294
+ *
295
+ * @generated from field: pidgr.v1.StepType type = 2;
296
+ */
297
+ type: StepType;
298
+
299
+ /**
300
+ * Step-specific configuration — exactly one must be set, matching the type.
301
+ *
302
+ * @generated from oneof pidgr.v1.WorkflowStep.config
303
+ */
304
+ config: {
305
+ /**
306
+ * Configuration for SEND_NOTIFICATION steps.
307
+ *
308
+ * @generated from field: pidgr.v1.SendNotificationConfig send_notification = 3;
309
+ */
310
+ value: SendNotificationConfig;
311
+ case: "sendNotification";
312
+ } | {
313
+ /**
314
+ * Configuration for DEADLINE_CHECK steps.
315
+ *
316
+ * @generated from field: pidgr.v1.DeadlineCheckConfig deadline_check = 4;
317
+ */
318
+ value: DeadlineCheckConfig;
319
+ case: "deadlineCheck";
320
+ } | {
321
+ /**
322
+ * Configuration for SEND_REMINDER steps.
323
+ *
324
+ * @generated from field: pidgr.v1.SendReminderConfig send_reminder = 5;
325
+ */
326
+ value: SendReminderConfig;
327
+ case: "sendReminder";
328
+ } | {
329
+ /**
330
+ * Configuration for CALL_WEBHOOK steps.
331
+ *
332
+ * @generated from field: pidgr.v1.CallWebhookConfig call_webhook = 6;
333
+ */
334
+ value: CallWebhookConfig;
335
+ case: "callWebhook";
336
+ } | { case: undefined; value?: undefined };
337
+
338
+ /**
339
+ * Map of outcome labels to the next step ID (e.g. "completed" -> "step_3").
340
+ * Constraints: Max 10 transitions per step.
341
+ *
342
+ * @generated from field: map<string, string> transitions = 7;
343
+ */
344
+ transitions: { [key: string]: string };
345
+ };
346
+
347
+ /**
348
+ * Describes the message pidgr.v1.WorkflowStep.
349
+ * Use `create(WorkflowStepSchema)` to create a new message.
350
+ */
351
+ export const WorkflowStepSchema: GenMessage<WorkflowStep> = /*@__PURE__*/
352
+ messageDesc(file_pidgr_v1_common, 6);
353
+
354
+ /**
355
+ * Configuration for a step that sends the initial push notification.
356
+ *
357
+ * @generated from message pidgr.v1.SendNotificationConfig
358
+ */
359
+ export type SendNotificationConfig = Message$1<"pidgr.v1.SendNotificationConfig"> & {
360
+ /**
361
+ * Notification delivery type (e.g. "push").
362
+ * Constraints: Accepted values: "push". Max length 50 characters.
363
+ *
364
+ * @generated from field: string type = 1;
365
+ */
366
+ type: string;
367
+
368
+ /**
369
+ * ID of the template to use for this step's notification.
370
+ * Empty falls back to campaign-level template_id.
371
+ * Constraints: Max length 36 characters (UUID).
372
+ *
373
+ * @generated from field: string template_id = 2;
374
+ */
375
+ templateId: string;
376
+
377
+ /**
378
+ * Pinned template version for this step.
379
+ * 0 falls back to campaign-level template_version.
380
+ *
381
+ * @generated from field: int32 template_version = 3;
382
+ */
383
+ templateVersion: number;
384
+
385
+ /**
386
+ * Display label for the action button (e.g. "Acknowledge", "Got it").
387
+ * Constraints: Max length 50 characters.
388
+ *
389
+ * @generated from field: string action_label = 4;
390
+ */
391
+ actionLabel: string;
392
+
393
+ /**
394
+ * Action type for this step's message button.
395
+ *
396
+ * @generated from field: pidgr.v1.ActionType action_type = 5;
397
+ */
398
+ actionType: ActionType;
399
+
400
+ /**
401
+ * Values for custom-sourced template variables specific to this step.
402
+ * Constraints: Max 100 entries. Key max length 100 characters, value max length 10000 characters.
403
+ *
404
+ * @generated from field: map<string, string> custom_variables = 6;
405
+ */
406
+ customVariables: { [key: string]: string };
407
+ };
408
+
409
+ /**
410
+ * Describes the message pidgr.v1.SendNotificationConfig.
411
+ * Use `create(SendNotificationConfigSchema)` to create a new message.
412
+ */
413
+ export const SendNotificationConfigSchema: GenMessage<SendNotificationConfig> = /*@__PURE__*/
414
+ messageDesc(file_pidgr_v1_common, 7);
415
+
416
+ /**
417
+ * Configuration for a deadline-based timer step that sleeps for a configured
418
+ * delay before proceeding. Acknowledgments happen independently at the delivery
419
+ * level and are evaluated by subsequent steps (e.g. SEND_REMINDER).
420
+ *
421
+ * @generated from message pidgr.v1.DeadlineCheckConfig
422
+ */
423
+ export type DeadlineCheckConfig = Message$1<"pidgr.v1.DeadlineCheckConfig"> & {
424
+ /**
425
+ * Duration string for the deadline delay (e.g. "120h", "72h").
426
+ * Constraints: Valid range 1m to 8760h (1 year).
427
+ *
428
+ * @generated from field: string delay = 1;
429
+ */
430
+ delay: string;
431
+ };
432
+
433
+ /**
434
+ * Describes the message pidgr.v1.DeadlineCheckConfig.
435
+ * Use `create(DeadlineCheckConfigSchema)` to create a new message.
436
+ */
437
+ export const DeadlineCheckConfigSchema: GenMessage<DeadlineCheckConfig> = /*@__PURE__*/
438
+ messageDesc(file_pidgr_v1_common, 8);
439
+
440
+ /**
441
+ * Configuration for a step that sends a one-time reminder to non-responsive recipients.
442
+ *
443
+ * @generated from message pidgr.v1.SendReminderConfig
444
+ */
445
+ export type SendReminderConfig = Message$1<"pidgr.v1.SendReminderConfig"> & {
446
+ /**
447
+ * Reminder delivery type (e.g. "push").
448
+ * Constraints: Accepted values: "push". Max length 50 characters.
449
+ *
450
+ * @generated from field: string type = 1;
451
+ */
452
+ type: string;
453
+ };
454
+
455
+ /**
456
+ * Describes the message pidgr.v1.SendReminderConfig.
457
+ * Use `create(SendReminderConfigSchema)` to create a new message.
458
+ */
459
+ export const SendReminderConfigSchema: GenMessage<SendReminderConfig> = /*@__PURE__*/
460
+ messageDesc(file_pidgr_v1_common, 9);
461
+
462
+ /**
463
+ * Configuration for a step that calls an external webhook.
464
+ *
465
+ * @generated from message pidgr.v1.CallWebhookConfig
466
+ */
467
+ export type CallWebhookConfig = Message$1<"pidgr.v1.CallWebhookConfig"> & {
468
+ /**
469
+ * Human-readable name for this webhook (for logging/display).
470
+ * Constraints: Max length 200 characters.
471
+ *
472
+ * @generated from field: string name = 1;
473
+ */
474
+ name: string;
475
+
476
+ /**
477
+ * URL to POST campaign context to.
478
+ * Constraints: Max length 2048 characters.
479
+ * Security: HTTPS required in production. Backend MUST reject private,
480
+ * loopback, and link-local addresses to prevent SSRF attacks.
481
+ *
482
+ * @generated from field: string url = 2;
483
+ */
484
+ url: string;
485
+
486
+ /**
487
+ * Additional HTTP headers to include in the webhook request.
488
+ * Constraints: Max 20 entries. Key max length 200 characters, value max length 2000 characters.
489
+ *
490
+ * @generated from field: map<string, string> headers = 3;
491
+ */
492
+ headers: { [key: string]: string };
493
+ };
494
+
495
+ /**
496
+ * Describes the message pidgr.v1.CallWebhookConfig.
497
+ * Use `create(CallWebhookConfigSchema)` to create a new message.
498
+ */
499
+ export const CallWebhookConfigSchema: GenMessage<CallWebhookConfig> = /*@__PURE__*/
500
+ messageDesc(file_pidgr_v1_common, 10);
501
+
502
+ /**
503
+ * Lifecycle status of a campaign.
504
+ *
505
+ * @generated from enum pidgr.v1.CampaignStatus
506
+ */
507
+ export enum CampaignStatus {
508
+ /**
509
+ * Default value; not a valid status.
510
+ *
511
+ * @generated from enum value: CAMPAIGN_STATUS_UNSPECIFIED = 0;
512
+ */
513
+ UNSPECIFIED = 0,
514
+
515
+ /**
516
+ * Campaign has been created but not yet started.
517
+ *
518
+ * @generated from enum value: CAMPAIGN_STATUS_CREATED = 1;
519
+ */
520
+ CREATED = 1,
521
+
522
+ /**
523
+ * Campaign is actively delivering messages and processing actions.
524
+ *
525
+ * @generated from enum value: CAMPAIGN_STATUS_RUNNING = 2;
526
+ */
527
+ RUNNING = 2,
528
+
529
+ /**
530
+ * All recipients have been processed; campaign is finished.
531
+ *
532
+ * @generated from enum value: CAMPAIGN_STATUS_COMPLETED = 3;
533
+ */
534
+ COMPLETED = 3,
535
+
536
+ /**
537
+ * Campaign terminated due to an unrecoverable error.
538
+ *
539
+ * @generated from enum value: CAMPAIGN_STATUS_FAILED = 4;
540
+ */
541
+ FAILED = 4,
542
+
543
+ /**
544
+ * Campaign was manually cancelled before completion.
545
+ *
546
+ * @generated from enum value: CAMPAIGN_STATUS_CANCELLED = 5;
547
+ */
548
+ CANCELLED = 5,
549
+ }
550
+
551
+ /**
552
+ * Describes the enum pidgr.v1.CampaignStatus.
553
+ */
554
+ export const CampaignStatusSchema: GenEnum<CampaignStatus> = /*@__PURE__*/
555
+ enumDesc(file_pidgr_v1_common, 0);
556
+
557
+ /**
558
+ * Delivery status for a single message sent to a recipient.
559
+ *
560
+ * @generated from enum pidgr.v1.DeliveryStatus
561
+ */
562
+ export enum DeliveryStatus {
563
+ /**
564
+ * Default value; not a valid status.
565
+ *
566
+ * @generated from enum value: DELIVERY_STATUS_UNSPECIFIED = 0;
567
+ */
568
+ UNSPECIFIED = 0,
569
+
570
+ /**
571
+ * Message is queued but has not been sent yet.
572
+ *
573
+ * @generated from enum value: DELIVERY_STATUS_PENDING = 1;
574
+ */
575
+ PENDING = 1,
576
+
577
+ /**
578
+ * Push notification was sent to the delivery provider.
579
+ *
580
+ * @generated from enum value: DELIVERY_STATUS_SENT = 2;
581
+ */
582
+ SENT = 2,
583
+
584
+ /**
585
+ * Message was confirmed delivered to the device.
586
+ *
587
+ * @generated from enum value: DELIVERY_STATUS_DELIVERED = 3;
588
+ */
589
+ DELIVERED = 3,
590
+
591
+ /**
592
+ * Recipient completed the required action (e.g. acknowledged).
593
+ *
594
+ * @generated from enum value: DELIVERY_STATUS_ACKNOWLEDGED = 4;
595
+ */
596
+ ACKNOWLEDGED = 4,
597
+
598
+ /**
599
+ * Recipient did not act before the deadline.
600
+ *
601
+ * @generated from enum value: DELIVERY_STATUS_MISSED = 5;
602
+ */
603
+ MISSED = 5,
604
+
605
+ /**
606
+ * Recipient has no registered device; delivery was skipped.
607
+ *
608
+ * @generated from enum value: DELIVERY_STATUS_NO_DEVICE = 6;
609
+ */
610
+ NO_DEVICE = 6,
611
+
612
+ /**
613
+ * Delivery failed due to a provider or system error.
614
+ *
615
+ * @generated from enum value: DELIVERY_STATUS_FAILED = 7;
616
+ */
617
+ FAILED = 7,
618
+ }
619
+
620
+ /**
621
+ * Describes the enum pidgr.v1.DeliveryStatus.
622
+ */
623
+ export const DeliveryStatusSchema: GenEnum<DeliveryStatus> = /*@__PURE__*/
624
+ enumDesc(file_pidgr_v1_common, 1);
625
+
626
+ /**
627
+ * Mobile platform for device registration.
628
+ *
629
+ * @generated from enum pidgr.v1.Platform
630
+ */
631
+ export enum Platform {
632
+ /**
633
+ * Default value; not a valid platform.
634
+ *
635
+ * @generated from enum value: PLATFORM_UNSPECIFIED = 0;
636
+ */
637
+ UNSPECIFIED = 0,
638
+
639
+ /**
640
+ * Apple iOS.
641
+ *
642
+ * @generated from enum value: PLATFORM_IOS = 1;
643
+ */
644
+ IOS = 1,
645
+
646
+ /**
647
+ * Google Android.
648
+ *
649
+ * @generated from enum value: PLATFORM_ANDROID = 2;
650
+ */
651
+ ANDROID = 2,
652
+ }
653
+
654
+ /**
655
+ * Describes the enum pidgr.v1.Platform.
656
+ */
657
+ export const PlatformSchema: GenEnum<Platform> = /*@__PURE__*/
658
+ enumDesc(file_pidgr_v1_common, 2);
659
+
660
+ /**
661
+ * Granular permission for authorization checks.
662
+ * Stored in the database as enum names (e.g. "PERMISSION_ORG_READ").
663
+ * New values MUST be appended with the next sequential number; existing values
664
+ * MUST NOT be renumbered or removed (enforced by buf breaking).
665
+ *
666
+ * @generated from enum pidgr.v1.Permission
667
+ */
668
+ export enum Permission {
669
+ /**
670
+ * Default value; not a valid permission.
671
+ *
672
+ * @generated from enum value: PERMISSION_UNSPECIFIED = 0;
673
+ */
674
+ UNSPECIFIED = 0,
675
+
676
+ /**
677
+ * View organization settings.
678
+ *
679
+ * @generated from enum value: PERMISSION_ORG_READ = 1;
680
+ */
681
+ ORG_READ = 1,
682
+
683
+ /**
684
+ * Modify organization settings.
685
+ *
686
+ * @generated from enum value: PERMISSION_ORG_WRITE = 2;
687
+ */
688
+ ORG_WRITE = 2,
689
+
690
+ /**
691
+ * View organization members.
692
+ *
693
+ * @generated from enum value: PERMISSION_MEMBERS_READ = 3;
694
+ */
695
+ MEMBERS_READ = 3,
696
+
697
+ /**
698
+ * Invite new users to the organization.
699
+ *
700
+ * @generated from enum value: PERMISSION_MEMBERS_INVITE = 4;
701
+ */
702
+ MEMBERS_INVITE = 4,
703
+
704
+ /**
705
+ * Change user roles, deactivate users.
706
+ *
707
+ * @generated from enum value: PERMISSION_MEMBERS_MANAGE = 5;
708
+ */
709
+ MEMBERS_MANAGE = 5,
710
+
711
+ /**
712
+ * View campaigns and deliveries.
713
+ *
714
+ * @generated from enum value: PERMISSION_CAMPAIGNS_READ = 6;
715
+ */
716
+ CAMPAIGNS_READ = 6,
717
+
718
+ /**
719
+ * Create and edit campaigns.
720
+ *
721
+ * @generated from enum value: PERMISSION_CAMPAIGNS_WRITE = 7;
722
+ */
723
+ CAMPAIGNS_WRITE = 7,
724
+
725
+ /**
726
+ * Start campaign execution.
727
+ *
728
+ * @generated from enum value: PERMISSION_CAMPAIGNS_START = 8;
729
+ */
730
+ CAMPAIGNS_START = 8,
731
+
732
+ /**
733
+ * View templates.
734
+ *
735
+ * @generated from enum value: PERMISSION_TEMPLATES_READ = 9;
736
+ */
737
+ TEMPLATES_READ = 9,
738
+
739
+ /**
740
+ * Create and edit templates.
741
+ *
742
+ * @generated from enum value: PERMISSION_TEMPLATES_WRITE = 10;
743
+ */
744
+ TEMPLATES_WRITE = 10,
745
+
746
+ /**
747
+ * View workflow definitions.
748
+ *
749
+ * @generated from enum value: PERMISSION_WORKFLOWS_READ = 11;
750
+ */
751
+ WORKFLOWS_READ = 11,
752
+
753
+ /**
754
+ * Create and edit workflow definitions.
755
+ *
756
+ * @generated from enum value: PERMISSION_WORKFLOWS_WRITE = 12;
757
+ */
758
+ WORKFLOWS_WRITE = 12,
759
+
760
+ /**
761
+ * View inbox messages and deliveries.
762
+ *
763
+ * @generated from enum value: PERMISSION_INBOX_READ = 13;
764
+ */
765
+ INBOX_READ = 13,
766
+
767
+ /**
768
+ * Submit actions on deliveries.
769
+ *
770
+ * @generated from enum value: PERMISSION_INBOX_ACT = 14;
771
+ */
772
+ INBOX_ACT = 14,
773
+
774
+ /**
775
+ * View all groups in the organization.
776
+ *
777
+ * @generated from enum value: PERMISSION_GROUPS_ALL_READ = 15;
778
+ */
779
+ GROUPS_ALL_READ = 15,
780
+
781
+ /**
782
+ * Create, edit, delete groups the caller created, manage own group membership.
783
+ *
784
+ * @generated from enum value: PERMISSION_GROUPS_WRITE = 16;
785
+ */
786
+ GROUPS_WRITE = 16,
787
+
788
+ /**
789
+ * Create, edit, delete any group in the organization, manage any group membership.
790
+ *
791
+ * @generated from enum value: PERMISSION_GROUPS_ALL_WRITE = 17;
792
+ */
793
+ GROUPS_ALL_WRITE = 17,
794
+
795
+ /**
796
+ * View all teams (organizational units) in the organization.
797
+ *
798
+ * @generated from enum value: PERMISSION_TEAMS_ALL_READ = 18;
799
+ */
800
+ TEAMS_ALL_READ = 18,
801
+
802
+ /**
803
+ * Create, edit, delete teams the caller created, manage own team membership.
804
+ *
805
+ * @generated from enum value: PERMISSION_TEAMS_WRITE = 19;
806
+ */
807
+ TEAMS_WRITE = 19,
808
+
809
+ /**
810
+ * Create, edit, delete any team in the organization, manage any team membership.
811
+ *
812
+ * @generated from enum value: PERMISSION_TEAMS_ALL_WRITE = 20;
813
+ */
814
+ TEAMS_ALL_WRITE = 20,
815
+ }
816
+
817
+ /**
818
+ * Describes the enum pidgr.v1.Permission.
819
+ */
820
+ export const PermissionSchema: GenEnum<Permission> = /*@__PURE__*/
821
+ enumDesc(file_pidgr_v1_common, 3);
822
+
823
+ /**
824
+ * Type of action a recipient can perform on a message.
825
+ *
826
+ * @generated from enum pidgr.v1.ActionType
827
+ */
828
+ export enum ActionType {
829
+ /**
830
+ * Default value; not a valid action type.
831
+ *
832
+ * @generated from enum value: ACTION_TYPE_UNSPECIFIED = 0;
833
+ */
834
+ UNSPECIFIED = 0,
835
+
836
+ /**
837
+ * Simple acknowledgment — recipient confirms they received the message.
838
+ *
839
+ * @generated from enum value: ACTION_TYPE_ACK = 1;
840
+ */
841
+ ACK = 1,
842
+ }
843
+
844
+ /**
845
+ * Describes the enum pidgr.v1.ActionType.
846
+ */
847
+ export const ActionTypeSchema: GenEnum<ActionType> = /*@__PURE__*/
848
+ enumDesc(file_pidgr_v1_common, 4);
849
+
850
+ /**
851
+ * Type of step within a workflow definition DAG.
852
+ *
853
+ * @generated from enum pidgr.v1.StepType
854
+ */
855
+ export enum StepType {
856
+ /**
857
+ * Default value; not a valid step type.
858
+ *
859
+ * @generated from enum value: STEP_TYPE_UNSPECIFIED = 0;
860
+ */
861
+ UNSPECIFIED = 0,
862
+
863
+ /**
864
+ * Send the initial push notification to all recipients.
865
+ *
866
+ * @generated from enum value: STEP_TYPE_SEND_NOTIFICATION = 1;
867
+ */
868
+ SEND_NOTIFICATION = 1,
869
+
870
+ /**
871
+ * Sleep for a configurable deadline, then proceed to the next step.
872
+ *
873
+ * @generated from enum value: STEP_TYPE_DEADLINE_CHECK = 2;
874
+ */
875
+ DEADLINE_CHECK = 2,
876
+
877
+ /**
878
+ * Send a follow-up reminder to recipients who have not acted.
879
+ *
880
+ * @generated from enum value: STEP_TYPE_SEND_REMINDER = 3;
881
+ */
882
+ SEND_REMINDER = 3,
883
+
884
+ /**
885
+ * Call an external webhook with campaign context.
886
+ *
887
+ * @generated from enum value: STEP_TYPE_CALL_WEBHOOK = 4;
888
+ */
889
+ CALL_WEBHOOK = 4,
890
+
891
+ /**
892
+ * Mark unacknowledged deliveries (SENT/DELIVERED) as MISSED. No config required.
893
+ *
894
+ * @generated from enum value: STEP_TYPE_MARK_MISSED = 5;
895
+ */
896
+ MARK_MISSED = 5,
897
+ }
898
+
899
+ /**
900
+ * Describes the enum pidgr.v1.StepType.
901
+ */
902
+ export const StepTypeSchema: GenEnum<StepType> = /*@__PURE__*/
903
+ enumDesc(file_pidgr_v1_common, 5);
904
+