API 명세서 다운로드

OAuth 인증

  • REST

접근토큰발급

기본 정보

API 정보 안내 표
Method POST
운영 도메인 https://api.kiwoom.com
모의투자 도메인 https://mockapi.kiwoom.com(KRX만 지원가능)
URL /oauth2/token
Format JSON
Content-Type application/json;charset=UTF-8

다른 TR 확인하기

요청

Body
Body 정보 표
Element 한글명 type Required Length Description
grant_type grant_type String Y client_credentials 입력
appkey 앱키 String Y
secretkey 시크릿키 String Y

응답

Body
Body 정보 표
Element 한글명 type Required Length Description
expires_dt 만료일 String Y
token_type 토큰타입 String Y
token 접근토큰 String Y

Example

{
	"grant_type" : "client_credentials",
	"appkey" : "AxserEsdcredca.....",
	"secretkey" : "SEefdcwcforehDre2fdvc...."
}
{
	"expires_dt":"20241107083713",
	"token_type":"bearer",
	"token":"WQJCwyqInphKnR3bSRtB9NE1lv..."
	"return_code":0,
	"return_msg":"정상적으로 처리되었습니다"
}