환불
POST /v2/payments/orders/{orderId}/refund
Read 타임아웃은 최소 20 초 이상으로 설정하세요.
Request
Response
Path
Name | Length | Description | Required |
---|---|---|---|
orderId | 100 | 주문 번호. 가맹점에서 주문을 관리하기 위해 생성한 ID를 입력하세요. 입력할 때 URL 인코딩을 적용하세요. |
Query
None
Body
Name | Type | Description | Required |
---|---|---|---|
refundAmount | number | 환불 금액. 부분 환불할 금액을 입력하세요. 이 필드를 생략하면 결제한 금액 전부가 환불됩니다. | |
promotionRestriction | object | 프로모션 제한 정보. 법, 규칙 등에 따라 프로모션 적용 불가한 상품의 금액을 입력하세요. 이 필드를 명시하면 부분 환불을 지원하지 않고 전액 환불됩니다. |
Headers
- Content-Type
- X-LINE-ChannelId
- X-LINE-ChannelSecret
- X-LINE-MerchantDeviceProfileId
- X-LINE-MerchantDeviceType
자세한 내용은 요청 헤더를 참고하세요.
Request examples
bash
curl -X POST \
-H "Content-Type: application/json" \
-H "X-LINE-ChannelId: YOUR_CHANNEL_ID" \
-H "X-LINE-ChannelSecret: YOUR_CHANNEL_SECRET" \
-H "X-LINE-MerchantDeviceProfileId: YOUR_DEVICE_PROFILE_ID" \
-d '{ "refundAmount": 100 }' \
https://sandbox-api-pay.line.me/v2/payments/orders/merchant_test_order_1/refund