Versions in this module Expand all Collapse all v0 v0.1.0 Oct 14, 2018 Changes in this version + var CardType_name = map[int32]string + var CardType_value = map[string]int32 + var ChargeStatus_name = map[int32]string + var ChargeStatus_value = map[string]int32 + var Currency_name = map[int32]string + var Currency_value = map[string]int32 + var ErrIntOverflowPayment = fmt.Errorf("proto: integer overflow") + var ErrInvalidLengthPayment = fmt.Errorf("proto: negative length found during unmarshaling") + var ListRequest_Sort_name = map[int32]string + var ListRequest_Sort_value = map[string]int32 + var PaymentProviderId_name = map[int32]string + var PaymentProviderId_value = map[string]int32 + var RefundReason_name = map[int32]string + var RefundReason_value = map[string]int32 + func RegisterPaymentServiceServer(s *grpc.Server, srv PaymentServiceServer) + type Card struct + CVC string + ExpireMonth string + ExpireYear string + FirstName string + LastName string + Number string + Type CardType + func (*Card) Descriptor() ([]byte, []int) + func (*Card) ProtoMessage() + func (m *Card) GetCVC() string + func (m *Card) GetExpireMonth() string + func (m *Card) GetExpireYear() string + func (m *Card) GetFirstName() string + func (m *Card) GetLastName() string + func (m *Card) GetNumber() string + func (m *Card) GetType() CardType + func (m *Card) Marshal() (dAtA []byte, err error) + func (m *Card) MarshalTo(dAtA []byte) (int, error) + func (m *Card) Reset() + func (m *Card) Size() (n int) + func (m *Card) String() string + func (m *Card) Unmarshal(dAtA []byte) error + type CardType int32 + const CardType_AmericanExpress + const CardType_CARD_Reserved + const CardType_DinersClub + const CardType_Discover + const CardType_JCB + const CardType_Mastercard + const CardType_Visa + func (CardType) EnumDescriptor() ([]byte, []int) + func (x CardType) String() string + type Charge struct + ChargeAmount uint64 + Created int64 + Currency Currency + Email string + Id string + Paid bool + ProviderChargeId string + ProviderId PaymentProviderId + RefundAmount uint64 + Refunded bool + Refunds []*Refund + Statement string + Updated int64 + func (*Charge) Descriptor() ([]byte, []int) + func (*Charge) ProtoMessage() + func (m *Charge) GetChargeAmount() uint64 + func (m *Charge) GetCreated() int64 + func (m *Charge) GetCurrency() Currency + func (m *Charge) GetEmail() string + func (m *Charge) GetId() string + func (m *Charge) GetPaid() bool + func (m *Charge) GetProviderChargeId() string + func (m *Charge) GetProviderId() PaymentProviderId + func (m *Charge) GetRefundAmount() uint64 + func (m *Charge) GetRefunded() bool + func (m *Charge) GetRefunds() []*Refund + func (m *Charge) GetStatement() string + func (m *Charge) GetUpdated() int64 + func (m *Charge) Marshal() (dAtA []byte, err error) + func (m *Charge) MarshalTo(dAtA []byte) (int, error) + func (m *Charge) Reset() + func (m *Charge) Size() (n int) + func (m *Charge) String() string + func (m *Charge) Unmarshal(dAtA []byte) error + type ChargeList struct + Charges []*Charge + Total int32 + func (*ChargeList) Descriptor() ([]byte, []int) + func (*ChargeList) ProtoMessage() + func (m *ChargeList) GetCharges() []*Charge + func (m *ChargeList) GetTotal() int32 + func (m *ChargeList) Marshal() (dAtA []byte, err error) + func (m *ChargeList) MarshalTo(dAtA []byte) (int, error) + func (m *ChargeList) Reset() + func (m *ChargeList) Size() (n int) + func (m *ChargeList) String() string + func (m *ChargeList) Unmarshal(dAtA []byte) error + type ChargeRequest struct + Card *Card + Currency Currency + Email string + Metadata map[string]string + PaymentProviderId PaymentProviderId + Statement string + Total uint64 + func (*ChargeRequest) Descriptor() ([]byte, []int) + func (*ChargeRequest) ProtoMessage() + func (m *ChargeRequest) GetCard() *Card + func (m *ChargeRequest) GetCurrency() Currency + func (m *ChargeRequest) GetEmail() string + func (m *ChargeRequest) GetMetadata() map[string]string + func (m *ChargeRequest) GetPaymentProviderId() PaymentProviderId + func (m *ChargeRequest) GetStatement() string + func (m *ChargeRequest) GetTotal() uint64 + func (m *ChargeRequest) Marshal() (dAtA []byte, err error) + func (m *ChargeRequest) MarshalTo(dAtA []byte) (int, error) + func (m *ChargeRequest) Reset() + func (m *ChargeRequest) Size() (n int) + func (m *ChargeRequest) String() string + func (m *ChargeRequest) Unmarshal(dAtA []byte) error + type ChargeStatus int32 + const ChargeStatus_Paid + const ChargeStatus_Refunded + func (ChargeStatus) EnumDescriptor() ([]byte, []int) + func (x ChargeStatus) String() string + type Currency int32 + const Currency_AED + const Currency_AFN + const Currency_ALL + const Currency_AMD + const Currency_ANG + const Currency_ARS + const Currency_AUD + const Currency_AWG + const Currency_AZN + const Currency_BAM + const Currency_BBD + const Currency_BGN + const Currency_BHD + const Currency_BMD + const Currency_BND + const Currency_BOB + const Currency_BRL + const Currency_BSD + const Currency_BWP + const Currency_BYN + const Currency_BYR + const Currency_BZD + const Currency_CAD + const Currency_CLP + const Currency_CNY + const Currency_COP + const Currency_CRC + const Currency_CUP + const Currency_CUR_RESERVED + const Currency_CZK + const Currency_DKK + const Currency_DOP + const Currency_DZD + const Currency_EEK + const Currency_EGP + const Currency_EUR + const Currency_FJD + const Currency_FKP + const Currency_GBP + const Currency_GGP + const Currency_GHC + const Currency_GIP + const Currency_GTQ + const Currency_GYD + const Currency_HKD + const Currency_HNL + const Currency_HRK + const Currency_HUF + const Currency_IDR + const Currency_ILS + const Currency_IMP + const Currency_INR + const Currency_IQD + const Currency_IRR + const Currency_ISK + const Currency_JEP + const Currency_JMD + const Currency_JOD + const Currency_JPY + const Currency_KES + const Currency_KGS + const Currency_KHR + const Currency_KPW + const Currency_KRW + const Currency_KWD + const Currency_KYD + const Currency_KZT + const Currency_LAK + const Currency_LBP + const Currency_LKR + const Currency_LRD + const Currency_LTL + const Currency_LVL + const Currency_LYD + const Currency_MAD + const Currency_MKD + const Currency_MNT + const Currency_MUR + const Currency_MWK + const Currency_MXN + const Currency_MYR + const Currency_MZN + const Currency_NAD + const Currency_NGN + const Currency_NIO + const Currency_NOK + const Currency_NPR + const Currency_NZD + const Currency_OMR + const Currency_PAB + const Currency_PEN + const Currency_PHP + const Currency_PKR + const Currency_PLN + const Currency_PYG + const Currency_QAR + const Currency_RON + const Currency_RSD + const Currency_RUB + const Currency_RUR + const Currency_SAR + const Currency_SBD + const Currency_SCR + const Currency_SEK + const Currency_SGD + const Currency_SHP + const Currency_SOS + const Currency_SRD + const Currency_SVC + const Currency_SYP + const Currency_THB + const Currency_TND + const Currency_TRL + const Currency_TRY + const Currency_TTD + const Currency_TWD + const Currency_TZS + const Currency_UAH + const Currency_UGX + const Currency_USD + const Currency_UYU + const Currency_UZS + const Currency_VEF + const Currency_VND + const Currency_XCD + const Currency_YER + const Currency_ZAR + const Currency_ZMW + const Currency_ZWD + func (Currency) EnumDescriptor() ([]byte, []int) + func (x Currency) String() string + type GetRequest struct + Id string + func (*GetRequest) Descriptor() ([]byte, []int) + func (*GetRequest) ProtoMessage() + func (m *GetRequest) GetId() string + func (m *GetRequest) Marshal() (dAtA []byte, err error) + func (m *GetRequest) MarshalTo(dAtA []byte) (int, error) + func (m *GetRequest) Reset() + func (m *GetRequest) Size() (n int) + func (m *GetRequest) String() string + func (m *GetRequest) Unmarshal(dAtA []byte) error + type ListRequest struct + Limit int64 + Page int64 + Sort ListRequest_Sort + func (*ListRequest) Descriptor() ([]byte, []int) + func (*ListRequest) ProtoMessage() + func (m *ListRequest) GetLimit() int64 + func (m *ListRequest) GetPage() int64 + func (m *ListRequest) GetSort() ListRequest_Sort + func (m *ListRequest) Marshal() (dAtA []byte, err error) + func (m *ListRequest) MarshalTo(dAtA []byte) (int, error) + func (m *ListRequest) Reset() + func (m *ListRequest) Size() (n int) + func (m *ListRequest) String() string + func (m *ListRequest) Unmarshal(dAtA []byte) error + type ListRequest_Sort int32 + const ListRequest_CreatedAsc + const ListRequest_CreatedDesc + const ListRequest_Natural + const ListRequest_UpdatedAsc + const ListRequest_UpdatedDesc + func (ListRequest_Sort) EnumDescriptor() ([]byte, []int) + func (x ListRequest_Sort) String() string + type PaymentProviderId int32 + const PaymentProviderId_Braintree + const PaymentProviderId_PROVIDER_Reserved + const PaymentProviderId_Paypal + const PaymentProviderId_Stripe + func (PaymentProviderId) EnumDescriptor() ([]byte, []int) + func (x PaymentProviderId) String() string + type PaymentServiceClient interface + Get func(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*Charge, error) + List func(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ChargeList, error) + NewCharge func(ctx context.Context, in *ChargeRequest, opts ...grpc.CallOption) (*Charge, error) + RefundCharge func(ctx context.Context, in *RefundRequest, opts ...grpc.CallOption) (*Charge, error) + func NewPaymentServiceClient(cc *grpc.ClientConn) PaymentServiceClient + type PaymentServiceServer interface + Get func(context.Context, *GetRequest) (*Charge, error) + List func(context.Context, *ListRequest) (*ChargeList, error) + NewCharge func(context.Context, *ChargeRequest) (*Charge, error) + RefundCharge func(context.Context, *RefundRequest) (*Charge, error) + type Refund struct + Created int64 + ProviderRefundId string + Reason RefundReason + RefundAmount uint64 + func (*Refund) Descriptor() ([]byte, []int) + func (*Refund) ProtoMessage() + func (m *Refund) GetCreated() int64 + func (m *Refund) GetProviderRefundId() string + func (m *Refund) GetReason() RefundReason + func (m *Refund) GetRefundAmount() uint64 + func (m *Refund) Marshal() (dAtA []byte, err error) + func (m *Refund) MarshalTo(dAtA []byte) (int, error) + func (m *Refund) Reset() + func (m *Refund) Size() (n int) + func (m *Refund) String() string + func (m *Refund) Unmarshal(dAtA []byte) error + type RefundReason int32 + const RefundReason_Duplicate + const RefundReason_Fraud + const RefundReason_GeneralError + const RefundReason_RequestedByCustomer + func (RefundReason) EnumDescriptor() ([]byte, []int) + func (x RefundReason) String() string + type RefundRequest struct + Amount uint64 + Id string + Reason RefundReason + func (*RefundRequest) Descriptor() ([]byte, []int) + func (*RefundRequest) ProtoMessage() + func (m *RefundRequest) GetAmount() uint64 + func (m *RefundRequest) GetId() string + func (m *RefundRequest) GetReason() RefundReason + func (m *RefundRequest) Marshal() (dAtA []byte, err error) + func (m *RefundRequest) MarshalTo(dAtA []byte) (int, error) + func (m *RefundRequest) Reset() + func (m *RefundRequest) Size() (n int) + func (m *RefundRequest) String() string + func (m *RefundRequest) Unmarshal(dAtA []byte) error