@taggor/contract 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 (50) hide show
  1. package/dist/.tsbuildinfo +1 -1
  2. package/dist/contract-version.d.ts +2 -1
  3. package/dist/contract-version.d.ts.map +1 -1
  4. package/dist/contract-version.js +2 -1
  5. package/dist/contract-version.js.map +1 -1
  6. package/dist/error-catalog.d.ts +5 -5
  7. package/dist/error-catalog.js +5 -5
  8. package/dist/error-catalog.js.map +1 -1
  9. package/dist/human-actions.d.ts +1 -1
  10. package/dist/human-actions.d.ts.map +1 -1
  11. package/dist/human-actions.js +42 -0
  12. package/dist/human-actions.js.map +1 -1
  13. package/dist/index.d.ts +2 -1
  14. package/dist/index.d.ts.map +1 -1
  15. package/dist/index.js +2 -1
  16. package/dist/index.js.map +1 -1
  17. package/dist/limit-catalog.d.ts +13 -3
  18. package/dist/limit-catalog.d.ts.map +1 -1
  19. package/dist/limit-catalog.js +17 -2
  20. package/dist/limit-catalog.js.map +1 -1
  21. package/dist/manifest.d.ts +2 -2
  22. package/dist/manifest.js +3 -3
  23. package/dist/manifest.js.map +1 -1
  24. package/dist/metering.d.ts +2 -3
  25. package/dist/metering.d.ts.map +1 -1
  26. package/dist/metering.js +3 -14
  27. package/dist/metering.js.map +1 -1
  28. package/dist/money.d.ts +41 -0
  29. package/dist/money.d.ts.map +1 -0
  30. package/dist/money.js +52 -0
  31. package/dist/money.js.map +1 -0
  32. package/dist/plan-pricing.d.ts +2 -2
  33. package/dist/plan-pricing.js +2 -2
  34. package/dist/plan-pricing.js.map +1 -1
  35. package/dist/ssr-render.d.ts +114 -0
  36. package/dist/ssr-render.d.ts.map +1 -0
  37. package/dist/ssr-render.js +271 -0
  38. package/dist/ssr-render.js.map +1 -0
  39. package/dist/zod-free.d.ts +1 -0
  40. package/dist/zod-free.d.ts.map +1 -1
  41. package/dist/zod-free.js +2 -0
  42. package/dist/zod-free.js.map +1 -1
  43. package/package.json +5 -1
  44. package/schema/component-manifest.v1.json +2 -2
  45. package/schema/published/SHA256SUMS +5 -0
  46. package/schema/published/build-diagnostic/v1.11.json +83 -0
  47. package/schema/published/component-manifest/v1.11.json +1443 -0
  48. package/schema/published/data-api/v1.11.json +282 -0
  49. package/schema/published/library-manifest/v1.11.json +68 -0
  50. package/schema/published/taggor-config/v1.11.json +56 -0
@@ -0,0 +1,282 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://taggor.dev/schema/data-api/v1.json",
4
+ "title": "Taggor data API v1",
5
+ "description": "Payloads between a component and the edge (submit, read, track). Generated from the Zod source in @taggor/contract; do not edit.",
6
+ "$defs": {
7
+ "SubmitRequest": {
8
+ "type": "object",
9
+ "properties": {
10
+ "data": {
11
+ "type": "object",
12
+ "propertyNames": {
13
+ "type": "string",
14
+ "maxLength": 40
15
+ },
16
+ "additionalProperties": {},
17
+ "maxProperties": 50
18
+ },
19
+ "idempotency_key": {
20
+ "type": "string",
21
+ "minLength": 16,
22
+ "maxLength": 64,
23
+ "pattern": "^[A-Za-z0-9_-]+$"
24
+ },
25
+ "turnstile_token": {
26
+ "type": "string",
27
+ "minLength": 1,
28
+ "maxLength": 2048
29
+ },
30
+ "_hp": {
31
+ "type": "string",
32
+ "maxLength": 256
33
+ },
34
+ "_t": {
35
+ "type": "integer",
36
+ "minimum": 0,
37
+ "maximum": 9007199254740991
38
+ },
39
+ "consent": {
40
+ "type": "object",
41
+ "properties": {
42
+ "given": {
43
+ "type": "boolean",
44
+ "const": true
45
+ },
46
+ "text_hash": {
47
+ "type": "string",
48
+ "minLength": 64,
49
+ "maxLength": 64,
50
+ "pattern": "^[0-9a-f]+$"
51
+ },
52
+ "locale": {
53
+ "type": "string",
54
+ "maxLength": 35,
55
+ "pattern": "^[a-z]{2,3}(?:-[A-Za-z0-9]{2,8})*$"
56
+ }
57
+ },
58
+ "required": [
59
+ "given",
60
+ "text_hash",
61
+ "locale"
62
+ ],
63
+ "additionalProperties": false,
64
+ "title": "Consent proof"
65
+ }
66
+ },
67
+ "required": [
68
+ "data",
69
+ "idempotency_key"
70
+ ],
71
+ "additionalProperties": false,
72
+ "title": "Submit request"
73
+ },
74
+ "SubmitAccepted": {
75
+ "type": "object",
76
+ "properties": {
77
+ "status": {
78
+ "type": "string",
79
+ "const": "accepted"
80
+ }
81
+ },
82
+ "required": [
83
+ "status"
84
+ ],
85
+ "additionalProperties": false,
86
+ "title": "Submit accepted"
87
+ },
88
+ "ReadRequest": {
89
+ "type": "object",
90
+ "properties": {
91
+ "limit": {
92
+ "description": "Defaults to 20.",
93
+ "type": "integer",
94
+ "minimum": 1,
95
+ "maximum": 100
96
+ },
97
+ "cursor": {
98
+ "type": "string",
99
+ "minLength": 1,
100
+ "maxLength": 512,
101
+ "pattern": "^[A-Za-z0-9_-]+$"
102
+ }
103
+ },
104
+ "additionalProperties": false,
105
+ "title": "Read request"
106
+ },
107
+ "ReadResponse": {
108
+ "type": "object",
109
+ "properties": {
110
+ "data": {
111
+ "maxItems": 100,
112
+ "type": "array",
113
+ "items": {
114
+ "type": "object",
115
+ "properties": {
116
+ "id": {
117
+ "type": "string",
118
+ "pattern": "^sub_[0-9A-HJKMNP-TV-Z]{26}$"
119
+ },
120
+ "created_at": {
121
+ "type": "string",
122
+ "format": "date-time",
123
+ "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"
124
+ },
125
+ "data": {
126
+ "type": "object",
127
+ "propertyNames": {
128
+ "type": "string",
129
+ "maxLength": 40
130
+ },
131
+ "additionalProperties": {},
132
+ "maxProperties": 50
133
+ }
134
+ },
135
+ "required": [
136
+ "id",
137
+ "created_at",
138
+ "data"
139
+ ],
140
+ "additionalProperties": false
141
+ }
142
+ },
143
+ "next_cursor": {
144
+ "anyOf": [
145
+ {
146
+ "type": "string",
147
+ "minLength": 1,
148
+ "maxLength": 512,
149
+ "pattern": "^[A-Za-z0-9_-]+$"
150
+ },
151
+ {
152
+ "type": "null"
153
+ }
154
+ ]
155
+ },
156
+ "has_more": {
157
+ "type": "boolean"
158
+ }
159
+ },
160
+ "required": [
161
+ "data",
162
+ "next_cursor",
163
+ "has_more"
164
+ ],
165
+ "additionalProperties": false,
166
+ "title": "Read response"
167
+ },
168
+ "TagName": {
169
+ "type": "string",
170
+ "minLength": 1,
171
+ "maxLength": 64,
172
+ "pattern": "^(?!taggor-)(?!(?:annotation-xml|color-profile|font-face|font-face-src|font-face-uri|font-face-format|font-face-name|missing-glyph)$)[a-z][a-z0-9]*(?:-[a-z0-9]+)+$"
173
+ },
174
+ "MemberName": {
175
+ "type": "string",
176
+ "minLength": 1,
177
+ "maxLength": 40,
178
+ "pattern": "^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$"
179
+ },
180
+ "SnakeName": {
181
+ "type": "string",
182
+ "minLength": 1,
183
+ "maxLength": 40,
184
+ "pattern": "^(?!(?:constructor|hasOwnProperty|isPrototypeOf|propertyIsEnumerable|toLocaleString|toString|valueOf)$)[a-z][a-z0-9]*(?:_[a-z0-9]+)*$"
185
+ },
186
+ "EnumValue": {
187
+ "type": "string",
188
+ "minLength": 1,
189
+ "maxLength": 64,
190
+ "pattern": "^[^\\u0000-\\u001f\\u007f]+$"
191
+ },
192
+ "TrackRequest": {
193
+ "type": "object",
194
+ "properties": {
195
+ "component": {
196
+ "$ref": "#/$defs/TagName"
197
+ },
198
+ "name": {
199
+ "$ref": "#/$defs/MemberName"
200
+ },
201
+ "props": {
202
+ "type": "object",
203
+ "propertyNames": {
204
+ "$ref": "#/$defs/SnakeName"
205
+ },
206
+ "additionalProperties": {
207
+ "anyOf": [
208
+ {
209
+ "type": "number"
210
+ },
211
+ {
212
+ "type": "boolean"
213
+ },
214
+ {
215
+ "$ref": "#/$defs/EnumValue"
216
+ }
217
+ ]
218
+ },
219
+ "maxProperties": 8
220
+ }
221
+ },
222
+ "required": [
223
+ "component",
224
+ "name"
225
+ ],
226
+ "additionalProperties": false,
227
+ "title": "Track request"
228
+ },
229
+ "DataError": {
230
+ "type": "object",
231
+ "properties": {
232
+ "code": {
233
+ "type": "string",
234
+ "enum": [
235
+ "validation_failed",
236
+ "collection_not_found",
237
+ "read_not_allowed",
238
+ "event_not_declared",
239
+ "origin_not_allowed",
240
+ "rate_limited",
241
+ "captcha_failed",
242
+ "payload_too_large",
243
+ "consent_required",
244
+ "daily_cap_reached"
245
+ ]
246
+ },
247
+ "message": {
248
+ "type": "string",
249
+ "maxLength": 500
250
+ },
251
+ "fields": {
252
+ "maxItems": 50,
253
+ "type": "array",
254
+ "items": {
255
+ "type": "object",
256
+ "properties": {
257
+ "path": {
258
+ "type": "string",
259
+ "maxLength": 160
260
+ },
261
+ "message": {
262
+ "type": "string",
263
+ "maxLength": 500
264
+ }
265
+ },
266
+ "required": [
267
+ "path",
268
+ "message"
269
+ ],
270
+ "additionalProperties": false
271
+ }
272
+ }
273
+ },
274
+ "required": [
275
+ "code",
276
+ "message"
277
+ ],
278
+ "additionalProperties": false,
279
+ "title": "Data API error"
280
+ }
281
+ }
282
+ }
@@ -0,0 +1,68 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://taggor.dev/schema/library-manifest/v1.json",
4
+ "$ref": "#/$defs/LibraryManifest",
5
+ "$defs": {
6
+ "LibraryManifest": {
7
+ "type": "object",
8
+ "properties": {
9
+ "name": {
10
+ "$ref": "#/$defs/LibraryName"
11
+ },
12
+ "version": {
13
+ "type": "string",
14
+ "maxLength": 256,
15
+ "pattern": "^(?:0|[1-9][0-9]{0,14})\\.(?:0|[1-9][0-9]{0,14})\\.(?:0|[1-9][0-9]{0,14})(?:-(?:0|[1-9][0-9]*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*)(?:\\.(?:0|[1-9][0-9]*|[0-9A-Za-z-]*[A-Za-z-][0-9A-Za-z-]*))*)?(?:\\+[0-9A-Za-z-]+(?:\\.[0-9A-Za-z-]+)*)?$",
16
+ "description": "An exact semantic version; prereleases are allowed."
17
+ },
18
+ "exports": {
19
+ "type": "object",
20
+ "propertyNames": {
21
+ "type": "string",
22
+ "maxLength": 128,
23
+ "pattern": "^(?:\\.|\\.\\/[A-Za-z0-9_-][A-Za-z0-9._-]{0,63}(?:\\/[A-Za-z0-9_-][A-Za-z0-9._-]{0,63})*)$",
24
+ "description": "A package export such as . or ./button."
25
+ },
26
+ "additionalProperties": {
27
+ "type": "string",
28
+ "maxLength": 200,
29
+ "pattern": "^src\\/(?:[A-Za-z0-9_-][A-Za-z0-9._-]*\\/)*[A-Za-z0-9_-][A-Za-z0-9._-]*\\.(?:m?js|tsx?)$",
30
+ "description": "A source file path relative to the library package, under src/."
31
+ },
32
+ "minProperties": 1,
33
+ "maxProperties": 50
34
+ },
35
+ "peerDependencies": {
36
+ "type": "object",
37
+ "propertyNames": {
38
+ "$ref": "#/$defs/LibraryPeerPackageName"
39
+ },
40
+ "additionalProperties": {
41
+ "type": "string",
42
+ "maxLength": 256,
43
+ "description": "A supported npm semver range, for example ^1.2.0."
44
+ },
45
+ "maxProperties": 30
46
+ }
47
+ },
48
+ "required": [
49
+ "name",
50
+ "version",
51
+ "exports"
52
+ ],
53
+ "additionalProperties": false,
54
+ "title": "Taggor workspace library manifest v1",
55
+ "description": "Declarative package metadata for an immutable workspace library. Ownership is resolved by the API and builder, not by this document."
56
+ },
57
+ "LibraryName": {
58
+ "type": "string",
59
+ "maxLength": 100,
60
+ "pattern": "^@[a-z0-9][a-z0-9_-]{0,31}\\/[a-z0-9][a-z0-9._-]{0,63}$"
61
+ },
62
+ "LibraryPeerPackageName": {
63
+ "type": "string",
64
+ "maxLength": 100,
65
+ "pattern": "^(?:[a-z0-9][a-z0-9._-]{0,63}|@[a-z0-9][a-z0-9_-]{0,31}\\/[a-z0-9][a-z0-9._-]{0,63})$"
66
+ }
67
+ }
68
+ }
@@ -0,0 +1,56 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://taggor.dev/schema/taggor-config/v1.json",
4
+ "$ref": "#/$defs/SourcePackageConfig",
5
+ "$defs": {
6
+ "SourcePackageConfig": {
7
+ "type": "object",
8
+ "properties": {
9
+ "$schema": {
10
+ "type": "string",
11
+ "minLength": 1,
12
+ "maxLength": 2048,
13
+ "pattern": "^(?:(?!\\udb40\\udc00|\\udb40\\udc01|\\udb40\\udc02|\\udb40\\udc03|\\udb40\\udc04|\\udb40\\udc05|\\udb40\\udc06|\\udb40\\udc07|\\udb40\\udc08|\\udb40\\udc09|\\udb40\\udc0a|\\udb40\\udc0b|\\udb40\\udc0c|\\udb40\\udc0d|\\udb40\\udc0e|\\udb40\\udc0f|\\udb40\\udc10|\\udb40\\udc11|\\udb40\\udc12|\\udb40\\udc13|\\udb40\\udc14|\\udb40\\udc15|\\udb40\\udc16|\\udb40\\udc17|\\udb40\\udc18|\\udb40\\udc19|\\udb40\\udc1a|\\udb40\\udc1b|\\udb40\\udc1c|\\udb40\\udc1d|\\udb40\\udc1e|\\udb40\\udc1f|\\udb40\\udc20|\\udb40\\udc21|\\udb40\\udc22|\\udb40\\udc23|\\udb40\\udc24|\\udb40\\udc25|\\udb40\\udc26|\\udb40\\udc27|\\udb40\\udc28|\\udb40\\udc29|\\udb40\\udc2a|\\udb40\\udc2b|\\udb40\\udc2c|\\udb40\\udc2d|\\udb40\\udc2e|\\udb40\\udc2f|\\udb40\\udc30|\\udb40\\udc31|\\udb40\\udc32|\\udb40\\udc33|\\udb40\\udc34|\\udb40\\udc35|\\udb40\\udc36|\\udb40\\udc37|\\udb40\\udc38|\\udb40\\udc39|\\udb40\\udc3a|\\udb40\\udc3b|\\udb40\\udc3c|\\udb40\\udc3d|\\udb40\\udc3e|\\udb40\\udc3f|\\udb40\\udc40|\\udb40\\udc41|\\udb40\\udc42|\\udb40\\udc43|\\udb40\\udc44|\\udb40\\udc45|\\udb40\\udc46|\\udb40\\udc47|\\udb40\\udc48|\\udb40\\udc49|\\udb40\\udc4a|\\udb40\\udc4b|\\udb40\\udc4c|\\udb40\\udc4d|\\udb40\\udc4e|\\udb40\\udc4f|\\udb40\\udc50|\\udb40\\udc51|\\udb40\\udc52|\\udb40\\udc53|\\udb40\\udc54|\\udb40\\udc55|\\udb40\\udc56|\\udb40\\udc57|\\udb40\\udc58|\\udb40\\udc59|\\udb40\\udc5a|\\udb40\\udc5b|\\udb40\\udc5c|\\udb40\\udc5d|\\udb40\\udc5e|\\udb40\\udc5f|\\udb40\\udc60|\\udb40\\udc61|\\udb40\\udc62|\\udb40\\udc63|\\udb40\\udc64|\\udb40\\udc65|\\udb40\\udc66|\\udb40\\udc67|\\udb40\\udc68|\\udb40\\udc69|\\udb40\\udc6a|\\udb40\\udc6b|\\udb40\\udc6c|\\udb40\\udc6d|\\udb40\\udc6e|\\udb40\\udc6f|\\udb40\\udc70|\\udb40\\udc71|\\udb40\\udc72|\\udb40\\udc73|\\udb40\\udc74|\\udb40\\udc75|\\udb40\\udc76|\\udb40\\udc77|\\udb40\\udc78|\\udb40\\udc79|\\udb40\\udc7a|\\udb40\\udc7b|\\udb40\\udc7c|\\udb40\\udc7d|\\udb40\\udc7e|\\udb40\\udc7f)(?:[^\\u0000-\\u0008\\u000a-\\u001f\\u007f-\\u009f\\u00ad\\u034f\\u061c\\u115f\\u1160\\u17b4\\u17b5\\u180e\\u200b\\u200e\\u200f\\u2028\\u2029\\u202a-\\u202e\\u2060-\\u2064\\u2066-\\u206f\\u3164\\ufeff\\uffa0\\ufff9-\\ufffb\\ud800-\\udfff]|[\\ud800-\\udbff][\\udc00-\\udfff]))*$"
14
+ },
15
+ "entry": {
16
+ "type": "string",
17
+ "maxLength": 200,
18
+ "pattern": "^src\\/(?:(?!\\.\\.?\\/)[A-Za-z0-9._-]+\\/)*[A-Za-z0-9._-]+\\.(?:tsx|ts|jsx|js)$"
19
+ },
20
+ "components": {
21
+ "maxItems": 100,
22
+ "type": "array",
23
+ "items": {
24
+ "type": "object",
25
+ "properties": {
26
+ "name": {
27
+ "type": "string",
28
+ "minLength": 1,
29
+ "maxLength": 64
30
+ },
31
+ "path": {
32
+ "type": "string",
33
+ "minLength": 1,
34
+ "maxLength": 200
35
+ }
36
+ },
37
+ "required": [
38
+ "name",
39
+ "path"
40
+ ],
41
+ "additionalProperties": false
42
+ }
43
+ },
44
+ "site_key": {
45
+ "type": "string",
46
+ "pattern": "^st_[a-z2-7]{10}$"
47
+ },
48
+ "workspace": {
49
+ "type": "string",
50
+ "pattern": "^[A-Za-z0-9][A-Za-z0-9_-]{0,63}$"
51
+ }
52
+ },
53
+ "additionalProperties": false
54
+ }
55
+ }
56
+ }