A

AmountMismatchException — Class in namespace Cable8mm\LaravelPortone\Exceptions

서버 준비 금액과 PortOne 실결제액이 다를 때 발생하는 예외.

$ Payment#amount — Property in class Payment
PaymentLifecycle::amountMismatch() — Method in class PaymentLifecycle

금액 불일치 자동 취소의 두 결과를 PortOne 취소 요청 전에 계산한다.

FakePaymentGateway::assertLookedUp() — Method in class FakePaymentGateway

결제 ID를 조회했는지 확인한다. times를 주면 정확한 횟수를 확인한다.

FakePaymentGateway::assertNotLookedUp() — Method in class FakePaymentGateway

결제 ID를 조회하지 않았는지 확인한다.

FakePaymentGateway::assertNothingLookedUp() — Method in class FakePaymentGateway

아무 결제도 조회하지 않았는지 확인한다.

FakePaymentGateway::assertCancelled() — Method in class FakePaymentGateway

결제 ID의 취소 요청이 있었는지 확인한다.

FakePaymentGateway::assertNotCancelled() — Method in class FakePaymentGateway

결제 ID의 취소 요청이 없었는지 확인한다.

FakePaymentGateway::assertNothingCancelled() — Method in class FakePaymentGateway

아무 취소 요청도 없었는지 확인한다.

B

Billable — Class in namespace Cable8mm\LaravelPortone\Concerns

결제 기능을 부여하는 Eloquent 모델용 트레이트.

$ Customer#billable_type — Property in class Customer
$ Customer#billable_id — Property in class Customer
$ Payment#billable_type — Property in class Payment
$ Payment#billable_id — Property in class Payment
PortOneServiceProvider::boot() — Method in class PortOneServiceProvider

웹훅 라우트를 등록하고 발행 자원을 선언한다.

FakePaymentGateway::bind() — Method in class FakePaymentGateway

새 가짜 게이트웨이를 애플리케이션 컨테이너의 PaymentGateway로 바인딩하고 반환한다.

SignedWebhook::body() — Method in class SignedWebhook

PortOne 거래 웹훅 형식의 본문을 만든다.

C

Billable::createOrGetPortOneCustomerId() — Method in class Billable

이 모델의 PortOne 고객 ID를 만들거나 기존 값을 반환한다.

Billable::completePayment() — Method in class Billable

구매자가 브라우저에서 결제한 뒤 서버에서 검증하고 확정한다.

CustomerRegistry — Class in namespace Cable8mm\LaravelPortone

Billable 모델별 PortOne 고객 ID를 보장하는 레지스트리.

ConfigurationException — Class in namespace Cable8mm\LaravelPortone\Exceptions

필수 설정(API Secret, 웹훅 Secret 등)이 없을 때 발생하는 예외.

Customer — Class in namespace Cable8mm\LaravelPortone\Models

고객 기록 Eloquent 모델.

$ Customer#customer_id — Property in class Customer
$ Payment#customer_id — Property in class Payment
$ Payment#cancelled_amount — Property in class Payment
$ Payment#created_at — Property in class Payment
Payment::casts() — Method in class Payment
Payment::checkoutParameters() — Method in class Payment

브라우저 결제창에 전달할 결제 파라미터를 반환한다.

PaymentGateway::cancel() — Method in class PaymentGateway

PortOne 결제를 취소(환불)한다. 금액 생략 시 전액 취소이다.

PaymentLedger::createPending() — Method in class PaymentLedger

PENDING 결제 레코드를 새로 만든다. payment_id 충돌 시 다시 시도한다.

PaymentLifecycle::complete() — Method in class PaymentLifecycle

확정 결과를 계산한다. PortOne 결제 완료 + 금액 일치가 조건이다.

PaymentOperations::complete() — Method in class PaymentOperations

결제를 확정한다. 레코드에 배타 접근을 걸고 PortOne 조회를 수행한다.

PaymentOperations::completeByPaymentId() — Method in class PaymentOperations

결제 ID만으로 결제를 확정한다. 웹훅처럼 소유 Billable을 모를 때 쓴다.

PortOneGateway::cancel() — Method in class PortOneGateway

PortOne 결제를 취소(환불)한다. 금액 생략 시 전액 취소이다.

PortOneRequestExecutor::createClient() — Method in class PortOneRequestExecutor

타임아웃과 base_uri를 적용한 HTTP 클라이언트를 만든다.

FakePaymentGateway::cancel() — Method in class FakePaymentGateway

취소 요청을 기록한다. 지정한 취소 실패가 있으면 기록한 뒤 던진다.

FakePaymentGateway::cancellations() — Method in class FakePaymentGateway

기록된 취소 요청을 반환한다.

D

$ ExpirePendingPaymentsCommand#description — Property in class ExpirePendingPaymentsCommand
$ ReplayWebhookCommand#description — Property in class ReplayWebhookCommand
$ ShowPaymentCommand#description — Property in class ShowPaymentCommand

E

ExpirePendingPaymentsCommand — Class in namespace Cable8mm\LaravelPortone\Console

오래된 PENDING 결제마다 만료 확인 잡을 하나씩 큐에 넣는 명령.

CustomerRegistry::ensureId() — Method in class CustomerRegistry

이 모델의 고객 ID를 만들거나 기존 값을 반환한다.

ExpirePendingPayment — Class in namespace Cable8mm\LaravelPortone\Jobs

오래된 PENDING 결제 1건을 PortOne에 확인하는 큐 잡.

PaymentLifecycle::expire() — Method in class PaymentLifecycle

만료 확인 결과를 계산한다.

PaymentOperations::expire() — Method in class PaymentOperations

오래된 PENDING 결제 1건을 PortOne에 확인해 PAID 또는 EXPIRED로 바꾼다.

F

Billable::findPayment() — Method in class Billable

내 범위에서 결제 1건을 찾는다. 다른 모델의 결제는 조회되지 않는다.

CustomerRegistry::findId() — Method in class CustomerRegistry

이 모델의 고객 ID를 조회한다.

AmountMismatchException::fromPayment() — Method in class AmountMismatchException

금액 불일치로 저장된 결제 레코드에서 예외를 만든다.

PaymentLedger::find() — Method in class PaymentLedger

Billable 범위 안에서 결제 1건을 찾는다.

FakePaymentGateway — Class in namespace Cable8mm\LaravelPortone\Testing

테스트용 PaymentGateway. PortOne에 요청하지 않고 지정한 응답을 돌려주며 호출을 기록한다.

FakePaymentGateway::failLookup() — Method in class FakePaymentGateway

결제 ID의 조회가 이 예외를 던지게 한다(예: PortOne 장애).

FakePaymentGateway::failCancel() — Method in class FakePaymentGateway

결제 ID의 취소 요청이 이 예외를 던지게 한다. 요청은 기록된다.

G

GatewayPayment — Class in namespace Cable8mm\LaravelPortone

PortOne 조회 결과를 담는 값 객체.

$ Customer#guarded — Property in class Customer
$ Payment#guarded — Property in class Payment
PortOneGateway::gatewayPayment() — Method in class PortOneGateway

PortOne 결제 응답을 조회 결과로 바꾼다. 금액은 portone-php Payment 접근자로 읽는다.

H

Billable::hasPortOneId() — Method in class Billable

이 모델에 연결된 PortOne 고객 ID가 있는지 확인한다.

ExpirePendingPaymentsCommand::handle() — Method in class ExpirePendingPaymentsCommand
ReplayWebhookCommand::handle() — Method in class ReplayWebhookCommand
ShowPaymentCommand::handle() — Method in class ShowPaymentCommand
CustomerRegistry::has() — Method in class CustomerRegistry

이 모델에 연결된 고객 레코드가 있는지 확인한다.

ExpirePendingPayment::handle() — Method in class ExpirePendingPayment

결제 1건의 만료 확인을 실행한다.

SignedWebhook::headers() — Method in class SignedWebhook

본문의 webhook-id, webhook-signature, webhook-timestamp 헤더를 만든다.

I

InvalidPaymentStatusException — Class in namespace Cable8mm\LaravelPortone\Exceptions

환불할 수 없는 상태의 결제를 환불하려 할 때 발생하는 예외.

InvalidRefundAmountException — Class in namespace Cable8mm\LaravelPortone\Exceptions

환불 금액이 0 이하이거나 환불 가능한 잔액을 초과할 때 발생하는 예외.

PaymentLifecycle::isAmountMismatch() — Method in class PaymentLifecycle

PortOne이 결제 완료라고 했는데 실결제액이 준비 금액과 다른지 판단한다.

InteractsWithPortOneWebhooks — Class in namespace Cable8mm\LaravelPortone\Testing

서명된 PortOne 웹훅을 패키지 웹훅 경로(portone.webhook)로 보내는 테스트 도우미.

L

PaymentGateway::lookup() — Method in class PaymentGateway

PortOne에서 결제 1건을 조회한다.

PaymentGateway::lookupForExpiry() — Method in class PaymentGateway

만료 확인용으로 결제 1건을 조회한다.

PortOneGateway::lookup() — Method in class PortOneGateway

PortOne에서 결제 1건을 조회한다.

PortOneGateway::lookupForExpiry() — Method in class PortOneGateway

만료 확인용으로 결제 1건을 조회한다. PortOne이 결제를 모르면 found가 false이다.

FakePaymentGateway::lookup() — Method in class FakePaymentGateway

지정한 조회 응답을 반환한다. 지정하지 않은 결제 ID면 PAYMENT_NOT_FOUND 예외를 던진다.

FakePaymentGateway::lookupForExpiry() — Method in class FakePaymentGateway

지정한 조회 응답을 반환한다. 지정하지 않은 결제 ID면 found가 false인 결과를 반환한다.

FakePaymentGateway::lookupCount() — Method in class FakePaymentGateway

기록된 조회 횟수를 반환한다. 결제 ID를 주면 그 결제만 센다.

O

$ Payment#order_name — Property in class Payment

P

Billable::portOneId() — Method in class Billable

이 모델에 연결된 PortOne 고객 ID를 조회한다.

Billable::preparePayment() — Method in class Billable

결제 레코드를 미리 만든다. PortOne을 호출하지 않으며 상태는 PENDING이다.

Billable::payments() — Method in class Billable

이 모델의 결제 목록 관계(최신순)를 반환한다.

PaymentAmountMismatchedOnExpiry — Class in namespace Cable8mm\LaravelPortone\Events

만료 확인에서 다른 금액으로 결제된 것이 확인되어 자동 취소 규칙을 적용했음을 알리는 이벤트.

PaymentCancelled — Class in namespace Cable8mm\LaravelPortone\Events

전액 취소 웹훅(Transaction.Cancelled)을 알리는 이벤트.

PaymentExpired — Class in namespace Cable8mm\LaravelPortone\Events

만료 확인에서 미결제가 확인되어 결제 레코드가 EXPIRED가 되었음을 알리는 이벤트.

PaymentExpiryEvent — Class in namespace Cable8mm\LaravelPortone\Events

만료 확인 잡(ExpirePendingPayment)의 결과를 알리는 이벤트의 공통 부분.

PaymentFailed — Class in namespace Cable8mm\LaravelPortone\Events

결제 실패 웹훅(Transaction.Failed)을 알리는 이벤트.

PaymentPaid — Class in namespace Cable8mm\LaravelPortone\Events

결제 완료 웹훅(Transaction.Paid)을 알리는 이벤트.

PaymentPaidOnExpiry — Class in namespace Cable8mm\LaravelPortone\Events

만료 확인에서 뒤늦은 결제(같은 금액)가 확인되어 결제 레코드가 PAID가 되었음을 알리는 이벤트.

PaymentPartiallyCancelled — Class in namespace Cable8mm\LaravelPortone\Events

부분 취소 웹훅(Transaction.PartialCancelled)을 알리는 이벤트.

PaymentWebhookEvent — Class in namespace Cable8mm\LaravelPortone\Events

서명 검증에 성공한 거래(Transaction.*) 웹훅을 종류별로 알리는 이벤트의 공통 부분.

AmountMismatchException::paidAmount() — Method in class AmountMismatchException

PortOne 실결제액(원)을 반환한다. 알 수 없으면 null이다.

PaymentNotFoundException — Class in namespace Cable8mm\LaravelPortone\Exceptions

호출한 Billable 범위에 해당 결제가 없을 때 발생하는 예외.

PaymentNotPaidException — Class in namespace Cable8mm\LaravelPortone\Exceptions

PortOne에서 미결제로 조회된 결제를 확정하려 할 때 발생하는 예외.

Payment — Class in namespace Cable8mm\LaravelPortone\Models

결제 기록 Eloquent 모델.

$ Payment#payment_id — Property in class Payment
$ Payment#paid_amount — Property in class Payment

PortOne이 확인해 준 실결제액(원). PAID 확정과 금액 불일치 때 저장하며, PortOne이 아직 실결제액을 알려 주지 않은 PENDING·EXPIRED는 null이다

$ Payment#paid_at — Property in class Payment
Payment::prunable() — Method in class Payment

model:prune이 지울 레코드: portone.expired_retention_days일보다 오래된 EXPIRED 결제만.

PaymentGateway — Class in namespace Cable8mm\LaravelPortone

PortOne API 호출 규격. 모든 외부 요청은 이 인터페이스를 통한다.

PaymentLedger — Class in namespace Cable8mm\LaravelPortone

결제 레코드의 배타 접근과 저장을 전담하는 저장소.

PaymentLedger::payments() — Method in class PaymentLedger

이 모델의 결제 목록 관계(최신순)를 반환한다.

PaymentLifecycle — Class in namespace Cable8mm\LaravelPortone

결제 확정·환불·만료·취소 동기화의 상태 전이를 순수하게 계산하는 클래스.

PaymentOperations — Class in namespace Cable8mm\LaravelPortone

결제 준비·확정·환불 흐름을 조율하는 서비스.

PaymentOperations::prepare() — Method in class PaymentOperations

결제 레코드를 미리 만든다. PortOne을 호출하지 않는다.

PaymentResponseRedactor — Class in namespace Cable8mm\LaravelPortone

PortOne 결제 조회 응답에서 개인정보와 카드·계좌 식별 정보를 가린다.

PortOneGateway — Class in namespace Cable8mm\LaravelPortone

cable8mm/portone-php 클라이언트로 PortOne V2 API를 호출하는 게이트웨이.

PortOneGateway::paymentResponse() — Method in class PortOneGateway

PortOne 결제 조회 응답을 받은 그대로 반환한다. 테스트용 응답 기록 등에 쓴다.

PortOneRequestExecutor — Class in namespace Cable8mm\LaravelPortone

PortOne API 주소를 적용한 HTTP 실행기.

PortOneServiceProvider — Class in namespace Cable8mm\LaravelPortone

패키지 서비스 프로바이더.

PortOneWebhookVerifier — Class in namespace Cable8mm\LaravelPortone

cable8mm/portone-php 검증기로 웹훅 서명을 확인하는 래퍼.

FakePaymentGateway::payment() — Method in class FakePaymentGateway

결제 ID의 조회 응답을 지정한다.

InteractsWithPortOneWebhooks::postPortOneWebhook() — Method in class InteractsWithPortOneWebhooks

서명된 웹훅을 패키지 웹훅 경로로 보낸다.

R

Billable::refund() — Method in class Billable

결제를 환불한다. 금액을 생략하면 전액 환불이다.

ReplayWebhookCommand — Class in namespace Cable8mm\LaravelPortone\Console

서명된 PortOne 웹훅을 앱 자신의 웹훅 주소로 HTTP 전송하는 명령. 공개 주소 없이 로컬에서 웹훅 흐름을 확인할 때 쓴다.

PaymentLifecycle::refund() — Method in class PaymentLifecycle

환불 결과를 계산한다. 전액이면 CANCELLED, 일부면 PARTIALLY_CANCELLED이다.

PaymentOperations::refund() — Method in class PaymentOperations

PortOne 취소를 먼저 승인받은 뒤 로컬 레코드에 반영한다.

PaymentResponseRedactor::redact() — Method in class PaymentResponseRedactor

응답의 복사본에서 KEYS에 해당하는 값을 가려 반환한다.

PortOneServiceProvider::register() — Method in class PortOneServiceProvider

설정을 병합하고 PortOne 게이트웨이를 바인딩한다.

S

$ ExpirePendingPaymentsCommand#signature — Property in class ExpirePendingPaymentsCommand
$ ReplayWebhookCommand#signature — Property in class ReplayWebhookCommand
ShowPaymentCommand — Class in namespace Cable8mm\LaravelPortone\Console

PortOne 결제 조회 응답을 JSON으로 출력하는 명령. 자동 테스트용 실제 응답을 기록할 때 쓴다.

$ ShowPaymentCommand#signature — Property in class ShowPaymentCommand
$ Payment#status — Property in class Payment
PaymentLedger::stalePending() — Method in class PaymentLedger

기준 시각보다 먼저 만들어진 PENDING 결제를 모든 Billable에 걸쳐 고른다.

PaymentLifecycle::syncCancellation() — Method in class PaymentLifecycle

PortOne 취소 상태를 로컬 레코드에 맞추는 결과를 계산한다(취소 동기화).

PaymentOperations::syncByPaymentId() — Method in class PaymentOperations

결제 ID로 레코드를 찾아 PortOne의 취소 상태를 반영한다(취소 동기화).

SignedWebhook — Class in namespace Cable8mm\LaravelPortone\Testing

테스트·로컬 재전송용 웹훅 본문을 만들고 설정된 웹훅 Secret으로 서명한다.

T

$ Customer#table — Property in class Customer
$ Customer#timestamps — Property in class Customer
$ Payment#table — Property in class Payment

U

$ Payment#updated_at — Property in class Payment
PaymentLedger::update() — Method in class PaymentLedger

미리 계산된 결과 값을 레코드에 그대로 쓴다. 증가분이 아닌 절대값이다.

V

PortOneWebhookVerifier::verify() — Method in class PortOneWebhookVerifier

웹훅 서명을 검증하고 웹훅 객체를 반환한다.

W

WebhookReceived — Class in namespace Cable8mm\LaravelPortone\Events

서명 검증에 성공한 PortOne 웹훅을 알리는 이벤트.

AmountMismatchException::wasCancelled() — Method in class AmountMismatchException

PortOne이 자동 전액 취소를 받아들였는지 반환한다.

WebhookController — Class in namespace Cable8mm\LaravelPortone\Http\Controllers

포트원 웹훅 수신 컨트롤러.

PaymentLedger::withExclusiveAccess() — Method in class PaymentLedger

레코드를 잠그고 콜백을 실행한다. 범위를 벗어나면 예외가 발생한다.

PaymentLedger::withExclusiveAccessByPaymentId() — Method in class PaymentLedger

결제 ID만으로 레코드를 잠그고 콜백을 실행한다. 레코드가 없으면 예외가 발생한다.

PaymentLedger::withExclusiveAccessByReference() — Method in class PaymentLedger

Billable 참조(타입·키)로 범위를 정해 레코드를 잠그고 콜백을 실행한다.

_

PaymentAmountMismatchedOnExpiry::__construct() — Method in class PaymentAmountMismatchedOnExpiry
PaymentExpiryEvent::__construct() — Method in class PaymentExpiryEvent
PaymentWebhookEvent::__construct() — Method in class PaymentWebhookEvent
WebhookReceived::__construct() — Method in class WebhookReceived
AmountMismatchException::__construct() — Method in class AmountMismatchException
GatewayPayment::__construct() — Method in class GatewayPayment
WebhookController::__invoke() — Method in class WebhookController

웹훅 요청을 검증하고 이벤트로 변환한다.

ExpirePendingPayment::__construct() — Method in class ExpirePendingPayment
PaymentOperations::__construct() — Method in class PaymentOperations
PortOneRequestExecutor::__construct() — Method in class PortOneRequestExecutor