sayren Docs
결제

결제 상태 조회

결제 요청(`POST /checkout/{checkoutId}/payment`)으로 받은 `paymentId`의 현재 상태를 돌려준다. 결제 서비스에서 돌아온 복귀 화면이 결과를 확정하는 경로이고, 구매자가 결제 앱에서 돌아오지 않은 결제도 이 API로 확인한다. 화면 분기는 `result`로 한다 — `COMPLETED`면 `orderId`로 주문 완료 화면을, `PROCESSING`이면 잠시 뒤 다시 조회, `CANCELED`·`FAILED`면 `lastFailure`를 보여 주고 다른 결제 옵션으로 재시도할 수 있다. 만료 시각이 지난 결제 대기는 `expired`(`EXPIRED`)로 보고한다. 개인정보와 결제사 값은 싣지 않는다.

GET
/storefront/v1/payments/{paymentId}

결제 요청(POST /checkout/{checkoutId}/payment)으로 받은 paymentId의 현재 상태를 돌려준다. 결제 서비스에서 돌아온 복귀 화면이 결과를 확정하는 경로이고, 구매자가 결제 앱에서 돌아오지 않은 결제도 이 API로 확인한다. 화면 분기는 result로 한다 — COMPLETED면 orderId로 주문 완료 화면을, PROCESSING이면 잠시 뒤 다시 조회, CANCELED·FAILED면 lastFailure를 보여 주고 다른 결제 옵션으로 재시도할 수 있다. 만료 시각이 지난 결제 대기는 expired(EXPIRED)로 보고한다. 개인정보와 결제사 값은 싣지 않는다.

AuthorizationBearer <token>

회원 accessToken

In: header

Path Parameters

paymentId*string

Response Body

application/json

curl -X GET "https://example.com/storefront/v1/payments/string"
{  "meta": {    "status": 200,    "code": "OK",    "message": "OK",    "isSuccess": true  },  "data": {    "paymentId": "string",    "status": "string",    "result": "string",    "orderId": "string",    "lastFailure": {      "attemptId": "string",      "category": "string",      "code": "string",      "message": "string",      "optionUnavailable": true    },    "testPayment": true,    "expiresAt": "string"  },  "error": null}