feat(router): Make domain field optional for Beckn Protocol v2.x.x

This commit is contained in:
ameersohel45
2025-11-24 12:48:23 +05:30
parent 2f0956cd98
commit 6e6b066b80
14 changed files with 230 additions and 48 deletions

View File

@@ -1,13 +1,13 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: bpp
target:
url: https://gateway.example.com
endpoints:
- search
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: bpp
endpoints:
- select
@@ -16,7 +16,7 @@ routingRules:
- status
- cancel
- domain: ONDC:TRV12
version: 2.0.0
version: 1.1.0
targetType: bpp
endpoints:
- select

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: url
target:
url: https://services-backend/trv/v1
@@ -12,7 +12,7 @@ routingRules:
- on_update
- on_cancel
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: publisher
target:
publisherId: trv_topic_id1

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: bap
endpoints:
- on_search
@@ -11,7 +11,7 @@ routingRules:
- on_update
- on_cancel
- domain: ONDC:TRV11
version: 2.0.0
version: 1.1.0
targetType: bap
endpoints:
- on_search

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: url
target:
url: https://services-backend/trv/v1
@@ -11,14 +11,14 @@ routingRules:
- status
- cancel
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: publisher
target:
publisherId: trv_topic_id1
endpoints:
- search
- domain: ONDC:TRV11
version: 2.0.0
version: 1.1.0
targetType: url
target:
url: https://services-backend/trv/v1

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: bap
target:
url: https://mock_bap.com/v2/ondc

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: bpp
target:
url: https://mock_bpp.com/v2/ondc

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: url
target:
url: https://services-backend.com/v2/ondc

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: url
target:
url: https://services-backend.com/v2/ondc

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: publisher
target:
publisherId: test_topic

View File

@@ -1,6 +1,6 @@
routingRules:
- domain: ONDC:TRV10
version: 2.0.0
version: 1.1.0
targetType: url
target:
url: https://services-backend.com/v2/ondc

View File

@@ -0,0 +1,15 @@
routingRules:
- version: 2.0.0
targetType: bpp
target:
url: https://gateway.example.com
endpoints:
- search
- version: 2.0.0
targetType: bpp
endpoints:
- select
- init
- confirm
- status
- cancel

View File

@@ -0,0 +1,17 @@
routingRules:
- version: 2.0.0
targetType: url
target:
url: https://services-backend/trv/v2
endpoints:
- select
- init
- confirm
- status
- cancel
- version: 2.0.0
targetType: publisher
target:
publisherId: trv_topic_v2
endpoints:
- search