@hypercerts-org/lexicon 0.8.0-beta.0 → 0.10.0-beta.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.
- package/README.md +249 -180
- package/README.md.orig +267 -0
- package/lexicons/app/certified/badge/award.json +36 -0
- package/lexicons/app/certified/badge/definition.json +53 -0
- package/lexicons/app/certified/badge/response.json +36 -0
- package/lexicons/app/certified/defs.json +4 -16
- package/lexicons/app/certified/location.json +5 -8
- package/lexicons/com/atproto/repo/strongRef.json +1 -1
- package/lexicons/org/hypercerts/claim/activity.json +135 -0
- package/lexicons/org/hypercerts/claim/collection.json +54 -0
- package/lexicons/org/hypercerts/claim/contribution.json +4 -11
- package/lexicons/org/hypercerts/claim/evaluation.json +50 -9
- package/lexicons/org/hypercerts/claim/evidence.json +29 -16
- package/lexicons/org/hypercerts/claim/measurement.json +18 -8
- package/lexicons/org/hypercerts/claim/project.json +64 -0
- package/lexicons/org/hypercerts/claim/rights.json +16 -3
- package/lexicons/org/hypercerts/defs.json +71 -0
- package/lexicons/org/hypercerts/funding/receipt.json +66 -0
- package/package.json +31 -38
- package/types/index.ts +1257 -0
- package/types/lexicons.ts +1071 -0
- package/types/types/app/certified/badge/award.ts +48 -0
- package/types/types/app/certified/badge/definition.ts +49 -0
- package/types/types/app/certified/badge/response.ts +44 -0
- package/types/types/app/certified/defs.ts +14 -0
- package/types/types/app/certified/location.ts +49 -0
- package/types/types/com/atproto/repo/strongRef.ts +31 -0
- package/types/types/org/hypercerts/claim/activity.ts +99 -0
- package/types/types/org/hypercerts/claim/collection.ts +49 -0
- package/types/types/org/hypercerts/claim/contribution.ts +48 -0
- package/types/types/org/hypercerts/claim/evaluation.ts +77 -0
- package/types/types/org/hypercerts/claim/evidence.ts +53 -0
- package/types/types/org/hypercerts/claim/measurement.ts +54 -0
- package/types/types/org/hypercerts/claim/project.ts +53 -0
- package/types/types/org/hypercerts/claim/rights.ts +49 -0
- package/types/types/org/hypercerts/defs.ts +96 -0
- package/types/types/org/hypercerts/funding/receipt.ts +58 -0
- package/types/util.ts +82 -0
- package/dist/index.cjs +0 -1472
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.ts +0 -2094
- package/dist/index.mjs +0 -1441
- package/dist/index.mjs.map +0 -1
- package/lexicons/org/hypercerts/claim.json +0 -95
- package/lexicons/org/hypercerts/collection.json +0 -62
package/dist/index.cjs
DELETED
|
@@ -1,1472 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var lexicon$a = require('@atproto/lexicon');
|
|
4
|
-
|
|
5
|
-
var lexicon$9 = 1;
|
|
6
|
-
var id$i = "app.certified.defs";
|
|
7
|
-
var defs$a = {
|
|
8
|
-
uri: {
|
|
9
|
-
type: "string",
|
|
10
|
-
format: "uri",
|
|
11
|
-
maxGraphemes: 1000,
|
|
12
|
-
description: "URI to external data"
|
|
13
|
-
},
|
|
14
|
-
smallBlob: {
|
|
15
|
-
type: "blob",
|
|
16
|
-
accept: [
|
|
17
|
-
"*/*"
|
|
18
|
-
],
|
|
19
|
-
maxSize: 10485760,
|
|
20
|
-
description: "Blob to external data (up to 10MB)"
|
|
21
|
-
},
|
|
22
|
-
largeBlob: {
|
|
23
|
-
type: "blob",
|
|
24
|
-
accept: [
|
|
25
|
-
"*/*"
|
|
26
|
-
],
|
|
27
|
-
maxSize: 104857600,
|
|
28
|
-
description: "Blob to external data (up to 100MB)"
|
|
29
|
-
}
|
|
30
|
-
};
|
|
31
|
-
var defsLexicon = {
|
|
32
|
-
lexicon: lexicon$9,
|
|
33
|
-
id: id$i,
|
|
34
|
-
defs: defs$a
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
var lexicon$8 = 1;
|
|
38
|
-
var id$h = "app.certified.location";
|
|
39
|
-
var defs$9 = {
|
|
40
|
-
main: {
|
|
41
|
-
type: "record",
|
|
42
|
-
description: "A location reference",
|
|
43
|
-
key: "any",
|
|
44
|
-
record: {
|
|
45
|
-
type: "object",
|
|
46
|
-
required: [
|
|
47
|
-
"lpVersion",
|
|
48
|
-
"srs",
|
|
49
|
-
"locationType",
|
|
50
|
-
"location",
|
|
51
|
-
"createdAt"
|
|
52
|
-
],
|
|
53
|
-
properties: {
|
|
54
|
-
lpVersion: {
|
|
55
|
-
type: "string",
|
|
56
|
-
description: "The version of the Location Protocol",
|
|
57
|
-
maxLength: 10
|
|
58
|
-
},
|
|
59
|
-
srs: {
|
|
60
|
-
type: "string",
|
|
61
|
-
format: "uri",
|
|
62
|
-
description: "The Spatial Reference System URI (e.g., http://www.opengis.net/def/crs/OGC/1.3/CRS84) that defines the coordinate system.",
|
|
63
|
-
maxLength: 100
|
|
64
|
-
},
|
|
65
|
-
locationType: {
|
|
66
|
-
type: "string",
|
|
67
|
-
description: "An identifier for the format of the location data (e.g., coordinate-decimal, geojson-point)",
|
|
68
|
-
knownValues: [
|
|
69
|
-
"coordinate-decimal",
|
|
70
|
-
"geojson-point"
|
|
71
|
-
],
|
|
72
|
-
maxLength: 20
|
|
73
|
-
},
|
|
74
|
-
location: {
|
|
75
|
-
type: "union",
|
|
76
|
-
refs: [
|
|
77
|
-
"app.certified.defs#uri",
|
|
78
|
-
"app.certified.defs#smallBlob"
|
|
79
|
-
],
|
|
80
|
-
description: "The location of where the work was performed as a URI or blob."
|
|
81
|
-
},
|
|
82
|
-
name: {
|
|
83
|
-
type: "string",
|
|
84
|
-
description: "Optional name for this location",
|
|
85
|
-
maxLength: 1000,
|
|
86
|
-
maxGraphemes: 100
|
|
87
|
-
},
|
|
88
|
-
description: {
|
|
89
|
-
type: "string",
|
|
90
|
-
description: "Optional description for this location",
|
|
91
|
-
maxLength: 2000,
|
|
92
|
-
maxGraphemes: 500
|
|
93
|
-
},
|
|
94
|
-
createdAt: {
|
|
95
|
-
type: "string",
|
|
96
|
-
format: "datetime",
|
|
97
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
};
|
|
103
|
-
var locationLexicon = {
|
|
104
|
-
lexicon: lexicon$8,
|
|
105
|
-
id: id$h,
|
|
106
|
-
defs: defs$9
|
|
107
|
-
};
|
|
108
|
-
|
|
109
|
-
var lexicon$7 = 1;
|
|
110
|
-
var id$g = "org.hypercerts.claim";
|
|
111
|
-
var defs$8 = {
|
|
112
|
-
main: {
|
|
113
|
-
type: "record",
|
|
114
|
-
description: "A hypercert record tracking impact work.",
|
|
115
|
-
key: "any",
|
|
116
|
-
record: {
|
|
117
|
-
type: "object",
|
|
118
|
-
required: [
|
|
119
|
-
"title",
|
|
120
|
-
"shortDescription",
|
|
121
|
-
"createdAt",
|
|
122
|
-
"workScope",
|
|
123
|
-
"workTimeFrameFrom",
|
|
124
|
-
"workTimeFrameTo"
|
|
125
|
-
],
|
|
126
|
-
properties: {
|
|
127
|
-
title: {
|
|
128
|
-
type: "string",
|
|
129
|
-
description: "Title of the hypercert",
|
|
130
|
-
maxLength: 256
|
|
131
|
-
},
|
|
132
|
-
shortDescription: {
|
|
133
|
-
type: "string",
|
|
134
|
-
description: "Short blurb of the impact work done.",
|
|
135
|
-
maxLength: 3000,
|
|
136
|
-
maxGraphemes: 300
|
|
137
|
-
},
|
|
138
|
-
description: {
|
|
139
|
-
type: "string",
|
|
140
|
-
description: "Optional longer description of the impact work done.",
|
|
141
|
-
maxLength: 30000,
|
|
142
|
-
maxGraphemes: 3000
|
|
143
|
-
},
|
|
144
|
-
image: {
|
|
145
|
-
type: "union",
|
|
146
|
-
refs: [
|
|
147
|
-
"app.certified.defs#uri",
|
|
148
|
-
"app.certified.defs#smallBlob"
|
|
149
|
-
],
|
|
150
|
-
description: "The hypercert visual representation as a URI or blob"
|
|
151
|
-
},
|
|
152
|
-
workScope: {
|
|
153
|
-
type: "string",
|
|
154
|
-
description: "Scope of the work performed",
|
|
155
|
-
maxLength: 5000,
|
|
156
|
-
maxGraphemes: 1000
|
|
157
|
-
},
|
|
158
|
-
workTimeFrameFrom: {
|
|
159
|
-
type: "string",
|
|
160
|
-
format: "datetime",
|
|
161
|
-
description: "When the work began"
|
|
162
|
-
},
|
|
163
|
-
workTimeFrameTo: {
|
|
164
|
-
type: "string",
|
|
165
|
-
format: "datetime",
|
|
166
|
-
description: "When the work ended"
|
|
167
|
-
},
|
|
168
|
-
evidence: {
|
|
169
|
-
type: "array",
|
|
170
|
-
description: "Supporting evidence, documentation, or external data URIs",
|
|
171
|
-
items: {
|
|
172
|
-
type: "ref",
|
|
173
|
-
ref: "com.atproto.repo.strongRef",
|
|
174
|
-
description: "A strong reference to the evidence that supports this impact claim. The record referenced must conform with the org.hypercerts.claim.evidence lexicon"
|
|
175
|
-
},
|
|
176
|
-
maxLength: 100
|
|
177
|
-
},
|
|
178
|
-
contributions: {
|
|
179
|
-
type: "array",
|
|
180
|
-
description: "A strong reference to the contributions done to create the impact in the hypercerts. The record referenced must conform with the lexicon org.hypercerts.claim.contributions",
|
|
181
|
-
items: {
|
|
182
|
-
type: "ref",
|
|
183
|
-
ref: "com.atproto.repo.strongRef"
|
|
184
|
-
}
|
|
185
|
-
},
|
|
186
|
-
rights: {
|
|
187
|
-
type: "ref",
|
|
188
|
-
ref: "com.atproto.repo.strongRef",
|
|
189
|
-
description: "A strong reference to the rights that this hypercert has. The record referenced must conform with the lexicon org.hypercerts.claim.rights"
|
|
190
|
-
},
|
|
191
|
-
location: {
|
|
192
|
-
type: "ref",
|
|
193
|
-
ref: "com.atproto.repo.strongRef",
|
|
194
|
-
description: "A strong reference to the location where the work for done hypercert was located. The record referenced must conform with the lexicon org.hypercerts.claim.location"
|
|
195
|
-
},
|
|
196
|
-
createdAt: {
|
|
197
|
-
type: "string",
|
|
198
|
-
format: "datetime",
|
|
199
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
};
|
|
205
|
-
var claimLexicon = {
|
|
206
|
-
lexicon: lexicon$7,
|
|
207
|
-
id: id$g,
|
|
208
|
-
defs: defs$8
|
|
209
|
-
};
|
|
210
|
-
|
|
211
|
-
var lexicon$6 = 1;
|
|
212
|
-
var id$f = "org.hypercerts.claim.contribution";
|
|
213
|
-
var defs$7 = {
|
|
214
|
-
main: {
|
|
215
|
-
type: "record",
|
|
216
|
-
description: "A contribution made toward a hypercert's impact.",
|
|
217
|
-
key: "any",
|
|
218
|
-
record: {
|
|
219
|
-
type: "object",
|
|
220
|
-
required: [
|
|
221
|
-
"hypercert",
|
|
222
|
-
"contributors",
|
|
223
|
-
"createdAt"
|
|
224
|
-
],
|
|
225
|
-
properties: {
|
|
226
|
-
hypercert: {
|
|
227
|
-
type: "ref",
|
|
228
|
-
ref: "com.atproto.repo.strongRef",
|
|
229
|
-
description: "A strong reference to the hypercert this contribution is for. The record referenced must conform with the lexicon org.hypercerts.claim."
|
|
230
|
-
},
|
|
231
|
-
role: {
|
|
232
|
-
type: "string",
|
|
233
|
-
description: "Role or title of the contributor(s).",
|
|
234
|
-
maxLength: 100
|
|
235
|
-
},
|
|
236
|
-
contributors: {
|
|
237
|
-
type: "array",
|
|
238
|
-
description: "List of the contributors (names, pseudonyms, or DIDs). If multiple contributors are stored in the same hypercertContribution, then they would have the exact same role.",
|
|
239
|
-
items: {
|
|
240
|
-
type: "string"
|
|
241
|
-
}
|
|
242
|
-
},
|
|
243
|
-
description: {
|
|
244
|
-
type: "string",
|
|
245
|
-
description: "What the contribution concretely achieved",
|
|
246
|
-
maxLength: 2000,
|
|
247
|
-
maxGraphemes: 500
|
|
248
|
-
},
|
|
249
|
-
workTimeframeFrom: {
|
|
250
|
-
type: "string",
|
|
251
|
-
format: "datetime",
|
|
252
|
-
description: "When this contribution started. This should be a subset of the hypercert timeframe."
|
|
253
|
-
},
|
|
254
|
-
workTimeframeTo: {
|
|
255
|
-
type: "string",
|
|
256
|
-
format: "datetime",
|
|
257
|
-
description: "When this contribution finished. This should be a subset of the hypercert timeframe."
|
|
258
|
-
},
|
|
259
|
-
createdAt: {
|
|
260
|
-
type: "string",
|
|
261
|
-
format: "datetime",
|
|
262
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
263
|
-
}
|
|
264
|
-
}
|
|
265
|
-
}
|
|
266
|
-
}
|
|
267
|
-
};
|
|
268
|
-
var contributionLexicon = {
|
|
269
|
-
lexicon: lexicon$6,
|
|
270
|
-
id: id$f,
|
|
271
|
-
defs: defs$7
|
|
272
|
-
};
|
|
273
|
-
|
|
274
|
-
var lexicon$5 = 1;
|
|
275
|
-
var id$e = "org.hypercerts.claim.evaluation";
|
|
276
|
-
var defs$6 = {
|
|
277
|
-
main: {
|
|
278
|
-
type: "record",
|
|
279
|
-
description: "An evaluation of a hypercert or other claim",
|
|
280
|
-
key: "tid",
|
|
281
|
-
record: {
|
|
282
|
-
type: "object",
|
|
283
|
-
required: [
|
|
284
|
-
"subject",
|
|
285
|
-
"evaluators",
|
|
286
|
-
"summary",
|
|
287
|
-
"createdAt"
|
|
288
|
-
],
|
|
289
|
-
properties: {
|
|
290
|
-
subject: {
|
|
291
|
-
type: "ref",
|
|
292
|
-
ref: "com.atproto.repo.strongRef",
|
|
293
|
-
description: "A strong reference to the evaluated claim. (e.g measurement, hypercert, contribution, etc)"
|
|
294
|
-
},
|
|
295
|
-
evaluators: {
|
|
296
|
-
type: "array",
|
|
297
|
-
description: "DIDs of the evaluators",
|
|
298
|
-
items: {
|
|
299
|
-
type: "string",
|
|
300
|
-
format: "did"
|
|
301
|
-
},
|
|
302
|
-
maxLength: 100
|
|
303
|
-
},
|
|
304
|
-
evaluations: {
|
|
305
|
-
type: "array",
|
|
306
|
-
description: "Evaluation data (URIs or blobs) containing detailed reports or methodology",
|
|
307
|
-
items: {
|
|
308
|
-
type: "union",
|
|
309
|
-
refs: [
|
|
310
|
-
"app.certified.defs#uri",
|
|
311
|
-
"app.certified.defs#smallBlob"
|
|
312
|
-
]
|
|
313
|
-
},
|
|
314
|
-
maxLength: 100
|
|
315
|
-
},
|
|
316
|
-
summary: {
|
|
317
|
-
type: "string",
|
|
318
|
-
description: "Brief evaluation summary",
|
|
319
|
-
maxLength: 5000,
|
|
320
|
-
maxGraphemes: 1000
|
|
321
|
-
},
|
|
322
|
-
createdAt: {
|
|
323
|
-
type: "string",
|
|
324
|
-
format: "datetime",
|
|
325
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
326
|
-
}
|
|
327
|
-
}
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
|
-
};
|
|
331
|
-
var evaluationLexicon = {
|
|
332
|
-
lexicon: lexicon$5,
|
|
333
|
-
id: id$e,
|
|
334
|
-
defs: defs$6
|
|
335
|
-
};
|
|
336
|
-
|
|
337
|
-
var lexicon$4 = 1;
|
|
338
|
-
var id$d = "org.hypercerts.claim.evidence";
|
|
339
|
-
var defs$5 = {
|
|
340
|
-
main: {
|
|
341
|
-
type: "record",
|
|
342
|
-
description: "A piece of evidence supporting a hypercert claim",
|
|
343
|
-
key: "any",
|
|
344
|
-
record: {
|
|
345
|
-
type: "object",
|
|
346
|
-
required: [
|
|
347
|
-
"content",
|
|
348
|
-
"shortDescription",
|
|
349
|
-
"createdAt"
|
|
350
|
-
],
|
|
351
|
-
properties: {
|
|
352
|
-
content: {
|
|
353
|
-
type: "union",
|
|
354
|
-
refs: [
|
|
355
|
-
"app.certified.defs#uri",
|
|
356
|
-
"app.certified.defs#smallBlob"
|
|
357
|
-
],
|
|
358
|
-
description: "A piece of evidence (URI or blobs) supporting a hypercert claim"
|
|
359
|
-
},
|
|
360
|
-
title: {
|
|
361
|
-
type: "string",
|
|
362
|
-
maxLength: 256,
|
|
363
|
-
description: "Optional title to describe the nature of the evidence"
|
|
364
|
-
},
|
|
365
|
-
shortDescription: {
|
|
366
|
-
type: "string",
|
|
367
|
-
maxLength: 3000,
|
|
368
|
-
maxGraphemes: 300,
|
|
369
|
-
description: "Short description explaining what this evidence demonstrates or proves"
|
|
370
|
-
},
|
|
371
|
-
description: {
|
|
372
|
-
type: "string",
|
|
373
|
-
description: "Optional longer description describing the impact claim evidence.",
|
|
374
|
-
maxLength: 30000,
|
|
375
|
-
maxGraphemes: 3000
|
|
376
|
-
},
|
|
377
|
-
createdAt: {
|
|
378
|
-
type: "string",
|
|
379
|
-
format: "datetime",
|
|
380
|
-
description: "Client-declared timestamp when this hypercert claim was originally created"
|
|
381
|
-
}
|
|
382
|
-
}
|
|
383
|
-
}
|
|
384
|
-
}
|
|
385
|
-
};
|
|
386
|
-
var evidenceLexicon = {
|
|
387
|
-
lexicon: lexicon$4,
|
|
388
|
-
id: id$d,
|
|
389
|
-
defs: defs$5
|
|
390
|
-
};
|
|
391
|
-
|
|
392
|
-
var lexicon$3 = 1;
|
|
393
|
-
var id$c = "org.hypercerts.claim.measurement";
|
|
394
|
-
var defs$4 = {
|
|
395
|
-
main: {
|
|
396
|
-
type: "record",
|
|
397
|
-
description: "External measurement data supporting a hypercert claim",
|
|
398
|
-
key: "tid",
|
|
399
|
-
record: {
|
|
400
|
-
type: "object",
|
|
401
|
-
required: [
|
|
402
|
-
"hypercert",
|
|
403
|
-
"measurers",
|
|
404
|
-
"metric",
|
|
405
|
-
"value",
|
|
406
|
-
"createdAt"
|
|
407
|
-
],
|
|
408
|
-
properties: {
|
|
409
|
-
hypercert: {
|
|
410
|
-
type: "ref",
|
|
411
|
-
ref: "com.atproto.repo.strongRef",
|
|
412
|
-
description: "A strong reference to the hypercert that this measurement is for. The record referenced must conform with the lexicon org.hypercerts.claim."
|
|
413
|
-
},
|
|
414
|
-
measurers: {
|
|
415
|
-
type: "array",
|
|
416
|
-
description: "DIDs of the entity (or entities) that measured this data",
|
|
417
|
-
items: {
|
|
418
|
-
type: "string",
|
|
419
|
-
format: "did"
|
|
420
|
-
},
|
|
421
|
-
maxLength: 100
|
|
422
|
-
},
|
|
423
|
-
metric: {
|
|
424
|
-
type: "string",
|
|
425
|
-
description: "The metric being measured",
|
|
426
|
-
maxLength: 500
|
|
427
|
-
},
|
|
428
|
-
value: {
|
|
429
|
-
type: "string",
|
|
430
|
-
description: "The measured value",
|
|
431
|
-
maxLength: 500
|
|
432
|
-
},
|
|
433
|
-
measurementMethodURI: {
|
|
434
|
-
type: "string",
|
|
435
|
-
format: "uri",
|
|
436
|
-
description: "URI to methodology documentation, standard protocol, or measurement procedure"
|
|
437
|
-
},
|
|
438
|
-
evidenceURI: {
|
|
439
|
-
type: "array",
|
|
440
|
-
description: "URIs to supporting evidence or data",
|
|
441
|
-
items: {
|
|
442
|
-
type: "string",
|
|
443
|
-
format: "uri"
|
|
444
|
-
},
|
|
445
|
-
maxLength: 50
|
|
446
|
-
},
|
|
447
|
-
createdAt: {
|
|
448
|
-
type: "string",
|
|
449
|
-
format: "datetime",
|
|
450
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
451
|
-
}
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
}
|
|
455
|
-
};
|
|
456
|
-
var measurementLexicon = {
|
|
457
|
-
lexicon: lexicon$3,
|
|
458
|
-
id: id$c,
|
|
459
|
-
defs: defs$4
|
|
460
|
-
};
|
|
461
|
-
|
|
462
|
-
var lexicon$2 = 1;
|
|
463
|
-
var id$b = "org.hypercerts.claim.rights";
|
|
464
|
-
var defs$3 = {
|
|
465
|
-
main: {
|
|
466
|
-
type: "record",
|
|
467
|
-
description: "Describes the rights that a user has with a hypercert, such as whether it can be sold, transferred, and under what conditions.",
|
|
468
|
-
key: "any",
|
|
469
|
-
record: {
|
|
470
|
-
type: "object",
|
|
471
|
-
required: [
|
|
472
|
-
"rightsName",
|
|
473
|
-
"rightsType",
|
|
474
|
-
"rightsDescription",
|
|
475
|
-
"createdAt"
|
|
476
|
-
],
|
|
477
|
-
properties: {
|
|
478
|
-
rightsName: {
|
|
479
|
-
type: "string",
|
|
480
|
-
description: "Full name of the rights",
|
|
481
|
-
maxLength: 100
|
|
482
|
-
},
|
|
483
|
-
rightsType: {
|
|
484
|
-
type: "string",
|
|
485
|
-
description: "Short rights identifier for easier search",
|
|
486
|
-
maxLength: 10
|
|
487
|
-
},
|
|
488
|
-
rightsDescription: {
|
|
489
|
-
type: "string",
|
|
490
|
-
description: "Description of the rights of this hypercert"
|
|
491
|
-
},
|
|
492
|
-
createdAt: {
|
|
493
|
-
type: "string",
|
|
494
|
-
format: "datetime",
|
|
495
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
496
|
-
}
|
|
497
|
-
}
|
|
498
|
-
}
|
|
499
|
-
}
|
|
500
|
-
};
|
|
501
|
-
var rightsLexicon = {
|
|
502
|
-
lexicon: lexicon$2,
|
|
503
|
-
id: id$b,
|
|
504
|
-
defs: defs$3
|
|
505
|
-
};
|
|
506
|
-
|
|
507
|
-
var lexicon$1 = 1;
|
|
508
|
-
var id$a = "com.atproto.repo.strongRef";
|
|
509
|
-
var description = "A URI with a content-hash fingerprint.";
|
|
510
|
-
var defs$2 = {
|
|
511
|
-
main: {
|
|
512
|
-
type: "object",
|
|
513
|
-
required: [
|
|
514
|
-
"uri",
|
|
515
|
-
"cid"
|
|
516
|
-
],
|
|
517
|
-
properties: {
|
|
518
|
-
uri: {
|
|
519
|
-
type: "string",
|
|
520
|
-
format: "at-uri"
|
|
521
|
-
},
|
|
522
|
-
cid: {
|
|
523
|
-
type: "string",
|
|
524
|
-
format: "cid"
|
|
525
|
-
}
|
|
526
|
-
}
|
|
527
|
-
}
|
|
528
|
-
};
|
|
529
|
-
var strongRef$1 = {
|
|
530
|
-
lexicon: lexicon$1,
|
|
531
|
-
id: id$a,
|
|
532
|
-
description: description,
|
|
533
|
-
defs: defs$2
|
|
534
|
-
};
|
|
535
|
-
|
|
536
|
-
var lexicon = 1;
|
|
537
|
-
var id$9 = "org.hypercerts.collection";
|
|
538
|
-
var defs$1 = {
|
|
539
|
-
main: {
|
|
540
|
-
type: "record",
|
|
541
|
-
description: "A collection/group of hypercerts that have a specific property.",
|
|
542
|
-
key: "tid",
|
|
543
|
-
record: {
|
|
544
|
-
type: "object",
|
|
545
|
-
required: [
|
|
546
|
-
"title",
|
|
547
|
-
"claims",
|
|
548
|
-
"createdAt"
|
|
549
|
-
],
|
|
550
|
-
properties: {
|
|
551
|
-
title: {
|
|
552
|
-
type: "string",
|
|
553
|
-
description: "The title of this collection",
|
|
554
|
-
maxLength: 800,
|
|
555
|
-
maxGraphemes: 80
|
|
556
|
-
},
|
|
557
|
-
shortDescription: {
|
|
558
|
-
type: "string",
|
|
559
|
-
maxLength: 3000,
|
|
560
|
-
maxGraphemes: 300,
|
|
561
|
-
description: "A short description of this collection"
|
|
562
|
-
},
|
|
563
|
-
coverPhoto: {
|
|
564
|
-
type: "union",
|
|
565
|
-
refs: [
|
|
566
|
-
"app.certified.defs#uri",
|
|
567
|
-
"app.certified.defs#smallBlob"
|
|
568
|
-
],
|
|
569
|
-
description: "The cover photo of this collection (either in URI format or in a blob)."
|
|
570
|
-
},
|
|
571
|
-
claims: {
|
|
572
|
-
type: "array",
|
|
573
|
-
description: "Array of claims with their associated weights in this collection",
|
|
574
|
-
items: {
|
|
575
|
-
type: "ref",
|
|
576
|
-
ref: "#claimItem"
|
|
577
|
-
}
|
|
578
|
-
},
|
|
579
|
-
createdAt: {
|
|
580
|
-
type: "string",
|
|
581
|
-
format: "datetime",
|
|
582
|
-
description: "Client-declared timestamp when this record was originally created"
|
|
583
|
-
}
|
|
584
|
-
}
|
|
585
|
-
}
|
|
586
|
-
},
|
|
587
|
-
claimItem: {
|
|
588
|
-
type: "object",
|
|
589
|
-
required: [
|
|
590
|
-
"claim",
|
|
591
|
-
"weight"
|
|
592
|
-
],
|
|
593
|
-
properties: {
|
|
594
|
-
claim: {
|
|
595
|
-
type: "ref",
|
|
596
|
-
ref: "com.atproto.repo.strongRef",
|
|
597
|
-
description: "A strong reference to a hypercert claim record. This claim must conform to the lexicon org.hypercerts.claim.record"
|
|
598
|
-
},
|
|
599
|
-
weight: {
|
|
600
|
-
type: "string",
|
|
601
|
-
description: "The weight/importance of this hypercert claim in the collection (a percentage from 0-100, stored as a string to avoid float precision issues). The total claim weights should add up to 100."
|
|
602
|
-
}
|
|
603
|
-
}
|
|
604
|
-
}
|
|
605
|
-
};
|
|
606
|
-
var collectionLexicon = {
|
|
607
|
-
lexicon: lexicon,
|
|
608
|
-
id: id$9,
|
|
609
|
-
defs: defs$1
|
|
610
|
-
};
|
|
611
|
-
|
|
612
|
-
/**
|
|
613
|
-
* GENERATED CODE - DO NOT MODIFY
|
|
614
|
-
*/
|
|
615
|
-
function isObject(v) {
|
|
616
|
-
return v != null && typeof v === 'object';
|
|
617
|
-
}
|
|
618
|
-
function is$type($type, id, hash) {
|
|
619
|
-
return hash === 'main'
|
|
620
|
-
? $type === id
|
|
621
|
-
: // $type === `${id}#${hash}`
|
|
622
|
-
typeof $type === 'string' &&
|
|
623
|
-
$type.length === id.length + 1 + hash.length &&
|
|
624
|
-
$type.charCodeAt(id.length) === 35 /* '#' */ &&
|
|
625
|
-
$type.startsWith(id) &&
|
|
626
|
-
$type.endsWith(hash);
|
|
627
|
-
}
|
|
628
|
-
function is$typed$9(v, id, hash) {
|
|
629
|
-
return isObject(v) && '$type' in v && is$type(v.$type, id, hash);
|
|
630
|
-
}
|
|
631
|
-
function maybe$typed(v, id, hash) {
|
|
632
|
-
return (isObject(v) &&
|
|
633
|
-
('$type' in v ? v.$type === undefined || is$type(v.$type, id, hash) : true));
|
|
634
|
-
}
|
|
635
|
-
/**
|
|
636
|
-
* Utility function that allows to convert a "validate*" utility function into a
|
|
637
|
-
* type predicate.
|
|
638
|
-
*/
|
|
639
|
-
function asPredicate(validate) {
|
|
640
|
-
return function (v) {
|
|
641
|
-
return validate(v).success;
|
|
642
|
-
};
|
|
643
|
-
}
|
|
644
|
-
|
|
645
|
-
/**
|
|
646
|
-
* GENERATED CODE - DO NOT MODIFY
|
|
647
|
-
*/
|
|
648
|
-
const schemaDict = {
|
|
649
|
-
AppCertifiedDefs: {
|
|
650
|
-
lexicon: 1,
|
|
651
|
-
id: 'app.certified.defs',
|
|
652
|
-
defs: {
|
|
653
|
-
uri: {
|
|
654
|
-
type: 'string',
|
|
655
|
-
format: 'uri',
|
|
656
|
-
maxGraphemes: 1000,
|
|
657
|
-
description: 'URI to external data',
|
|
658
|
-
},
|
|
659
|
-
smallBlob: {
|
|
660
|
-
type: 'blob',
|
|
661
|
-
accept: ['*/*'],
|
|
662
|
-
maxSize: 10485760,
|
|
663
|
-
description: 'Blob to external data (up to 10MB)',
|
|
664
|
-
},
|
|
665
|
-
largeBlob: {
|
|
666
|
-
type: 'blob',
|
|
667
|
-
accept: ['*/*'],
|
|
668
|
-
maxSize: 104857600,
|
|
669
|
-
description: 'Blob to external data (up to 100MB)',
|
|
670
|
-
},
|
|
671
|
-
},
|
|
672
|
-
},
|
|
673
|
-
AppCertifiedLocation: {
|
|
674
|
-
lexicon: 1,
|
|
675
|
-
id: 'app.certified.location',
|
|
676
|
-
defs: {
|
|
677
|
-
main: {
|
|
678
|
-
type: 'record',
|
|
679
|
-
description: 'A location reference',
|
|
680
|
-
key: 'any',
|
|
681
|
-
record: {
|
|
682
|
-
type: 'object',
|
|
683
|
-
required: [
|
|
684
|
-
'lpVersion',
|
|
685
|
-
'srs',
|
|
686
|
-
'locationType',
|
|
687
|
-
'location',
|
|
688
|
-
'createdAt',
|
|
689
|
-
],
|
|
690
|
-
properties: {
|
|
691
|
-
lpVersion: {
|
|
692
|
-
type: 'string',
|
|
693
|
-
description: 'The version of the Location Protocol',
|
|
694
|
-
maxLength: 10,
|
|
695
|
-
},
|
|
696
|
-
srs: {
|
|
697
|
-
type: 'string',
|
|
698
|
-
format: 'uri',
|
|
699
|
-
description: 'The Spatial Reference System URI (e.g., http://www.opengis.net/def/crs/OGC/1.3/CRS84) that defines the coordinate system.',
|
|
700
|
-
maxLength: 100,
|
|
701
|
-
},
|
|
702
|
-
locationType: {
|
|
703
|
-
type: 'string',
|
|
704
|
-
description: 'An identifier for the format of the location data (e.g., coordinate-decimal, geojson-point)',
|
|
705
|
-
knownValues: ['coordinate-decimal', 'geojson-point'],
|
|
706
|
-
maxLength: 20,
|
|
707
|
-
},
|
|
708
|
-
location: {
|
|
709
|
-
type: 'union',
|
|
710
|
-
refs: [
|
|
711
|
-
'lex:app.certified.defs#uri',
|
|
712
|
-
'lex:app.certified.defs#smallBlob',
|
|
713
|
-
],
|
|
714
|
-
description: 'The location of where the work was performed as a URI or blob.',
|
|
715
|
-
},
|
|
716
|
-
name: {
|
|
717
|
-
type: 'string',
|
|
718
|
-
description: 'Optional name for this location',
|
|
719
|
-
maxLength: 1000,
|
|
720
|
-
maxGraphemes: 100,
|
|
721
|
-
},
|
|
722
|
-
description: {
|
|
723
|
-
type: 'string',
|
|
724
|
-
description: 'Optional description for this location',
|
|
725
|
-
maxLength: 2000,
|
|
726
|
-
maxGraphemes: 500,
|
|
727
|
-
},
|
|
728
|
-
createdAt: {
|
|
729
|
-
type: 'string',
|
|
730
|
-
format: 'datetime',
|
|
731
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
732
|
-
},
|
|
733
|
-
},
|
|
734
|
-
},
|
|
735
|
-
},
|
|
736
|
-
},
|
|
737
|
-
},
|
|
738
|
-
ComAtprotoRepoStrongRef: {
|
|
739
|
-
lexicon: 1,
|
|
740
|
-
id: 'com.atproto.repo.strongRef',
|
|
741
|
-
description: 'A URI with a content-hash fingerprint.',
|
|
742
|
-
defs: {
|
|
743
|
-
main: {
|
|
744
|
-
type: 'object',
|
|
745
|
-
required: ['uri', 'cid'],
|
|
746
|
-
properties: {
|
|
747
|
-
uri: {
|
|
748
|
-
type: 'string',
|
|
749
|
-
format: 'at-uri',
|
|
750
|
-
},
|
|
751
|
-
cid: {
|
|
752
|
-
type: 'string',
|
|
753
|
-
format: 'cid',
|
|
754
|
-
},
|
|
755
|
-
},
|
|
756
|
-
},
|
|
757
|
-
},
|
|
758
|
-
},
|
|
759
|
-
OrgHypercertsClaim: {
|
|
760
|
-
lexicon: 1,
|
|
761
|
-
id: 'org.hypercerts.claim',
|
|
762
|
-
defs: {
|
|
763
|
-
main: {
|
|
764
|
-
type: 'record',
|
|
765
|
-
description: 'A hypercert record tracking impact work.',
|
|
766
|
-
key: 'any',
|
|
767
|
-
record: {
|
|
768
|
-
type: 'object',
|
|
769
|
-
required: [
|
|
770
|
-
'title',
|
|
771
|
-
'shortDescription',
|
|
772
|
-
'createdAt',
|
|
773
|
-
'workScope',
|
|
774
|
-
'workTimeFrameFrom',
|
|
775
|
-
'workTimeFrameTo',
|
|
776
|
-
],
|
|
777
|
-
properties: {
|
|
778
|
-
title: {
|
|
779
|
-
type: 'string',
|
|
780
|
-
description: 'Title of the hypercert',
|
|
781
|
-
maxLength: 256,
|
|
782
|
-
},
|
|
783
|
-
shortDescription: {
|
|
784
|
-
type: 'string',
|
|
785
|
-
description: 'Short blurb of the impact work done.',
|
|
786
|
-
maxLength: 3000,
|
|
787
|
-
maxGraphemes: 300,
|
|
788
|
-
},
|
|
789
|
-
description: {
|
|
790
|
-
type: 'string',
|
|
791
|
-
description: 'Optional longer description of the impact work done.',
|
|
792
|
-
maxLength: 30000,
|
|
793
|
-
maxGraphemes: 3000,
|
|
794
|
-
},
|
|
795
|
-
image: {
|
|
796
|
-
type: 'union',
|
|
797
|
-
refs: [
|
|
798
|
-
'lex:app.certified.defs#uri',
|
|
799
|
-
'lex:app.certified.defs#smallBlob',
|
|
800
|
-
],
|
|
801
|
-
description: 'The hypercert visual representation as a URI or blob',
|
|
802
|
-
},
|
|
803
|
-
workScope: {
|
|
804
|
-
type: 'string',
|
|
805
|
-
description: 'Scope of the work performed',
|
|
806
|
-
maxLength: 5000,
|
|
807
|
-
maxGraphemes: 1000,
|
|
808
|
-
},
|
|
809
|
-
workTimeFrameFrom: {
|
|
810
|
-
type: 'string',
|
|
811
|
-
format: 'datetime',
|
|
812
|
-
description: 'When the work began',
|
|
813
|
-
},
|
|
814
|
-
workTimeFrameTo: {
|
|
815
|
-
type: 'string',
|
|
816
|
-
format: 'datetime',
|
|
817
|
-
description: 'When the work ended',
|
|
818
|
-
},
|
|
819
|
-
evidence: {
|
|
820
|
-
type: 'array',
|
|
821
|
-
description: 'Supporting evidence, documentation, or external data URIs',
|
|
822
|
-
items: {
|
|
823
|
-
type: 'ref',
|
|
824
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
825
|
-
description: 'A strong reference to the evidence that supports this impact claim. The record referenced must conform with the org.hypercerts.claim.evidence lexicon',
|
|
826
|
-
},
|
|
827
|
-
maxLength: 100,
|
|
828
|
-
},
|
|
829
|
-
contributions: {
|
|
830
|
-
type: 'array',
|
|
831
|
-
description: 'A strong reference to the contributions done to create the impact in the hypercerts. The record referenced must conform with the lexicon org.hypercerts.claim.contributions',
|
|
832
|
-
items: {
|
|
833
|
-
type: 'ref',
|
|
834
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
835
|
-
},
|
|
836
|
-
},
|
|
837
|
-
rights: {
|
|
838
|
-
type: 'ref',
|
|
839
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
840
|
-
description: 'A strong reference to the rights that this hypercert has. The record referenced must conform with the lexicon org.hypercerts.claim.rights',
|
|
841
|
-
},
|
|
842
|
-
location: {
|
|
843
|
-
type: 'ref',
|
|
844
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
845
|
-
description: 'A strong reference to the location where the work for done hypercert was located. The record referenced must conform with the lexicon org.hypercerts.claim.location',
|
|
846
|
-
},
|
|
847
|
-
createdAt: {
|
|
848
|
-
type: 'string',
|
|
849
|
-
format: 'datetime',
|
|
850
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
851
|
-
},
|
|
852
|
-
},
|
|
853
|
-
},
|
|
854
|
-
},
|
|
855
|
-
},
|
|
856
|
-
},
|
|
857
|
-
OrgHypercertsClaimContribution: {
|
|
858
|
-
lexicon: 1,
|
|
859
|
-
id: 'org.hypercerts.claim.contribution',
|
|
860
|
-
defs: {
|
|
861
|
-
main: {
|
|
862
|
-
type: 'record',
|
|
863
|
-
description: "A contribution made toward a hypercert's impact.",
|
|
864
|
-
key: 'any',
|
|
865
|
-
record: {
|
|
866
|
-
type: 'object',
|
|
867
|
-
required: ['hypercert', 'contributors', 'createdAt'],
|
|
868
|
-
properties: {
|
|
869
|
-
hypercert: {
|
|
870
|
-
type: 'ref',
|
|
871
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
872
|
-
description: 'A strong reference to the hypercert this contribution is for. The record referenced must conform with the lexicon org.hypercerts.claim.',
|
|
873
|
-
},
|
|
874
|
-
role: {
|
|
875
|
-
type: 'string',
|
|
876
|
-
description: 'Role or title of the contributor(s).',
|
|
877
|
-
maxLength: 100,
|
|
878
|
-
},
|
|
879
|
-
contributors: {
|
|
880
|
-
type: 'array',
|
|
881
|
-
description: 'List of the contributors (names, pseudonyms, or DIDs). If multiple contributors are stored in the same hypercertContribution, then they would have the exact same role.',
|
|
882
|
-
items: {
|
|
883
|
-
type: 'string',
|
|
884
|
-
},
|
|
885
|
-
},
|
|
886
|
-
description: {
|
|
887
|
-
type: 'string',
|
|
888
|
-
description: 'What the contribution concretely achieved',
|
|
889
|
-
maxLength: 2000,
|
|
890
|
-
maxGraphemes: 500,
|
|
891
|
-
},
|
|
892
|
-
workTimeframeFrom: {
|
|
893
|
-
type: 'string',
|
|
894
|
-
format: 'datetime',
|
|
895
|
-
description: 'When this contribution started. This should be a subset of the hypercert timeframe.',
|
|
896
|
-
},
|
|
897
|
-
workTimeframeTo: {
|
|
898
|
-
type: 'string',
|
|
899
|
-
format: 'datetime',
|
|
900
|
-
description: 'When this contribution finished. This should be a subset of the hypercert timeframe.',
|
|
901
|
-
},
|
|
902
|
-
createdAt: {
|
|
903
|
-
type: 'string',
|
|
904
|
-
format: 'datetime',
|
|
905
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
906
|
-
},
|
|
907
|
-
},
|
|
908
|
-
},
|
|
909
|
-
},
|
|
910
|
-
},
|
|
911
|
-
},
|
|
912
|
-
OrgHypercertsClaimEvaluation: {
|
|
913
|
-
lexicon: 1,
|
|
914
|
-
id: 'org.hypercerts.claim.evaluation',
|
|
915
|
-
defs: {
|
|
916
|
-
main: {
|
|
917
|
-
type: 'record',
|
|
918
|
-
description: 'An evaluation of a hypercert or other claim',
|
|
919
|
-
key: 'tid',
|
|
920
|
-
record: {
|
|
921
|
-
type: 'object',
|
|
922
|
-
required: ['subject', 'evaluators', 'summary', 'createdAt'],
|
|
923
|
-
properties: {
|
|
924
|
-
subject: {
|
|
925
|
-
type: 'ref',
|
|
926
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
927
|
-
description: 'A strong reference to the evaluated claim. (e.g measurement, hypercert, contribution, etc)',
|
|
928
|
-
},
|
|
929
|
-
evaluators: {
|
|
930
|
-
type: 'array',
|
|
931
|
-
description: 'DIDs of the evaluators',
|
|
932
|
-
items: {
|
|
933
|
-
type: 'string',
|
|
934
|
-
format: 'did',
|
|
935
|
-
},
|
|
936
|
-
maxLength: 100,
|
|
937
|
-
},
|
|
938
|
-
evaluations: {
|
|
939
|
-
type: 'array',
|
|
940
|
-
description: 'Evaluation data (URIs or blobs) containing detailed reports or methodology',
|
|
941
|
-
items: {
|
|
942
|
-
type: 'union',
|
|
943
|
-
refs: [
|
|
944
|
-
'lex:app.certified.defs#uri',
|
|
945
|
-
'lex:app.certified.defs#smallBlob',
|
|
946
|
-
],
|
|
947
|
-
},
|
|
948
|
-
maxLength: 100,
|
|
949
|
-
},
|
|
950
|
-
summary: {
|
|
951
|
-
type: 'string',
|
|
952
|
-
description: 'Brief evaluation summary',
|
|
953
|
-
maxLength: 5000,
|
|
954
|
-
maxGraphemes: 1000,
|
|
955
|
-
},
|
|
956
|
-
createdAt: {
|
|
957
|
-
type: 'string',
|
|
958
|
-
format: 'datetime',
|
|
959
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
960
|
-
},
|
|
961
|
-
},
|
|
962
|
-
},
|
|
963
|
-
},
|
|
964
|
-
},
|
|
965
|
-
},
|
|
966
|
-
OrgHypercertsClaimEvidence: {
|
|
967
|
-
lexicon: 1,
|
|
968
|
-
id: 'org.hypercerts.claim.evidence',
|
|
969
|
-
defs: {
|
|
970
|
-
main: {
|
|
971
|
-
type: 'record',
|
|
972
|
-
description: 'A piece of evidence supporting a hypercert claim',
|
|
973
|
-
key: 'any',
|
|
974
|
-
record: {
|
|
975
|
-
type: 'object',
|
|
976
|
-
required: ['content', 'shortDescription', 'createdAt'],
|
|
977
|
-
properties: {
|
|
978
|
-
content: {
|
|
979
|
-
type: 'union',
|
|
980
|
-
refs: [
|
|
981
|
-
'lex:app.certified.defs#uri',
|
|
982
|
-
'lex:app.certified.defs#smallBlob',
|
|
983
|
-
],
|
|
984
|
-
description: 'A piece of evidence (URI or blobs) supporting a hypercert claim',
|
|
985
|
-
},
|
|
986
|
-
title: {
|
|
987
|
-
type: 'string',
|
|
988
|
-
maxLength: 256,
|
|
989
|
-
description: 'Optional title to describe the nature of the evidence',
|
|
990
|
-
},
|
|
991
|
-
shortDescription: {
|
|
992
|
-
type: 'string',
|
|
993
|
-
maxLength: 3000,
|
|
994
|
-
maxGraphemes: 300,
|
|
995
|
-
description: 'Short description explaining what this evidence demonstrates or proves',
|
|
996
|
-
},
|
|
997
|
-
description: {
|
|
998
|
-
type: 'string',
|
|
999
|
-
description: 'Optional longer description describing the impact claim evidence.',
|
|
1000
|
-
maxLength: 30000,
|
|
1001
|
-
maxGraphemes: 3000,
|
|
1002
|
-
},
|
|
1003
|
-
createdAt: {
|
|
1004
|
-
type: 'string',
|
|
1005
|
-
format: 'datetime',
|
|
1006
|
-
description: 'Client-declared timestamp when this hypercert claim was originally created',
|
|
1007
|
-
},
|
|
1008
|
-
},
|
|
1009
|
-
},
|
|
1010
|
-
},
|
|
1011
|
-
},
|
|
1012
|
-
},
|
|
1013
|
-
OrgHypercertsClaimMeasurement: {
|
|
1014
|
-
lexicon: 1,
|
|
1015
|
-
id: 'org.hypercerts.claim.measurement',
|
|
1016
|
-
defs: {
|
|
1017
|
-
main: {
|
|
1018
|
-
type: 'record',
|
|
1019
|
-
description: 'External measurement data supporting a hypercert claim',
|
|
1020
|
-
key: 'tid',
|
|
1021
|
-
record: {
|
|
1022
|
-
type: 'object',
|
|
1023
|
-
required: ['hypercert', 'measurers', 'metric', 'value', 'createdAt'],
|
|
1024
|
-
properties: {
|
|
1025
|
-
hypercert: {
|
|
1026
|
-
type: 'ref',
|
|
1027
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
1028
|
-
description: 'A strong reference to the hypercert that this measurement is for. The record referenced must conform with the lexicon org.hypercerts.claim.',
|
|
1029
|
-
},
|
|
1030
|
-
measurers: {
|
|
1031
|
-
type: 'array',
|
|
1032
|
-
description: 'DIDs of the entity (or entities) that measured this data',
|
|
1033
|
-
items: {
|
|
1034
|
-
type: 'string',
|
|
1035
|
-
format: 'did',
|
|
1036
|
-
},
|
|
1037
|
-
maxLength: 100,
|
|
1038
|
-
},
|
|
1039
|
-
metric: {
|
|
1040
|
-
type: 'string',
|
|
1041
|
-
description: 'The metric being measured',
|
|
1042
|
-
maxLength: 500,
|
|
1043
|
-
},
|
|
1044
|
-
value: {
|
|
1045
|
-
type: 'string',
|
|
1046
|
-
description: 'The measured value',
|
|
1047
|
-
maxLength: 500,
|
|
1048
|
-
},
|
|
1049
|
-
measurementMethodURI: {
|
|
1050
|
-
type: 'string',
|
|
1051
|
-
format: 'uri',
|
|
1052
|
-
description: 'URI to methodology documentation, standard protocol, or measurement procedure',
|
|
1053
|
-
},
|
|
1054
|
-
evidenceURI: {
|
|
1055
|
-
type: 'array',
|
|
1056
|
-
description: 'URIs to supporting evidence or data',
|
|
1057
|
-
items: {
|
|
1058
|
-
type: 'string',
|
|
1059
|
-
format: 'uri',
|
|
1060
|
-
},
|
|
1061
|
-
maxLength: 50,
|
|
1062
|
-
},
|
|
1063
|
-
createdAt: {
|
|
1064
|
-
type: 'string',
|
|
1065
|
-
format: 'datetime',
|
|
1066
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
1067
|
-
},
|
|
1068
|
-
},
|
|
1069
|
-
},
|
|
1070
|
-
},
|
|
1071
|
-
},
|
|
1072
|
-
},
|
|
1073
|
-
OrgHypercertsClaimRights: {
|
|
1074
|
-
lexicon: 1,
|
|
1075
|
-
id: 'org.hypercerts.claim.rights',
|
|
1076
|
-
defs: {
|
|
1077
|
-
main: {
|
|
1078
|
-
type: 'record',
|
|
1079
|
-
description: 'Describes the rights that a user has with a hypercert, such as whether it can be sold, transferred, and under what conditions.',
|
|
1080
|
-
key: 'any',
|
|
1081
|
-
record: {
|
|
1082
|
-
type: 'object',
|
|
1083
|
-
required: [
|
|
1084
|
-
'rightsName',
|
|
1085
|
-
'rightsType',
|
|
1086
|
-
'rightsDescription',
|
|
1087
|
-
'createdAt',
|
|
1088
|
-
],
|
|
1089
|
-
properties: {
|
|
1090
|
-
rightsName: {
|
|
1091
|
-
type: 'string',
|
|
1092
|
-
description: 'Full name of the rights',
|
|
1093
|
-
maxLength: 100,
|
|
1094
|
-
},
|
|
1095
|
-
rightsType: {
|
|
1096
|
-
type: 'string',
|
|
1097
|
-
description: 'Short rights identifier for easier search',
|
|
1098
|
-
maxLength: 10,
|
|
1099
|
-
},
|
|
1100
|
-
rightsDescription: {
|
|
1101
|
-
type: 'string',
|
|
1102
|
-
description: 'Description of the rights of this hypercert',
|
|
1103
|
-
},
|
|
1104
|
-
createdAt: {
|
|
1105
|
-
type: 'string',
|
|
1106
|
-
format: 'datetime',
|
|
1107
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
1108
|
-
},
|
|
1109
|
-
},
|
|
1110
|
-
},
|
|
1111
|
-
},
|
|
1112
|
-
},
|
|
1113
|
-
},
|
|
1114
|
-
OrgHypercertsCollection: {
|
|
1115
|
-
lexicon: 1,
|
|
1116
|
-
id: 'org.hypercerts.collection',
|
|
1117
|
-
defs: {
|
|
1118
|
-
main: {
|
|
1119
|
-
type: 'record',
|
|
1120
|
-
description: 'A collection/group of hypercerts that have a specific property.',
|
|
1121
|
-
key: 'tid',
|
|
1122
|
-
record: {
|
|
1123
|
-
type: 'object',
|
|
1124
|
-
required: ['title', 'claims', 'createdAt'],
|
|
1125
|
-
properties: {
|
|
1126
|
-
title: {
|
|
1127
|
-
type: 'string',
|
|
1128
|
-
description: 'The title of this collection',
|
|
1129
|
-
maxLength: 800,
|
|
1130
|
-
maxGraphemes: 80,
|
|
1131
|
-
},
|
|
1132
|
-
shortDescription: {
|
|
1133
|
-
type: 'string',
|
|
1134
|
-
maxLength: 3000,
|
|
1135
|
-
maxGraphemes: 300,
|
|
1136
|
-
description: 'A short description of this collection',
|
|
1137
|
-
},
|
|
1138
|
-
coverPhoto: {
|
|
1139
|
-
type: 'union',
|
|
1140
|
-
refs: [
|
|
1141
|
-
'lex:app.certified.defs#uri',
|
|
1142
|
-
'lex:app.certified.defs#smallBlob',
|
|
1143
|
-
],
|
|
1144
|
-
description: 'The cover photo of this collection (either in URI format or in a blob).',
|
|
1145
|
-
},
|
|
1146
|
-
claims: {
|
|
1147
|
-
type: 'array',
|
|
1148
|
-
description: 'Array of claims with their associated weights in this collection',
|
|
1149
|
-
items: {
|
|
1150
|
-
type: 'ref',
|
|
1151
|
-
ref: 'lex:org.hypercerts.collection#claimItem',
|
|
1152
|
-
},
|
|
1153
|
-
},
|
|
1154
|
-
createdAt: {
|
|
1155
|
-
type: 'string',
|
|
1156
|
-
format: 'datetime',
|
|
1157
|
-
description: 'Client-declared timestamp when this record was originally created',
|
|
1158
|
-
},
|
|
1159
|
-
},
|
|
1160
|
-
},
|
|
1161
|
-
},
|
|
1162
|
-
claimItem: {
|
|
1163
|
-
type: 'object',
|
|
1164
|
-
required: ['claim', 'weight'],
|
|
1165
|
-
properties: {
|
|
1166
|
-
claim: {
|
|
1167
|
-
type: 'ref',
|
|
1168
|
-
ref: 'lex:com.atproto.repo.strongRef',
|
|
1169
|
-
description: 'A strong reference to a hypercert claim record. This claim must conform to the lexicon org.hypercerts.claim.record',
|
|
1170
|
-
},
|
|
1171
|
-
weight: {
|
|
1172
|
-
type: 'string',
|
|
1173
|
-
description: 'The weight/importance of this hypercert claim in the collection (a percentage from 0-100, stored as a string to avoid float precision issues). The total claim weights should add up to 100.',
|
|
1174
|
-
},
|
|
1175
|
-
},
|
|
1176
|
-
},
|
|
1177
|
-
},
|
|
1178
|
-
},
|
|
1179
|
-
};
|
|
1180
|
-
const schemas = Object.values(schemaDict);
|
|
1181
|
-
const lexicons = new lexicon$a.Lexicons(schemas);
|
|
1182
|
-
function validate$9(v, id, hash, requiredType) {
|
|
1183
|
-
return (requiredType ? is$typed$9 : maybe$typed)(v, id, hash)
|
|
1184
|
-
? lexicons.validate(`${id}#${hash}`, v)
|
|
1185
|
-
: {
|
|
1186
|
-
success: false,
|
|
1187
|
-
error: new lexicon$a.ValidationError(`Must be an object with "${hash === 'main' ? id : `${id}#${hash}`}" $type property`),
|
|
1188
|
-
};
|
|
1189
|
-
}
|
|
1190
|
-
const ids = {
|
|
1191
|
-
AppCertifiedDefs: 'app.certified.defs',
|
|
1192
|
-
AppCertifiedLocation: 'app.certified.location',
|
|
1193
|
-
ComAtprotoRepoStrongRef: 'com.atproto.repo.strongRef',
|
|
1194
|
-
OrgHypercertsClaim: 'org.hypercerts.claim',
|
|
1195
|
-
OrgHypercertsClaimContribution: 'org.hypercerts.claim.contribution',
|
|
1196
|
-
OrgHypercertsClaimEvaluation: 'org.hypercerts.claim.evaluation',
|
|
1197
|
-
OrgHypercertsClaimEvidence: 'org.hypercerts.claim.evidence',
|
|
1198
|
-
OrgHypercertsClaimMeasurement: 'org.hypercerts.claim.measurement',
|
|
1199
|
-
OrgHypercertsClaimRights: 'org.hypercerts.claim.rights',
|
|
1200
|
-
OrgHypercertsCollection: 'org.hypercerts.collection',
|
|
1201
|
-
};
|
|
1202
|
-
|
|
1203
|
-
var defs = /*#__PURE__*/Object.freeze({
|
|
1204
|
-
__proto__: null
|
|
1205
|
-
});
|
|
1206
|
-
|
|
1207
|
-
const is$typed$8 = is$typed$9, validate$8 = validate$9;
|
|
1208
|
-
const id$8 = 'app.certified.location';
|
|
1209
|
-
const hashMain$8 = 'main';
|
|
1210
|
-
function isMain$8(v) {
|
|
1211
|
-
return is$typed$8(v, id$8, hashMain$8);
|
|
1212
|
-
}
|
|
1213
|
-
function validateMain$8(v) {
|
|
1214
|
-
return validate$8(v, id$8, hashMain$8, true);
|
|
1215
|
-
}
|
|
1216
|
-
|
|
1217
|
-
var location = /*#__PURE__*/Object.freeze({
|
|
1218
|
-
__proto__: null,
|
|
1219
|
-
isMain: isMain$8,
|
|
1220
|
-
isRecord: isMain$8,
|
|
1221
|
-
validateMain: validateMain$8,
|
|
1222
|
-
validateRecord: validateMain$8
|
|
1223
|
-
});
|
|
1224
|
-
|
|
1225
|
-
const is$typed$7 = is$typed$9, validate$7 = validate$9;
|
|
1226
|
-
const id$7 = 'com.atproto.repo.strongRef';
|
|
1227
|
-
const hashMain$7 = 'main';
|
|
1228
|
-
function isMain$7(v) {
|
|
1229
|
-
return is$typed$7(v, id$7, hashMain$7);
|
|
1230
|
-
}
|
|
1231
|
-
function validateMain$7(v) {
|
|
1232
|
-
return validate$7(v, id$7, hashMain$7);
|
|
1233
|
-
}
|
|
1234
|
-
|
|
1235
|
-
var strongRef = /*#__PURE__*/Object.freeze({
|
|
1236
|
-
__proto__: null,
|
|
1237
|
-
isMain: isMain$7,
|
|
1238
|
-
validateMain: validateMain$7
|
|
1239
|
-
});
|
|
1240
|
-
|
|
1241
|
-
const is$typed$6 = is$typed$9, validate$6 = validate$9;
|
|
1242
|
-
const id$6 = 'org.hypercerts.claim';
|
|
1243
|
-
const hashMain$6 = 'main';
|
|
1244
|
-
function isMain$6(v) {
|
|
1245
|
-
return is$typed$6(v, id$6, hashMain$6);
|
|
1246
|
-
}
|
|
1247
|
-
function validateMain$6(v) {
|
|
1248
|
-
return validate$6(v, id$6, hashMain$6, true);
|
|
1249
|
-
}
|
|
1250
|
-
|
|
1251
|
-
var claim = /*#__PURE__*/Object.freeze({
|
|
1252
|
-
__proto__: null,
|
|
1253
|
-
isMain: isMain$6,
|
|
1254
|
-
isRecord: isMain$6,
|
|
1255
|
-
validateMain: validateMain$6,
|
|
1256
|
-
validateRecord: validateMain$6
|
|
1257
|
-
});
|
|
1258
|
-
|
|
1259
|
-
const is$typed$5 = is$typed$9, validate$5 = validate$9;
|
|
1260
|
-
const id$5 = 'org.hypercerts.claim.contribution';
|
|
1261
|
-
const hashMain$5 = 'main';
|
|
1262
|
-
function isMain$5(v) {
|
|
1263
|
-
return is$typed$5(v, id$5, hashMain$5);
|
|
1264
|
-
}
|
|
1265
|
-
function validateMain$5(v) {
|
|
1266
|
-
return validate$5(v, id$5, hashMain$5, true);
|
|
1267
|
-
}
|
|
1268
|
-
|
|
1269
|
-
var contribution = /*#__PURE__*/Object.freeze({
|
|
1270
|
-
__proto__: null,
|
|
1271
|
-
isMain: isMain$5,
|
|
1272
|
-
isRecord: isMain$5,
|
|
1273
|
-
validateMain: validateMain$5,
|
|
1274
|
-
validateRecord: validateMain$5
|
|
1275
|
-
});
|
|
1276
|
-
|
|
1277
|
-
const is$typed$4 = is$typed$9, validate$4 = validate$9;
|
|
1278
|
-
const id$4 = 'org.hypercerts.claim.evaluation';
|
|
1279
|
-
const hashMain$4 = 'main';
|
|
1280
|
-
function isMain$4(v) {
|
|
1281
|
-
return is$typed$4(v, id$4, hashMain$4);
|
|
1282
|
-
}
|
|
1283
|
-
function validateMain$4(v) {
|
|
1284
|
-
return validate$4(v, id$4, hashMain$4, true);
|
|
1285
|
-
}
|
|
1286
|
-
|
|
1287
|
-
var evaluation = /*#__PURE__*/Object.freeze({
|
|
1288
|
-
__proto__: null,
|
|
1289
|
-
isMain: isMain$4,
|
|
1290
|
-
isRecord: isMain$4,
|
|
1291
|
-
validateMain: validateMain$4,
|
|
1292
|
-
validateRecord: validateMain$4
|
|
1293
|
-
});
|
|
1294
|
-
|
|
1295
|
-
const is$typed$3 = is$typed$9, validate$3 = validate$9;
|
|
1296
|
-
const id$3 = 'org.hypercerts.claim.evidence';
|
|
1297
|
-
const hashMain$3 = 'main';
|
|
1298
|
-
function isMain$3(v) {
|
|
1299
|
-
return is$typed$3(v, id$3, hashMain$3);
|
|
1300
|
-
}
|
|
1301
|
-
function validateMain$3(v) {
|
|
1302
|
-
return validate$3(v, id$3, hashMain$3, true);
|
|
1303
|
-
}
|
|
1304
|
-
|
|
1305
|
-
var evidence = /*#__PURE__*/Object.freeze({
|
|
1306
|
-
__proto__: null,
|
|
1307
|
-
isMain: isMain$3,
|
|
1308
|
-
isRecord: isMain$3,
|
|
1309
|
-
validateMain: validateMain$3,
|
|
1310
|
-
validateRecord: validateMain$3
|
|
1311
|
-
});
|
|
1312
|
-
|
|
1313
|
-
const is$typed$2 = is$typed$9, validate$2 = validate$9;
|
|
1314
|
-
const id$2 = 'org.hypercerts.claim.measurement';
|
|
1315
|
-
const hashMain$2 = 'main';
|
|
1316
|
-
function isMain$2(v) {
|
|
1317
|
-
return is$typed$2(v, id$2, hashMain$2);
|
|
1318
|
-
}
|
|
1319
|
-
function validateMain$2(v) {
|
|
1320
|
-
return validate$2(v, id$2, hashMain$2, true);
|
|
1321
|
-
}
|
|
1322
|
-
|
|
1323
|
-
var measurement = /*#__PURE__*/Object.freeze({
|
|
1324
|
-
__proto__: null,
|
|
1325
|
-
isMain: isMain$2,
|
|
1326
|
-
isRecord: isMain$2,
|
|
1327
|
-
validateMain: validateMain$2,
|
|
1328
|
-
validateRecord: validateMain$2
|
|
1329
|
-
});
|
|
1330
|
-
|
|
1331
|
-
const is$typed$1 = is$typed$9, validate$1 = validate$9;
|
|
1332
|
-
const id$1 = 'org.hypercerts.claim.rights';
|
|
1333
|
-
const hashMain$1 = 'main';
|
|
1334
|
-
function isMain$1(v) {
|
|
1335
|
-
return is$typed$1(v, id$1, hashMain$1);
|
|
1336
|
-
}
|
|
1337
|
-
function validateMain$1(v) {
|
|
1338
|
-
return validate$1(v, id$1, hashMain$1, true);
|
|
1339
|
-
}
|
|
1340
|
-
|
|
1341
|
-
var rights = /*#__PURE__*/Object.freeze({
|
|
1342
|
-
__proto__: null,
|
|
1343
|
-
isMain: isMain$1,
|
|
1344
|
-
isRecord: isMain$1,
|
|
1345
|
-
validateMain: validateMain$1,
|
|
1346
|
-
validateRecord: validateMain$1
|
|
1347
|
-
});
|
|
1348
|
-
|
|
1349
|
-
const is$typed = is$typed$9, validate = validate$9;
|
|
1350
|
-
const id = 'org.hypercerts.collection';
|
|
1351
|
-
const hashMain = 'main';
|
|
1352
|
-
function isMain(v) {
|
|
1353
|
-
return is$typed(v, id, hashMain);
|
|
1354
|
-
}
|
|
1355
|
-
function validateMain(v) {
|
|
1356
|
-
return validate(v, id, hashMain, true);
|
|
1357
|
-
}
|
|
1358
|
-
const hashClaimItem = 'claimItem';
|
|
1359
|
-
function isClaimItem(v) {
|
|
1360
|
-
return is$typed(v, id, hashClaimItem);
|
|
1361
|
-
}
|
|
1362
|
-
function validateClaimItem(v) {
|
|
1363
|
-
return validate(v, id, hashClaimItem);
|
|
1364
|
-
}
|
|
1365
|
-
|
|
1366
|
-
var collection = /*#__PURE__*/Object.freeze({
|
|
1367
|
-
__proto__: null,
|
|
1368
|
-
isClaimItem: isClaimItem,
|
|
1369
|
-
isMain: isMain,
|
|
1370
|
-
isRecord: isMain,
|
|
1371
|
-
validateClaimItem: validateClaimItem,
|
|
1372
|
-
validateMain: validateMain,
|
|
1373
|
-
validateRecord: validateMain
|
|
1374
|
-
});
|
|
1375
|
-
|
|
1376
|
-
/**
|
|
1377
|
-
* Hypercert lexicon definitions for AT Protocol.
|
|
1378
|
-
*
|
|
1379
|
-
* This module exports the lexicon documents, collection names,
|
|
1380
|
-
* and generated TypeScript types for all hypercert-related record types.
|
|
1381
|
-
*
|
|
1382
|
-
* @packageDocumentation
|
|
1383
|
-
*/
|
|
1384
|
-
/**
|
|
1385
|
-
* All hypercert-related lexicons for registration with AT Protocol Agent.
|
|
1386
|
-
*
|
|
1387
|
-
* This array contains all lexicon documents needed to work with
|
|
1388
|
-
* hypercert records.
|
|
1389
|
-
*/
|
|
1390
|
-
const HYPERCERT_LEXICONS = [
|
|
1391
|
-
defsLexicon,
|
|
1392
|
-
locationLexicon,
|
|
1393
|
-
claimLexicon,
|
|
1394
|
-
rightsLexicon,
|
|
1395
|
-
contributionLexicon,
|
|
1396
|
-
measurementLexicon,
|
|
1397
|
-
evaluationLexicon,
|
|
1398
|
-
evidenceLexicon,
|
|
1399
|
-
collectionLexicon,
|
|
1400
|
-
];
|
|
1401
|
-
/**
|
|
1402
|
-
* Collection NSIDs (Namespaced Identifiers) for hypercert records.
|
|
1403
|
-
*
|
|
1404
|
-
* Use these constants when performing record operations to ensure
|
|
1405
|
-
* correct collection names.
|
|
1406
|
-
*/
|
|
1407
|
-
const HYPERCERT_COLLECTIONS = {
|
|
1408
|
-
/**
|
|
1409
|
-
* Main hypercert claim record collection.
|
|
1410
|
-
*/
|
|
1411
|
-
CLAIM: "org.hypercerts.claim",
|
|
1412
|
-
/**
|
|
1413
|
-
* Rights record collection.
|
|
1414
|
-
*/
|
|
1415
|
-
RIGHTS: "org.hypercerts.claim.rights",
|
|
1416
|
-
/**
|
|
1417
|
-
* Location record collection (shared certified lexicon).
|
|
1418
|
-
*/
|
|
1419
|
-
LOCATION: "app.certified.location",
|
|
1420
|
-
/**
|
|
1421
|
-
* Contribution record collection.
|
|
1422
|
-
*/
|
|
1423
|
-
CONTRIBUTION: "org.hypercerts.claim.contribution",
|
|
1424
|
-
/**
|
|
1425
|
-
* Measurement record collection.
|
|
1426
|
-
*/
|
|
1427
|
-
MEASUREMENT: "org.hypercerts.claim.measurement",
|
|
1428
|
-
/**
|
|
1429
|
-
* Evaluation record collection.
|
|
1430
|
-
*/
|
|
1431
|
-
EVALUATION: "org.hypercerts.claim.evaluation",
|
|
1432
|
-
/**
|
|
1433
|
-
* Evidence record collection.
|
|
1434
|
-
*/
|
|
1435
|
-
EVIDENCE: "org.hypercerts.claim.evidence",
|
|
1436
|
-
/**
|
|
1437
|
-
* Collection record collection (groups of hypercerts).
|
|
1438
|
-
*/
|
|
1439
|
-
COLLECTION: "org.hypercerts.collection",
|
|
1440
|
-
};
|
|
1441
|
-
|
|
1442
|
-
exports.AppCertifiedDefs = defs;
|
|
1443
|
-
exports.AppCertifiedLocation = location;
|
|
1444
|
-
exports.ComAtprotoRepoStrongRef = strongRef;
|
|
1445
|
-
exports.HYPERCERT_COLLECTIONS = HYPERCERT_COLLECTIONS;
|
|
1446
|
-
exports.HYPERCERT_LEXICONS = HYPERCERT_LEXICONS;
|
|
1447
|
-
exports.OrgHypercertsClaim = claim;
|
|
1448
|
-
exports.OrgHypercertsClaimContribution = contribution;
|
|
1449
|
-
exports.OrgHypercertsClaimEvaluation = evaluation;
|
|
1450
|
-
exports.OrgHypercertsClaimEvidence = evidence;
|
|
1451
|
-
exports.OrgHypercertsClaimMeasurement = measurement;
|
|
1452
|
-
exports.OrgHypercertsClaimRights = rights;
|
|
1453
|
-
exports.OrgHypercertsCollection = collection;
|
|
1454
|
-
exports.asPredicate = asPredicate;
|
|
1455
|
-
exports.claimLexicon = claimLexicon;
|
|
1456
|
-
exports.collectionLexicon = collectionLexicon;
|
|
1457
|
-
exports.contributionLexicon = contributionLexicon;
|
|
1458
|
-
exports.defsLexicon = defsLexicon;
|
|
1459
|
-
exports.evaluationLexicon = evaluationLexicon;
|
|
1460
|
-
exports.evidenceLexicon = evidenceLexicon;
|
|
1461
|
-
exports.ids = ids;
|
|
1462
|
-
exports.is$typed = is$typed$9;
|
|
1463
|
-
exports.lexicons = lexicons;
|
|
1464
|
-
exports.locationLexicon = locationLexicon;
|
|
1465
|
-
exports.maybe$typed = maybe$typed;
|
|
1466
|
-
exports.measurementLexicon = measurementLexicon;
|
|
1467
|
-
exports.rightsLexicon = rightsLexicon;
|
|
1468
|
-
exports.schemaDict = schemaDict;
|
|
1469
|
-
exports.schemas = schemas;
|
|
1470
|
-
exports.strongRefLexicon = strongRef$1;
|
|
1471
|
-
exports.validate = validate$9;
|
|
1472
|
-
//# sourceMappingURL=index.cjs.map
|