[KRS 판매처리 (sales process) API] 1.URL POST https://api.storyway.co.kr/api/wssp/insertSaleInfo 2.RequestBody (JSON) - [sales type] { "orderNo":"100000023", // {st_order.order_no} "deptCd":"999991", // {st_order.mall_code} "saleDate":"20230901", // current date (YYYYMMDD, EX:20230901) "saleTime":"132153", // current time (HH24MISS, EX:132153) "orderType":"1", // "1" (store order) "saleAmt":10000, // {st_order.order_amount} "delvAmt":1000, // {st_order.delivery_amount} "pointAmt":3000, // {st_order.use_point} "mileageAmt":30, // {st_order.use_money} "couponAmt":450, // {st_order.coupon_amount} "orderStat":"2", // {st_order.smart_order_status} "itemCds":[ {"itemCd":"8000001", // {st_product.krs_item_cd} "itemNm":"TEST1", // {st_product.product_name} "pluCd":"8809174211616",// {st_product.krs_bar_cd} "salePrice":9000, // {st_order_product.sale_price} "saleQty":1, // {st_order_product.order_count} "saleAmt":9000, // {st_order_product.product_amount} "saleAmtSup":8100, // refer to calculation formula "saleAmtVat":900, // refer to calculation formula "ovchSaleAmt":200, // {st_order_product.discount_amount} "taxType":"1" // {st_product.krs_taxn_se_cd} }, ... ], "payKey":"222", // {st_order_payment.payment_key} (if data is not existed (when payment_amount=0), set empty "payType":"1", // {st_order.payment_method} "payAmt":10000, // {st_order.payment_amount} "cancelAmt":0, // 0 "payStat":"1", // "1" (결제완료: payment complete) } 1) calculation formula a) "saleAmtSup" - if st_product.krs_taxn_se_cd = '1', saleAmtSup = ROUND(saleAmt/1.1, 2) - else, saleAmtSup = saleAmt b) "saleAmtVat" - if st_product.krs_taxn_se_cd = '1', saleAmtVat = saleAmt - saleAmtSup - else, saleAmtSup = 0 3.RequestBody (JSON) - [sales cancel type] - same with No 2 - sales except "cancelAmt": {st_order.payment_amount} "payStat": "2" // 결제취소 (payment cancel)