payment-poc/state/model.go

33 lines
865 B
Go

package state
type PaymentState string
const (
// initial state
StatePreinitialized PaymentState = "preinitialized"
// initial state
StateInitialized PaymentState = "initialized"
// state given to async payments (eg. GooglePay,ApplePay...)
StatePending PaymentState = "pending"
// state on response
StateAccepted PaymentState = "accepted"
StateError PaymentState = "error"
StateCanceledInitialization PaymentState = "canceled_initialization"
// state after confirmation
StateCompleted PaymentState = "completed"
StateVoided PaymentState = "voided"
StateCanceled PaymentState = "canceled"
)
type PaymentGateway string
const (
GatewayWsPay PaymentGateway = "wspay"
GatewayStripe PaymentGateway = "stripe"
GatewayVivaWallet PaymentGateway = "viva-wallet"
GatewayMock PaymentGateway = "mock"
)