@joe-broadhead/opencode-messaging 0.4.0 → 0.5.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@joe-broadhead/opencode-messaging",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "description": "OpenCode plugin for Messaging agent-to-agent messaging and tasks",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -36,6 +36,8 @@
36
36
  "dist/messaging.js",
37
37
  "dist/third-party-notices.md",
38
38
  "skills/opencode-messaging/SKILL.md",
39
+ "assets/icon.svg",
40
+ "views/section.html",
39
41
  "docs/*.md",
40
42
  "README.md",
41
43
  "LICENSE",
@@ -56,7 +58,8 @@
56
58
  "pack:tarball": "node scripts/pack-tarballs.mjs",
57
59
  "smoke:pack": "node scripts/smoke-pack.mjs",
58
60
  "audit:shipped": "node scripts/audit-shipped.mjs",
59
- "messaging:bump": "node scripts/messaging-bump.mjs"
61
+ "messaging:bump": "node scripts/messaging-bump.mjs",
62
+ "jelly:update": "node scripts/jelly-declaration.mjs"
60
63
  },
61
64
  "peerDependencies": {
62
65
  "@opencode/plugin": ">=2.2.5 <2.3",
@@ -77,7 +80,7 @@
77
80
  "devDependencies": {
78
81
  "@babel/core": "7.29.7",
79
82
  "@babel/preset-typescript": "7.27.1",
80
- "@joe-broadhead/messaging": "file:vendor/messaging-0.4.0.tgz",
83
+ "@joe-broadhead/messaging": "file:vendor/messaging-0.5.0.tgz",
81
84
  "@opencode/plugin": "2.2.5",
82
85
  "@opentui/solid": "0.8.0",
83
86
  "@types/node": "22.20.5",
@@ -90,10 +93,1250 @@
90
93
  "zod": "4.6.7"
91
94
  },
92
95
  "optionalDependencies": {
93
- "@joe-broadhead/messaging-bin-darwin-arm64": "0.4.0",
94
- "@joe-broadhead/messaging-bin-darwin-x64": "0.4.0",
95
- "@joe-broadhead/messaging-bin-linux-arm64-gnu": "0.4.0",
96
- "@joe-broadhead/messaging-bin-linux-x64-gnu": "0.4.0",
97
- "@joe-broadhead/messaging-bin-win32-x64": "0.4.0"
96
+ "@joe-broadhead/messaging-bin-darwin-arm64": "0.5.0",
97
+ "@joe-broadhead/messaging-bin-darwin-x64": "0.5.0",
98
+ "@joe-broadhead/messaging-bin-linux-arm64-gnu": "0.5.0",
99
+ "@joe-broadhead/messaging-bin-linux-x64-gnu": "0.5.0",
100
+ "@joe-broadhead/messaging-bin-win32-x64": "0.5.0"
101
+ },
102
+ "jelly": {
103
+ "title": "Messaging",
104
+ "summary": "Your teammates, their coding agents and the people you message.",
105
+ "icon": "assets/icon.svg",
106
+ "tools": [
107
+ {
108
+ "name": "messaging.contacts",
109
+ "permission": "messaging.read",
110
+ "effect": "allow",
111
+ "readOnly": true
112
+ },
113
+ {
114
+ "name": "messaging.send",
115
+ "permission": "messaging.send",
116
+ "effect": "allow",
117
+ "readOnly": false
118
+ },
119
+ {
120
+ "name": "messaging.inbox",
121
+ "permission": "messaging.read",
122
+ "effect": "allow",
123
+ "readOnly": true
124
+ },
125
+ {
126
+ "name": "messaging.read",
127
+ "permission": "messaging.read",
128
+ "effect": "allow",
129
+ "readOnly": true
130
+ },
131
+ {
132
+ "name": "messaging.search",
133
+ "permission": "messaging.read",
134
+ "effect": "allow",
135
+ "readOnly": true
136
+ },
137
+ {
138
+ "name": "messaging.tasks",
139
+ "permission": "messaging.read",
140
+ "effect": "allow",
141
+ "readOnly": true
142
+ },
143
+ {
144
+ "name": "messaging.task_update",
145
+ "permission": "messaging.send",
146
+ "effect": "allow",
147
+ "readOnly": false
148
+ },
149
+ {
150
+ "name": "messaging.task_cancel",
151
+ "permission": "messaging.send",
152
+ "effect": "allow",
153
+ "readOnly": false
154
+ }
155
+ ],
156
+ "skills": [
157
+ "opencode-messaging"
158
+ ],
159
+ "rpc": [
160
+ {
161
+ "name": "people.search",
162
+ "label": "find people",
163
+ "permission": "messaging.read",
164
+ "readOnly": true,
165
+ "input": {
166
+ "type": "object",
167
+ "properties": {
168
+ "query": {
169
+ "type": "string",
170
+ "maxLength": 100
171
+ },
172
+ "limit": {
173
+ "type": "integer",
174
+ "minimum": 1,
175
+ "maximum": 200
176
+ }
177
+ },
178
+ "additionalProperties": false
179
+ },
180
+ "output": {
181
+ "type": "object"
182
+ }
183
+ },
184
+ {
185
+ "name": "people.get",
186
+ "label": "read a person's page",
187
+ "permission": "messaging.read",
188
+ "readOnly": true,
189
+ "input": {
190
+ "type": "object",
191
+ "properties": {
192
+ "person": {
193
+ "anyOf": [
194
+ {
195
+ "type": "string",
196
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
197
+ },
198
+ {
199
+ "type": "string",
200
+ "pattern": "^p_[a-z2-7]{26}$"
201
+ }
202
+ ]
203
+ }
204
+ },
205
+ "required": [
206
+ "person"
207
+ ],
208
+ "additionalProperties": false
209
+ },
210
+ "output": {
211
+ "type": "object"
212
+ }
213
+ },
214
+ {
215
+ "name": "grant.list",
216
+ "label": "read what people and their agents may do",
217
+ "permission": "messaging.read",
218
+ "readOnly": true,
219
+ "input": {
220
+ "type": "object",
221
+ "properties": {
222
+ "subject": {
223
+ "anyOf": [
224
+ {
225
+ "type": "object",
226
+ "properties": {
227
+ "person": {
228
+ "anyOf": [
229
+ {
230
+ "type": "string",
231
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
232
+ },
233
+ {
234
+ "type": "string",
235
+ "pattern": "^p_[a-z2-7]{26}$"
236
+ }
237
+ ]
238
+ }
239
+ },
240
+ "required": [
241
+ "person"
242
+ ],
243
+ "additionalProperties": false
244
+ },
245
+ {
246
+ "type": "object",
247
+ "properties": {
248
+ "channel": {
249
+ "type": "string",
250
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
251
+ }
252
+ },
253
+ "required": [
254
+ "channel"
255
+ ],
256
+ "additionalProperties": false
257
+ }
258
+ ]
259
+ }
260
+ },
261
+ "additionalProperties": false
262
+ },
263
+ "output": {
264
+ "type": "object"
265
+ }
266
+ },
267
+ {
268
+ "name": "conv.list",
269
+ "label": "list your chats",
270
+ "permission": "messaging.read",
271
+ "readOnly": true,
272
+ "input": {
273
+ "type": "object",
274
+ "properties": {
275
+ "limit": {
276
+ "type": "integer",
277
+ "minimum": 1,
278
+ "maximum": 200
279
+ }
280
+ },
281
+ "additionalProperties": false
282
+ },
283
+ "output": {
284
+ "type": "object"
285
+ }
286
+ },
287
+ {
288
+ "name": "conv.read",
289
+ "label": "read a chat",
290
+ "permission": "messaging.read",
291
+ "readOnly": true,
292
+ "input": {
293
+ "type": "object",
294
+ "properties": {
295
+ "key": {
296
+ "type": "string",
297
+ "minLength": 1,
298
+ "maxLength": 200
299
+ },
300
+ "conversation": {
301
+ "type": "string",
302
+ "pattern": "^(?:dm:(?:[a-z][a-z0-9-]{0,31}|p_[a-z2-7]{26})|channel:[a-z][a-z0-9-]{0,31}|agent:(?:[a-z][a-z0-9-]{0,31}|p_[a-z2-7]{26})\\/[a-z0-9][a-z0-9._-]{0,63})$"
303
+ },
304
+ "thread": {
305
+ "type": "string",
306
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
307
+ },
308
+ "before": {
309
+ "anyOf": [
310
+ {
311
+ "type": "integer",
312
+ "minimum": 0,
313
+ "maximum": 9007199254740991
314
+ },
315
+ {
316
+ "type": "object",
317
+ "properties": {
318
+ "at": {
319
+ "type": "integer",
320
+ "minimum": 0,
321
+ "maximum": 9007199254740991
322
+ },
323
+ "id": {
324
+ "type": "string",
325
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
326
+ }
327
+ },
328
+ "required": [
329
+ "at",
330
+ "id"
331
+ ],
332
+ "additionalProperties": false
333
+ }
334
+ ]
335
+ },
336
+ "after": {
337
+ "anyOf": [
338
+ {
339
+ "type": "integer",
340
+ "minimum": 0,
341
+ "maximum": 9007199254740991
342
+ },
343
+ {
344
+ "type": "object",
345
+ "properties": {
346
+ "at": {
347
+ "type": "integer",
348
+ "minimum": 0,
349
+ "maximum": 9007199254740991
350
+ },
351
+ "id": {
352
+ "type": "string",
353
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
354
+ }
355
+ },
356
+ "required": [
357
+ "at",
358
+ "id"
359
+ ],
360
+ "additionalProperties": false
361
+ }
362
+ ]
363
+ },
364
+ "limit": {
365
+ "type": "integer",
366
+ "minimum": 1,
367
+ "maximum": 100
368
+ }
369
+ },
370
+ "required": [
371
+ "conversation"
372
+ ],
373
+ "additionalProperties": false
374
+ },
375
+ "output": {
376
+ "type": "object"
377
+ }
378
+ },
379
+ {
380
+ "name": "request.list",
381
+ "label": "read the requests waiting for you",
382
+ "permission": "messaging.read",
383
+ "readOnly": true,
384
+ "input": {
385
+ "type": "object",
386
+ "properties": {},
387
+ "additionalProperties": false
388
+ },
389
+ "output": {
390
+ "type": "object"
391
+ }
392
+ },
393
+ {
394
+ "name": "device.status",
395
+ "label": "read this device's status",
396
+ "permission": "messaging.read",
397
+ "readOnly": true,
398
+ "input": {
399
+ "type": "object",
400
+ "properties": {},
401
+ "additionalProperties": false
402
+ },
403
+ "output": {
404
+ "type": "object"
405
+ }
406
+ },
407
+ {
408
+ "name": "device.list",
409
+ "label": "list your devices",
410
+ "permission": "messaging.read",
411
+ "readOnly": true,
412
+ "input": {
413
+ "type": "object",
414
+ "properties": {},
415
+ "additionalProperties": false
416
+ },
417
+ "output": {
418
+ "type": "object"
419
+ }
420
+ },
421
+ {
422
+ "name": "agents.list",
423
+ "label": "list your agents' Messaging conversations",
424
+ "permission": "messaging.read",
425
+ "readOnly": true,
426
+ "input": {
427
+ "type": "object",
428
+ "properties": {},
429
+ "additionalProperties": false
430
+ },
431
+ "output": {
432
+ "type": "object"
433
+ }
434
+ },
435
+ {
436
+ "name": "agents.read",
437
+ "label": "read your agents' Messaging traffic",
438
+ "permission": "messaging.read",
439
+ "readOnly": true,
440
+ "input": {
441
+ "type": "object",
442
+ "properties": {
443
+ "agent": {
444
+ "type": "string",
445
+ "pattern": "^[a-z0-9][a-z0-9._-]{0,63}$"
446
+ },
447
+ "conversation": {
448
+ "type": "string",
449
+ "pattern": "^(?:dm:(?:[a-z][a-z0-9-]{0,31}|p_[a-z2-7]{26})|channel:[a-z][a-z0-9-]{0,31}|agent:(?:[a-z][a-z0-9-]{0,31}|p_[a-z2-7]{26})\\/[a-z0-9][a-z0-9._-]{0,63})$"
450
+ },
451
+ "before": {
452
+ "type": "object",
453
+ "properties": {
454
+ "at": {
455
+ "type": "integer",
456
+ "minimum": 0,
457
+ "maximum": 9007199254740991
458
+ },
459
+ "id": {
460
+ "type": "string",
461
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
462
+ }
463
+ },
464
+ "required": [
465
+ "at",
466
+ "id"
467
+ ],
468
+ "additionalProperties": false
469
+ },
470
+ "limit": {
471
+ "type": "integer",
472
+ "minimum": 1,
473
+ "maximum": 100
474
+ }
475
+ },
476
+ "required": [
477
+ "agent"
478
+ ],
479
+ "additionalProperties": false
480
+ },
481
+ "output": {
482
+ "type": "object"
483
+ }
484
+ },
485
+ {
486
+ "name": "notice.list",
487
+ "label": "read your notices",
488
+ "permission": "messaging.read",
489
+ "readOnly": true,
490
+ "input": {
491
+ "type": "object",
492
+ "properties": {
493
+ "lines": {
494
+ "type": "boolean"
495
+ },
496
+ "limit": {
497
+ "type": "integer",
498
+ "minimum": 1,
499
+ "maximum": 200
500
+ }
501
+ },
502
+ "additionalProperties": false
503
+ },
504
+ "output": {
505
+ "type": "object"
506
+ }
507
+ },
508
+ {
509
+ "name": "request.answer.preview",
510
+ "label": "say whom a request answer reaches",
511
+ "permission": "messaging.read",
512
+ "readOnly": true,
513
+ "input": {
514
+ "type": "object",
515
+ "properties": {
516
+ "id": {
517
+ "type": "string",
518
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
519
+ },
520
+ "answer": {
521
+ "type": "string",
522
+ "enum": [
523
+ "once",
524
+ "always",
525
+ "accept",
526
+ "decline",
527
+ "block"
528
+ ]
529
+ },
530
+ "all": {
531
+ "type": "boolean"
532
+ }
533
+ },
534
+ "required": [
535
+ "id",
536
+ "answer"
537
+ ],
538
+ "additionalProperties": false
539
+ },
540
+ "output": {
541
+ "type": "object"
542
+ }
543
+ },
544
+ {
545
+ "name": "grant.set.preview",
546
+ "label": "say what a change of permissions means",
547
+ "permission": "messaging.read",
548
+ "readOnly": true,
549
+ "input": {
550
+ "type": "object",
551
+ "properties": {
552
+ "subject": {
553
+ "anyOf": [
554
+ {
555
+ "type": "object",
556
+ "properties": {
557
+ "person": {
558
+ "anyOf": [
559
+ {
560
+ "type": "string",
561
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
562
+ },
563
+ {
564
+ "type": "string",
565
+ "pattern": "^p_[a-z2-7]{26}$"
566
+ }
567
+ ]
568
+ }
569
+ },
570
+ "required": [
571
+ "person"
572
+ ],
573
+ "additionalProperties": false
574
+ },
575
+ {
576
+ "type": "object",
577
+ "properties": {
578
+ "channel": {
579
+ "type": "string",
580
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
581
+ }
582
+ },
583
+ "required": [
584
+ "channel"
585
+ ],
586
+ "additionalProperties": false
587
+ }
588
+ ]
589
+ },
590
+ "chat": {
591
+ "type": "string",
592
+ "enum": [
593
+ "open",
594
+ "muted",
595
+ "blocked"
596
+ ]
597
+ },
598
+ "agentMail": {
599
+ "type": "string",
600
+ "enum": [
601
+ "open",
602
+ "blocked"
603
+ ]
604
+ },
605
+ "ask": {
606
+ "type": "string",
607
+ "enum": [
608
+ "open",
609
+ "request",
610
+ "no"
611
+ ]
612
+ },
613
+ "trustedUntil": {
614
+ "type": "integer",
615
+ "minimum": 0,
616
+ "maximum": 9007199254740991
617
+ },
618
+ "discoverable": {
619
+ "type": "boolean"
620
+ },
621
+ "trust": {
622
+ "type": "boolean",
623
+ "const": true
624
+ }
625
+ },
626
+ "required": [
627
+ "subject"
628
+ ],
629
+ "additionalProperties": false
630
+ },
631
+ "output": {
632
+ "type": "object"
633
+ }
634
+ },
635
+ {
636
+ "name": "contact.request.preview",
637
+ "label": "say whether an email has a Messaging account",
638
+ "permission": "messaging.read",
639
+ "readOnly": true,
640
+ "input": {
641
+ "type": "object",
642
+ "properties": {
643
+ "email": {
644
+ "type": "string",
645
+ "maxLength": 254,
646
+ "pattern": "^[^\\s@A-Z]{1,64}@(?:[a-z0-9-]+\\.)+[a-z0-9-]+$"
647
+ },
648
+ "text": {
649
+ "type": "string",
650
+ "minLength": 1
651
+ },
652
+ "suggestion": {
653
+ "type": "string",
654
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
655
+ }
656
+ },
657
+ "required": [
658
+ "email",
659
+ "text"
660
+ ],
661
+ "additionalProperties": false
662
+ },
663
+ "output": {
664
+ "type": "object"
665
+ }
666
+ },
667
+ {
668
+ "name": "device.approve.preview",
669
+ "label": "show the device you approve and its code",
670
+ "permission": "messaging.read",
671
+ "readOnly": true,
672
+ "input": {
673
+ "type": "object",
674
+ "properties": {
675
+ "link": {
676
+ "type": "string",
677
+ "minLength": 1,
678
+ "maxLength": 2048
679
+ },
680
+ "sas": {
681
+ "type": "string",
682
+ "pattern": "^[0-9]{6}$"
683
+ }
684
+ },
685
+ "required": [
686
+ "link",
687
+ "sas"
688
+ ],
689
+ "additionalProperties": false
690
+ },
691
+ "output": {
692
+ "type": "object"
693
+ }
694
+ },
695
+ {
696
+ "name": "device.remove.preview",
697
+ "label": "show the device you remove",
698
+ "permission": "messaging.read",
699
+ "readOnly": true,
700
+ "input": {
701
+ "type": "object",
702
+ "properties": {
703
+ "device": {
704
+ "type": "string",
705
+ "pattern": "^[A-Za-z0-9_-]{43}$",
706
+ "description": "Ed25519 public key of a machine, base64url"
707
+ },
708
+ "reason": {
709
+ "type": "string",
710
+ "enum": [
711
+ "self",
712
+ "removed",
713
+ "lost"
714
+ ]
715
+ },
716
+ "token": {
717
+ "type": "string",
718
+ "maxLength": 8192,
719
+ "pattern": "^[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]+$"
720
+ }
721
+ },
722
+ "required": [
723
+ "device"
724
+ ],
725
+ "additionalProperties": false
726
+ },
727
+ "output": {
728
+ "type": "object"
729
+ }
730
+ }
731
+ ],
732
+ "actions": [
733
+ {
734
+ "name": "person.send",
735
+ "label": "send a message as you",
736
+ "target": "service",
737
+ "class": "chat",
738
+ "confirm": "session",
739
+ "views": [
740
+ "messaging"
741
+ ],
742
+ "input": {
743
+ "type": "object",
744
+ "properties": {
745
+ "conversation": {
746
+ "type": "string",
747
+ "pattern": "^(?:dm:(?:[a-z][a-z0-9-]{0,31}|p_[a-z2-7]{26})|channel:[a-z][a-z0-9-]{0,31})$"
748
+ },
749
+ "text": {
750
+ "type": "string",
751
+ "minLength": 1
752
+ },
753
+ "thread": {
754
+ "type": "string",
755
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
756
+ },
757
+ "clientId": {
758
+ "type": "string",
759
+ "minLength": 1,
760
+ "maxLength": 200
761
+ }
762
+ },
763
+ "required": [
764
+ "conversation",
765
+ "text"
766
+ ],
767
+ "additionalProperties": false
768
+ },
769
+ "output": {
770
+ "type": "object"
771
+ }
772
+ },
773
+ {
774
+ "name": "conv.markRead",
775
+ "label": "mark a chat read",
776
+ "target": "service",
777
+ "class": "chat",
778
+ "confirm": "never",
779
+ "views": [
780
+ "messaging"
781
+ ],
782
+ "input": {
783
+ "type": "object",
784
+ "properties": {
785
+ "conversation": {
786
+ "type": "string",
787
+ "pattern": "^(?:dm:(?:[a-z][a-z0-9-]{0,31}|p_[a-z2-7]{26})|channel:[a-z][a-z0-9-]{0,31})$"
788
+ },
789
+ "upTo": {
790
+ "type": "integer",
791
+ "minimum": 0,
792
+ "maximum": 9007199254740991
793
+ }
794
+ },
795
+ "required": [
796
+ "conversation",
797
+ "upTo"
798
+ ],
799
+ "additionalProperties": false
800
+ },
801
+ "output": {
802
+ "type": "object"
803
+ }
804
+ },
805
+ {
806
+ "name": "notice.ack",
807
+ "label": "clear your notices",
808
+ "target": "service",
809
+ "class": "chat",
810
+ "confirm": "never",
811
+ "views": [
812
+ "messaging"
813
+ ],
814
+ "input": {
815
+ "type": "object",
816
+ "properties": {
817
+ "ids": {
818
+ "minItems": 1,
819
+ "maxItems": 200,
820
+ "type": "array",
821
+ "items": {
822
+ "type": "string",
823
+ "pattern": "^[mra]_[0-9A-Za-z]{1,64}$"
824
+ }
825
+ }
826
+ },
827
+ "required": [
828
+ "ids"
829
+ ],
830
+ "additionalProperties": false
831
+ },
832
+ "output": {
833
+ "type": "object"
834
+ }
835
+ },
836
+ {
837
+ "name": "request.answer",
838
+ "label": "answer a request for you",
839
+ "target": "service",
840
+ "class": "local",
841
+ "confirm": "always",
842
+ "preview": "request.answer.preview",
843
+ "summary": [
844
+ "answer",
845
+ "all"
846
+ ],
847
+ "views": [
848
+ "messaging"
849
+ ],
850
+ "input": {
851
+ "type": "object",
852
+ "properties": {
853
+ "id": {
854
+ "type": "string",
855
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
856
+ },
857
+ "answer": {
858
+ "type": "string",
859
+ "enum": [
860
+ "once",
861
+ "always",
862
+ "accept",
863
+ "decline",
864
+ "block"
865
+ ]
866
+ },
867
+ "all": {
868
+ "type": "boolean"
869
+ }
870
+ },
871
+ "required": [
872
+ "id",
873
+ "answer"
874
+ ],
875
+ "additionalProperties": false
876
+ },
877
+ "output": {
878
+ "type": "object"
879
+ }
880
+ },
881
+ {
882
+ "name": "grant.set",
883
+ "label": "change what someone and their agents may do",
884
+ "target": "service",
885
+ "class": "local",
886
+ "confirm": "always",
887
+ "preview": "grant.set.preview",
888
+ "views": [
889
+ "messaging"
890
+ ],
891
+ "input": {
892
+ "type": "object",
893
+ "properties": {
894
+ "subject": {
895
+ "anyOf": [
896
+ {
897
+ "type": "object",
898
+ "properties": {
899
+ "person": {
900
+ "anyOf": [
901
+ {
902
+ "type": "string",
903
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
904
+ },
905
+ {
906
+ "type": "string",
907
+ "pattern": "^p_[a-z2-7]{26}$"
908
+ }
909
+ ]
910
+ }
911
+ },
912
+ "required": [
913
+ "person"
914
+ ],
915
+ "additionalProperties": false
916
+ },
917
+ {
918
+ "type": "object",
919
+ "properties": {
920
+ "channel": {
921
+ "type": "string",
922
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
923
+ }
924
+ },
925
+ "required": [
926
+ "channel"
927
+ ],
928
+ "additionalProperties": false
929
+ }
930
+ ]
931
+ },
932
+ "chat": {
933
+ "type": "string",
934
+ "enum": [
935
+ "open",
936
+ "muted",
937
+ "blocked"
938
+ ]
939
+ },
940
+ "agentMail": {
941
+ "type": "string",
942
+ "enum": [
943
+ "open",
944
+ "blocked"
945
+ ]
946
+ },
947
+ "ask": {
948
+ "type": "string",
949
+ "enum": [
950
+ "open",
951
+ "request",
952
+ "no"
953
+ ]
954
+ },
955
+ "trustedUntil": {
956
+ "type": "integer",
957
+ "minimum": 0,
958
+ "maximum": 9007199254740991
959
+ },
960
+ "discoverable": {
961
+ "type": "boolean"
962
+ },
963
+ "trust": {
964
+ "type": "boolean",
965
+ "const": true
966
+ }
967
+ },
968
+ "required": [
969
+ "subject"
970
+ ],
971
+ "additionalProperties": false
972
+ },
973
+ "output": {
974
+ "type": "object"
975
+ }
976
+ },
977
+ {
978
+ "name": "contact.request",
979
+ "label": "write to someone outside your org",
980
+ "target": "service",
981
+ "class": "local",
982
+ "confirm": "always",
983
+ "preview": "contact.request.preview",
984
+ "summary": [
985
+ "email",
986
+ "text"
987
+ ],
988
+ "views": [
989
+ "messaging"
990
+ ],
991
+ "input": {
992
+ "type": "object",
993
+ "properties": {
994
+ "email": {
995
+ "type": "string",
996
+ "maxLength": 254,
997
+ "pattern": "^[^\\s@A-Z]{1,64}@(?:[a-z0-9-]+\\.)+[a-z0-9-]+$"
998
+ },
999
+ "text": {
1000
+ "type": "string",
1001
+ "minLength": 1
1002
+ },
1003
+ "suggestion": {
1004
+ "type": "string",
1005
+ "pattern": "^[0-7][0-9A-HJKMNP-TV-Z]{25}$"
1006
+ }
1007
+ },
1008
+ "required": [
1009
+ "email",
1010
+ "text"
1011
+ ],
1012
+ "additionalProperties": false
1013
+ },
1014
+ "output": {
1015
+ "type": "object"
1016
+ }
1017
+ },
1018
+ {
1019
+ "name": "channel.create",
1020
+ "label": "create a channel",
1021
+ "target": "service",
1022
+ "class": "local",
1023
+ "confirm": "always",
1024
+ "summary": [
1025
+ "name",
1026
+ "persons"
1027
+ ],
1028
+ "views": [
1029
+ "messaging"
1030
+ ],
1031
+ "input": {
1032
+ "type": "object",
1033
+ "properties": {
1034
+ "name": {
1035
+ "type": "string",
1036
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1037
+ },
1038
+ "persons": {
1039
+ "maxItems": 32,
1040
+ "type": "array",
1041
+ "items": {
1042
+ "anyOf": [
1043
+ {
1044
+ "type": "string",
1045
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1046
+ },
1047
+ {
1048
+ "type": "string",
1049
+ "pattern": "^p_[a-z2-7]{26}$"
1050
+ }
1051
+ ]
1052
+ }
1053
+ }
1054
+ },
1055
+ "required": [
1056
+ "name",
1057
+ "persons"
1058
+ ],
1059
+ "additionalProperties": false
1060
+ },
1061
+ "output": {
1062
+ "type": "object"
1063
+ }
1064
+ },
1065
+ {
1066
+ "name": "channel.invite",
1067
+ "label": "invite people to a channel",
1068
+ "target": "service",
1069
+ "class": "local",
1070
+ "confirm": "always",
1071
+ "summary": [
1072
+ "name",
1073
+ "persons"
1074
+ ],
1075
+ "views": [
1076
+ "messaging"
1077
+ ],
1078
+ "input": {
1079
+ "type": "object",
1080
+ "properties": {
1081
+ "name": {
1082
+ "type": "string",
1083
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1084
+ },
1085
+ "persons": {
1086
+ "minItems": 1,
1087
+ "maxItems": 32,
1088
+ "type": "array",
1089
+ "items": {
1090
+ "anyOf": [
1091
+ {
1092
+ "type": "string",
1093
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1094
+ },
1095
+ {
1096
+ "type": "string",
1097
+ "pattern": "^p_[a-z2-7]{26}$"
1098
+ }
1099
+ ]
1100
+ }
1101
+ }
1102
+ },
1103
+ "required": [
1104
+ "name",
1105
+ "persons"
1106
+ ],
1107
+ "additionalProperties": false
1108
+ },
1109
+ "output": {
1110
+ "type": "object"
1111
+ }
1112
+ },
1113
+ {
1114
+ "name": "channel.remove",
1115
+ "label": "remove people from a channel",
1116
+ "target": "service",
1117
+ "class": "local",
1118
+ "confirm": "always",
1119
+ "summary": [
1120
+ "name",
1121
+ "persons"
1122
+ ],
1123
+ "views": [
1124
+ "messaging"
1125
+ ],
1126
+ "input": {
1127
+ "type": "object",
1128
+ "properties": {
1129
+ "name": {
1130
+ "type": "string",
1131
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1132
+ },
1133
+ "persons": {
1134
+ "minItems": 1,
1135
+ "maxItems": 32,
1136
+ "type": "array",
1137
+ "items": {
1138
+ "anyOf": [
1139
+ {
1140
+ "type": "string",
1141
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1142
+ },
1143
+ {
1144
+ "type": "string",
1145
+ "pattern": "^p_[a-z2-7]{26}$"
1146
+ }
1147
+ ]
1148
+ }
1149
+ }
1150
+ },
1151
+ "required": [
1152
+ "name",
1153
+ "persons"
1154
+ ],
1155
+ "additionalProperties": false
1156
+ },
1157
+ "output": {
1158
+ "type": "object"
1159
+ }
1160
+ },
1161
+ {
1162
+ "name": "channel.leave",
1163
+ "label": "leave a channel",
1164
+ "target": "service",
1165
+ "class": "local",
1166
+ "confirm": "always",
1167
+ "summary": [
1168
+ "name"
1169
+ ],
1170
+ "views": [
1171
+ "messaging"
1172
+ ],
1173
+ "input": {
1174
+ "type": "object",
1175
+ "properties": {
1176
+ "name": {
1177
+ "type": "string",
1178
+ "pattern": "^[a-z][a-z0-9-]{0,31}$"
1179
+ }
1180
+ },
1181
+ "required": [
1182
+ "name"
1183
+ ],
1184
+ "additionalProperties": false
1185
+ },
1186
+ "output": {
1187
+ "type": "object"
1188
+ }
1189
+ },
1190
+ {
1191
+ "name": "device.approve",
1192
+ "label": "approve a new device as yours",
1193
+ "target": "service",
1194
+ "class": "local",
1195
+ "confirm": "always",
1196
+ "preview": "device.approve.preview",
1197
+ "views": [
1198
+ "messaging"
1199
+ ],
1200
+ "input": {
1201
+ "type": "object",
1202
+ "properties": {
1203
+ "link": {
1204
+ "type": "string",
1205
+ "minLength": 1,
1206
+ "maxLength": 2048
1207
+ },
1208
+ "sas": {
1209
+ "type": "string",
1210
+ "pattern": "^[0-9]{6}$"
1211
+ }
1212
+ },
1213
+ "required": [
1214
+ "link",
1215
+ "sas"
1216
+ ],
1217
+ "additionalProperties": false
1218
+ },
1219
+ "output": {
1220
+ "type": "object"
1221
+ }
1222
+ },
1223
+ {
1224
+ "name": "device.remove",
1225
+ "label": "remove one of your devices",
1226
+ "target": "service",
1227
+ "class": "local",
1228
+ "confirm": "always",
1229
+ "preview": "device.remove.preview",
1230
+ "summary": [
1231
+ "reason"
1232
+ ],
1233
+ "views": [
1234
+ "messaging"
1235
+ ],
1236
+ "input": {
1237
+ "type": "object",
1238
+ "properties": {
1239
+ "device": {
1240
+ "type": "string",
1241
+ "pattern": "^[A-Za-z0-9_-]{43}$",
1242
+ "description": "Ed25519 public key of a machine, base64url"
1243
+ },
1244
+ "reason": {
1245
+ "type": "string",
1246
+ "enum": [
1247
+ "self",
1248
+ "removed",
1249
+ "lost"
1250
+ ]
1251
+ },
1252
+ "token": {
1253
+ "type": "string",
1254
+ "maxLength": 8192,
1255
+ "pattern": "^[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]+\\.[A-Za-z0-9_-]+$"
1256
+ }
1257
+ },
1258
+ "required": [
1259
+ "device"
1260
+ ],
1261
+ "additionalProperties": false
1262
+ },
1263
+ "output": {
1264
+ "type": "object"
1265
+ }
1266
+ }
1267
+ ],
1268
+ "asks": [
1269
+ "messaging.send"
1270
+ ],
1271
+ "resources": [
1272
+ "messaging"
1273
+ ],
1274
+ "service": {
1275
+ "id": "messaging",
1276
+ "label": "Messaging service",
1277
+ "sockets": [
1278
+ "agent.sock",
1279
+ "admin.sock"
1280
+ ],
1281
+ "health": "agent.sock",
1282
+ "agent": "agent.sock",
1283
+ "admin": "admin.sock",
1284
+ "wakes": true,
1285
+ "backup": {
1286
+ "exclude": [
1287
+ "identity.json",
1288
+ "pairing.json"
1289
+ ]
1290
+ }
1291
+ },
1292
+ "section": {
1293
+ "id": "messaging",
1294
+ "title": "Messaging",
1295
+ "page": "views/section.html",
1296
+ "rpc": [
1297
+ "people.search",
1298
+ "people.get",
1299
+ "grant.list",
1300
+ "conv.list",
1301
+ "conv.read",
1302
+ "request.list",
1303
+ "device.status",
1304
+ "device.list",
1305
+ "agents.list",
1306
+ "agents.read",
1307
+ "notice.list"
1308
+ ]
1309
+ },
1310
+ "notices": [
1311
+ {
1312
+ "id": "message",
1313
+ "label": "Message",
1314
+ "category": "message",
1315
+ "preview": "name"
1316
+ },
1317
+ {
1318
+ "id": "request",
1319
+ "label": "Request",
1320
+ "category": "request",
1321
+ "preview": "name"
1322
+ },
1323
+ {
1324
+ "id": "alert",
1325
+ "label": "Messaging alert",
1326
+ "category": "alert",
1327
+ "preview": "line"
1328
+ }
1329
+ ],
1330
+ "turns": {
1331
+ "label": "Messages"
1332
+ },
1333
+ "requires": [
1334
+ "service",
1335
+ "section",
1336
+ "actions",
1337
+ "turns",
1338
+ "notices",
1339
+ "resources"
1340
+ ]
98
1341
  }
99
1342
  }