Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 108 lines (91 sloc) 3.04 KB
schema({
"*id": String,
"*version": String,
"*url": String,
"*description": String,
"*updated": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*thingsCount": Number,
"*trackers-count": Number,
"*trackersTraversal-depth": Number,
"*maintainers": Array.of({
"name": String,
"*url": String,
"*email": String,
"*xIdentityMetadata": Object
}),
"things" : Array.of({
"id": String,
"title": String,
"*url": String,
"*downloadUrl": String,
"*refUrl": String,
"*authors": Array.of({
"name": String,
"*url": String,
"*email": String,
"*xIdentityMetadata": Object
}),
"*licenses": Array.of(String),
"*thumbnailUrls": Array.of(String),
"*description": String,
"*created": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*updated": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*metadata": {
"*created": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*updated": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*submitter": {
"name": String,
"*url": String,
"*email": String,
"*xIdentityMetadata": Object
},
},
"*subject": Array.of(String),
"*media": Array.of(String),
"*categories": Array.of(String),
"*tags": Array.of(String),
"*relationships": Array.of({
"*title": String,
"*type": String,
"*url": String,
"*xRelationshipMetadata": Object
}),
"*billOfMaterials": Array.of({
"*partNumber": String,
"*description": String,
"*type": /\bsource\b|\bgenerated\b|\bbom\b|\bimage\b|\bthing\b/,
"*url": String,
"*mimetype": String,
"*unit": String,
"*quantity": Number,
"*thumbnailUrl": String,
"*xBomMetadata": Object
}),
"*instructions": Array.of({
"*step": Number,
"*text": String,
"*imageUrls": Array.of(String),
"*xInstructionMetadata": Object
}),
"*xThingMetadata": Object
}),
"*thingsCache": {
"url": String,
"*thingsCount": Number,
"*updated": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*xThingsCacheMetadata": Object,
},
"*xTrackerMetadata": Object,
"*trackers" : Array.of({
"*id": String,
"*url": String,
"*accessed": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*status": /\bunknown\b|\bok\b|\berror\b/,
"*thingsCache": {
"url": String,
"*thingsCount": Number,
"*updated": /^\d{4}-[01]?[0-9]{1}-[0123]?[0-9]{1}T[012]?[0-9]{1}:[0-5]?[0-9]{1}:[0-5]?[0-9]{1}\.?\d+(([+|-]{1}\d+:\d+)|Z?)$/,
"*xThingsCacheMetadata": Object,
},
}),
})