@sockethub/schemas 3.0.0-alpha.11 → 3.0.0-alpha.13

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 (60) hide show
  1. package/dist/activity-stream-helper.d.ts +5 -0
  2. package/dist/activity-stream-helper.js +36 -0
  3. package/dist/activity-stream-helper.js.map +10 -0
  4. package/dist/context.d.ts +56 -0
  5. package/dist/context.js +80 -0
  6. package/dist/context.js.map +10 -0
  7. package/dist/contexts/platform/dummy/v1.jsonld +8 -0
  8. package/dist/contexts/platform/error/v1.jsonld +8 -0
  9. package/dist/contexts/platform/feeds/v1.jsonld +8 -0
  10. package/dist/contexts/platform/irc/v1.jsonld +8 -0
  11. package/dist/contexts/platform/metadata/v1.jsonld +8 -0
  12. package/dist/contexts/platform/sockethub%3Ainternal/v1.jsonld +8 -0
  13. package/dist/contexts/platform/xmpp/v1.jsonld +8 -0
  14. package/dist/contexts/v1.jsonld +7 -0
  15. package/dist/helpers/error-parser.d.ts +13 -0
  16. package/dist/helpers/objects.d.ts +122 -0
  17. package/dist/index.d.ts +9 -0
  18. package/dist/index.js +459 -216
  19. package/dist/index.js.map +12 -11
  20. package/dist/maps/context-map.json +35 -0
  21. package/dist/object-types.d.ts +2 -0
  22. package/dist/object-types.js +296 -0
  23. package/dist/object-types.js.map +12 -0
  24. package/dist/schemas/activity-stream.d.ts +161 -0
  25. package/dist/schemas/platform/dummy/v1/credentials.schema.json +1 -0
  26. package/dist/schemas/platform/dummy/v1/messages.schema.json +22 -0
  27. package/dist/schemas/platform/error/v1/credentials.schema.json +1 -0
  28. package/dist/schemas/platform/error/v1/messages.schema.json +1 -0
  29. package/dist/schemas/platform/feeds/v1/credentials.schema.json +1 -0
  30. package/dist/schemas/platform/feeds/v1/messages.schema.json +27 -0
  31. package/dist/schemas/platform/irc/v1/credentials.schema.json +118 -0
  32. package/dist/schemas/platform/irc/v1/messages.schema.json +103 -0
  33. package/dist/schemas/platform/metadata/v1/credentials.schema.json +1 -0
  34. package/dist/schemas/platform/metadata/v1/messages.schema.json +14 -0
  35. package/dist/schemas/platform/sockethub%3Ainternal/v1/credentials.schema.json +1 -0
  36. package/dist/schemas/platform/sockethub%3Ainternal/v1/messages.schema.json +1 -0
  37. package/dist/schemas/platform/xmpp/v1/credentials.schema.json +43 -0
  38. package/dist/schemas/platform/xmpp/v1/messages.schema.json +129 -0
  39. package/dist/schemas/platform.d.ts +62 -0
  40. package/dist/schemas/sockethub-config.d.ts +261 -0
  41. package/{src/types.ts → dist/types.d.ts} +25 -46
  42. package/dist/validator.d.ts +26 -0
  43. package/package.json +17 -7
  44. package/src/helpers/error-parser.ts +0 -113
  45. package/src/helpers/objects.ts +0 -227
  46. package/src/index.test.data.credentials.ts +0 -71
  47. package/src/index.test.data.objects.ts +0 -241
  48. package/src/index.test.data.platform.ts +0 -45
  49. package/src/index.test.data.streams.ts +0 -498
  50. package/src/index.test.ts +0 -99
  51. package/src/index.ts +0 -29
  52. package/src/schemas/activity-object.ts +0 -19
  53. package/src/schemas/activity-stream.ts +0 -54
  54. package/src/schemas/json/activity-object.json +0 -356
  55. package/src/schemas/json/activity-stream.json +0 -469
  56. package/src/schemas/json/platform.json +0 -28
  57. package/src/schemas/json/sockethub-config.json +0 -222
  58. package/src/schemas/platform.ts +0 -47
  59. package/src/schemas/sockethub-config.ts +0 -206
  60. package/src/validator.ts +0 -87
@@ -1,356 +0,0 @@
1
- {
2
- "$id": "https://sockethub.org/schemas/3.0.0-alpha.11/activity-object.json",
3
- "description": "Schema for Sockethub Activity Objects",
4
- "type": "object",
5
- "required": [
6
- "object"
7
- ],
8
- "properties": {
9
- "object": {
10
- "type": "object",
11
- "oneOf": [
12
- {
13
- "$ref": "#/definitions/type/feed"
14
- },
15
- {
16
- "$ref": "#/definitions/type/message"
17
- },
18
- {
19
- "$ref": "#/definitions/type/me"
20
- },
21
- {
22
- "$ref": "#/definitions/type/person"
23
- },
24
- {
25
- "$ref": "#/definitions/type/room"
26
- },
27
- {
28
- "$ref": "#/definitions/type/service"
29
- },
30
- {
31
- "$ref": "#/definitions/type/website"
32
- },
33
- {
34
- "$ref": "#/definitions/type/attendance"
35
- },
36
- {
37
- "$ref": "#/definitions/type/presence"
38
- },
39
- {
40
- "$ref": "#/definitions/type/relationship"
41
- },
42
- {
43
- "$ref": "#/definitions/type/topic"
44
- },
45
- {
46
- "$ref": "#/definitions/type/address"
47
- }
48
- ]
49
- }
50
- },
51
- "definitions": {
52
- "type": {
53
- "feed": {
54
- "required": [
55
- "id",
56
- "type"
57
- ],
58
- "additionalProperties": true,
59
- "properties": {
60
- "type": {
61
- "enum": [
62
- "feed"
63
- ]
64
- },
65
- "id": {
66
- "type": "string",
67
- "format": "iri"
68
- },
69
- "name": {
70
- "type": "string"
71
- },
72
- "description": {
73
- "type": "string"
74
- },
75
- "author": {
76
- "type": "string"
77
- },
78
- "favicon": {
79
- "type": "string"
80
- }
81
- }
82
- },
83
- "message": {
84
- "required": [
85
- "type",
86
- "content"
87
- ],
88
- "additionalProperties": true,
89
- "properties": {
90
- "type": {
91
- "enum": [
92
- "message"
93
- ]
94
- },
95
- "id": {
96
- "type": "string"
97
- },
98
- "name": {
99
- "type": "string"
100
- },
101
- "content": {
102
- "type": "string"
103
- }
104
- }
105
- },
106
- "me": {
107
- "required": [
108
- "type",
109
- "content"
110
- ],
111
- "additionalProperties": true,
112
- "properties": {
113
- "type": {
114
- "enum": [
115
- "me"
116
- ]
117
- },
118
- "content": {
119
- "type": "string"
120
- }
121
- }
122
- },
123
- "person": {
124
- "required": [
125
- "id",
126
- "type"
127
- ],
128
- "additionalProperties": true,
129
- "properties": {
130
- "id": {
131
- "type": "string"
132
- },
133
- "type": {
134
- "enum": [
135
- "person"
136
- ]
137
- },
138
- "name": {
139
- "type": "string"
140
- }
141
- }
142
- },
143
- "room": {
144
- "required": [
145
- "id",
146
- "type"
147
- ],
148
- "additionalProperties": true,
149
- "properties": {
150
- "id": {
151
- "type": "string"
152
- },
153
- "type": {
154
- "enum": [
155
- "room"
156
- ]
157
- },
158
- "name": {
159
- "type": "string"
160
- }
161
- }
162
- },
163
- "service": {
164
- "required": [
165
- "id",
166
- "type"
167
- ],
168
- "additionalProperties": true,
169
- "properties": {
170
- "id": {
171
- "type": "string"
172
- },
173
- "type": {
174
- "enum": [
175
- "service"
176
- ]
177
- },
178
- "name": {
179
- "type": "string"
180
- }
181
- }
182
- },
183
- "website": {
184
- "required": [
185
- "id",
186
- "type"
187
- ],
188
- "additionalProperties": true,
189
- "properties": {
190
- "id": {
191
- "type": "string",
192
- "format": "iri"
193
- },
194
- "type": {
195
- "enum": [
196
- "website"
197
- ]
198
- },
199
- "name": {
200
- "type": "string"
201
- }
202
- }
203
- },
204
- "attendance": {
205
- "required": [
206
- "type"
207
- ],
208
- "additionalProperties": false,
209
- "properties": {
210
- "type": {
211
- "enum": [
212
- "attendance"
213
- ]
214
- },
215
- "members": {
216
- "type": "array",
217
- "items": {
218
- "type": "string"
219
- }
220
- }
221
- }
222
- },
223
- "presence": {
224
- "required": [
225
- "type"
226
- ],
227
- "additionalProperties": false,
228
- "properties": {
229
- "type": {
230
- "enum": [
231
- "presence"
232
- ]
233
- },
234
- "presence": {
235
- "enum": [
236
- "away",
237
- "chat",
238
- "dnd",
239
- "xa",
240
- "offline",
241
- "online"
242
- ]
243
- },
244
- "role": {
245
- "enum": [
246
- "owner",
247
- "member",
248
- "participant",
249
- "admin"
250
- ]
251
- },
252
- "content": {
253
- "type": "string"
254
- }
255
- }
256
- },
257
- "relationship": {
258
- "required": [
259
- "type",
260
- "relationship"
261
- ],
262
- "additionalProperties": false,
263
- "properties": {
264
- "type": {
265
- "enum": [
266
- "relationship"
267
- ]
268
- },
269
- "relationship": {
270
- "enum": [
271
- "role"
272
- ]
273
- },
274
- "subject": {
275
- "type": "object",
276
- "oneOf": [
277
- {
278
- "$ref": "#/definitions/type/presence"
279
- }
280
- ]
281
- },
282
- "object": {
283
- "type": "object",
284
- "oneOf": [
285
- {
286
- "$ref": "#/definitions/type/feed"
287
- },
288
- {
289
- "$ref": "#/definitions/type/message"
290
- },
291
- {
292
- "$ref": "#/definitions/type/me"
293
- },
294
- {
295
- "$ref": "#/definitions/type/person"
296
- },
297
- {
298
- "$ref": "#/definitions/type/room"
299
- },
300
- {
301
- "$ref": "#/definitions/type/service"
302
- },
303
- {
304
- "$ref": "#/definitions/type/website"
305
- },
306
- {
307
- "$ref": "#/definitions/type/attendance"
308
- },
309
- {
310
- "$ref": "#/definitions/type/presence"
311
- },
312
- {
313
- "$ref": "#/definitions/type/relationship"
314
- },
315
- {
316
- "$ref": "#/definitions/type/topic"
317
- },
318
- {
319
- "$ref": "#/definitions/type/address"
320
- }
321
- ]
322
- }
323
- }
324
- },
325
- "topic": {
326
- "required": [
327
- "type"
328
- ],
329
- "additionalProperties": false,
330
- "properties": {
331
- "type": {
332
- "enum": [
333
- "topic"
334
- ]
335
- },
336
- "content": {
337
- "type": "string"
338
- }
339
- }
340
- },
341
- "address": {
342
- "required": [
343
- "type"
344
- ],
345
- "additionalProperties": false,
346
- "properties": {
347
- "type": {
348
- "enum": [
349
- "address"
350
- ]
351
- }
352
- }
353
- }
354
- }
355
- }
356
- }