43 lines
745 B
JSON
43 lines
745 B
JSON
{
|
|
"$id": "orders",
|
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
"type": "object",
|
|
"required": [
|
|
"orderNumber",
|
|
"status",
|
|
"total"
|
|
],
|
|
"properties": {
|
|
"orderNumber": {
|
|
"type": "string"
|
|
},
|
|
"status": {
|
|
"type": "string",
|
|
"enum": [
|
|
"pending",
|
|
"processing",
|
|
"shipped",
|
|
"delivered",
|
|
"cancelled"
|
|
]
|
|
},
|
|
"total": {
|
|
"type": "number",
|
|
"minimum": 0
|
|
},
|
|
"date": {
|
|
"type": "string",
|
|
"format": "date-time"
|
|
},
|
|
"shippingAddress": {
|
|
"type": "string"
|
|
},
|
|
"customer": {
|
|
"type": "string",
|
|
"x-relation": {
|
|
"collection": "customers",
|
|
"type": "single"
|
|
}
|
|
}
|
|
}
|
|
} |