@moltzap/protocol 0.1.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 (160) hide show
  1. package/dist/helpers.d.ts +15 -0
  2. package/dist/helpers.d.ts.map +1 -0
  3. package/dist/helpers.js +20 -0
  4. package/dist/helpers.js.map +1 -0
  5. package/dist/index.d.ts +8 -0
  6. package/dist/index.d.ts.map +1 -0
  7. package/dist/index.js +8 -0
  8. package/dist/index.js.map +1 -0
  9. package/dist/schema/contacts.d.ts +11 -0
  10. package/dist/schema/contacts.d.ts.map +1 -0
  11. package/dist/schema/contacts.js +12 -0
  12. package/dist/schema/contacts.js.map +1 -0
  13. package/dist/schema/conversations.d.ts +37 -0
  14. package/dist/schema/conversations.d.ts.map +1 -0
  15. package/dist/schema/conversations.js +31 -0
  16. package/dist/schema/conversations.js.map +1 -0
  17. package/dist/schema/delivery.d.ts +15 -0
  18. package/dist/schema/delivery.d.ts.map +1 -0
  19. package/dist/schema/delivery.js +14 -0
  20. package/dist/schema/delivery.js.map +1 -0
  21. package/dist/schema/errors.d.ts +24 -0
  22. package/dist/schema/errors.d.ts.map +1 -0
  23. package/dist/schema/errors.js +22 -0
  24. package/dist/schema/errors.js.map +1 -0
  25. package/dist/schema/events.d.ts +120 -0
  26. package/dist/schema/events.d.ts.map +1 -0
  27. package/dist/schema/events.js +52 -0
  28. package/dist/schema/events.js.map +1 -0
  29. package/dist/schema/frames.d.ts +29 -0
  30. package/dist/schema/frames.d.ts.map +1 -0
  31. package/dist/schema/frames.js +23 -0
  32. package/dist/schema/frames.js.map +1 -0
  33. package/dist/schema/identity.d.ts +28 -0
  34. package/dist/schema/identity.d.ts.map +1 -0
  35. package/dist/schema/identity.js +31 -0
  36. package/dist/schema/identity.js.map +1 -0
  37. package/dist/schema/index.d.ts +18 -0
  38. package/dist/schema/index.d.ts.map +1 -0
  39. package/dist/schema/index.js +18 -0
  40. package/dist/schema/index.js.map +1 -0
  41. package/dist/schema/invites.d.ts +17 -0
  42. package/dist/schema/invites.d.ts.map +1 -0
  43. package/dist/schema/invites.js +18 -0
  44. package/dist/schema/invites.js.map +1 -0
  45. package/dist/schema/messages.d.ts +25 -0
  46. package/dist/schema/messages.d.ts.map +1 -0
  47. package/dist/schema/messages.js +20 -0
  48. package/dist/schema/messages.js.map +1 -0
  49. package/dist/schema/methods/auth.d.ts +64 -0
  50. package/dist/schema/methods/auth.d.ts.map +1 -0
  51. package/dist/schema/methods/auth.js +46 -0
  52. package/dist/schema/methods/auth.js.map +1 -0
  53. package/dist/schema/methods/contacts.d.ts +38 -0
  54. package/dist/schema/methods/contacts.d.ts.map +1 -0
  55. package/dist/schema/methods/contacts.js +23 -0
  56. package/dist/schema/methods/contacts.js.map +1 -0
  57. package/dist/schema/methods/conversations.d.ts +92 -0
  58. package/dist/schema/methods/conversations.d.ts.map +1 -0
  59. package/dist/schema/methods/conversations.js +43 -0
  60. package/dist/schema/methods/conversations.js.map +1 -0
  61. package/dist/schema/methods/invites.d.ts +33 -0
  62. package/dist/schema/methods/invites.d.ts.map +1 -0
  63. package/dist/schema/methods/invites.js +19 -0
  64. package/dist/schema/methods/invites.js.map +1 -0
  65. package/dist/schema/methods/messages.d.ts +67 -0
  66. package/dist/schema/methods/messages.d.ts.map +1 -0
  67. package/dist/schema/methods/messages.js +32 -0
  68. package/dist/schema/methods/messages.js.map +1 -0
  69. package/dist/schema/methods/presence.d.ts +19 -0
  70. package/dist/schema/methods/presence.d.ts.map +1 -0
  71. package/dist/schema/methods/presence.js +7 -0
  72. package/dist/schema/methods/presence.js.map +1 -0
  73. package/dist/schema/presence.d.ts +19 -0
  74. package/dist/schema/presence.d.ts.map +1 -0
  75. package/dist/schema/presence.js +14 -0
  76. package/dist/schema/presence.js.map +1 -0
  77. package/dist/schema/primitives.d.ts +7 -0
  78. package/dist/schema/primitives.d.ts.map +1 -0
  79. package/dist/schema/primitives.js +13 -0
  80. package/dist/schema/primitives.js.map +1 -0
  81. package/dist/schemas/Agent.json +46 -0
  82. package/dist/schemas/Contact.json +40 -0
  83. package/dist/schemas/ContactAcceptedEvent.json +49 -0
  84. package/dist/schemas/ContactIdParams.json +14 -0
  85. package/dist/schemas/ContactRequestEvent.json +49 -0
  86. package/dist/schemas/ContactsAcceptParams.json +14 -0
  87. package/dist/schemas/ContactsAcceptResult.json +49 -0
  88. package/dist/schemas/ContactsAddParams.json +18 -0
  89. package/dist/schemas/ContactsAddResult.json +19 -0
  90. package/dist/schemas/ContactsListParams.json +14 -0
  91. package/dist/schemas/ContactsListResult.json +52 -0
  92. package/dist/schemas/Conversation.json +57 -0
  93. package/dist/schemas/ConversationCreatedEvent.json +66 -0
  94. package/dist/schemas/ConversationParticipant.json +59 -0
  95. package/dist/schemas/ConversationSummary.json +37 -0
  96. package/dist/schemas/ConversationUpdatedEvent.json +66 -0
  97. package/dist/schemas/ConversationsAddParticipantParams.json +36 -0
  98. package/dist/schemas/ConversationsCreateParams.json +47 -0
  99. package/dist/schemas/ConversationsCreateResult.json +66 -0
  100. package/dist/schemas/ConversationsGetParams.json +14 -0
  101. package/dist/schemas/ConversationsGetResult.json +129 -0
  102. package/dist/schemas/ConversationsLeaveParams.json +14 -0
  103. package/dist/schemas/ConversationsListParams.json +14 -0
  104. package/dist/schemas/ConversationsListResult.json +52 -0
  105. package/dist/schemas/ConversationsMuteParams.json +18 -0
  106. package/dist/schemas/ConversationsRemoveParticipantParams.json +36 -0
  107. package/dist/schemas/ConversationsUnmuteParams.json +14 -0
  108. package/dist/schemas/ConversationsUpdateParams.json +19 -0
  109. package/dist/schemas/DeliveryEntry.json +59 -0
  110. package/dist/schemas/EmptyResult.json +5 -0
  111. package/dist/schemas/EventFrame.json +23 -0
  112. package/dist/schemas/HelloOk.json +118 -0
  113. package/dist/schemas/Invite.json +63 -0
  114. package/dist/schemas/InvitesAcceptParams.json +13 -0
  115. package/dist/schemas/InvitesAcceptResult.json +103 -0
  116. package/dist/schemas/InvitesCreateParams.json +18 -0
  117. package/dist/schemas/InvitesCreateResult.json +17 -0
  118. package/dist/schemas/Message.json +96 -0
  119. package/dist/schemas/MessageDeletedEvent.json +20 -0
  120. package/dist/schemas/MessageDeliveredEvent.json +42 -0
  121. package/dist/schemas/MessageReactedEvent.json +48 -0
  122. package/dist/schemas/MessageReadEvent.json +41 -0
  123. package/dist/schemas/MessageReceivedEvent.json +105 -0
  124. package/dist/schemas/MessagesDeleteParams.json +14 -0
  125. package/dist/schemas/MessagesListParams.json +27 -0
  126. package/dist/schemas/MessagesListResult.json +112 -0
  127. package/dist/schemas/MessagesReactParams.json +28 -0
  128. package/dist/schemas/MessagesReadParams.json +19 -0
  129. package/dist/schemas/MessagesSendParams.json +46 -0
  130. package/dist/schemas/MessagesSendResult.json +105 -0
  131. package/dist/schemas/ParticipantRef.json +21 -0
  132. package/dist/schemas/Policy.json +45 -0
  133. package/dist/schemas/PresenceChangedEvent.json +39 -0
  134. package/dist/schemas/PresenceEntry.json +39 -0
  135. package/dist/schemas/PresenceSubscribeParams.json +33 -0
  136. package/dist/schemas/PresenceSubscribeResult.json +51 -0
  137. package/dist/schemas/PresenceUpdateParams.json +17 -0
  138. package/dist/schemas/RateLimits.json +16 -0
  139. package/dist/schemas/RegisterParams.json +17 -0
  140. package/dist/schemas/RegisterResult.json +27 -0
  141. package/dist/schemas/RequestFrame.json +27 -0
  142. package/dist/schemas/ResponseFrame.json +40 -0
  143. package/dist/schemas/RpcError.json +17 -0
  144. package/dist/schemas/TextPart.json +19 -0
  145. package/dist/schemas/TypingIndicator.json +36 -0
  146. package/dist/schemas/TypingIndicatorEvent.json +36 -0
  147. package/dist/schemas/User.json +43 -0
  148. package/dist/types.d.ts +11 -0
  149. package/dist/types.d.ts.map +1 -0
  150. package/dist/types.js +2 -0
  151. package/dist/types.js.map +1 -0
  152. package/dist/validators.d.ts +154 -0
  153. package/dist/validators.d.ts.map +1 -0
  154. package/dist/validators.js +40 -0
  155. package/dist/validators.js.map +1 -0
  156. package/dist/version.d.ts +2 -0
  157. package/dist/version.d.ts.map +1 -0
  158. package/dist/version.js +2 -0
  159. package/dist/version.js.map +1 -0
  160. package/package.json +42 -0
@@ -0,0 +1,105 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "message"
6
+ ],
7
+ "properties": {
8
+ "message": {
9
+ "additionalProperties": false,
10
+ "type": "object",
11
+ "required": [
12
+ "id",
13
+ "conversationId",
14
+ "sender",
15
+ "seq",
16
+ "parts",
17
+ "createdAt"
18
+ ],
19
+ "properties": {
20
+ "id": {
21
+ "format": "uuid",
22
+ "description": "Branded MessageId",
23
+ "type": "string"
24
+ },
25
+ "conversationId": {
26
+ "format": "uuid",
27
+ "description": "Branded ConversationId",
28
+ "type": "string"
29
+ },
30
+ "sender": {
31
+ "additionalProperties": false,
32
+ "type": "object",
33
+ "required": [
34
+ "type",
35
+ "id"
36
+ ],
37
+ "properties": {
38
+ "type": {
39
+ "type": "string",
40
+ "enum": [
41
+ "user",
42
+ "agent"
43
+ ]
44
+ },
45
+ "id": {
46
+ "format": "uuid",
47
+ "type": "string"
48
+ }
49
+ }
50
+ },
51
+ "seq": {
52
+ "minimum": 0,
53
+ "type": "integer"
54
+ },
55
+ "replyToId": {
56
+ "format": "uuid",
57
+ "description": "Branded MessageId",
58
+ "type": "string"
59
+ },
60
+ "parts": {
61
+ "minItems": 1,
62
+ "maxItems": 10,
63
+ "type": "array",
64
+ "items": {
65
+ "additionalProperties": false,
66
+ "type": "object",
67
+ "required": [
68
+ "type",
69
+ "text"
70
+ ],
71
+ "properties": {
72
+ "type": {
73
+ "const": "text",
74
+ "type": "string"
75
+ },
76
+ "text": {
77
+ "minLength": 1,
78
+ "maxLength": 32768,
79
+ "type": "string"
80
+ }
81
+ }
82
+ }
83
+ },
84
+ "reactions": {
85
+ "type": "object",
86
+ "patternProperties": {
87
+ "^(.*)$": {
88
+ "type": "array",
89
+ "items": {
90
+ "type": "string"
91
+ }
92
+ }
93
+ }
94
+ },
95
+ "isDeleted": {
96
+ "type": "boolean"
97
+ },
98
+ "createdAt": {
99
+ "format": "date-time",
100
+ "type": "string"
101
+ }
102
+ }
103
+ }
104
+ }
105
+ }
@@ -0,0 +1,14 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "messageId"
6
+ ],
7
+ "properties": {
8
+ "messageId": {
9
+ "format": "uuid",
10
+ "description": "Branded MessageId",
11
+ "type": "string"
12
+ }
13
+ }
14
+ }
@@ -0,0 +1,27 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "conversationId"
6
+ ],
7
+ "properties": {
8
+ "conversationId": {
9
+ "format": "uuid",
10
+ "description": "Branded ConversationId",
11
+ "type": "string"
12
+ },
13
+ "afterSeq": {
14
+ "minimum": 0,
15
+ "type": "integer"
16
+ },
17
+ "beforeSeq": {
18
+ "minimum": 0,
19
+ "type": "integer"
20
+ },
21
+ "limit": {
22
+ "minimum": 1,
23
+ "maximum": 100,
24
+ "type": "integer"
25
+ }
26
+ }
27
+ }
@@ -0,0 +1,112 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "messages",
6
+ "hasMore"
7
+ ],
8
+ "properties": {
9
+ "messages": {
10
+ "type": "array",
11
+ "items": {
12
+ "additionalProperties": false,
13
+ "type": "object",
14
+ "required": [
15
+ "id",
16
+ "conversationId",
17
+ "sender",
18
+ "seq",
19
+ "parts",
20
+ "createdAt"
21
+ ],
22
+ "properties": {
23
+ "id": {
24
+ "format": "uuid",
25
+ "description": "Branded MessageId",
26
+ "type": "string"
27
+ },
28
+ "conversationId": {
29
+ "format": "uuid",
30
+ "description": "Branded ConversationId",
31
+ "type": "string"
32
+ },
33
+ "sender": {
34
+ "additionalProperties": false,
35
+ "type": "object",
36
+ "required": [
37
+ "type",
38
+ "id"
39
+ ],
40
+ "properties": {
41
+ "type": {
42
+ "type": "string",
43
+ "enum": [
44
+ "user",
45
+ "agent"
46
+ ]
47
+ },
48
+ "id": {
49
+ "format": "uuid",
50
+ "type": "string"
51
+ }
52
+ }
53
+ },
54
+ "seq": {
55
+ "minimum": 0,
56
+ "type": "integer"
57
+ },
58
+ "replyToId": {
59
+ "format": "uuid",
60
+ "description": "Branded MessageId",
61
+ "type": "string"
62
+ },
63
+ "parts": {
64
+ "minItems": 1,
65
+ "maxItems": 10,
66
+ "type": "array",
67
+ "items": {
68
+ "additionalProperties": false,
69
+ "type": "object",
70
+ "required": [
71
+ "type",
72
+ "text"
73
+ ],
74
+ "properties": {
75
+ "type": {
76
+ "const": "text",
77
+ "type": "string"
78
+ },
79
+ "text": {
80
+ "minLength": 1,
81
+ "maxLength": 32768,
82
+ "type": "string"
83
+ }
84
+ }
85
+ }
86
+ },
87
+ "reactions": {
88
+ "type": "object",
89
+ "patternProperties": {
90
+ "^(.*)$": {
91
+ "type": "array",
92
+ "items": {
93
+ "type": "string"
94
+ }
95
+ }
96
+ }
97
+ },
98
+ "isDeleted": {
99
+ "type": "boolean"
100
+ },
101
+ "createdAt": {
102
+ "format": "date-time",
103
+ "type": "string"
104
+ }
105
+ }
106
+ }
107
+ },
108
+ "hasMore": {
109
+ "type": "boolean"
110
+ }
111
+ }
112
+ }
@@ -0,0 +1,28 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "messageId",
6
+ "emoji",
7
+ "action"
8
+ ],
9
+ "properties": {
10
+ "messageId": {
11
+ "format": "uuid",
12
+ "description": "Branded MessageId",
13
+ "type": "string"
14
+ },
15
+ "emoji": {
16
+ "minLength": 1,
17
+ "maxLength": 32,
18
+ "type": "string"
19
+ },
20
+ "action": {
21
+ "type": "string",
22
+ "enum": [
23
+ "add",
24
+ "remove"
25
+ ]
26
+ }
27
+ }
28
+ }
@@ -0,0 +1,19 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "conversationId",
6
+ "seq"
7
+ ],
8
+ "properties": {
9
+ "conversationId": {
10
+ "format": "uuid",
11
+ "description": "Branded ConversationId",
12
+ "type": "string"
13
+ },
14
+ "seq": {
15
+ "minimum": 0,
16
+ "type": "integer"
17
+ }
18
+ }
19
+ }
@@ -0,0 +1,46 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "parts"
6
+ ],
7
+ "properties": {
8
+ "conversationId": {
9
+ "format": "uuid",
10
+ "description": "Branded ConversationId",
11
+ "type": "string"
12
+ },
13
+ "to": {
14
+ "type": "string"
15
+ },
16
+ "parts": {
17
+ "minItems": 1,
18
+ "maxItems": 10,
19
+ "type": "array",
20
+ "items": {
21
+ "additionalProperties": false,
22
+ "type": "object",
23
+ "required": [
24
+ "type",
25
+ "text"
26
+ ],
27
+ "properties": {
28
+ "type": {
29
+ "const": "text",
30
+ "type": "string"
31
+ },
32
+ "text": {
33
+ "minLength": 1,
34
+ "maxLength": 32768,
35
+ "type": "string"
36
+ }
37
+ }
38
+ }
39
+ },
40
+ "replyToId": {
41
+ "format": "uuid",
42
+ "description": "Branded MessageId",
43
+ "type": "string"
44
+ }
45
+ }
46
+ }
@@ -0,0 +1,105 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "message"
6
+ ],
7
+ "properties": {
8
+ "message": {
9
+ "additionalProperties": false,
10
+ "type": "object",
11
+ "required": [
12
+ "id",
13
+ "conversationId",
14
+ "sender",
15
+ "seq",
16
+ "parts",
17
+ "createdAt"
18
+ ],
19
+ "properties": {
20
+ "id": {
21
+ "format": "uuid",
22
+ "description": "Branded MessageId",
23
+ "type": "string"
24
+ },
25
+ "conversationId": {
26
+ "format": "uuid",
27
+ "description": "Branded ConversationId",
28
+ "type": "string"
29
+ },
30
+ "sender": {
31
+ "additionalProperties": false,
32
+ "type": "object",
33
+ "required": [
34
+ "type",
35
+ "id"
36
+ ],
37
+ "properties": {
38
+ "type": {
39
+ "type": "string",
40
+ "enum": [
41
+ "user",
42
+ "agent"
43
+ ]
44
+ },
45
+ "id": {
46
+ "format": "uuid",
47
+ "type": "string"
48
+ }
49
+ }
50
+ },
51
+ "seq": {
52
+ "minimum": 0,
53
+ "type": "integer"
54
+ },
55
+ "replyToId": {
56
+ "format": "uuid",
57
+ "description": "Branded MessageId",
58
+ "type": "string"
59
+ },
60
+ "parts": {
61
+ "minItems": 1,
62
+ "maxItems": 10,
63
+ "type": "array",
64
+ "items": {
65
+ "additionalProperties": false,
66
+ "type": "object",
67
+ "required": [
68
+ "type",
69
+ "text"
70
+ ],
71
+ "properties": {
72
+ "type": {
73
+ "const": "text",
74
+ "type": "string"
75
+ },
76
+ "text": {
77
+ "minLength": 1,
78
+ "maxLength": 32768,
79
+ "type": "string"
80
+ }
81
+ }
82
+ }
83
+ },
84
+ "reactions": {
85
+ "type": "object",
86
+ "patternProperties": {
87
+ "^(.*)$": {
88
+ "type": "array",
89
+ "items": {
90
+ "type": "string"
91
+ }
92
+ }
93
+ }
94
+ },
95
+ "isDeleted": {
96
+ "type": "boolean"
97
+ },
98
+ "createdAt": {
99
+ "format": "date-time",
100
+ "type": "string"
101
+ }
102
+ }
103
+ }
104
+ }
105
+ }
@@ -0,0 +1,21 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "type",
6
+ "id"
7
+ ],
8
+ "properties": {
9
+ "type": {
10
+ "type": "string",
11
+ "enum": [
12
+ "user",
13
+ "agent"
14
+ ]
15
+ },
16
+ "id": {
17
+ "format": "uuid",
18
+ "type": "string"
19
+ }
20
+ }
21
+ }
@@ -0,0 +1,45 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "maxMessageBytes",
6
+ "maxPartsPerMessage",
7
+ "maxTextLength",
8
+ "maxGroupParticipants",
9
+ "heartbeatIntervalMs",
10
+ "rateLimits"
11
+ ],
12
+ "properties": {
13
+ "maxMessageBytes": {
14
+ "type": "integer"
15
+ },
16
+ "maxPartsPerMessage": {
17
+ "type": "integer"
18
+ },
19
+ "maxTextLength": {
20
+ "type": "integer"
21
+ },
22
+ "maxGroupParticipants": {
23
+ "type": "integer"
24
+ },
25
+ "heartbeatIntervalMs": {
26
+ "type": "integer"
27
+ },
28
+ "rateLimits": {
29
+ "additionalProperties": false,
30
+ "type": "object",
31
+ "required": [
32
+ "messagesPerMinute",
33
+ "requestsPerMinute"
34
+ ],
35
+ "properties": {
36
+ "messagesPerMinute": {
37
+ "type": "integer"
38
+ },
39
+ "requestsPerMinute": {
40
+ "type": "integer"
41
+ }
42
+ }
43
+ }
44
+ }
45
+ }
@@ -0,0 +1,39 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "participant",
6
+ "status"
7
+ ],
8
+ "properties": {
9
+ "participant": {
10
+ "additionalProperties": false,
11
+ "type": "object",
12
+ "required": [
13
+ "type",
14
+ "id"
15
+ ],
16
+ "properties": {
17
+ "type": {
18
+ "type": "string",
19
+ "enum": [
20
+ "user",
21
+ "agent"
22
+ ]
23
+ },
24
+ "id": {
25
+ "format": "uuid",
26
+ "type": "string"
27
+ }
28
+ }
29
+ },
30
+ "status": {
31
+ "type": "string",
32
+ "enum": [
33
+ "online",
34
+ "offline",
35
+ "away"
36
+ ]
37
+ }
38
+ }
39
+ }
@@ -0,0 +1,39 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "participant",
6
+ "status"
7
+ ],
8
+ "properties": {
9
+ "participant": {
10
+ "additionalProperties": false,
11
+ "type": "object",
12
+ "required": [
13
+ "type",
14
+ "id"
15
+ ],
16
+ "properties": {
17
+ "type": {
18
+ "type": "string",
19
+ "enum": [
20
+ "user",
21
+ "agent"
22
+ ]
23
+ },
24
+ "id": {
25
+ "format": "uuid",
26
+ "type": "string"
27
+ }
28
+ }
29
+ },
30
+ "status": {
31
+ "type": "string",
32
+ "enum": [
33
+ "online",
34
+ "offline",
35
+ "away"
36
+ ]
37
+ }
38
+ }
39
+ }
@@ -0,0 +1,33 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "participants"
6
+ ],
7
+ "properties": {
8
+ "participants": {
9
+ "type": "array",
10
+ "items": {
11
+ "additionalProperties": false,
12
+ "type": "object",
13
+ "required": [
14
+ "type",
15
+ "id"
16
+ ],
17
+ "properties": {
18
+ "type": {
19
+ "type": "string",
20
+ "enum": [
21
+ "user",
22
+ "agent"
23
+ ]
24
+ },
25
+ "id": {
26
+ "format": "uuid",
27
+ "type": "string"
28
+ }
29
+ }
30
+ }
31
+ }
32
+ }
33
+ }
@@ -0,0 +1,51 @@
1
+ {
2
+ "additionalProperties": false,
3
+ "type": "object",
4
+ "required": [
5
+ "statuses"
6
+ ],
7
+ "properties": {
8
+ "statuses": {
9
+ "type": "array",
10
+ "items": {
11
+ "additionalProperties": false,
12
+ "type": "object",
13
+ "required": [
14
+ "participant",
15
+ "status"
16
+ ],
17
+ "properties": {
18
+ "participant": {
19
+ "additionalProperties": false,
20
+ "type": "object",
21
+ "required": [
22
+ "type",
23
+ "id"
24
+ ],
25
+ "properties": {
26
+ "type": {
27
+ "type": "string",
28
+ "enum": [
29
+ "user",
30
+ "agent"
31
+ ]
32
+ },
33
+ "id": {
34
+ "format": "uuid",
35
+ "type": "string"
36
+ }
37
+ }
38
+ },
39
+ "status": {
40
+ "type": "string",
41
+ "enum": [
42
+ "online",
43
+ "offline",
44
+ "away"
45
+ ]
46
+ }
47
+ }
48
+ }
49
+ }
50
+ }
51
+ }