Government APIs k-skill Supports for AI Agents: Complete Reference
k-skill supports over a dozen Korean government APIs including KOSIS statistics, MOLIT real-estate data, ECOS economic indicators, and Seoul City transport data, routing all requests through a secure proxy layer so AI agents never handle raw authentication keys.
The NomaDamas/k-skill repository provides a comprehensive integration layer that enables AI agents to query Korean public-sector data sources without managing complex authentication flows. By normalizing disparate government endpoints into a unified interface, k-skill allows developers to retrieve statistics, legal information, and real-time civic data using simple skill commands.
National Statistics and Economic Data
KOSIS Open API (Statistics Korea)
The KOSIS Open API from Statistics Korea (통계청) provides national statistics covering population trends, economic indicators, and demographic data. According to the source documentation in docs/sources.md (lines 9-10), k-skill exposes this through the k-skill-proxy via routes /v1/kosis/search, /v1/kosis/meta, and /v1/kosis/data, forwarding requests to https://kosis.kr/openapi/....
The implementation resides in packages/k-skill-cli/helpers/kosis.js, which normalizes the response into a typed structure for AI agents. Accessing "big-data" queries requires a free KOSIS API key, injected securely by the proxy rather than exposed to the agent.
Bank of Korea ECOS API
For macroeconomic data such as GDP and CPI, k-skill integrates the Bank of Korea ECOS API. The proxy route /v1/ecos/* maps to https://ecos.bok.or.kr/api/... as documented in docs/sources.md (line 298). A free demo key is available for development, with production keys injected via environment variables.
Real Estate and Infrastructure
MOLIT Housing APIs
The Ministry of Land, Infrastructure and Transport (MOLIT) provides real-estate transaction data through multiple endpoints. k-skill supports apartment trades, rentals, office buildings, and multi-family units via routes /v1/molit/apt-trade, /v1/molit/apt-rent, and related paths (documented in docs/sources.md, lines 115-122).
These routes forward to https://apis.data.go.kr/1613000/... and are implemented in packages/k-skill-cli/helpers/molit.js. The helper handles the complex parameter mapping required for region-specific queries, allowing agents to specify simple arguments like --city Seoul.
EV-Charger Open API
Public electric vehicle charging station data comes from the 공공데이터포털 (Public Data Portal). The routes /v1/ev-charger/info and /v1/ev-charger/status provide location and real-time availability data, implemented in packages/k-skill-cli/helpers/evCharger.js (referenced in docs/sources.md, line 13).
Legal and Intellectual Property
Korean Law Information API
The 법제처 국가법령정보 Open API grants access to Korean statutes, regulations, and case law. k-skill exposes this via /v1/korean-law/* routes that proxy to https://open.law.go.kr/..., with implementation details in packages/k-skill-cli/helpers/koreanLaw.js (see docs/sources.md, line 129).
KIPRIS Plus Patent API
For intellectual property queries, the KIPRIS Plus 특허/실용신안 API provides patent and utility model information from the government-run KIPRIS system. The proxy route /v1/kipris-plus/* forwards to https://plus.kipris.or.kr/..., implemented in packages/k-skill-cli/helpers/kiprisPlus.js (documented in docs/sources.md, line 207).
Public Safety and Cultural Data
Cultural Heritage Administration API
The 국가유산청 (Cultural Heritage Administration) Open API lists heritage sites, detailed descriptions, and events. k-skill exposes endpoints /v1/khs/list, /v1/khs/detail, and /v1/khs/event (mapping to https://www.khs.go.kr/...), with the helper logic in packages/k-skill-cli/helpers/khs.js (see docs/sources.md, lines 292-295).
Han River Flood Control Office API
River-level and flood-control data from the 한강홍수통제소 is available via /v1/hrfco/* routes that proxy to https://api.hrfco.kr/... (documented in docs/sources.md, lines 229-232).
Food Safety API
The 식품안전나라 (Food Safety) API provides inspection data through the I0490 dataset. Routes under /v1/food-safety/* forward to https://www.foodsafetykorea.go.kr/... (see docs/sources.md, line 108).
Municipal and Transport Services
Seoul City Open API
Real-time municipal data including subway schedules, fine dust measurements, 따릉이 (bike-share) status, and weather forecasts are accessible through the Seoul City Open API. The proxy route /v1/seoul/* maps to https://openapi.seoul.go.kr/..., handling the authentication required by the Seoul metropolitan endpoints.
OPINET Fuel Price API
Fuel-price and gas station information is available via the OPINET 주유소 API. k-skill supports location-based queries and detailed station lookups through routes /v1/opinet/aroundAll and /v1/opinet/detailById, forwarding to https://www.opinet.co.kr/... (see packages/k-skill-cli/helpers/opinet.js and docs/sources.md, lines 211-214).
General Data.go.kr Integration
Beyond specific implementations, k-skill provides a generic routing layer for various 공공데이터포털 (Data.go.kr) datasets including building registers and waste management data. These are handled dynamically through the proxy when a valid service key is supplied, as noted in docs/sources.md (line 61).
Proxy Architecture and Security Model
All government API requests flow through the k-skill-proxy server defined in packages/k-skill-proxy/src/server.js. This architecture ensures AI agents never possess raw government API credentials.
The request flow follows four stages:
- Skill Invocation – An AI agent calls a skill such as
korean-housing-pricewith arguments like--city Seoul. - Helper Processing – The skill invokes a helper from
packages/k-skill-cli/helpers/(e.g.,molit.js,kosis.js), which constructs a normalized HTTP request. - Proxy Routing – The helper sends the request to
https://k-skill-proxy.nomadamas.org. The proxy injects required headers (e.g.,KSKILL_KOSIS_API_KEY) and forwards to the upstream government endpoint. - Response Normalization – The proxy returns the upstream JSON/XML, which the helper parses into a clean, typed structure for the agent.
This pattern is consistent across all supported government APIs, with packages/k-skill-proxy/src/server.js handling rate-limiting, caching, and authentication for every /v1/* route.
Practical Usage Examples
The following commands demonstrate how AI agents invoke government APIs through k-skill:
Retrieve national population statistics via KOSIS:
k-skill exec korean-statistics \
--dataset "population" \
--year 2024
Query real-estate transaction data from MOLIT:
k-skill exec korean-housing-price \
--city "Seoul" \
--type "apt" \
--year 2023
Check EV charging station availability:
k-skill exec ev-charger-status \
--region "Seoul"
Each command routes through the respective helper and proxy layers described above, translating simple CLI arguments into authenticated government API calls.
Summary
- k-skill supports Korean government APIs for statistics (KOSIS, ECOS), real estate (MOLIT), law (법제처), patents (KIPRIS), cultural heritage, food safety, and municipal data (Seoul City).
- All routes are documented in
docs/sources.mdand implemented as thin wrappers inpackages/k-skill-cli/helpers/. - The k-skill-proxy (
packages/k-skill-proxy/src/server.js) handles authentication, rate-limiting, and upstream routing to official endpoints. - AI agents interact via normalized skill commands without managing API keys directly.
- Helper modules normalize heterogeneous government data formats into consistent, typed responses.
Frequently Asked Questions
Which government APIs are supported by k-skill for AI agents?
k-skill supports the KOSIS national statistics API, Bank of Korea ECOS, MOLIT housing transaction APIs, the Korean Law Information API, KIPRIS Plus patents, Cultural Heritage Administration data, Food Safety API, EV-charger status, Seoul City Open API, and OPINET fuel prices. The complete list is maintained in docs/sources.md.
How does k-skill handle authentication for government APIs?
Authentication is managed by the k-skill-proxy server, which injects API keys (such as KSKILL_KOSIS_API_KEY) into requests forwarded to upstream government endpoints. AI agents and skill definitions never access these credentials directly, ensuring secure credential management.
Where are the government API routes defined in the source code?
Proxy routes are defined in packages/k-skill-proxy/src/server.js, which maps friendly paths like /v1/kosis/search to official government URLs. Helper modules in packages/k-skill-cli/helpers/ (e.g., kosis.js, molit.js) handle request construction and response parsing for each specific API.
Can developers add new government APIs to k-skill?
Yes. Developers can add support by creating a new helper in packages/k-skill-cli/helpers/ that constructs the appropriate request, then adding the corresponding route in packages/k-skill-proxy/src/server.js to handle authentication and forwarding to the new government endpoint. The new source should be documented in docs/sources.md.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →