Skip to content

Commit

Permalink
Pushed data changes
Browse files Browse the repository at this point in the history
  • Loading branch information
benjagm committed May 16, 2024
1 parent 0ba6ec2 commit c6e64f3
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 2 deletions.
6 changes: 4 additions & 2 deletions data/getting-started-examples.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
[
{
"name": "Getting Started Guide",
"name": "Getting Started example",
"default": true,
"file": "/data/getting-started-examples/schemas/default.json",
"instances": [
{
"name": "Basic valid instance",
"default": true,
"file": "/data/getting-started-examples/instances/default.json"
"valid": true,
"file": "/data/getting-started-examples/instances/default.json",
"details": "This is a valid JSON instance for the provided JSON Schema"
}
]
}
Expand Down
16 changes: 16 additions & 0 deletions data/getting-started-examples/instances/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"productId": 1,
"productName": "An ice sculpture",
"price": 12.50,
"tags": [ "cold", "ice" ],
"dimensions": {
"length": 7.0,
"width": 12.0,
"height": 9.5
},
"warehouseLocation": {
"latitude": -78.75,
"longitude": 20.4
}
}

52 changes: 52 additions & 0 deletions data/getting-started-examples/schemas/default.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://example.com/product.schema.json",
"title": "Product",
"description": "A product from Acme's catalog",
"type": "object",
"properties": {
"productId": {
"description": "The unique identifier for a product",
"type": "integer"
},
"productName": {
"description": "Name of the product",
"type": "string"
},
"price": {
"description": "The price of the product",
"type": "number",
"exclusiveMinimum": 0
},
"tags": {
"description": "Tags for the product",
"type": "array",
"items": {
"type": "string"
},
"minItems": 1,
"uniqueItems": true
},
"dimensions": {
"type": "object",
"properties": {
"length": {
"type": "number"
},
"width": {
"type": "number"
},
"height": {
"type": "number"
}
},
"required": [ "length", "width", "height" ]
},
"warehouseLocation": {
"description": "Coordinates of the warehouse where the product is located.",
"$ref": "https://example.com/geographical-location.schema.json"
}
},
"required": [ "productId", "productName", "price" ]
}

0 comments on commit c6e64f3

Please sign in to comment.