Skip to content

LINE Pay Reserve

Description

請求LINE Pay付款。

Resource

POST /v1/payment/line/reserve

Authorization

採用 OAuth 2.0 Bearer Token,詳細使用流程請參考 Auth Login

Request Body Parameters

Name Type Description
store_id string 門市代碼
productName string 產品名稱
productImageUrl string 產品影像URL(或使用品牌logo URL)
顯示於付款畫面上的影像URL
(optional)
amount integer 付款金額
currency string 付款貨幣
ALLOWED VALUES:
  • USD
  • JPY
  • TWD
  • THB
confirmUrl string 買家在LINE Pay 選擇付款方式並輸入密碼後,被重新導向到商家的URL
orderId string 商家與該筆付款請求對應的訂單編號,這是商家自行管理的唯一編號
packageName string 在Android 各應用程式間轉換時,防止網路釣魚詐騙的資訊
(optional)

Request

{
  "store_id": "0",
  "productName": "test product",
  "productImageUrl": "http://testst.com",
  "amount": 10,
  "currency": "TWD",
  "orderId": "20140101123456789",
  "confirmUrl": "naversearchapp://inappbrowser?url=http%3A%2F%2FtestMall.com%2FcheckResult.nhn%3ForderId%3D20140101123456789"
}

Response Body Parameters

Name Type Description
returnCode string 結果代碼,0000為成功
returnMessage string 結果訊息或失敗理由
info Info 相關資訊

Response Body Parameters - Info

Name Type Description
transactionId string 交易編號(19 位數)
paymentUrl Payment Url 付款URL
paymentAccessToken string 在LINE Pay app 輸入代碼來代替適用掃描器(Scanner)之時候所適用的代碼值(共12位數)

Response Body Parameters - Payment Url

Name Type Description
web string 付款請求後所前往的網頁URL
app string 前往付款畫面的應用程式URL

Response

{
  "returnCode": "0000",
  "returnMessage": "OK",
  "info": {
    "transactionId": 123123123123,
    "paymentUrl": {
      "web": "http://web-pay.line.me/web/wait?transactionReserveId=blahblah",
      "app": "line://pay/payment/blahblah"
    },
    "paymentAccessToken": "187568751124"
  }
}