GET
View an exchange rate
Organization space Accounting module For: Accountant · Permission: exchange_rates.retrieve Conditions
  • The accounting module must be included in the plan of the organization.
  • Exchange rates belong to the organization, not to a book.
  • The caller needs an accounting access grant on at least one book of the organization. This is checked before validation.
Part of Set up the books.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

exchangeRate
string
required

Identifier of the exchange rate (27-character KSUID).

Query Parameters

response
enum<string>
default:resource

Response mode. Default resource; none answers 204 No Content.

Available options:
resource
fields
string

Comma-separated JSON keys of the root resource (id is always rendered). Available: id, source_currency_code, source_currency_exponent, target_currency_code, target_currency_exponent, direction, rate, valid_from, valid_to, created_by, created_by_type, created_at.

include
string

Comma-separated include paths, each optionally followed by its fields in parentheses: units(id,sku),units.uomUnit(id,name). Max depth 6, max 40 paths. Available: .

Response

Resource.

id

Identifier of the exchange rate (27-character KSUID).

source_currency_code

Three-letter code of the currency converted from.

source_currency_exponent
integer

Number of decimal places of the source currency (divide an amount in minor units by 10 to this power).

target_currency_code

Three-letter code of the currency converted to.

target_currency_exponent
integer

Number of decimal places of the target currency.

direction

Money flow the rate applies to: incoming (money received) or outgoing (money paid out, such as refunds).

rate

Exchange rate: how many units of the target currency one unit of the source currency is worth, as an exact decimal string with no trailing zeros.

valid_from

First day the rate applies (YYYY-MM-DD).

valid_to

Last day the rate applies (YYYY-MM-DD); null while the rate is open-ended.

created_by

Identifier of the member or agent account that created the rate; null when it could not be identified.

created_by_type

Type of the creator (member or agent account); null when unknown.

created_at

Date and time the record was created (ISO 8601, UTC).