diff --git a/config/v3/exchange_rates/receive.json b/config/v3/exchange_rates/receive.json index 1a5c8391..251ddce6 100644 --- a/config/v3/exchange_rates/receive.json +++ b/config/v3/exchange_rates/receive.json @@ -29,7 +29,37 @@ "patternProperties": { "^[a-zA-Z0-9]{2,20}$": { "description": "The rate of exchanging a unit of the base currency into a target currency (represented by the key)", - "type": "number" + "type": [ + "number", + "object" + ], + "oneOf": [ + { + "type": "object", + "additionalProperties": false, + "required": [ + "spot_rate" + ], + "properties": { + "ask_rate": { + "description": "[Optional] The ask rate of exchanging a unit of the base currency into a target currency", + "type": "number" + }, + "bid_rate": { + "description": "[Optional] The bid rate of exchanging a unit of the base currency into a target currency", + "type": "number" + }, + "spot_rate": { + "description": "The spot rate of exchanging a unit of the base currency into a target currency", + "type": "number" + } + } + }, + { + "description": "The rate of exchanging a unit of the base currency into a target currency (represented by the key)", + "type": "number" + } + ] } } } diff --git a/config/v3/exchange_rates/send.json b/config/v3/exchange_rates/send.json index df036c46..20d7bbd8 100644 --- a/config/v3/exchange_rates/send.json +++ b/config/v3/exchange_rates/send.json @@ -22,6 +22,13 @@ "type": "string", "pattern": "^[a-zA-Z0-9]{2,20}$" }, + "include_spread": { + "description": "[Optional] 1 - Request for ask and bid rates along with the spot rate. Only available if target_currency is provided.", + "type": "integer", + "enum": [ + 1 + ] + }, "subscribe": { "description": "[Optional] 1 - to initiate a realtime stream of exchange rates relative to base currency.", "type": "integer",