DEV Community

Youngjun Yoon
Youngjun Yoon

Posted on

Building a daily crypto market brief from two public APIs (Upbit + CoinGecko)

Every day I publish a one-page market brief for Korean readers: what Bitcoin and the majors did, why, and which flows moved. No scraping, no paid data vendor. Two public APIs, about 15 minutes of setup, and a short Python script do the data half.

Here is the whole pipeline, with the exact endpoints, the numbers it produced today (2026-11-14, 20:08 KST), and the traps that cost me time.

The two sources

  • Upbit Open API — Korean won prices, 24h volume, 52-week high/low, and the Korean-market premium that global sites do not show.
  • CoinGecko API — USD prices, total market cap, dominance, and the Fear & Greed value.

They answer different questions. CoinGecko tells you what the world pays. Upbit tells you what Koreans pay, which is often not the same number.

Endpoint 1: Korean won prices and volume

GET https://api.upbit.com/v1/ticker?markets=KRW-BTC,KRW-ETH,KRW-XRP,KRW-SOL
Enter fullscreen mode Exit fullscreen mode

Each row returns trade_price, signed_change_rate, acc_trade_price_24h (24h traded value in KRW), and highest_52_week_price with its date. Today's snapshot:

Market Price (KRW) 24h 24h traded value
KRW-BTC 92,000,000 -1.32% 139.3B KRW
KRW-ETH 2,607,000 -0.91% 62.4B KRW
KRW-XRP 1,353 -1.89% 129.4B KRW
KRW-SOL 103,600 -2.91% 31.2B KRW

Trap #1: one invalid market code fails the entire request with {"error":{"name":404,"message":"Code not found"}}. It does not return partial data. Fetch the market list once and intersect:

GET https://api.upbit.com/v1/market/all?is_details=false
Enter fullscreen mode Exit fullscreen mode

That call is also how I learned that ZEC and XMR have no KRW market at all, so a global-only narrative about privacy coins cannot be told with Korean prices.

Trap #2: acc_trade_price_24h is a rolling 24h value in KRW. Dividing by the FX rate gives you a dollar volume that will not match CoinGecko's, because the two use different aggregation windows. Do not mix them in one table without a footnote.

Endpoint 2: USD prices, dominance, sentiment

GET https://api.coingecko.com/api/v3/simple/price?ids=bitcoin,ethereum,solana,ripple&vs_currencies=usd&include_24hr_change=true&include_market_cap=true
GET https://api.coingecko.com/api/v3/global
GET https://api.coingecko.com/api/v3/coins/markets?vs_currency=usd&order=market_cap_desc&per_page=15&price_change_percentage=24h,7d
Enter fullscreen mode Exit fullscreen mode

Today: BTC $67,194 (-3.07%), ETH $1,905.29 (-2.42%), total market cap $2.27T (-6.2% in 24h), BTC dominance 59.51%, Fear & Greed 27.

The one derived number that beats both APIs

The Korean premium — how much more the won market pays than the dollar market:

premium = krw_price / (usd_price * usd_krw) - 1
Enter fullscreen mode Exit fullscreen mode

With USD/KRW at 1,336.18:

Asset Upbit KRW USD Premium
BTC 92,000,000 67,194 +2.49%
ETH 2,607,000 1,905.29 +2.43%
SOL 103,600 75.64 +2.52%
XRP 1,353 0.9884 +2.50%

Four assets landing within 0.1pp of each other is the signal: this is not coin-specific demand, it is the won market trading rich as a whole. On a day when Bitcoin lost 3%, Korean buyers were still paying a 2.5% premium. That is a flow observation you cannot get from a single global price feed.

Trap #3: use the FX rate for the same timestamp as the prices. A rate from yesterday's close can shift a 2.5% premium by 0.3pp, which is enough to flip the story.

Turning numbers into a brief

The data is the easy part. The part that took longer to get right is the structure that both humans and answer engines can read:

  1. A one-paragraph answer at the top ("BTC is $67,194, -3.07%; the four reasons are…").
  2. One table with units, timestamps, and the source per column.
  3. The "why" split into causes, each with a number attached.
  4. A short list of what to watch next, stated as conditions rather than predictions.
  5. An FAQ block with the exact questions people type.
  6. Sources with links, and a plain disclaimer.

That structure is why the same brief works as a blog post, a YouTube script skeleton, and the answer an AI assistant quotes back.

Where this runs

I run this as a daily pipeline for CPCAI, a Korean market-interpretation app that puts Upbit and Binance prices, crypto news, and FRED macro indicators on one screen: web.cp-club.co.kr. The editorial rule is simple: every number in a post must be reproducible by someone with a browser and a curl command.

On the automation side, the collection, cross-checking, and table generation are handled together with an AI assistant rather than typed by hand. If you are setting up something similar, this is the assistant I use: Pickle invite link.

Prices above are from 2026-11-14 20:08 KST. Nothing here is investment advice.

Top comments (0)