@carrot-foundation/schemas 0.1.36 → 0.1.37

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 (40) hide show
  1. package/dist/index.cjs +1124 -36
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.d.cts +959 -13
  4. package/dist/index.d.ts +959 -13
  5. package/dist/index.js +1102 -37
  6. package/dist/index.js.map +1 -1
  7. package/package.json +1 -1
  8. package/schemas/ipfs/collection/collection.example.json +1 -0
  9. package/schemas/ipfs/collection/collection.schema.json +305 -32
  10. package/schemas/ipfs/credit/credit.example.json +1 -0
  11. package/schemas/ipfs/credit/credit.schema.json +326 -45
  12. package/schemas/ipfs/credit-purchase-receipt/credit-purchase-receipt.example.json +290 -0
  13. package/schemas/ipfs/credit-purchase-receipt/credit-purchase-receipt.schema.json +1768 -0
  14. package/schemas/ipfs/gas-id/gas-id.schema.json +6 -6
  15. package/schemas/ipfs/mass-id/mass-id.schema.json +6 -6
  16. package/schemas/ipfs/mass-id-audit/mass-id-audit.example.json +30 -29
  17. package/schemas/ipfs/mass-id-audit/mass-id-audit.schema.json +636 -15
  18. package/schemas/ipfs/methodology/methodology.example.json +27 -26
  19. package/schemas/ipfs/methodology/methodology.schema.json +457 -15
  20. package/schemas/ipfs/recycled-id/recycled-id.schema.json +6 -6
  21. package/schemas/ipfs/gas-id/gas-id.attributes.schema.json +0 -219
  22. package/schemas/ipfs/gas-id/gas-id.data.schema.json +0 -120
  23. package/schemas/ipfs/mass-id-audit/mass-id-audit.data.schema.json +0 -130
  24. package/schemas/ipfs/methodology/methodology.data.schema.json +0 -121
  25. package/schemas/ipfs/purchase-id/purchase-id.attributes.schema.json +0 -91
  26. package/schemas/ipfs/purchase-id/purchase-id.data.schema.json +0 -337
  27. package/schemas/ipfs/purchase-id/purchase-id.example.json +0 -224
  28. package/schemas/ipfs/purchase-id/purchase-id.schema.json +0 -29
  29. package/schemas/ipfs/recycled-id/recycled-id.attributes.schema.json +0 -202
  30. package/schemas/ipfs/recycled-id/recycled-id.data.schema.json +0 -63
  31. package/schemas/ipfs/shared/base/base.schema.json +0 -163
  32. package/schemas/ipfs/shared/certificate/certificate.schema.json +0 -145
  33. package/schemas/ipfs/shared/definitions/definitions.schema.json +0 -255
  34. package/schemas/ipfs/shared/entities/location/location.schema.json +0 -90
  35. package/schemas/ipfs/shared/entities/participant/participant.schema.json +0 -28
  36. package/schemas/ipfs/shared/nft/nft.schema.json +0 -182
  37. package/schemas/ipfs/shared/references/audit-reference/audit-reference.schema.json +0 -42
  38. package/schemas/ipfs/shared/references/gas-id-reference/gas-id-reference.schema.json +0 -27
  39. package/schemas/ipfs/shared/references/mass-id-reference/mass-id-reference.schema.json +0 -27
  40. package/schemas/ipfs/shared/references/methodology-reference/methodology-reference.schema.json +0 -34
@@ -0,0 +1,1768 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "title": "CreditPurchaseReceipt NFT IPFS Record",
4
+ "description": "Complete CreditPurchaseReceipt NFT IPFS record including attributes and credit purchase data",
5
+ "$id": "https://raw.githubusercontent.com/carrot-foundation/schemas/refs/tags/0.1.37/schemas/ipfs/credit-purchase-receipt/credit-purchase-receipt.schema.json",
6
+ "version": "0.1.37",
7
+ "type": "object",
8
+ "properties": {
9
+ "$schema": {
10
+ "title": "JSON Schema URI",
11
+ "description": "URI of the JSON Schema used to validate this record",
12
+ "example": "https://raw.githubusercontent.com/carrot-foundation/schemas/refs/heads/main/schemas/ipfs/shared/base/base.schema.json",
13
+ "type": "string",
14
+ "format": "uri"
15
+ },
16
+ "schema": {
17
+ "type": "object",
18
+ "properties": {
19
+ "hash": {
20
+ "title": "Schema Hash",
21
+ "description": "Keccak256 hash of the JSON Schema this record was validated against",
22
+ "examples": [
23
+ "ac08c3cf2e175e55961d6affdb38bc24591b84ceef7f3707c69ae3d52c148b2f",
24
+ "0xac08c3cf2e175e55961d6affdb38bc24591b84ceef7f3707c69ae3d52c148b2f"
25
+ ],
26
+ "anyOf": [
27
+ {
28
+ "title": "Keccak256 Hash",
29
+ "description": "Keccak256 cryptographic hash as hexadecimal string",
30
+ "examples": [
31
+ "ac08c3cf2e175e55961d6affdb38bc24591b84ceef7f3707c69ae3d52c148b2f",
32
+ "b1c2d3e4f5a6b7c8d9e0f1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b1c2"
33
+ ],
34
+ "type": "string",
35
+ "pattern": "^[0-9a-fA-F]{64}$"
36
+ },
37
+ {
38
+ "type": "string",
39
+ "pattern": "^0x[a-fA-F0-9]{64}$"
40
+ }
41
+ ]
42
+ },
43
+ "type": {
44
+ "title": "CreditPurchaseReceipt Schema Type",
45
+ "description": "CreditPurchaseReceipt NFT schema type",
46
+ "type": "string",
47
+ "const": "CreditPurchaseReceipt"
48
+ },
49
+ "version": {
50
+ "title": "Schema Version",
51
+ "description": "Version of the schema, using semantic versioning",
52
+ "examples": [
53
+ "0.1.0",
54
+ "1.0.0",
55
+ "2.1.3"
56
+ ],
57
+ "type": "string",
58
+ "minLength": 1,
59
+ "pattern": "^v?\\d+\\.\\d+\\.\\d+(-[a-zA-Z0-9.-]+)?(\\+[a-zA-Z0-9.-]+)?$"
60
+ }
61
+ },
62
+ "required": [
63
+ "hash",
64
+ "type",
65
+ "version"
66
+ ],
67
+ "additionalProperties": false
68
+ },
69
+ "created_at": {
70
+ "title": "Created At",
71
+ "description": "ISO 8601 creation timestamp for this record",
72
+ "examples": [
73
+ "2024-12-05T11:02:47.000Z",
74
+ "2025-02-22T10:35:12.000Z"
75
+ ],
76
+ "type": "string",
77
+ "format": "date-time",
78
+ "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))$"
79
+ },
80
+ "external_id": {
81
+ "title": "External ID",
82
+ "description": "Off-chain reference ID (UUID from Carrot backend)",
83
+ "examples": [
84
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
85
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
86
+ ],
87
+ "type": "string",
88
+ "format": "uuid",
89
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
90
+ },
91
+ "external_url": {
92
+ "title": "External URL",
93
+ "description": "External URL of the content",
94
+ "examples": [
95
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
96
+ "https://carrot.eco/whitepaper.pdf"
97
+ ],
98
+ "type": "string",
99
+ "format": "uri"
100
+ },
101
+ "original_content_hash": {
102
+ "title": "Original Content Hash",
103
+ "description": "SHA-256 hash of the original JSON content including private data before schema validation",
104
+ "examples": [
105
+ "87f633634cc4b02f628685651f0a29b7bfa22a0bd841f725c6772dd00a58d489",
106
+ "6e83b8e6373847bbdc056549bedda38dc88854ce41ba4fca11e0fc6ce3e07ef6"
107
+ ],
108
+ "type": "string",
109
+ "pattern": "^[0-9a-fA-F]{64}$"
110
+ },
111
+ "content_hash": {
112
+ "title": "Content Hash",
113
+ "description": "SHA-256 hash of RFC 8785 canonicalized JSON after schema validation",
114
+ "examples": [
115
+ "87f633634cc4b02f628685651f0a29b7bfa22a0bd841f725c6772dd00a58d489",
116
+ "6e83b8e6373847bbdc056549bedda38dc88854ce41ba4fca11e0fc6ce3e07ef6"
117
+ ],
118
+ "type": "string",
119
+ "pattern": "^[0-9a-fA-F]{64}$"
120
+ },
121
+ "creator": {
122
+ "title": "Creator",
123
+ "description": "Entity that created this record",
124
+ "type": "object",
125
+ "properties": {
126
+ "name": {
127
+ "title": "Creator Name",
128
+ "description": "Company or individual name that created this record",
129
+ "examples": [
130
+ "Carrot Foundation"
131
+ ],
132
+ "type": "string"
133
+ },
134
+ "id": {
135
+ "title": "Creator ID",
136
+ "description": "Unique identifier for the creator",
137
+ "examples": [
138
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
139
+ "6f520d88-864d-432d-bf9f-5c3166c4818f",
140
+ "f77afa89-1c58-40fd-9bf5-8a86703a8af4"
141
+ ],
142
+ "type": "string",
143
+ "format": "uuid",
144
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
145
+ }
146
+ },
147
+ "required": [
148
+ "name",
149
+ "id"
150
+ ],
151
+ "additionalProperties": false
152
+ },
153
+ "relationships": {
154
+ "title": "Relationships",
155
+ "description": "References to other IPFS records this record relates to",
156
+ "type": "array",
157
+ "items": {
158
+ "title": "Relationship",
159
+ "description": "Relationship to another IPFS record",
160
+ "type": "object",
161
+ "properties": {
162
+ "target_uri": {
163
+ "title": "Target IPFS URI",
164
+ "description": "Target IPFS URI of the referenced record",
165
+ "examples": [
166
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
167
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
168
+ ],
169
+ "type": "string",
170
+ "minLength": 1,
171
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
172
+ },
173
+ "type": {
174
+ "title": "Relationship Type",
175
+ "description": "Type of relationship to the referenced record",
176
+ "examples": [
177
+ "mass-id",
178
+ "collection",
179
+ "credit-purchase-receipt"
180
+ ],
181
+ "type": "string",
182
+ "enum": [
183
+ "collection",
184
+ "credit",
185
+ "gas-id",
186
+ "mass-id",
187
+ "mass-id-audit",
188
+ "methodology",
189
+ "credit-purchase-receipt",
190
+ "recycled-id"
191
+ ]
192
+ },
193
+ "description": {
194
+ "title": "Relationship Description",
195
+ "description": "Human-readable description of the relationship",
196
+ "examples": [
197
+ "This record supersedes the previous version",
198
+ "Related carbon credit batch",
199
+ "Source document for this verification",
200
+ "Child record derived from this parent",
201
+ "Updated version of original record"
202
+ ],
203
+ "type": "string"
204
+ }
205
+ },
206
+ "required": [
207
+ "target_uri",
208
+ "type"
209
+ ],
210
+ "additionalProperties": false
211
+ }
212
+ },
213
+ "environment": {
214
+ "title": "Environment",
215
+ "description": "Environment information",
216
+ "type": "object",
217
+ "properties": {
218
+ "blockchain_network": {
219
+ "title": "Blockchain Network",
220
+ "description": "Blockchain Network Environment",
221
+ "type": "string",
222
+ "enum": [
223
+ "mainnet",
224
+ "testnet"
225
+ ]
226
+ },
227
+ "deployment": {
228
+ "title": "Deployment Environment",
229
+ "description": "System environment where this record was generated",
230
+ "type": "string",
231
+ "enum": [
232
+ "production",
233
+ "development",
234
+ "testing"
235
+ ]
236
+ },
237
+ "data_set_name": {
238
+ "title": "Data Set Name",
239
+ "description": "Name of the data set for this record",
240
+ "type": "string",
241
+ "enum": [
242
+ "TEST",
243
+ "PROD"
244
+ ]
245
+ }
246
+ },
247
+ "required": [
248
+ "blockchain_network",
249
+ "deployment",
250
+ "data_set_name"
251
+ ],
252
+ "additionalProperties": false
253
+ },
254
+ "data": {
255
+ "title": "Credit Purchase Receipt Data",
256
+ "description": "Complete data structure for a credit purchase receipt",
257
+ "type": "object",
258
+ "properties": {
259
+ "summary": {
260
+ "title": "Credit Purchase Receipt Summary",
261
+ "description": "Summary totals for the credit purchase including amounts and collections represented",
262
+ "type": "object",
263
+ "properties": {
264
+ "total_usdc_amount": {
265
+ "title": "Total USDC Amount",
266
+ "description": "Total amount paid in USDC for the purchase",
267
+ "examples": [
268
+ 0,
269
+ 45.2,
270
+ 72.5
271
+ ],
272
+ "type": "number",
273
+ "minimum": 0
274
+ },
275
+ "total_credits": {
276
+ "title": "Total Credits",
277
+ "description": "Total amount of credits purchased",
278
+ "examples": [
279
+ 0,
280
+ 45.2,
281
+ 72.5
282
+ ],
283
+ "type": "number",
284
+ "minimum": 0
285
+ },
286
+ "total_certificates": {
287
+ "title": "Total Certificates",
288
+ "description": "Total number of certificates purchased",
289
+ "examples": [
290
+ 1,
291
+ 123,
292
+ 456
293
+ ],
294
+ "type": "integer",
295
+ "minimum": 1,
296
+ "maximum": 9007199254740991
297
+ },
298
+ "purchase_date": {
299
+ "title": "Purchase Date",
300
+ "description": "Date when the purchase was made (YYYY-MM-DD)",
301
+ "examples": [
302
+ "2024-12-05",
303
+ "2025-02-22",
304
+ "2024-02-10"
305
+ ],
306
+ "type": "string",
307
+ "format": "date",
308
+ "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])))$"
309
+ },
310
+ "credit_symbols": {
311
+ "title": "Credit Symbols",
312
+ "description": "Array of credit token symbols included in the purchase",
313
+ "minItems": 1,
314
+ "type": "array",
315
+ "items": {
316
+ "title": "Token Symbol",
317
+ "description": "Symbol representing a token or cryptocurrency",
318
+ "examples": [
319
+ "MASS",
320
+ "REC",
321
+ "GAS"
322
+ ],
323
+ "type": "string",
324
+ "minLength": 1,
325
+ "maxLength": 10,
326
+ "pattern": "^[A-Z0-9-]+$"
327
+ }
328
+ },
329
+ "certificate_types": {
330
+ "title": "Certificate Types",
331
+ "description": "Array of certificate types included in the purchase",
332
+ "minItems": 1,
333
+ "type": "array",
334
+ "items": {
335
+ "type": "string",
336
+ "enum": [
337
+ "GasID",
338
+ "RecycledID"
339
+ ]
340
+ }
341
+ },
342
+ "collection_slugs": {
343
+ "title": "Collection Slugs",
344
+ "description": "Array of collection slugs represented in the purchase",
345
+ "minItems": 1,
346
+ "type": "array",
347
+ "items": {
348
+ "title": "Collection Slug",
349
+ "description": "URL-friendly identifier for a collection",
350
+ "examples": [
351
+ "bold-cold-start-carazinho",
352
+ "bold-brazil"
353
+ ],
354
+ "type": "string",
355
+ "minLength": 1,
356
+ "maxLength": 100,
357
+ "pattern": "^[a-z0-9-]+$"
358
+ }
359
+ }
360
+ },
361
+ "required": [
362
+ "total_usdc_amount",
363
+ "total_credits",
364
+ "total_certificates",
365
+ "purchase_date",
366
+ "credit_symbols",
367
+ "certificate_types",
368
+ "collection_slugs"
369
+ ],
370
+ "additionalProperties": false
371
+ },
372
+ "parties": {
373
+ "title": "Parties",
374
+ "description": "Parties involved in the purchase including payer, receiver, and optional buyer",
375
+ "type": "object",
376
+ "properties": {
377
+ "payer": {
378
+ "title": "Payer Wallet Address",
379
+ "description": "Ethereum address paying for the purchase",
380
+ "examples": [
381
+ "0x1234567890abcdef1234567890abcdef12345678",
382
+ "0xabcdef1234567890abcdef1234567890abcdef12"
383
+ ],
384
+ "type": "string",
385
+ "pattern": "^0x[a-f0-9]{40}$"
386
+ },
387
+ "receiver": {
388
+ "title": "Receiver",
389
+ "description": "Receiver wallet and optional identity information",
390
+ "type": "object",
391
+ "properties": {
392
+ "wallet_address": {
393
+ "title": "Receiver Wallet Address",
394
+ "description": "Ethereum address of the receiver",
395
+ "examples": [
396
+ "0x1234567890abcdef1234567890abcdef12345678",
397
+ "0xabcdef1234567890abcdef1234567890abcdef12"
398
+ ],
399
+ "type": "string",
400
+ "pattern": "^0x[a-f0-9]{40}$"
401
+ },
402
+ "identity": {
403
+ "title": "Identity",
404
+ "description": "Participant identity information",
405
+ "type": "object",
406
+ "properties": {
407
+ "name": {
408
+ "title": "Identity Name",
409
+ "description": "Display name for the participant",
410
+ "examples": [
411
+ "EcoTech Solutions Inc."
412
+ ],
413
+ "type": "string",
414
+ "minLength": 1,
415
+ "maxLength": 100
416
+ },
417
+ "external_id": {
418
+ "title": "Identity External ID",
419
+ "description": "External identifier for the participant",
420
+ "examples": [
421
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
422
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
423
+ ],
424
+ "type": "string",
425
+ "format": "uuid",
426
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
427
+ },
428
+ "external_url": {
429
+ "title": "Identity External URL",
430
+ "description": "External URL for the participant profile",
431
+ "examples": [
432
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
433
+ "https://carrot.eco/whitepaper.pdf"
434
+ ],
435
+ "type": "string",
436
+ "format": "uri"
437
+ }
438
+ },
439
+ "required": [
440
+ "name",
441
+ "external_id",
442
+ "external_url"
443
+ ],
444
+ "additionalProperties": false
445
+ }
446
+ },
447
+ "required": [
448
+ "wallet_address"
449
+ ],
450
+ "additionalProperties": false
451
+ },
452
+ "buyer": {
453
+ "title": "Buyer",
454
+ "description": "Buyer identifier and optional identity information",
455
+ "type": "object",
456
+ "properties": {
457
+ "buyer_id": {
458
+ "title": "Buyer ID",
459
+ "description": "Unique identifier for the buyer",
460
+ "examples": [
461
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
462
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
463
+ ],
464
+ "type": "string",
465
+ "format": "uuid",
466
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
467
+ },
468
+ "identity": {
469
+ "title": "Identity",
470
+ "description": "Participant identity information",
471
+ "type": "object",
472
+ "properties": {
473
+ "name": {
474
+ "title": "Identity Name",
475
+ "description": "Display name for the participant",
476
+ "examples": [
477
+ "EcoTech Solutions Inc."
478
+ ],
479
+ "type": "string",
480
+ "minLength": 1,
481
+ "maxLength": 100
482
+ },
483
+ "external_id": {
484
+ "title": "Identity External ID",
485
+ "description": "External identifier for the participant",
486
+ "examples": [
487
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
488
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
489
+ ],
490
+ "type": "string",
491
+ "format": "uuid",
492
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
493
+ },
494
+ "external_url": {
495
+ "title": "Identity External URL",
496
+ "description": "External URL for the participant profile",
497
+ "examples": [
498
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
499
+ "https://carrot.eco/whitepaper.pdf"
500
+ ],
501
+ "type": "string",
502
+ "format": "uri"
503
+ }
504
+ },
505
+ "required": [
506
+ "name",
507
+ "external_id",
508
+ "external_url"
509
+ ],
510
+ "additionalProperties": false
511
+ }
512
+ },
513
+ "required": [
514
+ "buyer_id"
515
+ ],
516
+ "additionalProperties": false
517
+ }
518
+ },
519
+ "required": [
520
+ "payer",
521
+ "receiver"
522
+ ],
523
+ "additionalProperties": false
524
+ },
525
+ "collections": {
526
+ "title": "Collections",
527
+ "description": "Collections included in the purchase",
528
+ "minItems": 1,
529
+ "type": "array",
530
+ "items": {
531
+ "title": "Collection",
532
+ "description": "Collection included in the purchase",
533
+ "type": "object",
534
+ "properties": {
535
+ "slug": {
536
+ "title": "Collection Slug",
537
+ "description": "URL-friendly identifier for a collection",
538
+ "examples": [
539
+ "bold-cold-start-carazinho",
540
+ "bold-brazil"
541
+ ],
542
+ "type": "string",
543
+ "minLength": 1,
544
+ "maxLength": 100,
545
+ "pattern": "^[a-z0-9-]+$"
546
+ },
547
+ "external_id": {
548
+ "title": "Collection External ID",
549
+ "description": "External identifier for the collection",
550
+ "examples": [
551
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
552
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
553
+ ],
554
+ "type": "string",
555
+ "format": "uuid",
556
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
557
+ },
558
+ "name": {
559
+ "title": "Collection Name",
560
+ "description": "Display name of the collection",
561
+ "examples": [
562
+ "BOLD Cold Start - Carazinho",
563
+ "BOLD Brazil"
564
+ ],
565
+ "type": "string",
566
+ "minLength": 1,
567
+ "maxLength": 150
568
+ },
569
+ "external_url": {
570
+ "title": "Collection External URL",
571
+ "description": "External URL for the collection",
572
+ "examples": [
573
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
574
+ "https://carrot.eco/whitepaper.pdf"
575
+ ],
576
+ "type": "string",
577
+ "format": "uri"
578
+ },
579
+ "uri": {
580
+ "title": "Collection URI",
581
+ "description": "IPFS URI for the collection metadata",
582
+ "examples": [
583
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
584
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
585
+ ],
586
+ "type": "string",
587
+ "minLength": 1,
588
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
589
+ },
590
+ "credit_amount": {
591
+ "title": "Collection Credit Amount",
592
+ "description": "Total credits purchased from this collection",
593
+ "examples": [
594
+ 0,
595
+ 45.2,
596
+ 72.5
597
+ ],
598
+ "type": "number",
599
+ "minimum": 0
600
+ }
601
+ },
602
+ "required": [
603
+ "slug",
604
+ "external_id",
605
+ "name",
606
+ "external_url",
607
+ "uri",
608
+ "credit_amount"
609
+ ],
610
+ "additionalProperties": false
611
+ }
612
+ },
613
+ "credits": {
614
+ "title": "Credits",
615
+ "description": "Credits included in the purchase",
616
+ "minItems": 1,
617
+ "type": "array",
618
+ "items": {
619
+ "title": "Credit",
620
+ "description": "Credit token included in the purchase",
621
+ "type": "object",
622
+ "properties": {
623
+ "slug": {
624
+ "title": "Credit Slug",
625
+ "description": "URL-friendly identifier for the credit",
626
+ "examples": [
627
+ "mass-id-123",
628
+ "recycled-plastic",
629
+ "organic-waste"
630
+ ],
631
+ "type": "string",
632
+ "minLength": 1,
633
+ "maxLength": 100,
634
+ "pattern": "^[a-z0-9-]+$"
635
+ },
636
+ "symbol": {
637
+ "title": "Credit Token Symbol",
638
+ "description": "Symbol of the credit token",
639
+ "examples": [
640
+ "C-CARB",
641
+ "C-BIOW"
642
+ ],
643
+ "type": "string",
644
+ "minLength": 1,
645
+ "maxLength": 10,
646
+ "pattern": "^[A-Z0-9-]+$"
647
+ },
648
+ "external_id": {
649
+ "title": "Credit External ID",
650
+ "description": "External identifier for the credit",
651
+ "examples": [
652
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
653
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
654
+ ],
655
+ "type": "string",
656
+ "format": "uuid",
657
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
658
+ },
659
+ "external_url": {
660
+ "title": "Credit External URL",
661
+ "description": "External URL for the credit",
662
+ "examples": [
663
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
664
+ "https://carrot.eco/whitepaper.pdf"
665
+ ],
666
+ "type": "string",
667
+ "format": "uri"
668
+ },
669
+ "uri": {
670
+ "title": "Credit URI",
671
+ "description": "IPFS URI for the credit details",
672
+ "examples": [
673
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
674
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
675
+ ],
676
+ "type": "string",
677
+ "minLength": 1,
678
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
679
+ },
680
+ "smart_contract": {
681
+ "title": "Smart Contract",
682
+ "description": "Smart contract details for on-chain references",
683
+ "type": "object",
684
+ "properties": {
685
+ "address": {
686
+ "title": "Smart Contract Address",
687
+ "description": "Address of the smart contract",
688
+ "examples": [
689
+ "0x1234567890abcdef1234567890abcdef12345678",
690
+ "0xabcdef1234567890abcdef1234567890abcdef12"
691
+ ],
692
+ "type": "string",
693
+ "pattern": "^0x[a-f0-9]{40}$"
694
+ },
695
+ "chain_id": {
696
+ "title": "Chain ID",
697
+ "description": "Blockchain network identifier",
698
+ "examples": [
699
+ 1,
700
+ 137,
701
+ 11155111
702
+ ],
703
+ "type": "integer",
704
+ "minimum": 1,
705
+ "maximum": 9007199254740991
706
+ },
707
+ "network_name": {
708
+ "title": "Blockchain Network Name",
709
+ "description": "Name of the blockchain network",
710
+ "examples": [
711
+ "Polygon",
712
+ "Ethereum mainnet",
713
+ "Sepolia"
714
+ ],
715
+ "type": "string",
716
+ "minLength": 1,
717
+ "maxLength": 100
718
+ }
719
+ },
720
+ "required": [
721
+ "address",
722
+ "chain_id",
723
+ "network_name"
724
+ ],
725
+ "additionalProperties": false
726
+ },
727
+ "purchase_amount": {
728
+ "title": "Credit Purchase Amount",
729
+ "description": "Total credits purchased for this credit type",
730
+ "examples": [
731
+ 0,
732
+ 45.2,
733
+ 72.5
734
+ ],
735
+ "type": "number",
736
+ "minimum": 0
737
+ },
738
+ "retirement_amount": {
739
+ "title": "Credit Retirement Amount",
740
+ "description": "Credits retired immediately for this credit type during purchase",
741
+ "examples": [
742
+ 0,
743
+ 45.2,
744
+ 72.5
745
+ ],
746
+ "type": "number",
747
+ "minimum": 0
748
+ }
749
+ },
750
+ "required": [
751
+ "slug",
752
+ "symbol",
753
+ "external_id",
754
+ "external_url",
755
+ "uri",
756
+ "smart_contract",
757
+ "purchase_amount"
758
+ ],
759
+ "additionalProperties": false
760
+ }
761
+ },
762
+ "certificates": {
763
+ "title": "Certificates",
764
+ "description": "Certificates involved in the purchase",
765
+ "minItems": 1,
766
+ "type": "array",
767
+ "items": {
768
+ "title": "Certificate",
769
+ "description": "Certificate associated with the purchase",
770
+ "type": "object",
771
+ "properties": {
772
+ "token_id": {
773
+ "title": "Certificate Token ID",
774
+ "description": "Token ID of the certificate",
775
+ "examples": [
776
+ "123",
777
+ "456789",
778
+ "1000000"
779
+ ],
780
+ "type": "string",
781
+ "minLength": 1,
782
+ "pattern": "^\\d+$"
783
+ },
784
+ "type": {
785
+ "title": "Certificate Type",
786
+ "description": "Type of certificate (e.g., GasID, RecycledID)",
787
+ "type": "string",
788
+ "enum": [
789
+ "GasID",
790
+ "RecycledID"
791
+ ]
792
+ },
793
+ "external_id": {
794
+ "title": "Certificate External ID",
795
+ "description": "External identifier for the certificate",
796
+ "examples": [
797
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
798
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
799
+ ],
800
+ "type": "string",
801
+ "format": "uuid",
802
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
803
+ },
804
+ "external_url": {
805
+ "title": "Certificate External URL",
806
+ "description": "External URL for the certificate",
807
+ "examples": [
808
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
809
+ "https://carrot.eco/whitepaper.pdf"
810
+ ],
811
+ "type": "string",
812
+ "format": "uri"
813
+ },
814
+ "uri": {
815
+ "title": "Certificate URI",
816
+ "description": "IPFS URI for the certificate metadata",
817
+ "examples": [
818
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
819
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
820
+ ],
821
+ "type": "string",
822
+ "minLength": 1,
823
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
824
+ },
825
+ "smart_contract": {
826
+ "title": "Smart Contract",
827
+ "description": "Smart contract details for on-chain references",
828
+ "type": "object",
829
+ "properties": {
830
+ "address": {
831
+ "title": "Smart Contract Address",
832
+ "description": "Address of the smart contract",
833
+ "examples": [
834
+ "0x1234567890abcdef1234567890abcdef12345678",
835
+ "0xabcdef1234567890abcdef1234567890abcdef12"
836
+ ],
837
+ "type": "string",
838
+ "pattern": "^0x[a-f0-9]{40}$"
839
+ },
840
+ "chain_id": {
841
+ "title": "Chain ID",
842
+ "description": "Blockchain network identifier",
843
+ "examples": [
844
+ 1,
845
+ 137,
846
+ 11155111
847
+ ],
848
+ "type": "integer",
849
+ "minimum": 1,
850
+ "maximum": 9007199254740991
851
+ },
852
+ "network_name": {
853
+ "title": "Blockchain Network Name",
854
+ "description": "Name of the blockchain network",
855
+ "examples": [
856
+ "Polygon",
857
+ "Ethereum mainnet",
858
+ "Sepolia"
859
+ ],
860
+ "type": "string",
861
+ "minLength": 1,
862
+ "maxLength": 100
863
+ }
864
+ },
865
+ "required": [
866
+ "address",
867
+ "chain_id",
868
+ "network_name"
869
+ ],
870
+ "additionalProperties": false
871
+ },
872
+ "collection_slug": {
873
+ "title": "Collection Slug",
874
+ "description": "Slug of the collection this certificate belongs to",
875
+ "examples": [
876
+ "bold-cold-start-carazinho",
877
+ "bold-brazil"
878
+ ],
879
+ "type": "string",
880
+ "minLength": 1,
881
+ "maxLength": 100,
882
+ "pattern": "^[a-z0-9-]+$"
883
+ },
884
+ "total_amount": {
885
+ "title": "Certificate Total Amount",
886
+ "description": "Total credits available in this certificate",
887
+ "examples": [
888
+ 0,
889
+ 45.2,
890
+ 72.5
891
+ ],
892
+ "type": "number",
893
+ "minimum": 0
894
+ },
895
+ "purchased_amount": {
896
+ "title": "Certificate Purchased Amount",
897
+ "description": "Credits purchased from this certificate",
898
+ "examples": [
899
+ 0,
900
+ 45.2,
901
+ 72.5
902
+ ],
903
+ "type": "number",
904
+ "minimum": 0
905
+ },
906
+ "retired_amount": {
907
+ "title": "Certificate Retired Amount",
908
+ "description": "Credits retired from this certificate during the purchase (0 if none)",
909
+ "examples": [
910
+ 0,
911
+ 45.2,
912
+ 72.5
913
+ ],
914
+ "type": "number",
915
+ "minimum": 0
916
+ },
917
+ "credit_slug": {
918
+ "title": "Credit Slug",
919
+ "description": "Slug of the credit type for this certificate",
920
+ "examples": [
921
+ "carbon",
922
+ "organic"
923
+ ],
924
+ "type": "string",
925
+ "minLength": 1,
926
+ "maxLength": 100,
927
+ "pattern": "^[a-z0-9-]+$"
928
+ },
929
+ "mass_id": {
930
+ "title": "MassID Reference with Smart Contract",
931
+ "description": "Reference to a MassID record including smart contract details",
932
+ "type": "object",
933
+ "properties": {
934
+ "token_id": {
935
+ "title": "MassID Token ID",
936
+ "description": "NFT token ID of the MassID",
937
+ "examples": [
938
+ "123",
939
+ "456789",
940
+ "1000000"
941
+ ],
942
+ "type": "string",
943
+ "minLength": 1,
944
+ "pattern": "^\\d+$"
945
+ },
946
+ "external_url": {
947
+ "title": "MassID External URL",
948
+ "description": "URL to view the MassID on Carrot Explorer",
949
+ "examples": [
950
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
951
+ "https://carrot.eco/whitepaper.pdf"
952
+ ],
953
+ "type": "string",
954
+ "format": "uri"
955
+ },
956
+ "uri": {
957
+ "title": "MassID IPFS URI",
958
+ "description": "IPFS URI of the MassID record",
959
+ "examples": [
960
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
961
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
962
+ ],
963
+ "type": "string",
964
+ "minLength": 1,
965
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
966
+ },
967
+ "external_id": {
968
+ "title": "MassID External ID",
969
+ "description": "Unique identifier for the referenced MassID",
970
+ "examples": [
971
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
972
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
973
+ ],
974
+ "type": "string",
975
+ "format": "uuid",
976
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
977
+ },
978
+ "smart_contract": {
979
+ "title": "Smart Contract",
980
+ "description": "Smart contract details for on-chain references",
981
+ "type": "object",
982
+ "properties": {
983
+ "address": {
984
+ "title": "Smart Contract Address",
985
+ "description": "Address of the smart contract",
986
+ "examples": [
987
+ "0x1234567890abcdef1234567890abcdef12345678",
988
+ "0xabcdef1234567890abcdef1234567890abcdef12"
989
+ ],
990
+ "type": "string",
991
+ "pattern": "^0x[a-f0-9]{40}$"
992
+ },
993
+ "chain_id": {
994
+ "title": "Chain ID",
995
+ "description": "Blockchain network identifier",
996
+ "examples": [
997
+ 1,
998
+ 137,
999
+ 11155111
1000
+ ],
1001
+ "type": "integer",
1002
+ "minimum": 1,
1003
+ "maximum": 9007199254740991
1004
+ },
1005
+ "network_name": {
1006
+ "title": "Blockchain Network Name",
1007
+ "description": "Name of the blockchain network",
1008
+ "examples": [
1009
+ "Polygon",
1010
+ "Ethereum mainnet",
1011
+ "Sepolia"
1012
+ ],
1013
+ "type": "string",
1014
+ "minLength": 1,
1015
+ "maxLength": 100
1016
+ }
1017
+ },
1018
+ "required": [
1019
+ "address",
1020
+ "chain_id",
1021
+ "network_name"
1022
+ ],
1023
+ "additionalProperties": false
1024
+ }
1025
+ },
1026
+ "required": [
1027
+ "token_id",
1028
+ "external_url",
1029
+ "uri",
1030
+ "external_id",
1031
+ "smart_contract"
1032
+ ],
1033
+ "additionalProperties": false
1034
+ }
1035
+ },
1036
+ "required": [
1037
+ "token_id",
1038
+ "type",
1039
+ "external_id",
1040
+ "external_url",
1041
+ "uri",
1042
+ "smart_contract",
1043
+ "collection_slug",
1044
+ "total_amount",
1045
+ "purchased_amount",
1046
+ "retired_amount",
1047
+ "credit_slug",
1048
+ "mass_id"
1049
+ ],
1050
+ "additionalProperties": false
1051
+ }
1052
+ },
1053
+ "participant_rewards": {
1054
+ "title": "Participant Rewards",
1055
+ "description": "Rewards distributed to participants in the supply chain for this purchase",
1056
+ "minItems": 1,
1057
+ "type": "array",
1058
+ "items": {
1059
+ "title": "Participant Reward",
1060
+ "description": "Reward distribution for a participant",
1061
+ "type": "object",
1062
+ "properties": {
1063
+ "id_hash": {
1064
+ "title": "Participant ID Hash",
1065
+ "description": "Hash representing the participant identifier (SHA-256 hex string)",
1066
+ "examples": [
1067
+ "87f633634cc4b02f628685651f0a29b7bfa22a0bd841f725c6772dd00a58d489",
1068
+ "6e83b8e6373847bbdc056549bedda38dc88854ce41ba4fca11e0fc6ce3e07ef6"
1069
+ ],
1070
+ "type": "string",
1071
+ "pattern": "^[0-9a-fA-F]{64}$"
1072
+ },
1073
+ "participant_name": {
1074
+ "title": "Participant Name",
1075
+ "description": "Legal name of the participant receiving the reward",
1076
+ "examples": [
1077
+ "Enlatados Produção",
1078
+ "Eco Reciclagem",
1079
+ "Green Tech Corp"
1080
+ ],
1081
+ "type": "string",
1082
+ "minLength": 1,
1083
+ "maxLength": 100
1084
+ },
1085
+ "roles": {
1086
+ "title": "Participant Roles",
1087
+ "description": "Roles the participant has in the supply chain",
1088
+ "minItems": 1,
1089
+ "type": "array",
1090
+ "items": {
1091
+ "title": "Participant Role",
1092
+ "description": "Role that a participant plays in the waste management supply chain",
1093
+ "examples": [
1094
+ "Waste Generator",
1095
+ "Hauler",
1096
+ "Recycler"
1097
+ ],
1098
+ "type": "string",
1099
+ "minLength": 1,
1100
+ "maxLength": 100
1101
+ }
1102
+ },
1103
+ "usdc_amount": {
1104
+ "title": "USDC Reward Amount",
1105
+ "description": "USDC amount allocated to this participant",
1106
+ "examples": [
1107
+ 0,
1108
+ 45.2,
1109
+ 72.5
1110
+ ],
1111
+ "type": "number",
1112
+ "minimum": 0
1113
+ }
1114
+ },
1115
+ "required": [
1116
+ "id_hash",
1117
+ "participant_name",
1118
+ "roles",
1119
+ "usdc_amount"
1120
+ ],
1121
+ "additionalProperties": false
1122
+ }
1123
+ },
1124
+ "retirement": {
1125
+ "title": "Retirement",
1126
+ "description": "Immediate retirement details performed as part of purchase",
1127
+ "type": "object",
1128
+ "properties": {
1129
+ "beneficiary_id": {
1130
+ "title": "Retirement Beneficiary ID",
1131
+ "description": "UUID identifying the beneficiary of the retirement (bytes16 normalized to UUID)",
1132
+ "examples": [
1133
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
1134
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
1135
+ ],
1136
+ "type": "string",
1137
+ "format": "uuid",
1138
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
1139
+ },
1140
+ "retirement_receipt": {
1141
+ "title": "Retirement Receipt Reference",
1142
+ "description": "Reference to the retirement receipt NFT",
1143
+ "type": "object",
1144
+ "properties": {
1145
+ "token_id": {
1146
+ "title": "Retirement Receipt Token ID",
1147
+ "description": "Token ID of the retirement receipt NFT",
1148
+ "examples": [
1149
+ "123",
1150
+ "456789",
1151
+ "1000000"
1152
+ ],
1153
+ "type": "string",
1154
+ "minLength": 1,
1155
+ "pattern": "^\\d+$"
1156
+ },
1157
+ "external_id": {
1158
+ "title": "Retirement Receipt External ID",
1159
+ "description": "External identifier for the retirement receipt",
1160
+ "examples": [
1161
+ "ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
1162
+ "b2c4e6f8-a1b3-4c5d-9e8f-123456789abc"
1163
+ ],
1164
+ "type": "string",
1165
+ "format": "uuid",
1166
+ "pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-4[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$"
1167
+ },
1168
+ "external_url": {
1169
+ "title": "Retirement Receipt External URL",
1170
+ "description": "External URL for the retirement receipt",
1171
+ "examples": [
1172
+ "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
1173
+ "https://carrot.eco/whitepaper.pdf"
1174
+ ],
1175
+ "type": "string",
1176
+ "format": "uri"
1177
+ },
1178
+ "uri": {
1179
+ "title": "Retirement Receipt URI",
1180
+ "description": "IPFS URI for the retirement receipt metadata",
1181
+ "examples": [
1182
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
1183
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
1184
+ ],
1185
+ "type": "string",
1186
+ "minLength": 1,
1187
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
1188
+ },
1189
+ "smart_contract": {
1190
+ "title": "Smart Contract",
1191
+ "description": "Smart contract details for on-chain references",
1192
+ "type": "object",
1193
+ "properties": {
1194
+ "address": {
1195
+ "title": "Smart Contract Address",
1196
+ "description": "Address of the smart contract",
1197
+ "examples": [
1198
+ "0x1234567890abcdef1234567890abcdef12345678",
1199
+ "0xabcdef1234567890abcdef1234567890abcdef12"
1200
+ ],
1201
+ "type": "string",
1202
+ "pattern": "^0x[a-f0-9]{40}$"
1203
+ },
1204
+ "chain_id": {
1205
+ "title": "Chain ID",
1206
+ "description": "Blockchain network identifier",
1207
+ "examples": [
1208
+ 1,
1209
+ 137,
1210
+ 11155111
1211
+ ],
1212
+ "type": "integer",
1213
+ "minimum": 1,
1214
+ "maximum": 9007199254740991
1215
+ },
1216
+ "network_name": {
1217
+ "title": "Blockchain Network Name",
1218
+ "description": "Name of the blockchain network",
1219
+ "examples": [
1220
+ "Polygon",
1221
+ "Ethereum mainnet",
1222
+ "Sepolia"
1223
+ ],
1224
+ "type": "string",
1225
+ "minLength": 1,
1226
+ "maxLength": 100
1227
+ }
1228
+ },
1229
+ "required": [
1230
+ "address",
1231
+ "chain_id",
1232
+ "network_name"
1233
+ ],
1234
+ "additionalProperties": false
1235
+ }
1236
+ },
1237
+ "required": [
1238
+ "token_id",
1239
+ "external_id",
1240
+ "external_url",
1241
+ "uri",
1242
+ "smart_contract"
1243
+ ],
1244
+ "additionalProperties": false
1245
+ }
1246
+ },
1247
+ "required": [
1248
+ "beneficiary_id"
1249
+ ],
1250
+ "additionalProperties": false
1251
+ }
1252
+ },
1253
+ "required": [
1254
+ "summary",
1255
+ "parties",
1256
+ "collections",
1257
+ "credits",
1258
+ "certificates",
1259
+ "participant_rewards"
1260
+ ],
1261
+ "additionalProperties": false
1262
+ },
1263
+ "blockchain": {
1264
+ "title": "Blockchain Information",
1265
+ "description": "Blockchain-specific information for the NFT",
1266
+ "type": "object",
1267
+ "properties": {
1268
+ "smart_contract_address": {
1269
+ "title": "Smart Contract Address",
1270
+ "description": "A valid Ethereum address in hexadecimal format",
1271
+ "examples": [
1272
+ "0x1234567890abcdef1234567890abcdef12345678",
1273
+ "0xabcdef1234567890abcdef1234567890abcdef12"
1274
+ ],
1275
+ "type": "string",
1276
+ "pattern": "^0x[a-f0-9]{40}$"
1277
+ },
1278
+ "chain_id": {
1279
+ "title": "Chain ID",
1280
+ "description": "Blockchain chain ID",
1281
+ "examples": [
1282
+ 1,
1283
+ 137,
1284
+ 11155111
1285
+ ],
1286
+ "type": "integer",
1287
+ "minimum": 1,
1288
+ "maximum": 9007199254740991
1289
+ },
1290
+ "network_name": {
1291
+ "title": "Network Name",
1292
+ "description": "Name of the blockchain network",
1293
+ "type": "string",
1294
+ "minLength": 5,
1295
+ "maxLength": 100
1296
+ },
1297
+ "token_id": {
1298
+ "title": "Token ID",
1299
+ "description": "NFT token ID",
1300
+ "examples": [
1301
+ "123",
1302
+ "456789",
1303
+ "1000000"
1304
+ ],
1305
+ "type": "string",
1306
+ "minLength": 1,
1307
+ "pattern": "^\\d+$"
1308
+ }
1309
+ },
1310
+ "required": [
1311
+ "smart_contract_address",
1312
+ "chain_id",
1313
+ "network_name",
1314
+ "token_id"
1315
+ ],
1316
+ "additionalProperties": false
1317
+ },
1318
+ "name": {
1319
+ "title": "NFT Name",
1320
+ "description": "Full display name for this NFT, including extra context",
1321
+ "examples": [
1322
+ "MassID #123 • Organic • 3.0t",
1323
+ "RecycledID #456 • Plastic • 2.5t",
1324
+ "GasID #789 • Methane • 1000 m³"
1325
+ ],
1326
+ "type": "string",
1327
+ "minLength": 1,
1328
+ "maxLength": 100
1329
+ },
1330
+ "short_name": {
1331
+ "title": "Short Name",
1332
+ "description": "Compact name for UI summaries, tables, or tooltips",
1333
+ "examples": [
1334
+ "MassID #123",
1335
+ "RecycledID #456",
1336
+ "GasID #789"
1337
+ ],
1338
+ "type": "string",
1339
+ "minLength": 1,
1340
+ "maxLength": 50
1341
+ },
1342
+ "description": {
1343
+ "title": "Description",
1344
+ "description": "Human-readable summary of the NFT's role and context. Ideally, maximum 300 characters.",
1345
+ "examples": [
1346
+ "This MassID represents 3 metric tons of organic food waste from Enlatados Produção, tracked through complete chain of custody from generation to composting.",
1347
+ "This RecycledID represents 2.5 metric tons of recycled plastic bottles processed by Green Solutions Ltd."
1348
+ ],
1349
+ "type": "string",
1350
+ "minLength": 10,
1351
+ "maxLength": 500
1352
+ },
1353
+ "image": {
1354
+ "title": "Image URI",
1355
+ "description": "IPFS URI pointing to the preview image",
1356
+ "examples": [
1357
+ "ipfs://QmTy8w65yBXgyfG2ZBg5TrfB2hPjrDQH3RCQFJGkARStJb/mass-id-organic.png",
1358
+ "ipfs://QmYjtig7VJQ6XsnUjqqJvj7QaMcCAwtrgNdahSiFofrE7o"
1359
+ ],
1360
+ "type": "string",
1361
+ "minLength": 1,
1362
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
1363
+ },
1364
+ "background_color": {
1365
+ "title": "Background Color",
1366
+ "description": "Hex color code for marketplace background display",
1367
+ "examples": [
1368
+ "#2D5A27",
1369
+ "#FF5733",
1370
+ "#1E90FF"
1371
+ ],
1372
+ "type": "string",
1373
+ "minLength": 1,
1374
+ "pattern": "^#[0-9A-F]{6}$"
1375
+ },
1376
+ "animation_url": {
1377
+ "title": "Animation URL",
1378
+ "description": "IPFS URI pointing to an animated or interactive media file",
1379
+ "examples": [
1380
+ "ipfs://QmAnimation123/mass-id-animation.mp4",
1381
+ "ipfs://QmInteractive456/recycled-visualization.webm"
1382
+ ],
1383
+ "type": "string",
1384
+ "minLength": 1,
1385
+ "pattern": "^ipfs:\\/\\/[a-zA-Z0-9]+(\\/.*)?$"
1386
+ },
1387
+ "external_links": {
1388
+ "title": "External Links",
1389
+ "description": "Optional list of public resource links with labels",
1390
+ "examples": [
1391
+ [
1392
+ {
1393
+ "label": "Carrot Explorer",
1394
+ "url": "https://explore.carrot.eco/document/ad44dd3f-f176-4b98-bf78-5ee6e77d0530",
1395
+ "description": "Complete chain of custody and audit trail"
1396
+ },
1397
+ {
1398
+ "label": "Carrot White Paper",
1399
+ "url": "https://carrot.eco/whitepaper.pdf",
1400
+ "description": "Carrot Foundation technical and impact white paper"
1401
+ }
1402
+ ]
1403
+ ],
1404
+ "maxItems": 10,
1405
+ "type": "array",
1406
+ "items": {
1407
+ "title": "External Link",
1408
+ "description": "External link with label and description",
1409
+ "type": "object",
1410
+ "properties": {
1411
+ "label": {
1412
+ "title": "Link Label",
1413
+ "description": "Display name for the external link",
1414
+ "type": "string",
1415
+ "minLength": 1,
1416
+ "maxLength": 50
1417
+ },
1418
+ "url": {
1419
+ "title": "Link URL",
1420
+ "description": "Direct URI to the linked resource",
1421
+ "type": "string",
1422
+ "format": "uri"
1423
+ },
1424
+ "description": {
1425
+ "title": "Link Description",
1426
+ "description": "Optional context about what the link provides",
1427
+ "type": "string",
1428
+ "minLength": 10,
1429
+ "maxLength": 100
1430
+ }
1431
+ },
1432
+ "required": [
1433
+ "label",
1434
+ "url"
1435
+ ],
1436
+ "additionalProperties": false
1437
+ }
1438
+ },
1439
+ "attributes": {
1440
+ "title": "Credit Purchase Receipt NFT Attribute Array",
1441
+ "description": "Attributes for credit purchase receipts including per-credit breakdowns, totals, receiver, purchase date, and per-collection amounts. Attributes must have unique trait types.",
1442
+ "minItems": 5,
1443
+ "type": "array",
1444
+ "items": {
1445
+ "anyOf": [
1446
+ {
1447
+ "title": "Credit Attribute",
1448
+ "description": "Attribute representing purchased amount per credit token symbol",
1449
+ "type": "object",
1450
+ "properties": {
1451
+ "trait_type": {
1452
+ "title": "Credit Token Symbol",
1453
+ "description": "Symbol of the credit token (e.g., C-CARB, C-BIOW)",
1454
+ "examples": [
1455
+ "C-CARB",
1456
+ "C-BIOW"
1457
+ ],
1458
+ "type": "string",
1459
+ "minLength": 1,
1460
+ "maxLength": 10,
1461
+ "pattern": "^[A-Z0-9-]+$"
1462
+ },
1463
+ "value": {
1464
+ "title": "Credit Amount",
1465
+ "description": "Amount of credits purchased for the token symbol",
1466
+ "examples": [
1467
+ 0,
1468
+ 45.2,
1469
+ 72.5
1470
+ ],
1471
+ "type": "number",
1472
+ "minimum": 0
1473
+ },
1474
+ "display_type": {
1475
+ "type": "string",
1476
+ "const": "number"
1477
+ },
1478
+ "max_value": {
1479
+ "title": "Max Value",
1480
+ "description": "Maximum possible value for numeric traits",
1481
+ "examples": [
1482
+ 0,
1483
+ 45.2,
1484
+ 72.5
1485
+ ],
1486
+ "type": "number",
1487
+ "minimum": 0
1488
+ }
1489
+ },
1490
+ "required": [
1491
+ "trait_type",
1492
+ "value",
1493
+ "display_type"
1494
+ ],
1495
+ "additionalProperties": false
1496
+ },
1497
+ {
1498
+ "title": "Total Credits Purchased Attribute",
1499
+ "description": "Aggregate credits purchased attribute",
1500
+ "type": "object",
1501
+ "properties": {
1502
+ "trait_type": {
1503
+ "type": "string",
1504
+ "const": "Total Credits Purchased"
1505
+ },
1506
+ "value": {
1507
+ "title": "Total Credits Purchased",
1508
+ "description": "Total number of credits purchased across all tokens",
1509
+ "examples": [
1510
+ 0,
1511
+ 45.2,
1512
+ 72.5
1513
+ ],
1514
+ "type": "number",
1515
+ "minimum": 0
1516
+ },
1517
+ "display_type": {
1518
+ "type": "string",
1519
+ "const": "number"
1520
+ },
1521
+ "max_value": {
1522
+ "title": "Max Value",
1523
+ "description": "Maximum possible value for numeric traits",
1524
+ "examples": [
1525
+ 0,
1526
+ 45.2,
1527
+ 72.5
1528
+ ],
1529
+ "type": "number",
1530
+ "minimum": 0
1531
+ }
1532
+ },
1533
+ "required": [
1534
+ "trait_type",
1535
+ "value",
1536
+ "display_type"
1537
+ ],
1538
+ "additionalProperties": false
1539
+ },
1540
+ {
1541
+ "title": "Total USDC Amount Attribute",
1542
+ "description": "Aggregate USDC amount attribute",
1543
+ "type": "object",
1544
+ "properties": {
1545
+ "trait_type": {
1546
+ "type": "string",
1547
+ "const": "Total USDC Amount"
1548
+ },
1549
+ "value": {
1550
+ "title": "Total USDC Amount",
1551
+ "description": "Total USDC amount paid for the purchase",
1552
+ "examples": [
1553
+ 0,
1554
+ 45.2,
1555
+ 72.5
1556
+ ],
1557
+ "type": "number",
1558
+ "minimum": 0
1559
+ },
1560
+ "display_type": {
1561
+ "type": "string",
1562
+ "const": "number"
1563
+ },
1564
+ "max_value": {
1565
+ "title": "Max Value",
1566
+ "description": "Maximum possible value for numeric traits",
1567
+ "examples": [
1568
+ 0,
1569
+ 45.2,
1570
+ 72.5
1571
+ ],
1572
+ "type": "number",
1573
+ "minimum": 0
1574
+ }
1575
+ },
1576
+ "required": [
1577
+ "trait_type",
1578
+ "value",
1579
+ "display_type"
1580
+ ],
1581
+ "additionalProperties": false
1582
+ },
1583
+ {
1584
+ "title": "Purchase Date Attribute",
1585
+ "description": "Purchase date attribute using Unix timestamp in milliseconds",
1586
+ "type": "object",
1587
+ "properties": {
1588
+ "trait_type": {
1589
+ "type": "string",
1590
+ "const": "Purchase Date"
1591
+ },
1592
+ "value": {
1593
+ "title": "Purchase Date",
1594
+ "description": "Unix timestamp in milliseconds when the purchase was completed",
1595
+ "examples": [
1596
+ 1704067200000,
1597
+ 1735689600000,
1598
+ 1762371245149
1599
+ ],
1600
+ "type": "integer",
1601
+ "exclusiveMinimum": 0,
1602
+ "maximum": 9007199254740991
1603
+ },
1604
+ "display_type": {
1605
+ "type": "string",
1606
+ "const": "date"
1607
+ },
1608
+ "max_value": {
1609
+ "title": "Max Value",
1610
+ "description": "Maximum possible value for numeric traits",
1611
+ "examples": [
1612
+ 0,
1613
+ 45.2,
1614
+ 72.5
1615
+ ],
1616
+ "type": "number",
1617
+ "minimum": 0
1618
+ }
1619
+ },
1620
+ "required": [
1621
+ "trait_type",
1622
+ "value",
1623
+ "display_type"
1624
+ ],
1625
+ "additionalProperties": false
1626
+ },
1627
+ {
1628
+ "title": "Certificates Purchased Attribute",
1629
+ "description": "Attribute representing how many certificates were purchased",
1630
+ "type": "object",
1631
+ "properties": {
1632
+ "trait_type": {
1633
+ "type": "string",
1634
+ "const": "Certificates Purchased"
1635
+ },
1636
+ "value": {
1637
+ "title": "Certificates Purchased",
1638
+ "description": "Total number of certificates purchased",
1639
+ "examples": [
1640
+ 1,
1641
+ 123,
1642
+ 456
1643
+ ],
1644
+ "type": "integer",
1645
+ "minimum": 1,
1646
+ "maximum": 9007199254740991
1647
+ },
1648
+ "display_type": {
1649
+ "type": "string",
1650
+ "const": "number"
1651
+ },
1652
+ "max_value": {
1653
+ "title": "Max Value",
1654
+ "description": "Maximum possible value for numeric traits",
1655
+ "examples": [
1656
+ 0,
1657
+ 45.2,
1658
+ 72.5
1659
+ ],
1660
+ "type": "number",
1661
+ "minimum": 0
1662
+ }
1663
+ },
1664
+ "required": [
1665
+ "trait_type",
1666
+ "value",
1667
+ "display_type"
1668
+ ],
1669
+ "additionalProperties": false
1670
+ },
1671
+ {
1672
+ "title": "Receiver Attribute",
1673
+ "description": "Attribute containing the receiver display name",
1674
+ "type": "object",
1675
+ "properties": {
1676
+ "trait_type": {
1677
+ "type": "string",
1678
+ "const": "Receiver"
1679
+ },
1680
+ "value": {
1681
+ "title": "Receiver",
1682
+ "description": "Organization or individual receiving the credits from the purchase",
1683
+ "examples": [
1684
+ "EcoTech Solutions Inc."
1685
+ ],
1686
+ "type": "string",
1687
+ "minLength": 1,
1688
+ "maxLength": 100
1689
+ }
1690
+ },
1691
+ "required": [
1692
+ "trait_type",
1693
+ "value"
1694
+ ],
1695
+ "additionalProperties": false
1696
+ },
1697
+ {
1698
+ "title": "Collection Attribute",
1699
+ "description": "Attribute representing the amount of credits purchased from a collection",
1700
+ "type": "object",
1701
+ "properties": {
1702
+ "trait_type": {
1703
+ "title": "Collection Name",
1704
+ "description": "Display name of the collection",
1705
+ "examples": [
1706
+ "BOLD Cold Start - Carazinho",
1707
+ "BOLD Brazil"
1708
+ ],
1709
+ "type": "string",
1710
+ "minLength": 1,
1711
+ "maxLength": 150
1712
+ },
1713
+ "value": {
1714
+ "title": "Credits from Collection",
1715
+ "description": "Amount of credits purchased from the collection",
1716
+ "examples": [
1717
+ 0,
1718
+ 45.2,
1719
+ 72.5
1720
+ ],
1721
+ "type": "number",
1722
+ "minimum": 0
1723
+ },
1724
+ "display_type": {
1725
+ "type": "string",
1726
+ "const": "number"
1727
+ },
1728
+ "max_value": {
1729
+ "title": "Max Value",
1730
+ "description": "Maximum possible value for numeric traits",
1731
+ "examples": [
1732
+ 0,
1733
+ 45.2,
1734
+ 72.5
1735
+ ],
1736
+ "type": "number",
1737
+ "minimum": 0
1738
+ }
1739
+ },
1740
+ "required": [
1741
+ "trait_type",
1742
+ "value",
1743
+ "display_type"
1744
+ ],
1745
+ "additionalProperties": false
1746
+ }
1747
+ ]
1748
+ }
1749
+ }
1750
+ },
1751
+ "required": [
1752
+ "$schema",
1753
+ "schema",
1754
+ "created_at",
1755
+ "external_id",
1756
+ "external_url",
1757
+ "original_content_hash",
1758
+ "content_hash",
1759
+ "data",
1760
+ "blockchain",
1761
+ "name",
1762
+ "short_name",
1763
+ "description",
1764
+ "image",
1765
+ "attributes"
1766
+ ],
1767
+ "additionalProperties": false
1768
+ }