Operating Instructions
Operating Instructions
0)
The new basic domain for A2A services is:
https://tassidicambio.bancaditalia.it/terzevalute-wf-web/rest/v1.0
For the sake of brevity, the basic domain is omitted from the description of the URLs.
So, for example, instead of writing
GET https://tassidicambio.bancaditalia.it/terzevalute-wf-web/rest/v1.0/currencies
we will simply write GET /currencies
Or instead of writing
GET https://tassidicambio.bancaditalia.it/terzevalute-wf-web/rest/v1.0/latestRates?lang={}
we will simply write GET /latestRates?lang={}
The repeatable input parameters will be indicated in the URL in square brackets, for exeample:
GET /dailyRates?referenceDate={}[&baseCurrencyIsoCode={}]¤cyIsoCode={}&lang={}
Latest Rates
It provides the exchange rates, against the euro and the US dollar, on the latest day for which there are
quotations available for all the currencies quoted in the database.
GET /latestRates?lang={}
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Description
lang No The language in which you want the data: "it" or "en" may be used (case insensitive).
If the parameter is not specified or is incorrectly spelled, the results will be provided in the
default language.
1
Examples of responses:
Filename: latest_rates_yyyyMMdd.csv
Country,Currency,ISO Code,UIC Code,Euro,US dollar,Rate convention against Dollar,Rate convention against Euro,Reference date (CET)
AFGHANISTAN (Islamic State of),Afghani,AFN,115,79.6447,68.3939,Foreign currency amount for 1 Dollar,Foreign currency amount for 1 Euro ,2017-
11-02
ALBANIA,Lek,ALL,047,133.59,114.72,Foreign currency amount for 1 Dollar,Foreign currency amount for 1 Euro ,2017-11-02
ALGERIA,Algerian Dinar,DZD,106,134.1344,115.1863,Foreign currency amount for 1 Dollar,Foreign currency amount for 1 Euro ,2017-11-02
ANGOLA,Adjusted Kwanza,AOA,087,193.132,165.850,Foreign currency amount for 1 Dollar,Foreign currency amount for 1 Euro ,2017-11-02
ANTIGUA AND BARBUDA,East Caribbean Dollar,XCD,137,3.1442,2.70,Foreign currency amount for 1 Dollar,Foreign currency amount for 1 Euro
,2017-11-02
2
Daily Exchange Rates
It provides daily exchange rates for a specific date, against the euro, the US dollar or the Italian lira, for one
or more requested currencies, which are valid and for which the rates for the selected date are available. If
no currency is specified, the service will return all the available currencies. If there are no quotations for the
date and currencies selected, the service will return an empty list with an information message.
GET /dailyRates?referenceDate={}[&baseCurrencyIsoCode={}]¤cyIsoCode={}&lang={}
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Repeatable Description
referenceDate Yes No Quotation date. It is represented in relation to the Central European Time
Zone in the format "yyyy-MM-dd".
If the parameter is not specified or is specified incorrectly, the service will
return a message with the required format.
baseCurrencyIsoCode No Yes The ISO code for the currency for which you want the exchange rate (case
insensitive). In the case of multiple currencies, the parameter must be
repeated. If the parameter is not specified, all the currencies for which the
rate is available on the requested date will be returned. ISO codes that do
not exist will be discarded. If none of the ISO codes inserted exist, an empty
list will be shown.
For ISO codes specified incorrectly, the service will return an error message.
currencyIsoCode Yes No The currency ISO code (case insensitive) against which you want the rates.
It can be "EUR", "USD" or "ITL". If the parameter is not specified, or the
value is not valid, the service will return an error message.
lang No No The language in which you want the data: it can be "it" or "en" (case
insensitive).
If the parameter is not specified, or the value is incorrect, the results will be
provided in the default language.
3
Example of a response:
Filename: daily_rates_yyyyMM.csv
4
Average Monthly Exchange Rates
It provides average monthly exchange rates for a specific month/year, against the euro, the US dollar or the
Italian lira, for one or more valid currencies, and for which the rates are available. If there are no quotations
for the month and currencies selected, the service will return an empty list.
GET /monthlyAverageRates?month={}&year={}[&baseCurrencyIsoCode={}]¤cyIsoCode
={}&lang={}
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Repeatable Description
month Yes No Quotation month. Must be an integer between 1 and 12.
If the parameter is not specified or the value is incorrect, the
service will return an http 400 error and a message with the
required format, i.e. an integer between 1 and 12.
year Yes No Quotation year. Must be a 4-digit integer in the YYYY format.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
If there are no rates for the month/year pair, the service will
return an empty list.
baseCurrencyIsoCode No Yes The currency ISO code for which you want the exchange rate
(case insensitive). In the case of multiple currencies, the
parameter must be repeated. If the parameter is not specified,
all the currencies for which the rate is available on the
requested date will be returned. ISO codes that do not exist will
be discarded. If none of the ISO insert codes exist, an empty list
will be returned.
For ISO codes specified incorrectly, the service will return an
error message.
currencyIsoCode Yes No The ISO code of the currency against which you want the rates.
It can be "EUR", "USD" or "ITL". If the parameter is not specified,
or the value is not valid, the service will return an error
message.
lang No No The language in which you want the data: it can be "it" or "en"
(case insensitive).
If the parameter is not specified, or the value is not valid, the
results will be provided in the default language.
5
http response codes:
200 OK
500 Internal Server Error
503 Service Unavailable
400 Bad Request
408 Request Timeout
404 Not Found
Examples of responses:
6
Annual Average Exchange Rates
It provides the annual average rates, against the euro, the US dollar or the Italian lira, for one or more
requested currencies, which are valid and for which the rates for the selected month are available. If no
currency is specified, the service will return all the available currency rates. If there are no quotations for
the year and currencies selected, the service will return an empty list.
GET /annualAverageRates?year={}&[baseCurrencyIsoCode={}]¤cyIsoCode={}&lang={}
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Repeatable Description
year Yes No Quotation year. Must be a 4-digit integer in the YYYY format.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
If there are no rates available for the year, the service will
return an empty list.
baseCurrencyIsoCode No Yes The ISO code for the currency for which you want the exchange
rate (case insensitive). In the case of multiple currencies, the
parameter must be repeated. If the parameter is not specified,
all the currencies for which the rate is available on the
requested date will be returned. ISO codes that do not exist will
be discarded. If none of the ISO insert codes exist, an empty list
will be returned.
For ISO codes specified incorrectly, the service will return an
error message.
currencyIsoCode Yes No The ISO code of the currency against which you want the rates
(case insensitive). It can be "EUR", "USD" or "ITL". If the
parameter is not specified, or the value is not valid, the service
will return an error message.
lang No No The language in which you want the data: it can be "it" or "en"
(case insensitive).
If the parameter is not specified, or the value is not valid, the
results will be provided in the default language.
7
Examples of responses:
Filename: annual_average_rates_yyyy.csv
8
Daily Exchange rates - Time Series
It provides daily exchange rates for a currency with reference to a specific date range. The foreign currency
may be the euro, the US dollar or the Italian lira. If no rate is available for the range provided, the service
will return an empty list. The end date may not be earlier than the start date, otherwise the service will
return an error message.
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Repeatable Description
startDate Yes No Quotation start date. It is represented in relation to the Central
European Time Zone in the format "yyyy-MM-dd".
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
endDate Yes No Quotation end date. It is represented in relation to the Central
European Time Zone in the format "yyyy-MM-dd".
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
baseCurrencyIsoCode Yes No The ISO code for the currency for which you want the exchange
rate (case insensitive). If the ISO insert code does not exist, an
empty list will be returned.
If the parameter is specified incorrectly, the service will return
an error message.
currencyIsoCode Yes No The ISO code (case insensitive) for the currency against which
you want the rates. It can be "EUR", "USD" or "ITL". If the
parameter is not specified, or the value specified is not valid,
the service will return an error message.
lang No No The language in which you want the data: it can be "it" or "en"
(case insensitive).
If the parameter is not specified, or the value is incorrect, the
results will be provided in the default language.
9
Examples of responses:
Filename: <baseCurrencyIsoCode>_daily_time_series.csv
10
Monthly Exchange rates - Time Series
It provides monthly exchange rates for a currency for a specific month range. The foreign currency may be
the euro, the US dollar or the Italian lira. If no rate is available for the range provided, the service will return
an empty list. The start month/year pair must not be after the end month/year pair, otherwise the service
will return an error message.
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Repeatable Description
startMonth Yes No Quotation start month. Must be an integer between 1 and 12.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
startYear Yes No Quotation start year. Must be a 4-digit integer in the YYYY
format.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
endMonth Yes No Quotation end month.. Must be an integer between 1 and 12.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
endYear Yes No Quotation end year. Must be a 4-digit integer in the YYYY
format.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
If the endMonth/endYear comes before the
startMonth/startYear the service will return an error message.
baseCurrencyIsoCode Yes No The ISO code for the currency for which you want the exchange
rate (case insensitive). If the ISO insert code does not exist, an
empty list will be returned.
If the parameter is specified incorrectly, the service will return
an error message.
currencyIsoCode Yes No The ISO code of the currency against which you want the rates.
It can be "EUR", "USD" or "ITL". If the parameter is not specified,
or the value is not valid, the service will return an error
message.
lang No No The language in which you want the data: it can be "it" or "en"
(case insensitive).
If the parameter is not specified, or the value is not valid, the
results will be provided in the default language.
11
http response codes:
200 OK
500 Internal Server Error
503 Service Unavailable
400 Bad Request
408 Request Timeout
404 Not Found
Examples of responses:
12
Annual Average Exchange Rates - Time Series
It provides annual average exchange rates for a currency and for a specific year range. The foreign currency
may be the euro, the US dollar or the Italian lira. If no rate is available for the range provided, the service
will return an empty list. The start year must not be after the end year, otherwise the service will return an
error message.
Media types
The result is available in the following formats: json, pdf, csv, Excel, depending on the HTTP Accept header
parameter:
• Accept: application/json
• Accept: application/pdf
• Accept: text/csv
• Accept: application/vnd.ms-excel
Input Parameters
Name Required Repeatable Description
startYear Yes No Quotation start year. Must be a 4-digit integer in the YYYY
format.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
endYear Yes No Quotation end year. Must be a 4-digit integer in the YYYY
format.
If the parameter is not specified or is specified incorrectly, the
service will return a message with the required format.
If the endYear comes before the startYear, the service will
return an error message.
baseCurrencyIsoCode Yes No The ISO code for the currency for which you want the exchange
rate (case insensitive). If the ISO insert code does not exist, an
empty list will be returned.
If the parameter is specified incorrectly, the service will return
an error message.
currencyIsoCode Yes No The ISO code for the currency against which you want the
rates(case insensitive). It can be "EUR", "USD" or "ITL". If the
parameter is not specified, or the value is not valid, the service
will return an error message.
lang No No The language in which you want the data: it can be "it" or "en"
(case insensitive).
If the parameter is not specified, or the value is not valid, the
results will be provided in the default language.
13
Examples of responses:
14
List of Currencies
Returns a list of all currencies, including expired currencies.
GET /currencies?lang={}
Media types
The result is available in json format with the HTTP Accept header parameter:
• Accept: application/json
Input Parameters
Name Required Repeatable Description
lang No No The language in which you want the data: it can be "it" or "en"
(case insensitive).
If the parameter is not specified, or the value is not valid, the
results will be provided in the default language.
Examples of responses:
15
"currencyISO": "AED",
"country": "UNITED ARAB EMIRATES",
"countryISO": null,
"validityStartDate": "1981-06-15",
"validityEndDate": null
}
],
"isoCode": "AED",
"name": "U.A.E. Dirham",
"graph": false
} ]
}
16