Documentation ¶
Index ¶
- func NewCognitoIdentityContext() interfaces.CognitoIdentityContext
- func NewPostgresContext() interfaces.PostgresContext
- func NewStripeContext() interfaces.StripeContext
- type CognitoIdentityContext
- type PostgresContext
- func (context *PostgresContext) DeleteAccount(id string) (*entities.Account, error)
- func (context *PostgresContext) InsertAccount(acct *entities.Account) error
- func (context *PostgresContext) InsertBusiness(business *entities.Business) error
- func (context *PostgresContext) InsertCourse(course *entities.Course) error
- func (context *PostgresContext) InsertCustomer(customer *entities.Customer) error
- func (context *PostgresContext) InsertPaymentMethod(paymentMethod *entities.PaymentMethod) error
- func (context *PostgresContext) SelectAccountByBusinessID(businessID string) (*entities.Account, error)
- func (context *PostgresContext) SelectAccountByID(id string) (*entities.Account, error)
- func (context *PostgresContext) SelectAccountByStripeID(stripeID string) (*entities.Account, error)
- func (context *PostgresContext) SelectCourseByID(id *string) (*entities.Course, error)
- func (context *PostgresContext) SelectCourses() ([]*entities.Course, error)
- func (context *PostgresContext) SelectCoursesByBusinessID(organizationID *string) ([]*entities.Course, error)
- func (context *PostgresContext) SelectCustomersByUserID(userID *string) ([]*entities.Customer, error)
- func (context *PostgresContext) SelectPaymentMethodsByCustomerID(customerID *string) ([]*entities.PaymentMethod, error)
- type StripeContext
- func (context *StripeContext) AttachPaymentMethod(stripePaymentMethodID *string, stripeCustomerID *string) (*stripe.PaymentMethod, error)
- func (context *StripeContext) DeleteAccount(id string, params *stripe.AccountParams) (*stripe.Account, error)
- func (context *StripeContext) GetAccountByID(id string, params *stripe.AccountParams) (*stripe.Account, error)
- func (context *StripeContext) GetBalance(params *stripe.BalanceParams) (*stripe.Balance, error)
- func (context *StripeContext) NewAccount(params *stripe.AccountParams) (*stripe.Account, error)
- func (context *StripeContext) NewCustomer(parameters *models.AddCustomerParameters) (*models.AddCustomerResult, error)
- func (context *StripeContext) NewPaymentMethod(parameters *models.AddPaymentMethodParameters) (*models.AddPaymentMethodResult, error)
- func (context *StripeContext) UpdateAccount(id string, params *stripe.AccountParams) (*stripe.Account, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCognitoIdentityContext ¶
func NewCognitoIdentityContext() interfaces.CognitoIdentityContext
NewCognitoIdentityContext ...
func NewPostgresContext ¶
func NewPostgresContext() interfaces.PostgresContext
NewPostgresContext ...
Types ¶
type CognitoIdentityContext ¶
type CognitoIdentityContext struct {
// contains filtered or unexported fields
}
CognitoIdentityContext ...
func (*CognitoIdentityContext) AdminCreateUser ¶
func (ctx *CognitoIdentityContext) AdminCreateUser(parameters *models.AddUserParameters) (*models.AddUserResult, error)
AdminCreateUser ...
func (*CognitoIdentityContext) AdminGetUser ¶
func (ctx *CognitoIdentityContext) AdminGetUser(in *cognitoidentityprovider.AdminGetUserInput) (*cognitoidentityprovider.AdminGetUserOutput, error)
AdminGetUser ...
type PostgresContext ¶
type PostgresContext struct {
// contains filtered or unexported fields
}
PostgresContext ...
func (*PostgresContext) DeleteAccount ¶
func (context *PostgresContext) DeleteAccount(id string) (*entities.Account, error)
DeleteAccount ...
func (*PostgresContext) InsertAccount ¶
func (context *PostgresContext) InsertAccount(acct *entities.Account) error
InsertAccount ...
func (*PostgresContext) InsertBusiness ¶
func (context *PostgresContext) InsertBusiness(business *entities.Business) error
InsertBusiness ...
func (*PostgresContext) InsertCourse ¶
func (context *PostgresContext) InsertCourse(course *entities.Course) error
InsertCourse ...
func (*PostgresContext) InsertCustomer ¶
func (context *PostgresContext) InsertCustomer(customer *entities.Customer) error
InsertCustomer ...
func (*PostgresContext) InsertPaymentMethod ¶
func (context *PostgresContext) InsertPaymentMethod(paymentMethod *entities.PaymentMethod) error
InsertPaymentMethod ...
func (*PostgresContext) SelectAccountByBusinessID ¶
func (context *PostgresContext) SelectAccountByBusinessID(businessID string) (*entities.Account, error)
SelectAccountByBusinessID ...
func (*PostgresContext) SelectAccountByID ¶
func (context *PostgresContext) SelectAccountByID(id string) (*entities.Account, error)
SelectAccountByID ...
func (*PostgresContext) SelectAccountByStripeID ¶
func (context *PostgresContext) SelectAccountByStripeID(stripeID string) (*entities.Account, error)
SelectAccountByStripeID ...
func (*PostgresContext) SelectCourseByID ¶
func (context *PostgresContext) SelectCourseByID(id *string) (*entities.Course, error)
SelectCourseByID ...
func (*PostgresContext) SelectCourses ¶
func (context *PostgresContext) SelectCourses() ([]*entities.Course, error)
SelectCourses ...
func (*PostgresContext) SelectCoursesByBusinessID ¶
func (context *PostgresContext) SelectCoursesByBusinessID(organizationID *string) ([]*entities.Course, error)
SelectCoursesByBusinessID ...
func (*PostgresContext) SelectCustomersByUserID ¶
func (context *PostgresContext) SelectCustomersByUserID(userID *string) ([]*entities.Customer, error)
SelectCustomersByUserID ...
func (*PostgresContext) SelectPaymentMethodsByCustomerID ¶
func (context *PostgresContext) SelectPaymentMethodsByCustomerID(customerID *string) ([]*entities.PaymentMethod, error)
SelectPaymentMethodsByCustomerID ...
type StripeContext ¶
type StripeContext struct{}
StripeContext ...
func (*StripeContext) AttachPaymentMethod ¶
func (context *StripeContext) AttachPaymentMethod(stripePaymentMethodID *string, stripeCustomerID *string) (*stripe.PaymentMethod, error)
AttachPaymentMethod ...
func (*StripeContext) DeleteAccount ¶
func (context *StripeContext) DeleteAccount(id string, params *stripe.AccountParams) (*stripe.Account, error)
DeleteAccount ...
func (*StripeContext) GetAccountByID ¶
func (context *StripeContext) GetAccountByID(id string, params *stripe.AccountParams) (*stripe.Account, error)
GetAccountByID ...
func (*StripeContext) GetBalance ¶
func (context *StripeContext) GetBalance(params *stripe.BalanceParams) (*stripe.Balance, error)
GetBalance ...
func (*StripeContext) NewAccount ¶
func (context *StripeContext) NewAccount(params *stripe.AccountParams) (*stripe.Account, error)
NewAccount creates new Stripe Account with CardPayments and Transfers capabilities in the US with Account email.
func (*StripeContext) NewCustomer ¶
func (context *StripeContext) NewCustomer(parameters *models.AddCustomerParameters) (*models.AddCustomerResult, error)
NewCustomer ...
func (*StripeContext) NewPaymentMethod ¶
func (context *StripeContext) NewPaymentMethod(parameters *models.AddPaymentMethodParameters) (*models.AddPaymentMethodResult, error)
NewPaymentMethod ...
func (*StripeContext) UpdateAccount ¶
func (context *StripeContext) UpdateAccount(id string, params *stripe.AccountParams) (*stripe.Account, error)
UpdateAccount ...