payment.otvCheckUser - GiGAGenie-ServiceSDK/UserGuide GitHub Wiki

gigagenie.payment.otvCheckUser

API ์„ค๋ช…

  • OTV ๊ฒฐ์ œ ์‚ฌ์šฉ์ž ํ™•์ธ API
  • OTV ๊ฒฐ์ œ๋ฅผ ์œ„ํ•œ ์‚ฌ์šฉ์ž ์ธ์ฆ ๋ฐ ์ƒํƒœ์ฒดํฌ๋ฅผ ์š”์ฒญํ•จ
  • ๊ฒฐ์ œ ์ด์šฉ ๊ฐ€๋Šฅ ์‚ฌ์šฉ์ž๊ฐ€ ์•„๋‹Œ ๊ฒฝ์šฐ ๊ฐ€์ž…์„ ์ œ์•ˆํ•จ

API ๊ตฌ์กฐ

  • function otvCheckUser(options,callback)
  • options
    • homeShoppingCode: (String, Mandatory) ์ œํœด์‚ฌ ์ฝ”๋“œ
    • payOption: (Number, Mandatory) ์ธ์ฆ ๋ฐฉ๋ฒ•์œผ๋กœ ๋‹ค์Œ ๋‘ ๊ฐ€์ง€๋ฅผ ์ง€์›ํ•จ
      • 1: ๋ฆฌ๋ชจ์ฝ˜
      • 2: ์Œ์„ฑ
  • result_cd
    • 200: ์„ฑ๊ณต
    • 410 : ์š”์ฒญ ์ค‘ ์‹ ๊ทœ ์š”์ฒญ์œผ๋กœ ์ค‘์ง€๋จ
    • 500: ์‹œ์Šคํ…œ Error
  • extra
    • authResult: (String) ์ธ์ฆ ๊ฒฐ๊ณผ

์‚ฌ์šฉ ์˜ˆ์‹œ

// callback ๋ฐฉ์‹
var options = {};
options.homeShoppingCode = "1111111111";
options.payOption = 2;
gigagenie.payment.otvCheckUser(options, function (result_cd, result_msg, extra) {
    if (result_cd === 200) {
        if (extra.authResult == "Success") {
            console.log("User Can Pay..");
        }
    } else {
        console.log("setAudioRecog Fail");
    }
});