delegate

package
v1.3.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 6, 2022 License: BSD-3-Clause Imports: 13 Imported by: 1

Documentation

Index

Constants

View Source
const (
	ExpireDayKey   = "expire_time_in_seconds"
	LastUpdateTime = "last_update_time"
	ChargeInDays   = "charge_in_days"
)
View Source
const (
	SecondsInOneDay = int64(24 * 3600)
)

Variables

This section is empty.

Functions

func Checkout

func Checkout(w http.ResponseWriter, r *http.Request)

func Customer

func Customer(w http.ResponseWriter, r *http.Request)

func IAPRecharge added in v1.2.9

func IAPRecharge(w http.ResponseWriter, r *http.Request)

func TransferToFriend added in v1.3.0

func TransferToFriend(w http.ResponseWriter, r *http.Request)

func UpdateCustomerVip added in v1.2.5

func UpdateCustomerVip(id string, days int, latestUpdate int64) error

Types

type ParamObj

type ParamObj struct {
	Success    bool   `json:"success,omitempty"`
	ErrMsg     string `json:"err_msg,omitempty"`
	WalletAddr string `json:"wallet_addr,omitempty"`

	StripeCusId        string `json:"stripe_cus_id,omitempty"`
	StripeSubCusId     string `json:"stripe_sub_cus_id,omitempty"`
	CusVipInSeconds    string `json:"cus_vip_in_seconds,omitempty"`
	VipUpdateInSeconds string `json:"vip_update_in_seconds,omitempty"`

	EphemeralKey   string `json:"ephemeral_key,omitempty"`
	PublishableKey string `json:"publishable_key,omitempty"`
	PaymentIntent  string `json:"payment_intent,omitempty"`

	Amount     int64  `json:"amount,omitempty"`
	ChargeDays int    `json:"charge_days,omitempty"`
	Currency   string `json:"currency,omitempty"`
}

func (*ParamObj) Data

func (dp *ParamObj) Data() []byte

func (*ParamObj) String added in v1.3.0

func (dp *ParamObj) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL