humanerd-drew/opencode-drewgent/korean-payment-gateway
Claude Code and agent skill by humanerd-drew/opencode-drewgent
- community
Checking that the SKILL.md file is still in the repository.
Integrate Korean payment gateways (KG이니시스, KCP, tosspayments, etc.) via PortOne V2 SDK into vanilla JS SPAs. Covers SDK loading, requestPayment API, payMethod selection (CARD / EASY_PAY for NaverPay/KakaoPay), payment response handling, and backend verification pattern.
Install
npx vskill@latest install humanerd-drew/opencode-drewgent/korean-payment-gatewaySKILL.md
The same SKILL.md was published earlier as humanerd-drew/opencode-drewgent/korean-payment-gateway.
Korean Payment Gateway Integration (PortOne V2 SDK)
Overview
PortOne (포트원, formerly 아임포트) is a Korean payment gateway aggregator. It unifies multiple PG providers (KG이니시스, NHN KCP, 토스페이먼츠, etc.) under a single JavaScript SDK.
This skill covers the PortOne V2 SDK (@portone/browser-sdk) integration into a vanilla JS SPA (no bundler).
Architecture
Step 1: SDK Loading
CDN (Vanilla JS — no bundler)
This sets window.PortOne globally.
NPM (Bundler — Vite, webpack, etc.)
Step 2: Configuration
Two values from PortOne Admin Console → 결제 연동 → 연동 정보:
| Key | Description | Format | |
|---|---|---|---|
storeId | 상점 아이디 | store-abc123 | |
channelKey | 채널 키 (per-channel) | channel-key-xxxxx |
Step 3: Payment Request
Basic Card Payment
NaverPay / KakaoPay (Easy Pay)
Supported payMethod Values
| Value | Description | |
|---|---|---|
CARD | 신용/체크카드 | |
EASY_PAY | 간편결제 (네이버페이/카카오페이 등) | |
VIRTUAL_ACCOUNT | 가상계좌 | |
TRANSFER | 계좌이체 | |
MOBILE | 휴대폰 소액결제 | |
GIFT_CERTIFICATE | 상품권/문화상품권 |
Step 4: Response Handling
Customer Info (Required by KG이니시스)
Step 5: Backend Verification (Pattern)
Backend calls PortOne API:
Key Points:
- Use PortOne API Secret Key server-side only
- Verify
totalAmountmatches your product price - Never trust client-side
totalAmountfor billing - Implement idempotency on
paymentId
Pitfalls
- StoreId is REQUIRED — both
storeIdandchannelKeyare required. - SDK not loaded — load the script early or check
window.PortOnebefore calling. - Integer amount —
totalAmountmust be an integer. - Mobile redirect — set
redirectUrlfor mobile flows. - Test vs live channel — PortOne admin has separate 테스트 and 실연동 channels.
- Never expose API Secret in frontend code.
인증마크 (PG Certification Mark)
Korean PG providers require displaying a certification mark in the site footer.
KG이니시스 Example
Replace YOUR_MID with your KG이니시스 merchant ID. Place in footer (desktop) and payment page content (mobile fallback).
Environment & Secret Management
PortOne API Secret
Local development (.dev.vars):
Production (Wrangler secret):
Frontend Config Pattern
Store storeId and channelKey in a config constant in the view file. These are public (visible in JS bundle). The API Secret stays server-side.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/software-development/korean-payment-gateway/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/humanerd-drew/opencode-drewgent/korean-payment-gateway)