# Retrieve current rates

{% admonition type="warning" %}
The from, to, and group parameters are not testable in our Sandbox environment at this time.
{% /admonition %}

GET /v1/rates
Fetch latest exchange rates of all currencies.

GET /v1/rates?source=EUR&target=USD
Fetch latest exchange rate of one currency pair.

GET /v1/rates?source=EUR&target=USD&time=2019-02-13T14:53:01
Fetch exchange rate of specific historical timestamp.

GET /v1/rates?source=EUR&target=USD&from=2019-02-13T14:53:01&to=2019-03-13T14:53:01&group=day
Fetch exchange rate history over period of time with daily interval.

GET /v1/rates?source=EUR&target=USD&from=2019-02-13T14:53:01&to=2019-03-13T14:53:01&group=hour
Fetch exchange rate history over period of time with hourly interval.

GET /v1/rates?source=EUR&target=USD&from=2019-02-13T14:53:01&to=2019-03-13T14:53:01&group=minute
Fetch exchange rate history over period of time with 1 minute interval.

{% admonition type="warning" %}
This endpoint only supports Bearer authentication for non-Affiliate partners.
{% /admonition %}

Endpoint: GET /v1/rates
Security: UserToken, PersonalToken

## Query parameters:

  - `source` (string)
    Source (send) currency code.
    Example: "EUR"

  - `target` (string)
    Target (receive) currency code.
    Example: "USD"

  - `time` (string)
    Timestamp to get historic exchange rate. Supports only Timestamp (combined date and time). Timezone offset is supported but optional. Supported examples: 2019-03-13T14:53:01 or 2019-03-13T14:53:01+0100.
    Example: "2019-02-13T14:53:01"

  - `from` (string)
    Period start date/time to get exchange rate history. Supports Timestamp (combined date and time) or Date (date only). Supported examples: 2019-03-13T14:53:01 or 2019-03-13.
    Example: "2019-02-13T14:53:01"

  - `to` (string)
    Period end date/time to get exchange rate history. Supports Timestamp (combined date and time) or Date (date only). Timezone offset is supported but optional. Supported examples: 2019-03-13T14:53:01+0100 or 2019-03-13+0100.
    Example: "2019-03-13T14:53:01"

  - `group` (string)
    Interval for history grouping.
    Enum: "day", "hour", "minute"

## Response 200 fields (application/json):

  - `rate` (number, required)
    Exchange rate value.
    Example: 1.166

  - `source` (string, required)
    Source (send) currency code.
    Example: "EUR"

  - `target` (string, required)
    Target (receive) currency code.
    Example: "USD"

  - `time` (string, required)
    Timestamp for exchange rate.
    Example: "2018-08-31T10:43:31+0000"


## Response 400 fields
