@moltzap/protocol 0.1.0 → 0.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 (87) hide show
  1. package/dist/schema/conversations.d.ts +6 -0
  2. package/dist/schema/conversations.d.ts.map +1 -1
  3. package/dist/schema/conversations.js +3 -0
  4. package/dist/schema/conversations.js.map +1 -1
  5. package/dist/schema/identity.d.ts.map +1 -1
  6. package/dist/schema/identity.js +1 -0
  7. package/dist/schema/identity.js.map +1 -1
  8. package/dist/schema/methods/auth.d.ts +37 -0
  9. package/dist/schema/methods/auth.d.ts.map +1 -1
  10. package/dist/schema/methods/auth.js +29 -0
  11. package/dist/schema/methods/auth.js.map +1 -1
  12. package/dist/schema/methods/conversations.d.ts +6 -0
  13. package/dist/schema/methods/conversations.d.ts.map +1 -1
  14. package/dist/types.d.ts +1 -1
  15. package/dist/types.d.ts.map +1 -1
  16. package/dist/validators.d.ts +9 -0
  17. package/dist/validators.d.ts.map +1 -1
  18. package/dist/validators.js +4 -1
  19. package/dist/validators.js.map +1 -1
  20. package/package.json +9 -11
  21. package/dist/schemas/Agent.json +0 -46
  22. package/dist/schemas/Contact.json +0 -40
  23. package/dist/schemas/ContactAcceptedEvent.json +0 -49
  24. package/dist/schemas/ContactIdParams.json +0 -14
  25. package/dist/schemas/ContactRequestEvent.json +0 -49
  26. package/dist/schemas/ContactsAcceptParams.json +0 -14
  27. package/dist/schemas/ContactsAcceptResult.json +0 -49
  28. package/dist/schemas/ContactsAddParams.json +0 -18
  29. package/dist/schemas/ContactsAddResult.json +0 -19
  30. package/dist/schemas/ContactsListParams.json +0 -14
  31. package/dist/schemas/ContactsListResult.json +0 -52
  32. package/dist/schemas/Conversation.json +0 -57
  33. package/dist/schemas/ConversationCreatedEvent.json +0 -66
  34. package/dist/schemas/ConversationParticipant.json +0 -59
  35. package/dist/schemas/ConversationSummary.json +0 -37
  36. package/dist/schemas/ConversationUpdatedEvent.json +0 -66
  37. package/dist/schemas/ConversationsAddParticipantParams.json +0 -36
  38. package/dist/schemas/ConversationsCreateParams.json +0 -47
  39. package/dist/schemas/ConversationsCreateResult.json +0 -66
  40. package/dist/schemas/ConversationsGetParams.json +0 -14
  41. package/dist/schemas/ConversationsGetResult.json +0 -129
  42. package/dist/schemas/ConversationsLeaveParams.json +0 -14
  43. package/dist/schemas/ConversationsListParams.json +0 -14
  44. package/dist/schemas/ConversationsListResult.json +0 -52
  45. package/dist/schemas/ConversationsMuteParams.json +0 -18
  46. package/dist/schemas/ConversationsRemoveParticipantParams.json +0 -36
  47. package/dist/schemas/ConversationsUnmuteParams.json +0 -14
  48. package/dist/schemas/ConversationsUpdateParams.json +0 -19
  49. package/dist/schemas/DeliveryEntry.json +0 -59
  50. package/dist/schemas/EmptyResult.json +0 -5
  51. package/dist/schemas/EventFrame.json +0 -23
  52. package/dist/schemas/HelloOk.json +0 -118
  53. package/dist/schemas/Invite.json +0 -63
  54. package/dist/schemas/InvitesAcceptParams.json +0 -13
  55. package/dist/schemas/InvitesAcceptResult.json +0 -103
  56. package/dist/schemas/InvitesCreateParams.json +0 -18
  57. package/dist/schemas/InvitesCreateResult.json +0 -17
  58. package/dist/schemas/Message.json +0 -96
  59. package/dist/schemas/MessageDeletedEvent.json +0 -20
  60. package/dist/schemas/MessageDeliveredEvent.json +0 -42
  61. package/dist/schemas/MessageReactedEvent.json +0 -48
  62. package/dist/schemas/MessageReadEvent.json +0 -41
  63. package/dist/schemas/MessageReceivedEvent.json +0 -105
  64. package/dist/schemas/MessagesDeleteParams.json +0 -14
  65. package/dist/schemas/MessagesListParams.json +0 -27
  66. package/dist/schemas/MessagesListResult.json +0 -112
  67. package/dist/schemas/MessagesReactParams.json +0 -28
  68. package/dist/schemas/MessagesReadParams.json +0 -19
  69. package/dist/schemas/MessagesSendParams.json +0 -46
  70. package/dist/schemas/MessagesSendResult.json +0 -105
  71. package/dist/schemas/ParticipantRef.json +0 -21
  72. package/dist/schemas/Policy.json +0 -45
  73. package/dist/schemas/PresenceChangedEvent.json +0 -39
  74. package/dist/schemas/PresenceEntry.json +0 -39
  75. package/dist/schemas/PresenceSubscribeParams.json +0 -33
  76. package/dist/schemas/PresenceSubscribeResult.json +0 -51
  77. package/dist/schemas/PresenceUpdateParams.json +0 -17
  78. package/dist/schemas/RateLimits.json +0 -16
  79. package/dist/schemas/RegisterParams.json +0 -17
  80. package/dist/schemas/RegisterResult.json +0 -27
  81. package/dist/schemas/RequestFrame.json +0 -27
  82. package/dist/schemas/ResponseFrame.json +0 -40
  83. package/dist/schemas/RpcError.json +0 -17
  84. package/dist/schemas/TextPart.json +0 -19
  85. package/dist/schemas/TypingIndicator.json +0 -36
  86. package/dist/schemas/TypingIndicatorEvent.json +0 -36
  87. package/dist/schemas/User.json +0 -43
@@ -1,20 +0,0 @@
1
- {
2
- "additionalProperties": false,
3
- "type": "object",
4
- "required": [
5
- "messageId",
6
- "conversationId"
7
- ],
8
- "properties": {
9
- "messageId": {
10
- "format": "uuid",
11
- "description": "Branded MessageId",
12
- "type": "string"
13
- },
14
- "conversationId": {
15
- "format": "uuid",
16
- "description": "Branded ConversationId",
17
- "type": "string"
18
- }
19
- }
20
- }
@@ -1,42 +0,0 @@
1
- {
2
- "additionalProperties": false,
3
- "type": "object",
4
- "required": [
5
- "messageId",
6
- "conversationId",
7
- "participant"
8
- ],
9
- "properties": {
10
- "messageId": {
11
- "format": "uuid",
12
- "description": "Branded MessageId",
13
- "type": "string"
14
- },
15
- "conversationId": {
16
- "format": "uuid",
17
- "description": "Branded ConversationId",
18
- "type": "string"
19
- },
20
- "participant": {
21
- "additionalProperties": false,
22
- "type": "object",
23
- "required": [
24
- "type",
25
- "id"
26
- ],
27
- "properties": {
28
- "type": {
29
- "type": "string",
30
- "enum": [
31
- "user",
32
- "agent"
33
- ]
34
- },
35
- "id": {
36
- "format": "uuid",
37
- "type": "string"
38
- }
39
- }
40
- }
41
- }
42
- }
@@ -1,48 +0,0 @@
1
- {
2
- "additionalProperties": false,
3
- "type": "object",
4
- "required": [
5
- "messageId",
6
- "emoji",
7
- "participant",
8
- "action"
9
- ],
10
- "properties": {
11
- "messageId": {
12
- "format": "uuid",
13
- "description": "Branded MessageId",
14
- "type": "string"
15
- },
16
- "emoji": {
17
- "type": "string"
18
- },
19
- "participant": {
20
- "additionalProperties": false,
21
- "type": "object",
22
- "required": [
23
- "type",
24
- "id"
25
- ],
26
- "properties": {
27
- "type": {
28
- "type": "string",
29
- "enum": [
30
- "user",
31
- "agent"
32
- ]
33
- },
34
- "id": {
35
- "format": "uuid",
36
- "type": "string"
37
- }
38
- }
39
- },
40
- "action": {
41
- "type": "string",
42
- "enum": [
43
- "add",
44
- "remove"
45
- ]
46
- }
47
- }
48
- }
@@ -1,41 +0,0 @@
1
- {
2
- "additionalProperties": false,
3
- "type": "object",
4
- "required": [
5
- "conversationId",
6
- "participant",
7
- "seq"
8
- ],
9
- "properties": {
10
- "conversationId": {
11
- "format": "uuid",
12
- "description": "Branded ConversationId",
13
- "type": "string"
14
- },
15
- "participant": {
16
- "additionalProperties": false,
17
- "type": "object",
18
- "required": [
19
- "type",
20
- "id"
21
- ],
22
- "properties": {
23
- "type": {
24
- "type": "string",
25
- "enum": [
26
- "user",
27
- "agent"
28
- ]
29
- },
30
- "id": {
31
- "format": "uuid",
32
- "type": "string"
33
- }
34
- }
35
- },
36
- "seq": {
37
- "minimum": 0,
38
- "type": "integer"
39
- }
40
- }
41
- }
@@ -1,105 +0,0 @@
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
- }
@@ -1,14 +0,0 @@
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
- }
@@ -1,27 +0,0 @@
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
- }
@@ -1,112 +0,0 @@
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
- }
@@ -1,28 +0,0 @@
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
- }
@@ -1,19 +0,0 @@
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
- }
@@ -1,46 +0,0 @@
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
- }
@@ -1,105 +0,0 @@
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
- }
@@ -1,21 +0,0 @@
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
- }
@@ -1,45 +0,0 @@
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
- }