Obtener historial de tasas de cambio
curl --request GET \
--url https://api.qbank.cl/platform/v1/rates/history \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.qbank.cl/platform/v1/rates/history"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.qbank.cl/platform/v1/rates/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.qbank.cl/platform/v1/rates/history",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.qbank.cl/platform/v1/rates/history"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.qbank.cl/platform/v1/rates/history")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.qbank.cl/platform/v1/rates/history")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"account_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
"base": "USD",
"from": "2026-06-12",
"to": "2026-07-11",
"granularity": "day",
"rates": {
"chile": {
"currency": "CLP",
"series": [
{
"date": "2026-06-12",
"rate": "939.068965",
"payin_rate": "967.452325"
},
{
"date": "2026-06-13",
"rate": "940.886699",
"payin_rate": "969.325000"
},
{
"date": "2026-07-11",
"rate": "910.896551",
"payin_rate": "938.428400"
}
],
"first": "939.068965",
"last": "910.896551",
"change_pct": "-3.00"
},
"mexico": {
"currency": "MXN",
"series": [
{
"date": "2026-06-12",
"rate": "17.241379",
"payin_rate": "17.762500"
},
{
"date": "2026-07-11",
"rate": "17.832512",
"payin_rate": "18.371500"
}
],
"first": "17.241379",
"last": "17.832512",
"change_pct": "3.43"
}
},
"asset_prices": {
"BTC": {
"currency": "USD",
"unit": "btc",
"series": [
{
"date": "2026-06-12",
"price": "106214.55"
},
{
"date": "2026-07-11",
"price": "109853.24"
}
],
"first": "106214.55",
"last": "109853.24",
"change_pct": "3.43"
},
"GOLD": {
"currency": "USD",
"unit": "gram",
"series": [
{
"date": "2026-06-12",
"price": "106.8812"
},
{
"date": "2026-07-11",
"price": "107.5341"
}
],
"first": "106.8812",
"last": "107.5341",
"change_pct": "0.61"
},
"SILVER": {
"currency": "USD",
"unit": "gram",
"series": [
{
"date": "2026-06-12",
"price": "106.8812"
},
{
"date": "2026-07-11",
"price": "1.0700"
}
],
"first": "106.8812",
"last": "107.5341",
"change_pct": "0.61"
},
"PLATINUM": {
"currency": "USD",
"unit": "gram",
"series": [
{
"date": "2026-06-12",
"price": "106.8812"
},
{
"date": "2026-07-11",
"price": "35.0000"
}
],
"first": "106.8812",
"last": "107.5341",
"change_pct": "0.61"
}
},
"retrieved_at": "2026-07-11T15:00:00Z"
}{
"error": "invalid_range",
"message": "from and to are required (YYYY-MM-DD)"
}{
"error": "unauthorized",
"message": "invalid or missing credentials"
}{
"error": "account_required",
"message": "this endpoint requires an account credential"
}{
"error": "rates_unavailable",
"message": "could not fetch fx rate history"
}Obtener historial de tasas de cambio
Serie temporal de las tasas de cambio que aplican a la cuenta que llama, para gráficos de evolución. Cada punto trae las mismas tasas que obtendrías operando en ese momento — rate (punta de payouts) y payin_rate (punta de depósitos) — y cada país incluye first, last y el change_pct con signo entre ambos, listo para el badge “+3.4% / -3.0%”. asset_prices trae la serie de referencia USD de BTC y GOLD. Los buckets sin datos arrastran el valor anterior; los días previos al inicio del historial se omiten (jamás se inventan).
GET
/
v1
/
rates
/
history
Obtener historial de tasas de cambio
curl --request GET \
--url https://api.qbank.cl/platform/v1/rates/history \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.qbank.cl/platform/v1/rates/history"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.qbank.cl/platform/v1/rates/history', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.qbank.cl/platform/v1/rates/history",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.qbank.cl/platform/v1/rates/history"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.qbank.cl/platform/v1/rates/history")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.qbank.cl/platform/v1/rates/history")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"account_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
"base": "USD",
"from": "2026-06-12",
"to": "2026-07-11",
"granularity": "day",
"rates": {
"chile": {
"currency": "CLP",
"series": [
{
"date": "2026-06-12",
"rate": "939.068965",
"payin_rate": "967.452325"
},
{
"date": "2026-06-13",
"rate": "940.886699",
"payin_rate": "969.325000"
},
{
"date": "2026-07-11",
"rate": "910.896551",
"payin_rate": "938.428400"
}
],
"first": "939.068965",
"last": "910.896551",
"change_pct": "-3.00"
},
"mexico": {
"currency": "MXN",
"series": [
{
"date": "2026-06-12",
"rate": "17.241379",
"payin_rate": "17.762500"
},
{
"date": "2026-07-11",
"rate": "17.832512",
"payin_rate": "18.371500"
}
],
"first": "17.241379",
"last": "17.832512",
"change_pct": "3.43"
}
},
"asset_prices": {
"BTC": {
"currency": "USD",
"unit": "btc",
"series": [
{
"date": "2026-06-12",
"price": "106214.55"
},
{
"date": "2026-07-11",
"price": "109853.24"
}
],
"first": "106214.55",
"last": "109853.24",
"change_pct": "3.43"
},
"GOLD": {
"currency": "USD",
"unit": "gram",
"series": [
{
"date": "2026-06-12",
"price": "106.8812"
},
{
"date": "2026-07-11",
"price": "107.5341"
}
],
"first": "106.8812",
"last": "107.5341",
"change_pct": "0.61"
},
"SILVER": {
"currency": "USD",
"unit": "gram",
"series": [
{
"date": "2026-06-12",
"price": "106.8812"
},
{
"date": "2026-07-11",
"price": "1.0700"
}
],
"first": "106.8812",
"last": "107.5341",
"change_pct": "0.61"
},
"PLATINUM": {
"currency": "USD",
"unit": "gram",
"series": [
{
"date": "2026-06-12",
"price": "106.8812"
},
{
"date": "2026-07-11",
"price": "35.0000"
}
],
"first": "106.8812",
"last": "107.5341",
"change_pct": "0.61"
}
},
"retrieved_at": "2026-07-11T15:00:00Z"
}{
"error": "invalid_range",
"message": "from and to are required (YYYY-MM-DD)"
}{
"error": "unauthorized",
"message": "invalid or missing credentials"
}{
"error": "account_required",
"message": "this endpoint requires an account credential"
}{
"error": "rates_unavailable",
"message": "could not fetch fx rate history"
}Autorizaciones
Parámetros de consulta
Respuesta
Serie de tasas por país más series de precios de assets.