add error statement for context
This commit is contained in:
40
pkg/plugin/schemas/ondc_trv10/v2.0.1/cancel.json
Normal file
40
pkg/plugin/schemas/ondc_trv10/v2.0.1/cancel.json
Normal file
@@ -0,0 +1,40 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "cancel",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/cancel.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "init.json#/allOf/2"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"order_id": {
|
||||
"type": "string"
|
||||
},
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": ["SOFT_CANCEL", "CONFIRM_CANCEL"]
|
||||
}
|
||||
},
|
||||
"required": ["code"]
|
||||
},
|
||||
"cancellation_reason_id": {
|
||||
"type": "string",
|
||||
"pattern": "^[0-9]+$"
|
||||
}
|
||||
},
|
||||
"required": ["order_id", "descriptor", "cancellation_reason_id"]
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
463
pkg/plugin/schemas/ondc_trv10/v2.0.1/confirm.json
Normal file
463
pkg/plugin/schemas/ondc_trv10/v2.0.1/confirm.json
Normal file
@@ -0,0 +1,463 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "confirm",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/confirm.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/2"
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "./on_select.json#/allOf/5"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"customer": {
|
||||
"properties": {
|
||||
"contact": {
|
||||
"properties": {
|
||||
"phone": {
|
||||
"type": "string",
|
||||
"pattern": "^\\+?[1-9]\\d{1,14}$"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"phone"
|
||||
]
|
||||
},
|
||||
"person": {
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"contact",
|
||||
"person"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"customer"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "./init.json#/allOf/7"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"payments": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"params": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"PRE-ORDER",
|
||||
"ON-FULFILLMENT",
|
||||
"POST-FULFILLMENT"
|
||||
]
|
||||
},
|
||||
"status": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"PAID",
|
||||
"NOT-PAID"
|
||||
]
|
||||
},
|
||||
"collected_by": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"BAP",
|
||||
"BPP"
|
||||
]
|
||||
},
|
||||
"tags": {
|
||||
"type": "array",
|
||||
"minItems": 2,
|
||||
"maxItems": 2,
|
||||
"uniqueItems": true,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"SETTLEMENT_TERMS",
|
||||
"BUYER_FINDER_FEES"
|
||||
]
|
||||
}
|
||||
},
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TERMS"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "STATIC_TERMS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_BASIS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"DELIVERY"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_WINDOW"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "DELAY_INTEREST"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TYPE"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"upi",
|
||||
"neft",
|
||||
"rtgs",
|
||||
"UPI",
|
||||
"NEFT",
|
||||
"RTGS"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_AMOUNT"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "MANDATORY_ARBITRATION"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"true",
|
||||
"false"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "COURT_JURISDICTION"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "BUYER_FINDER_FEES"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"enum": [
|
||||
"BUYER_FINDER_FEES_PERCENTAGE"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^-?\\d+(\\.\\d+)?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"descriptor"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"type",
|
||||
"status",
|
||||
"collected_by",
|
||||
"tags"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"payments": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"properties": {
|
||||
"type": {
|
||||
"type": "string"
|
||||
},
|
||||
"params": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"transaction_id": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"type"
|
||||
],
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"properties": {
|
||||
"type": {
|
||||
"const": "PRE-ORDER"
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"params": {
|
||||
"required": [
|
||||
"transaction_id"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"payments"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"not": {
|
||||
"required": [
|
||||
"id"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
550
pkg/plugin/schemas/ondc_trv10/v2.0.1/init.json
Normal file
550
pkg/plugin/schemas/ondc_trv10/v2.0.1/init.json
Normal file
@@ -0,0 +1,550 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "init",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/init.json#"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"context": {
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "./search.json#/properties/context/allOf/0"
|
||||
},
|
||||
{
|
||||
|
||||
"required": [
|
||||
"bpp_id",
|
||||
"bpp_uri"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"provider": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id"
|
||||
]
|
||||
},
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"provider",
|
||||
"items"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/4"
|
||||
},
|
||||
{
|
||||
"$ref": "./on_select.json#/allOf/7"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"required": [
|
||||
"fulfillments"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"order": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"payments": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"params": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"PRE-ORDER",
|
||||
"ON-FULFILLMENT",
|
||||
"POST-FULFILLMENT"
|
||||
]
|
||||
},
|
||||
"status": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"PAID",
|
||||
"NOT-PAID"
|
||||
]
|
||||
},
|
||||
"collected_by": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"BAP",
|
||||
"BPP"
|
||||
]
|
||||
},
|
||||
"tags": {
|
||||
"type": "array",
|
||||
"minItems": 2,
|
||||
"maxItems": 2,
|
||||
"uniqueItems": true,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"SETTLEMENT_TERMS",
|
||||
"BUYER_FINDER_FEES"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"descriptor"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"type",
|
||||
"status",
|
||||
"collected_by",
|
||||
"tags"
|
||||
],
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"const": "BAP"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"type": {
|
||||
"const": "PRE-ORDER"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"tags": {
|
||||
"items": {
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TERMS"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "STATIC_TERMS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_BASIS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"DELIVERY"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_WINDOW"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "DELAY_INTEREST"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"const": "BPP"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"type": {
|
||||
"const": "PRE-ORDER"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"tags": {
|
||||
"items": {
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TERMS"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "STATIC_TERMS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_BASIS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"DELIVERY"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_WINDOW"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"const": "BPP"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"type": {
|
||||
"const": "ON-FULFILLMENT"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"tags": {
|
||||
"items": {
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TERMS"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "STATIC_TERMS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_BASIS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"DELIVERY"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_WINDOW"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "DELAY_INTEREST"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"billing": {
|
||||
"required": [
|
||||
"name"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"billing"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_cancel.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_cancel.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_cancel",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_cancel.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
314
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_confirm.json
Normal file
314
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_confirm.json
Normal file
@@ -0,0 +1,314 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_confirm",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_confirm.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"provider": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["id"]
|
||||
}
|
||||
},
|
||||
"required": ["provider"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/5"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"fulfillment_ids": {
|
||||
"minItems": 1
|
||||
},
|
||||
"location_ids": {
|
||||
"minItems": 1
|
||||
}
|
||||
},
|
||||
"required": ["fulfillment_ids", "location_ids"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/4/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": ["DELIVERY"]
|
||||
}
|
||||
},
|
||||
"required": ["type"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"quote": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"currency": {
|
||||
"type": "string"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
},
|
||||
"required": ["currency", "value"]
|
||||
},
|
||||
"breakup": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"currency": {
|
||||
"type": "string"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
},
|
||||
"required": ["currency", "value"]
|
||||
},
|
||||
"title": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"BASE_FARE",
|
||||
"DISTANCE_FARE",
|
||||
"TAX",
|
||||
"DISCOUNT",
|
||||
"WAITING_CHARGE"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["price", "title"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["price", "breakup"]
|
||||
}
|
||||
},
|
||||
"required": ["quote"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"quote": {
|
||||
"properties": {
|
||||
"breakup": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"const": "BASE_FARE"
|
||||
},
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["value"]
|
||||
}
|
||||
},
|
||||
"required": ["title", "price"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"const": "DISTANCE_FARE"
|
||||
},
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["value"]
|
||||
}
|
||||
},
|
||||
"required": ["title", "price"]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/6"
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"cancellation_terms": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"fulfillment_state": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"RIDE_ASSIGNED",
|
||||
"RIDE_ENROUTE_PICKUP",
|
||||
"RIDE_ARRIVED_PICKUP",
|
||||
"RIDE_STARTED"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["code"]
|
||||
}
|
||||
},
|
||||
"required": ["descriptor"]
|
||||
},
|
||||
"cancellation_fee": {
|
||||
"oneOf": [
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"percentage": {
|
||||
"type": "string",
|
||||
"pattern": "^(100(\\.0{1,2})?|([0-9]{1,2})(\\.\\d{1,2})?)$"
|
||||
}
|
||||
},
|
||||
"required": ["percentage"]
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^[+-]?(\\d+(\\.\\d*)?|\\.\\d+)$"
|
||||
},
|
||||
"currency": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["currency", "value"]
|
||||
}
|
||||
},
|
||||
"required": ["amount"]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["fulfillment_state", "cancellation_fee"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["cancellation_terms"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": ["message"]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
317
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_init.json
Normal file
317
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_init.json
Normal file
@@ -0,0 +1,317 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_init",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_init.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"provider": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["id"]
|
||||
}
|
||||
},
|
||||
"required": ["provider"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/5"
|
||||
},
|
||||
{
|
||||
"$ref": "./on_select.json#/allOf/6"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"fulfillment_ids": {
|
||||
"minItems": 1
|
||||
},
|
||||
"location_ids": {
|
||||
"minItems": 1
|
||||
}
|
||||
},
|
||||
"required": ["fulfillment_ids", "location_ids"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/4/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": ["DELIVERY"]
|
||||
}
|
||||
},
|
||||
"required": ["type"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"quote": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"currency": {
|
||||
"type": "string"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
},
|
||||
"required": ["currency", "value"]
|
||||
},
|
||||
"breakup": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"currency": {
|
||||
"type": "string"
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
},
|
||||
"required": ["currency", "value"]
|
||||
},
|
||||
"title": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"BASE_FARE",
|
||||
"DISTANCE_FARE",
|
||||
"TAX",
|
||||
"DISCOUNT",
|
||||
"WAITING_CHARGE"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["price", "title"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["price", "breakup"]
|
||||
}
|
||||
},
|
||||
"required": ["quote"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"quote": {
|
||||
"properties": {
|
||||
"breakup": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"const": "BASE_FARE"
|
||||
},
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["value"]
|
||||
}
|
||||
},
|
||||
"required": ["title", "price"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"title": {
|
||||
"const": "DISTANCE_FARE"
|
||||
},
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["value"]
|
||||
}
|
||||
},
|
||||
"required": ["title", "price"]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"$ref": "./confirm.json#/allOf/6"
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"cancellation_terms": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"fulfillment_state": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"RIDE_ASSIGNED",
|
||||
"RIDE_ENROUTE_PICKUP",
|
||||
"RIDE_ARRIVED_PICKUP",
|
||||
"RIDE_STARTED"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["code"]
|
||||
}
|
||||
},
|
||||
"required": ["descriptor"]
|
||||
},
|
||||
"cancellation_fee": {
|
||||
"oneOf": [
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"percentage": {
|
||||
"type": "string",
|
||||
"pattern": "^(100(\\.0{1,2})?|([0-9]{1,2})(\\.\\d{1,2})?)$"
|
||||
}
|
||||
},
|
||||
"required": ["percentage"]
|
||||
},
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"amount": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^[+-]?(\\d+(\\.\\d*)?|\\.\\d+)$"
|
||||
},
|
||||
"currency": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["currency", "value"]
|
||||
}
|
||||
},
|
||||
"required": ["amount"]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["fulfillment_state", "cancellation_fee"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["cancellation_terms"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object"
|
||||
}
|
||||
},
|
||||
"required": ["message"]
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_rating.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_rating.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_rating",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_rating.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
644
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_search.json
Normal file
644
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_search.json
Normal file
@@ -0,0 +1,644 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_search",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_search.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"catalog": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"images": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"minItems": 1
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name"
|
||||
]
|
||||
},
|
||||
"providers": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
},
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"images": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "string"
|
||||
},
|
||||
"minItems": 1
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"name"
|
||||
]
|
||||
},
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"vehicle": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"category": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"AUTO_RICKSHAW",
|
||||
"CAB"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"category"
|
||||
]
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"DELIVERY"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"vehicle",
|
||||
"type"
|
||||
]
|
||||
}
|
||||
},
|
||||
"items": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"RIDE"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"code"
|
||||
]
|
||||
},
|
||||
"price": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^-?\\d+(\\.\\d+)?$"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"value",
|
||||
"currency"
|
||||
]
|
||||
},
|
||||
"fulfillment_ids": {
|
||||
"type": "array",
|
||||
"minItems": 1
|
||||
},
|
||||
"payment_ids": {
|
||||
"type": "array",
|
||||
"minItems": 1
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"descriptor",
|
||||
"price",
|
||||
"fulfillment_ids"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"id",
|
||||
"items",
|
||||
"fulfillments"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"providers"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"catalog"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"payments": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"BAP",
|
||||
"BPP"
|
||||
]
|
||||
},
|
||||
"tags": {
|
||||
"type": "array",
|
||||
"minItems": 2,
|
||||
"maxItems": 2,
|
||||
"uniqueItems": true,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"SETTLEMENT_TERMS",
|
||||
"BUYER_FINDER_FEES"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"descriptor"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"collected_by",
|
||||
"tags"
|
||||
],
|
||||
"allOf": [
|
||||
{
|
||||
"if": {
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"const": "BAP"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"tags": {
|
||||
"items": {
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TERMS"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "STATIC_TERMS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TYPE"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"upi",
|
||||
"neft",
|
||||
"rtgs",
|
||||
"UPI",
|
||||
"NEFT",
|
||||
"RTGS"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "DELAY_INTEREST"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "MANDATORY_ARBITRATION"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"true",
|
||||
"false"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "COURT_JURISDICTION"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"if": {
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"const": "BPP"
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"tags": {
|
||||
"items": {
|
||||
"if": {
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TERMS"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"then": {
|
||||
"properties": {
|
||||
"list": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "STATIC_TERMS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_TYPE"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"upi",
|
||||
"neft",
|
||||
"rtgs",
|
||||
"UPI",
|
||||
"NEFT",
|
||||
"RTGS"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "DELAY_INTEREST"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"pattern": "^\\d+(\\.\\d{1,2})?$"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "MANDATORY_ARBITRATION"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"true",
|
||||
"false"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "COURT_JURISDICTION"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_BASIS"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"DELIVERY"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"const": "SETTLEMENT_WINDOW"
|
||||
}
|
||||
}
|
||||
},
|
||||
"value": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"payments"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"catalog": {
|
||||
"properties": {
|
||||
"providers": {
|
||||
"items": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"items": {
|
||||
"properties": {
|
||||
"stops": {
|
||||
"allOf": [
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"location": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"gps": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"gps"
|
||||
]
|
||||
},
|
||||
"type": {
|
||||
"const": "START"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"location",
|
||||
"type"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"contains": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"location": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"gps": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"gps"
|
||||
]
|
||||
},
|
||||
"type": {
|
||||
"const": "END"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"location",
|
||||
"type"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"stops"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
227
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_select.json
Normal file
227
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_select.json
Normal file
@@ -0,0 +1,227 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_select",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_select.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"$ref": "./on_init.json#/allOf/2"
|
||||
},
|
||||
{
|
||||
"$ref": "./on_init.json#/allOf/5"
|
||||
},
|
||||
{
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"required": ["id"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["fulfillments"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"state": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"RIDE_ASSIGNED",
|
||||
"RIDE_ENROUTE_PICKUP",
|
||||
"RIDE_ARRIVED_PICKUP",
|
||||
"RIDE_STARTED",
|
||||
"RIDE_ENDED",
|
||||
"RIDE_CANCELLED"
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["code"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"properties": {
|
||||
"stops": {
|
||||
"items": {
|
||||
"properties": {
|
||||
"authorization": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": ["OTP"]
|
||||
},
|
||||
"token": {
|
||||
"type": "string",
|
||||
"pattern": "^-?\\d+(\\.\\d+)?$"
|
||||
}
|
||||
},
|
||||
"required": ["type", "token"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"items": {
|
||||
"properties": {
|
||||
"stops": {
|
||||
"type": "array",
|
||||
"minItems": 2,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"location": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"gps": { "type": "string" }
|
||||
},
|
||||
"required": ["gps"]
|
||||
},
|
||||
"type": {
|
||||
"enum": ["START", "END"]
|
||||
}
|
||||
},
|
||||
"required": ["location", "type"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["stops"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"minItems": 1,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"vehicle": {
|
||||
"properties": {
|
||||
"category": {
|
||||
"type": "string",
|
||||
"enum": ["AUTO_RICKSHAW", "CAB"]
|
||||
}
|
||||
},
|
||||
"required": ["category"]
|
||||
}
|
||||
},
|
||||
"required": ["vehicle"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["fulfillments"]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"$ref": "./on_init.json#/allOf/7"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"properties": {
|
||||
"order": {
|
||||
"properties": {
|
||||
"fulfillments": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"allOf": [
|
||||
{
|
||||
"not": {
|
||||
"required": ["agent"]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"$ref": "./on_init.json#/allOf/8"
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_status.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_status.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_status",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_status.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_support.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_support.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_support",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_support.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_track.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_track.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_track",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_track.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_update.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/on_update.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "on_update",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/on_update.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/rating.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/rating.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "rating",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/rating.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
146
pkg/plugin/schemas/ondc_trv10/v2.0.1/search.json
Normal file
146
pkg/plugin/schemas/ondc_trv10/v2.0.1/search.json
Normal file
@@ -0,0 +1,146 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "search",
|
||||
"allOf": [
|
||||
{ "$ref": "../../core/v1.1.0/search.json#" }
|
||||
],
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"context": {
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"properties": {
|
||||
"action": {
|
||||
"type": "string"
|
||||
},
|
||||
"location": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"city": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": { "type": "string" }
|
||||
},
|
||||
"required": ["code"]
|
||||
},
|
||||
"country": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": ["IND"]
|
||||
}
|
||||
},
|
||||
"required": ["code"]
|
||||
}
|
||||
},
|
||||
"required": ["city", "country"]
|
||||
},
|
||||
"bap_id": {
|
||||
"type": "string"
|
||||
},
|
||||
"bpp_id": {
|
||||
"type": "string"
|
||||
},
|
||||
"ttl": {
|
||||
"type": "string",
|
||||
"format": "duration"
|
||||
},
|
||||
"timestamp": {
|
||||
"type": "string",
|
||||
"format": "date-time"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
"location",
|
||||
"domain",
|
||||
"action",
|
||||
"message_id",
|
||||
"transaction_id",
|
||||
"timestamp",
|
||||
"bap_id",
|
||||
"bap_uri",
|
||||
"ttl"
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"message": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"intent": {
|
||||
"allOf": [
|
||||
{
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"payment": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"collected_by": {
|
||||
"type": "string",
|
||||
"enum": ["BPP", "BAP"]
|
||||
},
|
||||
"tags": {
|
||||
"type": "array",
|
||||
"minItems": 2,
|
||||
"maxItems": 2,
|
||||
"uniqueItems": true,
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"descriptor": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"code": {
|
||||
"type": "string",
|
||||
"enum": ["SETTLEMENT_TERMS", "BUYER_FINDER_FEES"]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["descriptor"]
|
||||
}
|
||||
}
|
||||
},
|
||||
"required": ["collected_by"]
|
||||
},
|
||||
"fulfillment": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"stops": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"location": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"gps": { "type": "string" }
|
||||
},
|
||||
"required": ["gps"]
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"enum": ["START", "END"]
|
||||
}
|
||||
},
|
||||
"required": ["location", "type"]
|
||||
},
|
||||
"minItems": 2
|
||||
}
|
||||
},
|
||||
"required": ["stops"]
|
||||
}
|
||||
},
|
||||
"required": ["payment", "fulfillment"]
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"required": ["intent"]
|
||||
}
|
||||
},
|
||||
"required": ["context", "message"]
|
||||
}
|
||||
|
||||
16
pkg/plugin/schemas/ondc_trv10/v2.0.1/select.json
Normal file
16
pkg/plugin/schemas/ondc_trv10/v2.0.1/select.json
Normal file
@@ -0,0 +1,16 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "select",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/select.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/2"
|
||||
}
|
||||
]
|
||||
}
|
||||
26
pkg/plugin/schemas/ondc_trv10/v2.0.1/status.json
Normal file
26
pkg/plugin/schemas/ondc_trv10/v2.0.1/status.json
Normal file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "status",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/status.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"order_id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["order_id"]
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/support.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/support.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "support",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/support.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/track.json
Normal file
13
pkg/plugin/schemas/ondc_trv10/v2.0.1/track.json
Normal file
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "track",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/track.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
}
|
||||
]
|
||||
}
|
||||
35
pkg/plugin/schemas/ondc_trv10/v2.0.1/update.json
Normal file
35
pkg/plugin/schemas/ondc_trv10/v2.0.1/update.json
Normal file
@@ -0,0 +1,35 @@
|
||||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "update",
|
||||
"type": "object",
|
||||
"allOf": [
|
||||
{
|
||||
"$ref": "../../core/v1.1.0/update.json#"
|
||||
},
|
||||
{
|
||||
"$ref": "./init.json#/allOf/1"
|
||||
},
|
||||
{
|
||||
"properties": {
|
||||
"message": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"order": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string"
|
||||
}
|
||||
},
|
||||
"required": ["id"]
|
||||
},
|
||||
"update_target": {
|
||||
"type": "string",
|
||||
"pattern": "^[^,]+(,[^,]+)*$"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user