You need to pull the Thailand 10-year government bond yield into your models and dashboards, compare it against other maturities and benchmarks, and backtest strategies across specific periods. By the end of this guide, you will be able to fetch the latest Thailand 10Y yield, query historical and intraday values, construct the full Thai sovereign yield curve, compute spreads versus a benchmark, and summarize fluctuations — all through the Bonds-API REST endpoints.
What you get from Bonds-API for Thailand (TH)
Bonds-API delivers sovereign bond yields as JSON over HTTPS and uses a simple GET-only interface. For Thailand (ISO2: TH), you can retrieve:
- Latest yields for specific maturities (including 10Y)
- Historical yields on a given date
- Daily time series across a date range
- Intraday snapshots for a trading date
- Country-vs-benchmark spreads (e.g., TH vs US at 10Y)
- The full Thai yield curve
- Fluctuation stats (change, min, max) over a period
All fields and endpoints in this article come from Bonds-API. Explore more at https://bonds-api.com, or jump straight to key resources: Register for Bonds API, Bonds API MCP, and Get started with Bonds API.
Data model, units, and timestamps
Yields are returned as percentages (e.g., 4.52 means 4.52%). Spreads are returned in basis points (bps), where 1 bp = 0.01%. Dates use the Y-m-d format (for example, 2026-10-16). When timestamps appear (e.g., intraday), they are in ISO-8601 with UTC offset, and the intraday meta includes timezone information.
Each endpoint returns a subset of consistent fields such as country, maturity, date, yield, and source. “official” typically reflects the publishing authority or official consolidated feed; “market” indicates market snapshots.
Official sample response block (verbatim)
The following sample block is provided as-is by the API team. It shows a GET to the latest endpoint using a query parameter for the API key and a US 10Y response payload. It is included verbatim for reference.
curl -s "https://bonds-api.com/api/v1/latest?countries=US&maturities=10Y&api_key=YOUR_API_KEY"
{
"success": true,
"date": "2026-10-16",
"rates": {
"US_10Y": 5.079
},
"dates": {
"US_10Y": "2026-10-16"
},
"currencies": {
"US_10Y": "USD"
},
"meta": {
"request_id": "e5558888-b506-4517-914e-0f3b3ff2abb7",
"timestamp": "2026-10-16T00:06:47+00:00"
}
}
For the Thailand-focused integration below, you will use the standard Bonds-API authentication header and the Thailand ISO2 code (TH) with the documented endpoints.
Latest Thailand 10Y yield
Use the latest endpoint to fetch the most recent available yields for Thailand. You can request specific maturities (e.g., 10Y) or omit maturities to get all available tenors for the country.
Endpoint
GET https://bonds-api.com/api/v1/latest
Parameters
- countries: ISO2 list (e.g., TH)
- maturities: optional, comma-separated (e.g., 2Y,10Y)
cURL
JSON response (official sample)
How to read it: yield is a percentage, date is Y-m-d (market day), and source indicates data provenance. Use the 10Y object’s yield for the Thailand 10-year rate.
Python (requests)
import requests
resp = requests.get(
'https://bonds-api.com/api/v1/latest',
headers={'X-API-Key': 'YOUR_API_KEY'},
params={'countries': 'TH', 'maturities': '2Y,10Y'}
)
data = resp.json()
th_10y = data['data']['TH']['10Y']['yield']
th_10y_date = data['data']['TH']['10Y']['date']
print('TH 10Y:', th_10y, 'on', th_10y_date)
JavaScript (fetch)
async function fetchLatestTH() {
const url = new URL('https://bonds-api.com/api/v1/latest');
url.searchParams.set('countries', 'TH');
url.searchParams.set('maturities', '2Y,10Y');
const resp = await fetch(url.toString(), {
method: 'GET',
headers: {'X-API-Key': 'YOUR_API_KEY'}
});
const data = await resp.json();
const th10y = data.data.TH['10Y'].yield;
const asOf = data.data.TH['10Y'].date;
console.log('TH 10Y', th10y, 'as of', asOf);
}
fetchLatestTH();
PHP (file_get_contents)
<?php
$endpoint = 'https://bonds-api.com/api/v1/latest?countries=TH&maturities=2Y,10Y';
$opts = [
'http' => [
'method' => 'GET',
'header' => "X-API-Key: YOUR_API_KEY\r\n"
]
];
$ctx = stream_context_create($opts);
$json = file_get_contents($endpoint, false, $ctx);
$data = json_decode($json, true);
$yield10 = $data['data']['TH']['10Y']['yield'];
$date10 = $data['data']['TH']['10Y']['date'];
echo "TH 10Y $yield10 on $date10\n";
Historical Thailand 10Y yield (specific date)
When you need the Thailand 10Y yield for a precise date (e.g., for backtesting or point-in-time analytics), call the historical endpoint.
Endpoint
GET https://bonds-api.com/api/v1/historical
Parameters
- country: TH
- maturity: e.g., 10Y
- date: Y-m-d
cURL
JSON response (official sample)
Fields: yield is in percent; date is Y-m-d. If the date is a holiday or non-business day, the API returns the yield for that calendar date if available from the official source; otherwise you may get a 404 “No data” error.
Python (requests)
import requests
params = {'country': 'TH', 'maturity': '10Y', 'date': '2025-06-15'}
resp = requests.get('https://bonds-api.com/api/v1/historical',
headers={'X-API-Key': 'YOUR_API_KEY'},
params=params)
rec = resp.json()
print(rec['country'], rec['maturity'], rec['yield'], rec['date'])
JavaScript (fetch)
async function getTH10YOn(dateStr) {
const url = new URL('https://bonds-api.com/api/v1/historical');
url.searchParams.set('country', 'TH');
url.searchParams.set('maturity', '10Y');
url.searchParams.set('date', dateStr);
const r = await fetch(url, { headers: {'X-API-Key': 'YOUR_API_KEY'} });
const j = await r.json();
return j.yield;
}
getTH10YOn('2025-06-15').then(console.log);
PHP (file_get_contents)
<?php
$q = http_build_query(['country' => 'TH', 'maturity' => '10Y', 'date' => '2025-06-15']);
$uri = "https://bonds-api.com/api/v1/historical?$q";
$ctx = stream_context_create(['http' => ['method' => 'GET', 'header' => "X-API-Key: YOUR_API_KEY\r\n"]]);
$raw = file_get_contents($uri, false, $ctx);
$j = json_decode($raw, true);
echo $j['yield'];
Thailand 10Y time series
For charting and factor modeling, you’ll want a continuous daily series. The timeseries endpoint returns observations over a date range, one entry per market day.
Endpoint
GET https://bonds-api.com/api/v1/timeseries
Parameters
- country: TH
- maturity: e.g., 10Y
- start: Y-m-d
- end: Y-m-d (must be >= start)
cURL
JSON response (official sample)
Each entry is a daily closing or end-of-day representative yield in percent. Non-business days are omitted. Use the series array directly for charting or return analysis.
Python (requests)
import requests
import statistics as stats
params = {'country': 'TH', 'maturity': '10Y', 'start': '2025-10-16', 'end': '2026-10-16'}
j = requests.get('https://bonds-api.com/api/v1/timeseries',
headers={'X-API-Key': 'YOUR_API_KEY'},
params=params).json()
yields = [pt['yield'] for pt in j['series']]
print('Count:', len(yields), 'Avg:', sum(yields)/len(yields))
JavaScript (fetch)
async function getTH10YSeries(start, end) {
const u = new URL('https://bonds-api.com/api/v1/timeseries');
u.searchParams.set('country', 'TH');
u.searchParams.set('maturity', '10Y');
u.searchParams.set('start', start);
u.searchParams.set('end', end);
const r = await fetch(u, { headers: {'X-API-Key': 'YOUR_API_KEY'} });
return r.json();
}
getTH10YSeries('2025-10-16', '2026-10-16').then(({series}) => {
console.log(series.length, 'points');
});
PHP (file_get_contents)
<?php
$params = http_build_query(['country' => 'TH', 'maturity' => '10Y', 'start' => '2025-10-16', 'end' => '2026-10-16']);
$uri = "https://bonds-api.com/api/v1/timeseries?$params";
$ctx = stream_context_create(['http' => ['method' => 'GET', 'header' => "X-API-Key: YOUR_API_KEY\r\n"]]);
$raw = file_get_contents($uri, false, $ctx);
$data = json_decode($raw, true);
echo count($data['series']);
Thailand vs benchmark (spread in bps)
To compare Thailand’s yield to a benchmark (e.g., US Treasuries), use the spread endpoint. The maturity defaults to 10Y if omitted.
Endpoint
GET https://bonds-api.com/api/v1/spread
Parameters
- country: TH
- benchmark: ISO2 of benchmark (e.g., US)
- maturity: optional (e.g., 10Y)
cURL
JSON response (official sample)
Interpretation: spread_bps is the difference in basis points (country minus benchmark). country_yield and benchmark_yield are both percentages.
Python (requests)
import requests
p = {'country': 'TH', 'benchmark': 'US', 'maturity': '10Y'}
j = requests.get('https://bonds-api.com/api/v1/spread',
headers={'X-API-Key': 'YOUR_API_KEY'},
params=p).json()
print('TH-UST 10Y spread (bps):', j['spread_bps'])
JavaScript (fetch)
async function getTHSpread() {
const u = new URL('https://bonds-api.com/api/v1/spread');
u.searchParams.set('country', 'TH');
u.searchParams.set('benchmark', 'US');
u.searchParams.set('maturity', '10Y');
const r = await fetch(u, { headers: {'X-API-Key': 'YOUR_API_KEY'} });
const j = await r.json();
console.log(j.spread_bps, 'bps');
}
getTHSpread();
PHP (file_get_contents)
<?php
$p = http_build_query(['country' => 'TH', 'benchmark' => 'US', 'maturity' => '10Y']);
$u = "https://bonds-api.com/api/v1/spread?$p";
$ctx = stream_context_create(['http' => ['method' => 'GET', 'header' => "X-API-Key: YOUR_API_KEY\r\n"]]);
$j = json_decode(file_get_contents($u, false, $ctx), true);
echo $j['spread_bps'];
Full Thailand yield curve
The curve endpoint returns the entire cross-section of Thai sovereign yields for the latest available date (or a requested date). Use this to build interpolated curves or to compare term structure shifts over time.
Endpoint
GET https://bonds-api.com/api/v1/curve
Parameters
- country: TH
- date: optional Y-m-d; defaults to latest day with data
cURL
JSON response (official sample)
Fields: curve maps maturities to yields (percent). inverted indicates whether short-term rates exceed long-term rates in a way consistent with an inverted curve definition for the snapshot date.
Available Thai maturities in the sample
| Maturity | Yield (%) |
|---|---|
| 1M | 5.31 |
| 3M | 5.27 |
| 6M | 5.18 |
| 1Y | 4.98 |
| 2Y | 4.25 |
| 5Y | 4.39 |
| 10Y | 4.52 |
| 30Y | 4.71 |
Python (requests)
import requests
j = requests.get('https://bonds-api.com/api/v1/curve',
headers={'X-API-Key': 'YOUR_API_KEY'},
params={'country': 'TH'}).json()
curve = j['curve']
th_10y = curve.get('10Y')
print('Curve date:', j['date'], '10Y:', th_10y, 'Inverted:', j['inverted'])
JavaScript (fetch)
async function getTHCurve() {
const u = new URL('https://bonds-api.com/api/v1/curve');
u.searchParams.set('country', 'TH');
const r = await fetch(u, { headers: {'X-API-Key': 'YOUR_API_KEY'} });
const j = await r.json();
console.log('Inverted?', j.inverted, '10Y', j.curve['10Y']);
}
getTHCurve();
PHP (file_get_contents)
<?php
$uri = 'https://bonds-api.com/api/v1/curve?country=TH';
$ctx = stream_context_create(['http' => ['method' => 'GET', 'header' => "X-API-Key: YOUR_API_KEY\r\n"]]);
$j = json_decode(file_get_contents($uri, false, $ctx), true);
echo $j['curve']['10Y'];
Intraday Thailand 10Y snapshots
When you need multiple intraday points for the Thailand 10Y on a specific date (UTC-based timestamps), use the intraday endpoint. This is useful for real-time dashboards and for checking intraday volatility.
Endpoint
GET https://bonds-api.com/api/v1/intraday
Parameters
- country: TH
- maturity: 10Y
- date: Y-m-d
cURL
JSON response (official sample)
Fields: fetched_at is an ISO-8601 UTC timestamp; yields are percentages. Use count to validate completeness and meta.timezone to anchor downstream time alignment.
Python (requests)
import requests
from datetime import datetime
p = {'country': 'TH', 'maturity': '10Y', 'date': '2026-10-16'}
j = requests.get('https://bonds-api.com/api/v1/intraday',
headers={'X-API-Key': 'YOUR_API_KEY'},
params=p).json()
for s in j['snapshots']:
t = datetime.fromisoformat(s['fetched_at'].replace('Z', '+00:00'))
print(t.isoformat(), s['yield'])
JavaScript (fetch)
async function intradayTH10Y(dateStr) {
const u = new URL('https://bonds-api.com/api/v1/intraday');
u.searchParams.set('country', 'TH');
u.searchParams.set('maturity', '10Y');
u.searchParams.set('date', dateStr);
const r = await fetch(u, { headers: {'X-API-Key': 'YOUR_API_KEY'} });
const j = await r.json();
return j.snapshots;
}
intradayTH10Y('2026-10-16').then(console.log);
PHP (file_get_contents)
<?php
$p = http_build_query(['country' => 'TH', 'maturity' => '10Y', 'date' => '2026-10-16']);
$u = "https://bonds-api.com/api/v1/intraday?$p";
$ctx = stream_context_create(['http' => ['method' => 'GET', 'header' => "X-API-Key: YOUR_API_KEY\r\n"]]);
$j = json_decode(file_get_contents($u, false, $ctx), true);
echo $j['count'];
Fluctuation summary for Thailand 10Y
To quickly assess period performance — start yield, end yield, absolute change, min, and max — use the fluctuation endpoint. It accepts multiple countries, but we will focus on TH.
Endpoint
GET https://bonds-api.com/api/v1/fluctuation
Parameters
- countries: comma-separated (TH)
- maturity: e.g., 10Y
- start: Y-m-d
- end: Y-m-d
cURL
JSON response (official sample)
Fields: change is the arithmetic difference in percentage points (end minus start). min and max are the extremes during the requested period.
Python (requests)
import requests
p = {'countries': 'TH', 'maturity': '10Y', 'start': '2025-10-16', 'end': '2026-10-16'}
j = requests.get('https://bonds-api.com/api/v1/fluctuation',
headers={'X-API-Key': 'YOUR_API_KEY'},
params=p).json()
print(j['data']['TH'])
JavaScript (fetch)
async function thFluctuation10Y(start, end) {
const u = new URL('https://bonds-api.com/api/v1/fluctuation');
u.searchParams.set('countries', 'TH');
u.searchParams.set('maturity', '10Y');
u.searchParams.set('start', start);
u.searchParams.set('end', end);
const r = await fetch(u, { headers: {'X-API-Key': 'YOUR_API_KEY'} });
return r.json();
}
thFluctuation10Y('2025-10-16', '2026-10-16').then(console.log);
PHP (file_get_contents)
<?php
$q = http_build_query(['countries' => 'TH', 'maturity' => '10Y', 'start' => '2025-10-16', 'end' => '2026-10-16']);
$u = "https://bonds-api.com/api/v1/fluctuation?$q";
$ctx = stream_context_create(['http' => ['method' => 'GET', 'header' => "X-API-Key: YOUR_API_KEY\r\n"]]);
$j = json_decode(file_get_contents($u, false, $ctx), true);
print_r($j['data']['TH']);
Production notes: business days, updates, caching, and errors
- Business days and holidays: Time series exclude non-trading days; historical queries for a holiday may return 404 if no official value exists. Use the timeseries endpoint to avoid sparse dates.
- Update frequency: Latest values reflect the most recent available official or market data. For truly intra-day usage, call the intraday endpoint for snapshots.
- Caching: Cache country-maturity latest responses for several minutes if your app refreshes frequently. For historical and timeseries ranges, you can cache aggressively since these values are static once published.
- Error handling: Expect JSON with success=false and an error string. Common cases: 401 (missing/invalid key), 403 (quota exceeded), 404 (no data for the combination), 422 (invalid parameter), 429 (rate limit exceeded), and 500 (server error). Implement retries with backoff for 429/500 and surface 4xx errors to client logs.
For developer tooling and endpoint exploration, see the MCP. Refer to documentation on https://bonds-api.com for additional details.
Building a robust Thailand 10Y workflow
Yield curve construction
If your endpoint supports multiple symbols, you can build a curve by fetching a set of Thai maturities. With Bonds-API, the curve endpoint already returns a cross-section, which you can feed into interpolation (e.g., cubic spline) to derive missing points between 5Y and 10Y or beyond.
- Use /curve for the snapshot cross-section.
- For EOD charts, call /curve per desired date to track term structure shifts.
- To anchor a model on the 10Y, extract curve["10Y"].
Spreads and risk factors
- Compute TH 10Y minus US 10Y via /spread (spread_bps). This is useful for global macro dashboards and relative-value analysis.
- Track period changes in basis points using /fluctuation and convert change (in percentage points) to bps by multiplying by 100.
Dashboards and alerting
- Use /latest to populate top-line tiles for TH 2Y, 5Y, 10Y, 30Y.
- Use /timeseries to draw daily charts and compute rolling statistics (volatility, drawdowns).
- Use /intraday when you need session-level updates and to trigger alerts (e.g., TH 10Y moves by more than 10 bps within a window).
End-to-end example: get, chart, and compare TH 10Y
- Fetch the latest TH 10Y with /latest for your headline number.
- Pull /timeseries for 1–3 years to chart levels and compute moving averages.
- Call /spread (TH vs US, 10Y) to add relative value context.
- On days of interest, call /intraday for sub-daily moves and session summaries.
- Periodically, archive /curve outputs to analyze term structure dynamics.
All of the above rely on lightweight GET requests and a single header for auth. Browse and prototype through the Bonds API MCP, and consult the reference on https://bonds-api.com.
FAQ
Q1: What units are yields and spreads in?
A: Yields are percentages (e.g., 4.52 means 4.52%). Spreads from /spread are in basis points (bps); 1 bp = 0.01%.
Q2: How are dates and timestamps formatted?
A: Dates are Y-m-d (e.g., 2026-10-16). Intraday timestamps are ISO-8601 with UTC (e.g., 2026-10-16T12:00:00Z). The intraday meta includes timezone = “UTC”.
Q3: Why is my historical request returning 404?
A: If the specific country/maturity/date combination has no data (e.g., a holiday with no official print), the endpoint returns 404. Use the /timeseries endpoint for ranges to avoid sparse calendar dates.
Q4: Can I query multiple Thai maturities at once?
A: Yes. With /latest you can pass maturities=2Y,5Y,10Y,30Y. For the full cross-section, use /curve which returns all available tenors for that day.
Q5: How often should I call /intraday?
A: Align calls to your UI refresh policy and consider caching snapshots for a few minutes to control load. Handle 429 (rate limit) with exponential backoff.
Ready to integrate the Thailand 10-year bond yield into your stack? Get an API key and start building: Register. You can also explore endpoints and payloads interactively via the MCP.