cash

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAccount

func GetAccount(stripeAccountId string) (*stripe.Account, error)

Types

type IRequests

type IRequests interface {
	CreatePaymentintent(userId string, totalAmount int) (ClientSecret string, StripeTransactionId string, err error)
	GetRegisterLink(email string, user users.User) (url string, err error)
	GetStripeMypageLink(stripeAccountId string) (url string, err error)
}

type IUtils

type IUtils interface {
	Transfer(amount int, transactionId string, stripeAccountId string) (transferId *string)
	Refund(amount int, transactionId string, stripeAccountId string) (err error)
}

type Requests

type Requests struct {
	CartRequests cart.IRequests
	UserRequests users.IRequests
}

func (Requests) CreatePaymentintent

func (r Requests) CreatePaymentintent(userId string, totalAmount int) (ClientSecret string, StripeTransactionId string, err error)
func (r Requests) GetRegisterLink(email string, user users.User) (url string, err error)
func (r Requests) GetStripeMypageLink(stripeAccountId string) (url string, err error)

type Utils

type Utils struct {
}

func (Utils) Refund

func (r Utils) Refund(amount int, transferId string, accountId string) (err error)

func (Utils) Transfer

func (r Utils) Transfer(amount int, stripeAccountId string, transactionId string) *string

Jump to

Keyboard shortcuts

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