@overtable/schemas 0.0.0-stage → 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 (44) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/LICENSE +202 -0
  3. package/README.md +55 -2
  4. package/dist/index.d.ts +215 -0
  5. package/dist/index.js +759 -0
  6. package/dist/json-schema/pairs/calendar.freebusy.answer.json +41 -0
  7. package/dist/json-schema/pairs/calendar.freebusy.ask.json +32 -0
  8. package/dist/json-schema/pairs/contact.channel.answer.json +26 -0
  9. package/dist/json-schema/pairs/contact.channel.ask.json +7 -0
  10. package/dist/json-schema/pairs/message.answer.json +7 -0
  11. package/dist/json-schema/pairs/message.ask.json +17 -0
  12. package/dist/json-schema/pairs/note.answer.json +7 -0
  13. package/dist/json-schema/pairs/note.ask.json +17 -0
  14. package/dist/json-schema/pairs/offers.list.answer.json +68 -0
  15. package/dist/json-schema/pairs/offers.list.ask.json +14 -0
  16. package/dist/json-schema/pairs/overtable.ping.answer.json +17 -0
  17. package/dist/json-schema/pairs/overtable.ping.ask.json +7 -0
  18. package/dist/json-schema/pairs/preferences.ask.answer.json +22 -0
  19. package/dist/json-schema/pairs/preferences.ask.ask.json +17 -0
  20. package/dist/json-schema/pairs/quote.answer.json +57 -0
  21. package/dist/json-schema/pairs/quote.ask.json +85 -0
  22. package/dist/json-schema/pairs/rate.range.answer.json +60 -0
  23. package/dist/json-schema/pairs/rate.range.ask.json +17 -0
  24. package/dist/json-schema/pairs/recommendation.ask.answer.json +21 -0
  25. package/dist/json-schema/pairs/recommendation.ask.ask.json +17 -0
  26. package/dist/json-schema/pairs/scope.ask.answer.json +25 -0
  27. package/dist/json-schema/pairs/scope.ask.ask.json +17 -0
  28. package/dist/json-schema/pairs/slot.answer.json +43 -0
  29. package/dist/json-schema/pairs/slot.ask.json +35 -0
  30. package/dist/json-schema/requests/order.json +56 -0
  31. package/dist/json-schema/requests/poll.json +30 -0
  32. package/dist/json-schema/requests/quote.json +56 -0
  33. package/dist/json-schema/requests/request_answer.json +216 -0
  34. package/dist/json-schema/requests/request_create.json +676 -0
  35. package/dist/json-schema/requests/slot.json +33 -0
  36. package/dist/json-schema/share/availability.json +50 -0
  37. package/dist/json-schema/share/contact_details.json +45 -0
  38. package/dist/json-schema/share/documents.json +59 -0
  39. package/dist/json-schema/share/finance.json +71 -0
  40. package/dist/json-schema/share/health.json +52 -0
  41. package/dist/json-schema/share/location.json +45 -0
  42. package/dist/json-schema/share/preferences.json +46 -0
  43. package/dist/json-schema/share/share.json +458 -0
  44. package/package.json +47 -4
@@ -0,0 +1,458 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "title": "share",
4
+ "anyOf": [
5
+ {
6
+ "type": "object",
7
+ "properties": {
8
+ "category": {
9
+ "type": "string",
10
+ "const": "availability"
11
+ },
12
+ "payload": {
13
+ "type": "object",
14
+ "properties": {
15
+ "title": {
16
+ "type": "string",
17
+ "minLength": 1,
18
+ "maxLength": 80,
19
+ "pattern": "^[^\\r\\n<>]+$",
20
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
21
+ },
22
+ "timeZone": {
23
+ "type": "string",
24
+ "minLength": 1,
25
+ "maxLength": 64,
26
+ "pattern": "^[^\\r\\n<>]+$",
27
+ "description": "IANA time zone, e.g. Europe/Paris"
28
+ },
29
+ "free": {
30
+ "type": "array",
31
+ "items": {
32
+ "type": "object",
33
+ "properties": {
34
+ "from": {
35
+ "type": "string",
36
+ "format": "date-time"
37
+ },
38
+ "to": {
39
+ "type": "string",
40
+ "format": "date-time"
41
+ }
42
+ },
43
+ "required": [
44
+ "from",
45
+ "to"
46
+ ],
47
+ "additionalProperties": false
48
+ },
49
+ "minItems": 1,
50
+ "maxItems": 50,
51
+ "description": "Free windows, ISO 8601 with offset"
52
+ }
53
+ },
54
+ "required": [
55
+ "title",
56
+ "free"
57
+ ],
58
+ "additionalProperties": false
59
+ }
60
+ },
61
+ "required": [
62
+ "category",
63
+ "payload"
64
+ ],
65
+ "additionalProperties": false
66
+ },
67
+ {
68
+ "type": "object",
69
+ "properties": {
70
+ "category": {
71
+ "type": "string",
72
+ "const": "finance"
73
+ },
74
+ "payload": {
75
+ "type": "object",
76
+ "properties": {
77
+ "title": {
78
+ "type": "string",
79
+ "minLength": 1,
80
+ "maxLength": 80,
81
+ "pattern": "^[^\\r\\n<>]+$",
82
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
83
+ },
84
+ "kind": {
85
+ "type": "string",
86
+ "enum": [
87
+ "amount",
88
+ "budget",
89
+ "bank_details",
90
+ "invoice",
91
+ "other"
92
+ ]
93
+ },
94
+ "amount": {
95
+ "type": "object",
96
+ "properties": {
97
+ "value": {
98
+ "type": "number",
99
+ "minimum": 0,
100
+ "maximum": 1000000000000
101
+ },
102
+ "currency": {
103
+ "type": "string",
104
+ "pattern": "^[A-Z]{3}$"
105
+ }
106
+ },
107
+ "required": [
108
+ "value",
109
+ "currency"
110
+ ],
111
+ "additionalProperties": false
112
+ },
113
+ "iban": {
114
+ "allOf": [
115
+ {
116
+ "type": "string"
117
+ },
118
+ {
119
+ "type": "string",
120
+ "pattern": "^[A-Z]{2}[0-9]{2}[A-Z0-9]{10,30}$"
121
+ }
122
+ ]
123
+ },
124
+ "reference": {
125
+ "type": "string",
126
+ "minLength": 1,
127
+ "maxLength": 120,
128
+ "pattern": "^[^\\r\\n<>]+$"
129
+ },
130
+ "note": {
131
+ "type": "string",
132
+ "minLength": 1,
133
+ "maxLength": 500,
134
+ "pattern": "^[^<>]+$"
135
+ }
136
+ },
137
+ "required": [
138
+ "title",
139
+ "kind"
140
+ ],
141
+ "additionalProperties": false
142
+ }
143
+ },
144
+ "required": [
145
+ "category",
146
+ "payload"
147
+ ],
148
+ "additionalProperties": false
149
+ },
150
+ {
151
+ "type": "object",
152
+ "properties": {
153
+ "category": {
154
+ "type": "string",
155
+ "const": "health"
156
+ },
157
+ "payload": {
158
+ "type": "object",
159
+ "properties": {
160
+ "title": {
161
+ "type": "string",
162
+ "minLength": 1,
163
+ "maxLength": 80,
164
+ "pattern": "^[^\\r\\n<>]+$",
165
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
166
+ },
167
+ "kind": {
168
+ "type": "string",
169
+ "enum": [
170
+ "allergy",
171
+ "medication",
172
+ "condition",
173
+ "appointment",
174
+ "vaccination",
175
+ "other"
176
+ ]
177
+ },
178
+ "subject": {
179
+ "type": "string",
180
+ "minLength": 1,
181
+ "maxLength": 80,
182
+ "pattern": "^[^\\r\\n<>]+$",
183
+ "description": "Whom it is about, e.g. Lily"
184
+ },
185
+ "details": {
186
+ "type": "string",
187
+ "minLength": 1,
188
+ "maxLength": 1000,
189
+ "pattern": "^[^<>]+$"
190
+ },
191
+ "severity": {
192
+ "type": "string",
193
+ "enum": [
194
+ "low",
195
+ "medium",
196
+ "high"
197
+ ]
198
+ }
199
+ },
200
+ "required": [
201
+ "title",
202
+ "kind",
203
+ "details"
204
+ ],
205
+ "additionalProperties": false
206
+ }
207
+ },
208
+ "required": [
209
+ "category",
210
+ "payload"
211
+ ],
212
+ "additionalProperties": false
213
+ },
214
+ {
215
+ "type": "object",
216
+ "properties": {
217
+ "category": {
218
+ "type": "string",
219
+ "const": "contact_details"
220
+ },
221
+ "payload": {
222
+ "type": "object",
223
+ "properties": {
224
+ "title": {
225
+ "type": "string",
226
+ "minLength": 1,
227
+ "maxLength": 80,
228
+ "pattern": "^[^\\r\\n<>]+$",
229
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
230
+ },
231
+ "name": {
232
+ "type": "string",
233
+ "minLength": 1,
234
+ "maxLength": 120,
235
+ "pattern": "^[^\\r\\n<>]+$"
236
+ },
237
+ "email": {
238
+ "type": "string",
239
+ "format": "email",
240
+ "maxLength": 254
241
+ },
242
+ "phone": {
243
+ "type": "string",
244
+ "pattern": "^\\+?[0-9][0-9 ().-]{5,24}$"
245
+ },
246
+ "address": {
247
+ "type": "string",
248
+ "minLength": 1,
249
+ "maxLength": 300,
250
+ "pattern": "^[^<>]+$"
251
+ },
252
+ "handle": {
253
+ "type": "string",
254
+ "minLength": 1,
255
+ "maxLength": 64,
256
+ "pattern": "^[^\\r\\n<>]+$"
257
+ }
258
+ },
259
+ "required": [
260
+ "title"
261
+ ],
262
+ "additionalProperties": false
263
+ }
264
+ },
265
+ "required": [
266
+ "category",
267
+ "payload"
268
+ ],
269
+ "additionalProperties": false
270
+ },
271
+ {
272
+ "type": "object",
273
+ "properties": {
274
+ "category": {
275
+ "type": "string",
276
+ "const": "location"
277
+ },
278
+ "payload": {
279
+ "type": "object",
280
+ "properties": {
281
+ "title": {
282
+ "type": "string",
283
+ "minLength": 1,
284
+ "maxLength": 80,
285
+ "pattern": "^[^\\r\\n<>]+$",
286
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
287
+ },
288
+ "place": {
289
+ "type": "string",
290
+ "minLength": 1,
291
+ "maxLength": 200,
292
+ "pattern": "^[^\\r\\n<>]+$"
293
+ },
294
+ "address": {
295
+ "type": "string",
296
+ "minLength": 1,
297
+ "maxLength": 300,
298
+ "pattern": "^[^<>]+$"
299
+ },
300
+ "lat": {
301
+ "type": "number",
302
+ "minimum": -90,
303
+ "maximum": 90
304
+ },
305
+ "lng": {
306
+ "type": "number",
307
+ "minimum": -180,
308
+ "maximum": 180
309
+ },
310
+ "until": {
311
+ "type": "string",
312
+ "format": "date-time",
313
+ "description": "Until when this holds"
314
+ }
315
+ },
316
+ "required": [
317
+ "title"
318
+ ],
319
+ "additionalProperties": false
320
+ }
321
+ },
322
+ "required": [
323
+ "category",
324
+ "payload"
325
+ ],
326
+ "additionalProperties": false
327
+ },
328
+ {
329
+ "type": "object",
330
+ "properties": {
331
+ "category": {
332
+ "type": "string",
333
+ "const": "documents"
334
+ },
335
+ "payload": {
336
+ "type": "object",
337
+ "properties": {
338
+ "title": {
339
+ "type": "string",
340
+ "minLength": 1,
341
+ "maxLength": 80,
342
+ "pattern": "^[^\\r\\n<>]+$",
343
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
344
+ },
345
+ "items": {
346
+ "type": "array",
347
+ "items": {
348
+ "type": "object",
349
+ "properties": {
350
+ "name": {
351
+ "type": "string",
352
+ "minLength": 1,
353
+ "maxLength": 200,
354
+ "pattern": "^[^\\r\\n<>]+$"
355
+ },
356
+ "mediaType": {
357
+ "type": "string",
358
+ "pattern": "^[a-z]+\\/[a-z0-9.+-]+$",
359
+ "maxLength": 100
360
+ },
361
+ "sizeBytes": {
362
+ "type": "integer",
363
+ "minimum": 0,
364
+ "maximum": 10000000000
365
+ },
366
+ "sha256": {
367
+ "type": "string",
368
+ "pattern": "^[a-f0-9]{64}$"
369
+ },
370
+ "url": {
371
+ "type": "string",
372
+ "format": "uri",
373
+ "maxLength": 2000,
374
+ "pattern": "^https:\\/\\/"
375
+ }
376
+ },
377
+ "required": [
378
+ "name"
379
+ ],
380
+ "additionalProperties": false
381
+ },
382
+ "minItems": 1,
383
+ "maxItems": 20
384
+ }
385
+ },
386
+ "required": [
387
+ "title",
388
+ "items"
389
+ ],
390
+ "additionalProperties": false
391
+ }
392
+ },
393
+ "required": [
394
+ "category",
395
+ "payload"
396
+ ],
397
+ "additionalProperties": false
398
+ },
399
+ {
400
+ "type": "object",
401
+ "properties": {
402
+ "category": {
403
+ "type": "string",
404
+ "const": "preferences"
405
+ },
406
+ "payload": {
407
+ "type": "object",
408
+ "properties": {
409
+ "title": {
410
+ "type": "string",
411
+ "minLength": 1,
412
+ "maxLength": 80,
413
+ "pattern": "^[^\\r\\n<>]+$",
414
+ "description": "A short label the owner reads on the hold screen: Allergy note, Home address. Not the data itself."
415
+ },
416
+ "items": {
417
+ "type": "array",
418
+ "items": {
419
+ "type": "object",
420
+ "properties": {
421
+ "topic": {
422
+ "type": "string",
423
+ "minLength": 1,
424
+ "maxLength": 80,
425
+ "pattern": "^[^\\r\\n<>]+$"
426
+ },
427
+ "value": {
428
+ "type": "string",
429
+ "minLength": 1,
430
+ "maxLength": 200,
431
+ "pattern": "^[^\\r\\n<>]+$"
432
+ }
433
+ },
434
+ "required": [
435
+ "topic",
436
+ "value"
437
+ ],
438
+ "additionalProperties": false
439
+ },
440
+ "minItems": 1,
441
+ "maxItems": 30
442
+ }
443
+ },
444
+ "required": [
445
+ "title",
446
+ "items"
447
+ ],
448
+ "additionalProperties": false
449
+ }
450
+ },
451
+ "required": [
452
+ "category",
453
+ "payload"
454
+ ],
455
+ "additionalProperties": false
456
+ }
457
+ ]
458
+ }
package/package.json CHANGED
@@ -1,6 +1,49 @@
1
1
  {
2
2
  "name": "@overtable/schemas",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.0",
4
+ "description": "The public shapes of Overtable's typed exchanges and requests, as Zod schemas, TypeScript types and JSON Schema.",
5
+ "keywords": [
6
+ "overtable",
7
+ "ai-agents",
8
+ "mcp",
9
+ "zod",
10
+ "json-schema"
11
+ ],
12
+ "license": "Apache-2.0",
13
+ "author": "Overtable",
14
+ "homepage": "https://overtable.dev",
15
+ "repository": {
16
+ "type": "git",
17
+ "url": "git+https://github.com/Overtable-dev/overtable-js.git",
18
+ "directory": "packages/schemas"
19
+ },
20
+ "bugs": {
21
+ "url": "https://github.com/Overtable-dev/overtable-js/issues"
22
+ },
23
+ "type": "module",
24
+ "main": "./dist/index.js",
25
+ "types": "./dist/index.d.ts",
26
+ "exports": {
27
+ ".": {
28
+ "types": "./dist/index.d.ts",
29
+ "import": "./dist/index.js"
30
+ },
31
+ "./json-schema/*": "./dist/json-schema/*",
32
+ "./package.json": "./package.json"
33
+ },
34
+ "files": [
35
+ "dist",
36
+ "CHANGELOG.md"
37
+ ],
38
+ "sideEffects": false,
39
+ "engines": {
40
+ "node": ">=20"
41
+ },
42
+ "dependencies": {
43
+ "zod": "^3.25.0"
44
+ },
45
+ "publishConfig": {
46
+ "access": "public",
47
+ "provenance": true
48
+ }
49
+ }