Search
GET /v1/search
Ranked search over the catalog. Exact id matches rank first, then id-prefix matches, then name matches, then description matches. It powers the ⌘K search on the website. Public, no key.
| Param | Type | Default | Notes |
|---|---|---|---|
q |
string | required | Search text (at least 1 character) |
module |
string | - | Restrict to one module |
limit |
int | 20 | 1-50 |
curl "https://api.pakdatahub.com/v1/search?q=kibor&limit=3"
{ "success": true, "count": 3, "data": [
{ "id": "rates.kibor.1y", "module": "fixed-income", "name": "KIBOR 1-Year", "unit": "percent", "frequency": "daily", "source": "SBP", "tier": "basic" },
{ "id": "rates.kibor.3m", "module": "fixed-income", "name": "KIBOR 3-Month", "unit": "percent", "frequency": "daily", "source": "SBP", "tier": "basic" },
{ "id": "rates.kibor.6m", "module": "fixed-income", "name": "KIBOR 6-Month", "unit": "percent", "frequency": "daily", "source": "SBP", "tier": "basic" }
] }
Good queries
| Looking for | Try |
|---|---|
| Exchange rates | q=usd, q=exchange rate, q=reer |
| Inflation | q=cpi, q=cpi urban food, q=wpi |
| Rates | q=kibor, q=pkrv, q=policy, q=cut off yield |
| External sector | q=remittances, q=current account, q=reserves, q=foreign direct investment |
| Money & banking | q=broad money, q=m2, q=deposits, q=npl |
| Real economy | q=gdp, q=auto sales, q=electricity generation, q=cement |
| Payments | q=raast, q=pos, q=cards |
Then fetch the id with /v1/series/{id}. To filter rather than rank, use /v1/catalog?q=.