Exchange Rate POST

URI

https://{DATACENTER}.brightpearlconnect.com/public-api/{ACCOUNT}
/accounting-service/currency/{currency-id}/exchange-rate

Refer to our documentation on URI syntax for more information on how to construct URIs.

Description

Posts a new currency exchange rate for an existing currency. Base currency is not allowed. The rateActiveFrom element must be an ISO-8601 formatted date, with the time stamp elements ignored by the API.

Timestamps for the active date will be derived by the API according to the following rules:

  • For the current day, the time will be set to "now".
  • For future dates, the time will be set to "midnight" for the applicable date.

Exchange rates for dates prior to current date will produce a validation error and will not be added.

All rateActiveFrom dates will be stored as UTC based dates.

Exchange rates will be rounded to 6 decimal places.

Example

Posts a new exchange rate for an existing currency and returns number of table rows added.

Request URI

/currency/3/exchange-rate

Request body

{
	"rateActiveFrom": "2015-05-20T00:00:00.000Z",
	"rate": 1.090876
}

Response

{
	"response": 1
}