Documentation ¶
Index ¶
- Constants
- Variables
- func NewVatReportProcessor(s *Service, ctx context.Context, date *timestamp.Timestamp) (*vatReportProcessor, error)
- func RandomString(n int) string
- type Accounting
- func (a *Accounting) GetCorrectionsForRoyaltyReport(ctx context.Context, merchantId, currency string, from, to time.Time) (items []*billingpb.AccountingEntry, err error)
- func (a Accounting) GetRollingReservesForRoyaltyReport(ctx context.Context, merchantId, currency string, from, to time.Time) (items []*billingpb.AccountingEntry, err error)
- type AccountingServiceInterface
- type BinData
- type BrowserCookieCustomer
- type CardPayAddress
- type CardPayBankCardAccount
- type CardPayCardAccount
- type CardPayCryptoCurrencyAccount
- type CardPayCustomer
- type CardPayEWalletAccount
- type CardPayItem
- type CardPayMerchantOrder
- type CardPayOrder
- type CardPayOrderRecurringResponse
- type CardPayOrderRecurringResponseRecurringData
- type CardPayOrderResponse
- type CardPayPaymentData
- type CardPayRecurringData
- type CardPayRecurringDataFiling
- type CardPayRefundData
- type CardPayRefundRequest
- type CardPayRefundResponse
- type CardPayRefundResponseCustomer
- type CardPayRefundResponsePaymentData
- type CardPayRefundResponseRefundData
- type CardPayRequest
- type CardPayReturnUrls
- type Centrifugo
- type CentrifugoInterface
- type Commission
- type Currency
- type DashboardReportProcessor
- func (m *DashboardReportProcessor) ExecuteGrossRevenueAndVatReports(ctx context.Context, receiver interface{}) (interface{}, error)
- func (m *DashboardReportProcessor) ExecuteReport(ctx context.Context, receiver interface{}) (interface{}, error)
- func (m *DashboardReportProcessor) ExecuteRevenueByCountryReport(ctx context.Context, receiver interface{}) (interface{}, error)
- func (m *DashboardReportProcessor) ExecuteRevenueDynamicReport(ctx context.Context, receiver interface{}) (interface{}, error)
- func (m *DashboardReportProcessor) ExecuteSalesTodayReport(ctx context.Context, receiver interface{}) (interface{}, error)
- func (m *DashboardReportProcessor) ExecuteSourcesReport(ctx context.Context, receiver interface{}) (interface{}, error)
- func (m *DashboardReportProcessor) ExecuteTotalTransactionsAndArpuReports(ctx context.Context, receiver interface{}) (interface{}, error)
- type DashboardReportProcessorInterface
- type DashboardRepository
- func (m *DashboardRepository) GetBaseReport(ctx context.Context, merchantId, period string) (*billingpb.DashboardBaseReports, error)
- func (m *DashboardRepository) GetBaseRevenueByCountryReport(ctx context.Context, merchantId, period string) (*billingpb.DashboardRevenueByCountryReport, error)
- func (m *DashboardRepository) GetBaseSalesTodayReport(ctx context.Context, merchantId, period string) (*billingpb.DashboardSalesTodayReport, error)
- func (m *DashboardRepository) GetBaseSourcesReport(ctx context.Context, merchantId, period string) (*billingpb.DashboardSourcesReport, error)
- func (m *DashboardRepository) GetMainReport(ctx context.Context, merchantId, period string) (*billingpb.DashboardMainReport, error)
- func (m *DashboardRepository) GetRevenueDynamicsReport(ctx context.Context, merchantId, period string) (*billingpb.DashboardRevenueDynamicReport, error)
- func (m *DashboardRepository) NewDashboardReportProcessor(merchantId, period, cacheKeyMask string, status interface{}, ...) (*DashboardReportProcessor, error)
- type DashboardRepositoryInterface
- type EmailConfirmToken
- type Entity
- type Gate
- type Gateway
- type GrossRevenueAndVatReports
- type Key
- func (h *Key) CancelById(ctx context.Context, id string) (*billingpb.Key, error)
- func (h *Key) CountKeysByProductPlatform(ctx context.Context, keyProductId string, platformId string) (int64, error)
- func (h *Key) FindUnfinished(ctx context.Context) ([]*billingpb.Key, error)
- func (h *Key) FinishRedeemById(ctx context.Context, id string) (*billingpb.Key, error)
- func (h *Key) GetById(ctx context.Context, id string) (*billingpb.Key, error)
- func (h *Key) Insert(ctx context.Context, key *billingpb.Key) error
- func (h *Key) ReserveKey(ctx context.Context, keyProductId string, platformId string, orderId string, ...) (*billingpb.Key, error)
- type KeyProductRepository
- type KeyProductRepositoryInterface
- type KeyRepositoryInterface
- type MerchantTariffRatesInterface
- type MerchantsTariffRatesRepository
- func (h *MerchantsTariffRatesRepository) GetBy(ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest) (*billingpb.GetMerchantTariffRatesResponseItems, error)
- func (h *MerchantsTariffRatesRepository) GetCacheKeyForGetBy(req *billingpb.GetMerchantTariffRatesRequest) (string, error)
- func (h *MerchantsTariffRatesRepository) GetPaymentTariffsBy(ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest) ([]*billingpb.MerchantTariffRatesPayment, error)
- func (h *MerchantsTariffRatesRepository) GetTariffsSettings(ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest) (*billingpb.MerchantTariffRatesSettings, error)
- type OrderCreateRequestProcessor
- type OrderView
- func (ow *OrderView) CountTransactions(ctx context.Context, match bson.M) (n int64, err error)
- func (ow *OrderView) GetOrderBy(ctx context.Context, id, uuid, merchantId string, receiver interface{}) (interface{}, error)
- func (ow *OrderView) GetPaylinkStat(ctx context.Context, paylinkId, merchantId string, from, to int64) (*billingpb.StatCommon, error)
- func (ow *OrderView) GetPaylinkStatByCountry(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error)
- func (ow *OrderView) GetPaylinkStatByDate(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error)
- func (ow *OrderView) GetPaylinkStatByReferrer(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error)
- func (ow *OrderView) GetPaylinkStatByUtm(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error)
- func (ow *OrderView) GetPaylinkStatMatchQuery(paylinkId, merchantId string, from, to int64) []bson.M
- func (ow *OrderView) GetPublicByOrderId(ctx context.Context, orderId string) (*billingpb.OrderViewPublic, error)
- func (ow *OrderView) GetRoyaltySummary(ctx context.Context, merchantId, currency string, from, to time.Time) (items []*billingpb.RoyaltyReportProductSummaryItem, ...)
- func (ow *OrderView) GetTransactionsPrivate(ctx context.Context, match bson.M, limit, offset int64) ([]*billingpb.OrderViewPrivate, error)
- func (ow *OrderView) GetTransactionsPublic(ctx context.Context, match bson.M, limit, offset int64) ([]*billingpb.OrderViewPublic, error)
- type OrderViewServiceInterface
- type Paylink
- func (p Paylink) CountByQuery(ctx context.Context, query bson.M) (n int64, err error)
- func (p Paylink) Delete(ctx context.Context, id, merchantId string) error
- func (p Paylink) GetById(ctx context.Context, id string) (pl *billingpb.Paylink, err error)
- func (p Paylink) GetByIdAndMerchant(ctx context.Context, id, merchantId string) (pl *billingpb.Paylink, err error)
- func (p Paylink) GetListByQuery(ctx context.Context, query bson.M, limit, offset int64) (result []*billingpb.Paylink, err error)
- func (p Paylink) GetPaylinkVisits(ctx context.Context, id string, from, to int64) (n int64, err error)
- func (p *Paylink) GetUrl(ctx context.Context, ...) (string, error)
- func (p Paylink) IncrVisits(ctx context.Context, id string) (err error)
- func (p Paylink) Insert(ctx context.Context, pl *billingpb.Paylink) (err error)
- func (p Paylink) Update(ctx context.Context, pl *billingpb.Paylink) (err error)
- func (p Paylink) UpdatePaylinkTotalStat(ctx context.Context, id, merchantId string) (err error)
- type PaylinkServiceInterface
- type PaymentChannelCostMerchant
- func (h PaymentChannelCostMerchant) Delete(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error
- func (h PaymentChannelCostMerchant) Get(ctx context.Context, merchantId string, name string, payoutCurrency string, ...) (c []*internalPkg.PaymentChannelCostMerchantSet, err error)
- func (h PaymentChannelCostMerchant) GetAllForMerchant(ctx context.Context, merchantId string) (*billingpb.PaymentChannelCostMerchantList, error)
- func (h PaymentChannelCostMerchant) GetById(ctx context.Context, id string) (*billingpb.PaymentChannelCostMerchant, error)
- func (h *PaymentChannelCostMerchant) Insert(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error
- func (h PaymentChannelCostMerchant) MultipleInsert(ctx context.Context, obj []*billingpb.PaymentChannelCostMerchant) error
- func (h PaymentChannelCostMerchant) Update(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error
- type PaymentChannelCostMerchantInterface
- type PaymentChannelCostSystem
- func (h PaymentChannelCostSystem) Delete(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error
- func (h PaymentChannelCostSystem) Get(ctx context.Context, name, region, country, mccCode, operatingCompanyId string) (*billingpb.PaymentChannelCostSystem, error)
- func (h PaymentChannelCostSystem) GetAll(ctx context.Context) (*billingpb.PaymentChannelCostSystemList, error)
- func (h PaymentChannelCostSystem) GetById(ctx context.Context, id string) (*billingpb.PaymentChannelCostSystem, error)
- func (h *PaymentChannelCostSystem) Insert(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error
- func (h PaymentChannelCostSystem) MultipleInsert(ctx context.Context, obj []*billingpb.PaymentChannelCostSystem) error
- func (h PaymentChannelCostSystem) Update(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error
- type PaymentChannelCostSystemInterface
- type PaymentCreateProcessor
- type PaymentFormProcessor
- type PaymentMethod
- func (h *PaymentMethod) GetAll(ctx context.Context) (map[string]*billingpb.PaymentMethod, error)
- func (h *PaymentMethod) GetByGroupAndCurrency(ctx context.Context, isProduction bool, group string, currency string) (*billingpb.PaymentMethod, error)
- func (h *PaymentMethod) GetById(ctx context.Context, id string) (*billingpb.PaymentMethod, error)
- func (h *PaymentMethod) GetPaymentSettings(paymentMethod *billingpb.PaymentMethod, currency string, mccCode string, ...) (*billingpb.PaymentMethodParams, error)
- func (h *PaymentMethod) Insert(ctx context.Context, pm *billingpb.PaymentMethod) error
- func (h *PaymentMethod) ListByOrder(ctx context.Context, order *billingpb.Order) ([]*billingpb.PaymentMethod, error)
- func (h *PaymentMethod) MultipleInsert(ctx context.Context, pm []*billingpb.PaymentMethod) error
- func (h *PaymentMethod) Update(ctx context.Context, pm *billingpb.PaymentMethod) error
- type PaymentMethodInterface
- type PaymentMethods
- type PaymentMinLimitSystem
- func (p PaymentMinLimitSystem) GetAll(ctx context.Context) (result []*billingpb.PaymentMinLimitSystem, err error)
- func (p PaymentMinLimitSystem) GetByCurrency(ctx context.Context, currency string) (pmls *billingpb.PaymentMinLimitSystem, err error)
- func (p PaymentMinLimitSystem) MultipleInsert(ctx context.Context, pmlsArray []*billingpb.PaymentMinLimitSystem) (err error)
- func (p PaymentMinLimitSystem) Upsert(ctx context.Context, pmls *billingpb.PaymentMinLimitSystem) (err error)
- type PaymentMinLimitSystemInterface
- type PaymentSystemMockError
- func (m *PaymentSystemMockError) CreatePayment(order *billingpb.Order, successUrl, failUrl string, ...) (string, error)
- func (m *PaymentSystemMockError) CreateRefund(order *billingpb.Order, refund *billingpb.Refund) error
- func (m *PaymentSystemMockError) GetRecurringId(request proto.Message) string
- func (m *PaymentSystemMockError) IsRecurringCallback(request proto.Message) bool
- func (m *PaymentSystemMockError) ProcessPayment(order *billingpb.Order, message proto.Message, raw, signature string) error
- func (m *PaymentSystemMockError) ProcessRefund(order *billingpb.Order, refund *billingpb.Refund, message proto.Message, ...) error
- type PaymentSystemMockOk
- func (m *PaymentSystemMockOk) CreatePayment(order *billingpb.Order, successUrl, failUrl string, ...) (string, error)
- func (m *PaymentSystemMockOk) CreateRefund(order *billingpb.Order, refund *billingpb.Refund) error
- func (m *PaymentSystemMockOk) GetRecurringId(request proto.Message) string
- func (m *PaymentSystemMockOk) IsRecurringCallback(request proto.Message) bool
- func (m *PaymentSystemMockOk) ProcessPayment(order *billingpb.Order, message proto.Message, raw, signature string) error
- func (m *PaymentSystemMockOk) ProcessRefund(order *billingpb.Order, refund *billingpb.Refund, message proto.Message, ...) error
- type PaymentSystemService
- func (h PaymentSystemService) GetById(ctx context.Context, id string) (*billingpb.PaymentSystem, error)
- func (h *PaymentSystemService) Insert(ctx context.Context, ps *billingpb.PaymentSystem) error
- func (h PaymentSystemService) MultipleInsert(ctx context.Context, ps []*billingpb.PaymentSystem) error
- func (h *PaymentSystemService) Update(ctx context.Context, ps *billingpb.PaymentSystem) error
- type PaymentSystemServiceInterface
- type PayoutDocument
- func (h *PayoutDocument) CountByQuery(ctx context.Context, query bson.M) (count int64, err error)
- func (h *PayoutDocument) FindByQuery(ctx context.Context, query bson.M, sorts []string, limit, offset int64) ([]*billingpb.PayoutDocument, error)
- func (h *PayoutDocument) GetBalanceAmount(ctx context.Context, merchantId, currency string) (float64, error)
- func (h *PayoutDocument) GetById(ctx context.Context, id string) (pd *billingpb.PayoutDocument, err error)
- func (h *PayoutDocument) GetByIdAndMerchant(ctx context.Context, id, merchantId string) (pd *billingpb.PayoutDocument, err error)
- func (h *PayoutDocument) GetLast(ctx context.Context, merchantId, currency string) (pd *billingpb.PayoutDocument, err error)
- func (h *PayoutDocument) Insert(ctx context.Context, pd *billingpb.PayoutDocument, ip, source string) (err error)
- func (h *PayoutDocument) Update(ctx context.Context, pd *billingpb.PayoutDocument, ip, source string) error
- type PayoutDocumentServiceInterface
- type Product
- func (h *Product) CountByProjectSku(ctx context.Context, projectId string, sku string) (int64, error)
- func (h *Product) GetById(ctx context.Context, id string) (*billingpb.Product, error)
- func (h *Product) List(ctx context.Context, merchantId string, projectId string, sku string, ...) (int64, []*billingpb.Product)
- func (h *Product) Upsert(ctx context.Context, p *billingpb.Product) error
- type ProductServiceInterface
- type Repository
- type RoyaltyReport
- func (r *RoyaltyReport) GetBalanceAmount(ctx context.Context, merchantId, currency string) (float64, error)
- func (r *RoyaltyReport) GetById(ctx context.Context, id string) (rr *billingpb.RoyaltyReport, err error)
- func (r *RoyaltyReport) GetByPayoutId(ctx context.Context, payoutId string) (result []*billingpb.RoyaltyReport, err error)
- func (r *RoyaltyReport) GetNonPayoutReports(ctx context.Context, merchantId, currency string) (result []*billingpb.RoyaltyReport, err error)
- func (r *RoyaltyReport) GetReportExists(ctx context.Context, merchantId, currency string, from, to time.Time) (report *billingpb.RoyaltyReport)
- func (r *RoyaltyReport) Insert(ctx context.Context, rr *billingpb.RoyaltyReport, ip, source string) (err error)
- func (r *RoyaltyReport) SetPaid(ctx context.Context, reportIds []string, payoutDocumentId, ip, source string) (err error)
- func (r *RoyaltyReport) SetPayoutDocumentId(ctx context.Context, reportIds []string, payoutDocumentId, ip, source string) error
- func (r *RoyaltyReport) UnsetPaid(ctx context.Context, reportIds []string, ip, source string) (err error)
- func (r *RoyaltyReport) UnsetPayoutDocumentId(ctx context.Context, reportIds []string, ip, source string) (err error)
- func (r *RoyaltyReport) Update(ctx context.Context, rr *billingpb.RoyaltyReport, ip, source string) error
- type RoyaltyReportMerchant
- type RoyaltyReportServiceInterface
- type Service
- func (s *Service) AcceptInvite(ctx context.Context, req *billingpb.AcceptInviteRequest, ...) error
- func (s *Service) AddOperatingCompany(ctx context.Context, req *billingpb.OperatingCompany, ...) (err error)
- func (s *Service) AutoAcceptRoyaltyReports(ctx context.Context, _ *billingpb.EmptyRequest, _ *billingpb.EmptyResponse) error
- func (s *Service) AutoCreatePayoutDocuments(ctx context.Context, req *billingpb.EmptyRequest, rsp *billingpb.EmptyResponse) error
- func (s *Service) CalcAnnualTurnovers(ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.EmptyResponse) error
- func (s *Service) CancelRedeemKeyForOrder(ctx context.Context, req *billingpb.KeyForOrderRequest, ...) error
- func (s *Service) ChangeCodeInOrder(ctx context.Context, req *billingpb.ChangeCodeInOrderRequest, ...) error
- func (s *Service) ChangeMerchant(ctx context.Context, req *billingpb.OnboardingRequest, ...) error
- func (s *Service) ChangeMerchantData(ctx context.Context, req *billingpb.ChangeMerchantDataRequest, ...) error
- func (s *Service) ChangeMerchantManualPayouts(ctx context.Context, req *billingpb.ChangeMerchantManualPayoutsRequest, ...) error
- func (s *Service) ChangeMerchantPaymentMethod(ctx context.Context, req *billingpb.MerchantPaymentMethodRequest, ...) (err error)
- func (s *Service) ChangeMerchantStatus(ctx context.Context, req *billingpb.MerchantChangeStatusRequest, ...) error
- func (s *Service) ChangeProject(ctx context.Context, req *billingpb.Project, ...) error
- func (s *Service) ChangeRoleForAdminUser(ctx context.Context, req *billingpb.ChangeRoleForAdminUserRequest, ...) error
- func (s *Service) ChangeRoleForMerchantUser(ctx context.Context, req *billingpb.ChangeRoleForMerchantUserRequest, ...) error
- func (s *Service) ChangeRoyaltyReport(ctx context.Context, req *billingpb.ChangeRoyaltyReportRequest, ...) error
- func (s *Service) CheckInviteToken(ctx context.Context, req *billingpb.CheckInviteTokenRequest, ...) error
- func (s *Service) CheckProjectRequestSignature(ctx context.Context, req *billingpb.CheckProjectRequestSignatureRequest, ...) error
- func (s *Service) CheckSkuAndKeyProject(ctx context.Context, req *billingpb.CheckSkuAndKeyProjectRequest, ...) error
- func (s *Service) ConfirmUserEmail(ctx context.Context, req *billingpb.ConfirmUserEmailRequest, ...) error
- func (s *Service) CreateAccountingEntry(ctx context.Context, req *billingpb.CreateAccountingEntryRequest, ...) error
- func (s *Service) CreateNotification(ctx context.Context, req *billingpb.NotificationRequest, ...) error
- func (s *Service) CreateOrUpdateKeyProduct(ctx context.Context, req *billingpb.CreateOrUpdateKeyProductRequest, ...) error
- func (s *Service) CreateOrUpdatePaylink(ctx context.Context, req *billingpb.CreatePaylinkRequest, ...) (err error)
- func (s *Service) CreateOrUpdatePaymentMethod(ctx context.Context, req *billingpb.PaymentMethod, ...) error
- func (s *Service) CreateOrUpdatePaymentMethodProductionSettings(ctx context.Context, req *billingpb.ChangePaymentMethodParamsRequest, ...) error
- func (s *Service) CreateOrUpdatePaymentMethodTestSettings(ctx context.Context, req *billingpb.ChangePaymentMethodParamsRequest, ...) error
- func (s *Service) CreateOrUpdateProduct(ctx context.Context, req *billingpb.Product, res *billingpb.Product) error
- func (s *Service) CreateOrUpdateUserProfile(ctx context.Context, req *billingpb.UserProfile, ...) error
- func (s *Service) CreatePageReview(ctx context.Context, req *billingpb.CreatePageReviewRequest, ...) error
- func (s *Service) CreatePayoutDocument(ctx context.Context, req *billingpb.CreatePayoutDocumentRequest, ...) error
- func (s *Service) CreateRefund(ctx context.Context, req *billingpb.CreateRefundRequest, ...) error
- func (s *Service) CreateRoyaltyReport(ctx context.Context, req *billingpb.CreateRoyaltyReportRequest, ...) error
- func (s *Service) CreateToken(ctx context.Context, req *billingpb.TokenRequest, rsp *billingpb.TokenResponse) error
- func (s *Service) DeleteAdminUser(ctx context.Context, req *billingpb.AdminRoleRequest, ...) error
- func (s *Service) DeleteKeyProduct(ctx context.Context, req *billingpb.RequestKeyProductMerchant, ...) error
- func (s *Service) DeleteMerchantUser(ctx context.Context, req *billingpb.MerchantRoleRequest, ...) error
- func (s *Service) DeleteMoneyBackCostMerchant(ctx context.Context, req *billingpb.PaymentCostDeleteRequest, ...) error
- func (s *Service) DeleteMoneyBackCostSystem(ctx context.Context, req *billingpb.PaymentCostDeleteRequest, ...) error
- func (s *Service) DeletePaylink(ctx context.Context, req *billingpb.PaylinkRequest, ...) error
- func (s *Service) DeletePaymentChannelCostMerchant(ctx context.Context, req *billingpb.PaymentCostDeleteRequest, ...) error
- func (s *Service) DeletePaymentChannelCostSystem(ctx context.Context, req *billingpb.PaymentCostDeleteRequest, ...) error
- func (s *Service) DeletePaymentMethodProductionSettings(ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, ...) error
- func (s *Service) DeletePaymentMethodTestSettings(ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, ...) error
- func (s *Service) DeleteProduct(ctx context.Context, req *billingpb.RequestProduct, ...) error
- func (s *Service) DeleteProject(ctx context.Context, req *billingpb.GetProjectRequest, ...) error
- func (s *Service) DeleteSavedCard(ctx context.Context, req *billingpb.DeleteSavedCardRequest, ...) error
- func (s *Service) FindAllOrders(ctx context.Context, req *billingpb.ListOrdersRequest, ...) error
- func (s *Service) FindAllOrdersPrivate(ctx context.Context, req *billingpb.ListOrdersRequest, ...) error
- func (s *Service) FindAllOrdersPublic(ctx context.Context, req *billingpb.ListOrdersRequest, ...) error
- func (s *Service) FindByZipCode(ctx context.Context, req *billingpb.FindByZipCodeRequest, ...) error
- func (s *Service) FinishRedeemKeyForOrder(ctx context.Context, req *billingpb.KeyForOrderRequest, ...) error
- func (s *Service) FixTaxes(ctx context.Context) error
- func (s *Service) FormatAmount(amount float64, currency string) float64
- func (s *Service) GetAdminUserRole(ctx context.Context, req *billingpb.AdminRoleRequest, ...) error
- func (s *Service) GetAdminUsers(ctx context.Context, _ *billingpb.EmptyRequest, ...) error
- func (s *Service) GetAllMoneyBackCostMerchant(ctx context.Context, req *billingpb.MoneyBackCostMerchantListRequest, ...) error
- func (s *Service) GetAllMoneyBackCostSystem(ctx context.Context, req *billingpb.EmptyRequest, ...) error
- func (s *Service) GetAllPaymentChannelCostMerchant(ctx context.Context, req *billingpb.PaymentChannelCostMerchantListRequest, ...) error
- func (s *Service) GetAllPaymentChannelCostSystem(ctx context.Context, req *billingpb.EmptyRequest, ...) error
- func (s *Service) GetAmountForVirtualCurrency(virtualAmount float64, group *billingpb.PriceGroup, ...) (float64, error)
- func (s *Service) GetAvailableKeysCount(ctx context.Context, req *billingpb.GetPlatformKeyCountRequest, ...) error
- func (s *Service) GetCommonUserProfile(ctx context.Context, req *billingpb.CommonUserProfileRequest, ...) error
- func (s *Service) GetCountriesList(ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.CountriesList) error
- func (s *Service) GetCountriesListForOrder(ctx context.Context, req *billingpb.GetCountriesListForOrderRequest, ...) error
- func (s *Service) GetCountry(ctx context.Context, req *billingpb.GetCountryRequest, res *billingpb.Country) error
- func (s *Service) GetDashboardBaseReport(ctx context.Context, req *billingpb.GetDashboardBaseReportRequest, ...) error
- func (s *Service) GetDashboardMainReport(ctx context.Context, req *billingpb.GetDashboardMainRequest, ...) error
- func (s *Service) GetDashboardRevenueDynamicsReport(ctx context.Context, req *billingpb.GetDashboardMainRequest, ...) error
- func (s *Service) GetKeyByID(ctx context.Context, req *billingpb.KeyForOrderRequest, ...) error
- func (s *Service) GetKeyProduct(ctx context.Context, req *billingpb.RequestKeyProductMerchant, ...) error
- func (s *Service) GetKeyProductInfo(ctx context.Context, req *billingpb.GetKeyProductInfoRequest, ...) error
- func (s *Service) GetKeyProducts(ctx context.Context, req *billingpb.ListKeyProductsRequest, ...) error
- func (s *Service) GetKeyProductsForOrder(ctx context.Context, req *billingpb.GetKeyProductsForOrderRequest, ...) error
- func (s *Service) GetMerchantBalance(ctx context.Context, req *billingpb.GetMerchantBalanceRequest, ...) error
- func (s *Service) GetMerchantBy(ctx context.Context, req *billingpb.GetMerchantByRequest, ...) error
- func (s *Service) GetMerchantOnboardingCompleteData(ctx context.Context, req *billingpb.SetMerchantS3AgreementRequest, ...) error
- func (s *Service) GetMerchantPaymentMethod(ctx context.Context, req *billingpb.GetMerchantPaymentMethodRequest, ...) error
- func (s *Service) GetMerchantTariffRates(ctx context.Context, req *billingpb.GetMerchantTariffRatesRequest, ...) error
- func (s *Service) GetMerchantUserRole(ctx context.Context, req *billingpb.MerchantRoleRequest, ...) error
- func (s *Service) GetMerchantUsers(ctx context.Context, req *billingpb.GetMerchantUsersRequest, ...) error
- func (s *Service) GetMerchantsForUser(ctx context.Context, req *billingpb.GetMerchantsForUserRequest, ...) error
- func (s *Service) GetMoneyBackCostMerchant(ctx context.Context, req *billingpb.MoneyBackCostMerchantRequest, ...) error
- func (s *Service) GetMoneyBackCostSystem(ctx context.Context, req *billingpb.MoneyBackCostSystemRequest, ...) error
- func (s *Service) GetNotification(ctx context.Context, req *billingpb.GetNotificationRequest, ...) error
- func (s *Service) GetOperatingCompaniesList(ctx context.Context, req *billingpb.EmptyRequest, ...) (err error)
- func (s *Service) GetOperatingCompany(ctx context.Context, req *billingpb.GetOperatingCompanyRequest, ...) (err error)
- func (s *Service) GetOrderKeyProducts(ctx context.Context, projectId string, productIds []string) ([]*billingpb.KeyProduct, error)
- func (s *Service) GetOrderKeyProductsAmount(products []*billingpb.KeyProduct, group *billingpb.PriceGroup, ...) (float64, error)
- func (s *Service) GetOrderKeyProductsItems(products []*billingpb.KeyProduct, language string, group *billingpb.PriceGroup, ...) ([]*billingpb.OrderItem, error)
- func (s *Service) GetOrderPrivate(ctx context.Context, req *billingpb.GetOrderRequest, ...) error
- func (s *Service) GetOrderProducts(ctx context.Context, projectId string, productIds []string) ([]*billingpb.Product, error)
- func (s *Service) GetOrderProductsAmount(products []*billingpb.Product, group *billingpb.PriceGroup) (float64, error)
- func (s *Service) GetOrderProductsItems(products []*billingpb.Product, language string, group *billingpb.PriceGroup) ([]*billingpb.OrderItem, error)
- func (s *Service) GetOrderPublic(ctx context.Context, req *billingpb.GetOrderRequest, ...) error
- func (s *Service) GetPaylink(ctx context.Context, req *billingpb.PaylinkRequest, ...) (err error)
- func (s *Service) GetPaylinkStatByCountry(ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, ...) (err error)
- func (s *Service) GetPaylinkStatByDate(ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, ...) (err error)
- func (s *Service) GetPaylinkStatByReferrer(ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, ...) (err error)
- func (s *Service) GetPaylinkStatByUtm(ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, ...) (err error)
- func (s *Service) GetPaylinkStatTotal(ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, ...) (err error)
- func (s *Service) GetPaylinkTransactions(ctx context.Context, req *billingpb.GetPaylinkTransactionsRequest, ...) error
- func (s *Service) GetPaylinkURL(ctx context.Context, req *billingpb.GetPaylinkURLRequest, ...) (err error)
- func (s *Service) GetPaylinks(ctx context.Context, req *billingpb.GetPaylinksRequest, ...) error
- func (s *Service) GetPaymentChannelCostMerchant(ctx context.Context, req *billingpb.PaymentChannelCostMerchantRequest, ...) error
- func (s *Service) GetPaymentChannelCostSystem(ctx context.Context, req *billingpb.PaymentChannelCostSystemRequest, ...) error
- func (s *Service) GetPaymentMethodProductionSettings(ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, ...) error
- func (s *Service) GetPaymentMethodTestSettings(ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, ...) error
- func (s *Service) GetPaymentMinLimitsSystem(ctx context.Context, req *billingpb.EmptyRequest, ...) (err error)
- func (s *Service) GetPayoutDocument(ctx context.Context, req *billingpb.GetPayoutDocumentRequest, ...) (err error)
- func (s *Service) GetPayoutDocumentRoyaltyReports(ctx context.Context, req *billingpb.GetPayoutDocumentRequest, ...) error
- func (s *Service) GetPayoutDocuments(ctx context.Context, req *billingpb.GetPayoutDocumentsRequest, ...) error
- func (s *Service) GetPlatforms(ctx context.Context, req *billingpb.ListPlatformsRequest, ...) error
- func (s *Service) GetPriceGroup(ctx context.Context, req *billingpb.GetPriceGroupRequest, ...) error
- func (s *Service) GetPriceGroupByCountry(ctx context.Context, req *billingpb.PriceGroupByCountryRequest, ...) error
- func (s *Service) GetPriceGroupByRegion(ctx context.Context, req *billingpb.GetPriceGroupByRegionRequest, ...) error
- func (s *Service) GetPriceGroupCurrencies(ctx context.Context, req *billingpb.EmptyRequest, ...) error
- func (s *Service) GetPriceGroupCurrencyByRegion(ctx context.Context, req *billingpb.PriceGroupByRegionRequest, ...) error
- func (s *Service) GetProduct(ctx context.Context, req *billingpb.RequestProduct, ...) error
- func (s *Service) GetProductPrices(ctx context.Context, req *billingpb.RequestProduct, ...) error
- func (s *Service) GetProductsForOrder(ctx context.Context, req *billingpb.GetProductsForOrderRequest, ...) error
- func (s *Service) GetProject(ctx context.Context, req *billingpb.GetProjectRequest, ...) error
- func (s *Service) GetRecommendedPriceByConversion(ctx context.Context, req *billingpb.RecommendedPriceRequest, ...) error
- func (s *Service) GetRecommendedPriceByPriceGroup(ctx context.Context, req *billingpb.RecommendedPriceRequest, ...) error
- func (s *Service) GetRecommendedPriceTable(ctx context.Context, req *billingpb.RecommendedPriceTableRequest, ...) error
- func (s *Service) GetRefund(ctx context.Context, req *billingpb.GetRefundRequest, ...) error
- func (s *Service) GetRoleList(ctx context.Context, req *billingpb.GetRoleListRequest, ...) error
- func (s *Service) GetRoyaltyReport(ctx context.Context, req *billingpb.GetRoyaltyReportRequest, ...) error
- func (s *Service) GetUserProfile(ctx context.Context, req *billingpb.GetUserProfileRequest, ...) error
- func (s *Service) GetVatReport(ctx context.Context, req *billingpb.VatReportRequest, ...) error
- func (s *Service) GetVatReportTransactions(ctx context.Context, req *billingpb.VatTransactionsRequest, ...) error
- func (s *Service) GetVatReportsDashboard(ctx context.Context, req *billingpb.EmptyRequest, ...) error
- func (s *Service) GetVatReportsForCountry(ctx context.Context, req *billingpb.VatReportsRequest, ...) error
- func (s *Service) IncrPaylinkVisits(ctx context.Context, req *billingpb.PaylinkRequestById, ...) error
- func (s *Service) Init() (err error)
- func (s *Service) InviteUserAdmin(ctx context.Context, req *billingpb.InviteUserAdminRequest, ...) error
- func (s *Service) InviteUserMerchant(ctx context.Context, req *billingpb.InviteUserMerchantRequest, ...) error
- func (s *Service) IsChangeDataAllow(merchant *billingpb.Merchant, data *billingpb.OnboardingRequest) bool
- func (s *Service) IsDbNotFoundError(err error) bool
- func (s *Service) IsOrderCanBePaying(ctx context.Context, req *billingpb.IsOrderCanBePayingRequest, ...) error
- func (s *Service) KeyDaemonProcess(ctx context.Context) (int, error)
- func (s *Service) ListMerchantPaymentMethods(ctx context.Context, req *billingpb.ListMerchantPaymentMethodsRequest, ...) error
- func (s *Service) ListMerchants(ctx context.Context, req *billingpb.MerchantListingRequest, ...) error
- func (s *Service) ListNotifications(ctx context.Context, req *billingpb.ListingNotificationRequest, ...) error
- func (s *Service) ListProducts(ctx context.Context, req *billingpb.ListProductsRequest, ...) error
- func (s *Service) ListProjects(ctx context.Context, req *billingpb.ListProjectsRequest, ...) error
- func (s *Service) ListRefunds(ctx context.Context, req *billingpb.ListRefundsRequest, ...) error
- func (s *Service) ListRoyaltyReportOrders(ctx context.Context, req *billingpb.ListRoyaltyReportOrdersRequest, ...) error
- func (s *Service) ListRoyaltyReports(ctx context.Context, req *billingpb.ListRoyaltyReportsRequest, ...) error
- func (s *Service) MarkNotificationAsRead(ctx context.Context, req *billingpb.GetNotificationRequest, ...) error
- func (s *Service) MerchantReviewRoyaltyReport(ctx context.Context, req *billingpb.MerchantReviewRoyaltyReportRequest, ...) error
- func (s *Service) MerchantsMigrate(ctx context.Context) error
- func (s *Service) OrderCreateByPaylink(ctx context.Context, req *billingpb.OrderCreateByPaylink, ...) error
- func (s *Service) OrderCreateProcess(ctx context.Context, req *billingpb.OrderCreateRequest, ...) error
- func (s *Service) OrderReCreateProcess(ctx context.Context, req *billingpb.OrderReCreateProcessRequest, ...) error
- func (s *Service) OrderReceipt(ctx context.Context, req *billingpb.OrderReceiptRequest, ...) error
- func (s *Service) PaymentCallbackProcess(ctx context.Context, req *billingpb.PaymentNotifyRequest, ...) error
- func (s *Service) PaymentCreateProcess(ctx context.Context, req *billingpb.PaymentCreateRequest, ...) error
- func (s *Service) PaymentFormJsonDataProcess(ctx context.Context, req *billingpb.PaymentFormJsonDataRequest, ...) error
- func (s *Service) PaymentFormLanguageChanged(ctx context.Context, req *billingpb.PaymentFormUserChangeLangRequest, ...) error
- func (s *Service) PaymentFormPaymentAccountChanged(ctx context.Context, req *billingpb.PaymentFormUserChangePaymentAccountRequest, ...) error
- func (s *Service) PaymentFormPlatformChanged(ctx context.Context, req *billingpb.PaymentFormUserChangePlatformRequest, ...) error
- func (s *Service) PayoutDocumentPdfUploaded(ctx context.Context, req *billingpb.PayoutDocumentPdfUploadedRequest, ...) error
- func (s *Service) ProcessBillingAddress(ctx context.Context, req *billingpb.ProcessBillingAddressRequest, ...) error
- func (s *Service) ProcessOrderKeyProducts(ctx context.Context, order *billingpb.Order) ([]*billingpb.Platform, error)
- func (s *Service) ProcessOrderProducts(ctx context.Context, order *billingpb.Order) error
- func (s *Service) ProcessOrderVirtualCurrency(ctx context.Context, order *billingpb.Order) error
- func (s *Service) ProcessRefundCallback(ctx context.Context, req *billingpb.CallbackRequest, ...) error
- func (s *Service) ProcessVatReports(ctx context.Context, req *billingpb.ProcessVatReportsRequest, ...) error
- func (s *Service) PublishKeyProduct(ctx context.Context, req *billingpb.PublishKeyProductRequest, ...) error
- func (s *Service) RebuildOrderView(ctx context.Context) error
- func (s *Service) ResendInviteAdmin(ctx context.Context, req *billingpb.ResendInviteAdminRequest, ...) error
- func (s *Service) ResendInviteMerchant(ctx context.Context, req *billingpb.ResendInviteMerchantRequest, ...) error
- func (s *Service) ReserveKeyForOrder(ctx context.Context, req *billingpb.PlatformKeyReserveRequest, ...) error
- func (s *Service) RoyaltyReportPdfUploaded(ctx context.Context, req *billingpb.RoyaltyReportPdfUploadedRequest, ...) error
- func (s *Service) SetMerchantOperatingCompany(ctx context.Context, req *billingpb.SetMerchantOperatingCompanyRequest, ...) error
- func (s *Service) SetMerchantS3Agreement(ctx context.Context, req *billingpb.SetMerchantS3AgreementRequest, ...) error
- func (s *Service) SetMerchantTariffRates(ctx context.Context, req *billingpb.SetMerchantTariffRatesRequest, ...) error
- func (s *Service) SetMoneyBackCostMerchant(ctx context.Context, req *billingpb.MoneyBackCostMerchant, ...) error
- func (s *Service) SetMoneyBackCostSystem(ctx context.Context, req *billingpb.MoneyBackCostSystem, ...) error
- func (s *Service) SetPaymentChannelCostMerchant(ctx context.Context, req *billingpb.PaymentChannelCostMerchant, ...) error
- func (s *Service) SetPaymentChannelCostSystem(ctx context.Context, req *billingpb.PaymentChannelCostSystem, ...) error
- func (s *Service) SetPaymentMinLimitSystem(ctx context.Context, req *billingpb.PaymentMinLimitSystem, ...) (err error)
- func (s *Service) SetUserNotifyNewRegion(ctx context.Context, req *billingpb.SetUserNotifyRequest, ...) error
- func (s *Service) SetUserNotifySales(ctx context.Context, req *billingpb.SetUserNotifyRequest, ...) error
- func (s *Service) UnPublishKeyProduct(ctx context.Context, req *billingpb.UnPublishKeyProductRequest, ...) error
- func (s *Service) UpdateCountry(ctx context.Context, req *billingpb.Country, res *billingpb.Country) error
- func (s *Service) UpdateOrder(ctx context.Context, req *billingpb.Order, _ *billingpb.EmptyResponse) error
- func (s *Service) UpdatePayoutDocument(ctx context.Context, req *billingpb.UpdatePayoutDocumentRequest, ...) error
- func (s *Service) UpdatePriceGroup(ctx context.Context, req *billingpb.PriceGroup, res *billingpb.PriceGroup) error
- func (s *Service) UpdateProductPrices(ctx context.Context, req *billingpb.UpdateProductPricesRequest, ...) error
- func (s *Service) UpdateVatReportStatus(ctx context.Context, req *billingpb.UpdateVatReportStatusRequest, ...) error
- func (s *Service) UploadKeysFile(ctx context.Context, req *billingpb.PlatformKeysFileRequest, ...) error
- type TariffRates
- type Token
- type TotalTransactionsAndArpuReports
Constants ¶
View Source
const ( HeaderContentType = "Content-Type" HeaderAuthorization = "Authorization" HeaderContentLength = "Content-Length" MIMEApplicationForm = "application/x-www-form-urlencoded" MIMEApplicationJSON = "application/json" CountryCodeUSA = "US" DefaultLanguage = "en" )
View Source
const ( VatPeriodEvery1Month = 1 VatPeriodEvery2Month = 2 VatPeriodEvery3Month = 3 )
Variables ¶
View Source
var ( VatReportOnStatusNotifyToCentrifugo = []string{ pkg.VatReportStatusNeedToPay, pkg.VatReportStatusPaid, pkg.VatReportStatusOverdue, pkg.VatReportStatusCanceled, } VatReportOnStatusNotifyToEmail = []string{ pkg.VatReportStatusNeedToPay, pkg.VatReportStatusOverdue, pkg.VatReportStatusCanceled, } VatReportStatusAllowManualChangeFrom = []string{ pkg.VatReportStatusNeedToPay, pkg.VatReportStatusOverdue, } VatReportStatusAllowManualChangeTo = []string{ pkg.VatReportStatusPaid, pkg.VatReportStatusCanceled, } AccountingEntriesLocalAmountsUpdate = []string{ pkg.AccountingEntryTypeRealGrossRevenue, pkg.AccountingEntryTypeRealTaxFee, pkg.AccountingEntryTypeCentralBankTaxFee, pkg.AccountingEntryTypeRealRefund, pkg.AccountingEntryTypeRealRefundTaxFee, } )
Functions ¶
func NewVatReportProcessor ¶
func RandomString ¶
Types ¶
type Accounting ¶
type Accounting Entity
func (*Accounting) GetCorrectionsForRoyaltyReport ¶
func (a *Accounting) GetCorrectionsForRoyaltyReport( ctx context.Context, merchantId, currency string, from, to time.Time, ) (items []*billingpb.AccountingEntry, err error)
func (Accounting) GetRollingReservesForRoyaltyReport ¶
func (a Accounting) GetRollingReservesForRoyaltyReport( ctx context.Context, merchantId, currency string, from, to time.Time, ) (items []*billingpb.AccountingEntry, err error)
type AccountingServiceInterface ¶
type AccountingServiceInterface interface { GetCorrectionsForRoyaltyReport(ctx context.Context, merchantId, currency string, from, to time.Time) (items []*billingpb.AccountingEntry, err error) GetRollingReservesForRoyaltyReport(ctx context.Context, merchantId, currency string, from, to time.Time) (items []*billingpb.AccountingEntry, err error) }
type BinData ¶
type BinData struct { Id primitive.ObjectID `bson:"_id"` CardBin int32 `bson:"card_bin"` CardBrand string `bson:"card_brand"` CardType string `bson:"card_type"` CardCategory string `bson:"card_category"` BankName string `bson:"bank_name"` BankCountryName string `bson:"bank_country_name"` BankCountryIsoCode string `bson:"bank_country_code_a2"` BankSite string `bson:"bank_site"` BankPhone string `bson:"bank_phone"` }
type BrowserCookieCustomer ¶
type BrowserCookieCustomer struct { CustomerId string `json:"customer_id"` VirtualCustomerId string `json:"virtual_customer_id"` Ip string `json:"ip"` IpCountry string `json:"ip_country"` SelectedCountry string `json:"selected_country"` UserAgent string `json:"user_agent"` AcceptLanguage string `json:"accept_language"` SessionCount int32 `json:"session_count"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` }
type CardPayAddress ¶
type CardPayBankCardAccount ¶
type CardPayCardAccount ¶
type CardPayCardAccount struct { BillingAddress *CardPayAddress `json:"billing_address,omitempty"` Card *CardPayBankCardAccount `json:"card"` Token string `json:"token,omitempty"` }
type CardPayCryptoCurrencyAccount ¶
type CardPayCryptoCurrencyAccount struct {
RollbackAddress string `json:"rollback_address"`
}
type CardPayCustomer ¶
type CardPayEWalletAccount ¶
type CardPayEWalletAccount struct {
Id string `json:"id"`
}
type CardPayItem ¶
type CardPayMerchantOrder ¶
type CardPayMerchantOrder struct { Id string `json:"id" validate:"required,hexadecimal"` Description string `json:"description,omitempty"` Items []*CardPayItem `json:"items,omitempty"` ShippingAddress *CardPayAddress `json:"shipping_address,omitempty"` }
type CardPayOrder ¶
type CardPayOrder struct { Request *CardPayRequest `json:"request"` MerchantOrder *CardPayMerchantOrder `json:"merchant_order"` Description string `json:"description"` PaymentMethod string `json:"payment_method"` PaymentData *CardPayPaymentData `json:"payment_data,omitempty"` RecurringData *CardPayRecurringData `json:"recurring_data,omitempty"` CardAccount *CardPayCardAccount `json:"card_account,omitempty"` Customer *CardPayCustomer `json:"customer"` EWalletAccount *CardPayEWalletAccount `json:"ewallet_account,omitempty"` CryptoCurrencyAccount *CardPayCryptoCurrencyAccount `json:"cryptocurrency_account,omitempty"` ReturnUrls *CardPayReturnUrls `json:"return_urls,omitempty"` }
type CardPayOrderRecurringResponse ¶
type CardPayOrderRecurringResponse struct {
RecurringData *CardPayOrderRecurringResponseRecurringData `json:"recurring_data"`
}
func (*CardPayOrderRecurringResponse) IsSuccessStatus ¶
func (h *CardPayOrderRecurringResponse) IsSuccessStatus() bool
type CardPayOrderRecurringResponseRecurringData ¶
type CardPayOrderRecurringResponseRecurringData struct { Id string `json:"id"` Filing *CardPayRecurringDataFiling `json:"filing"` Status string `json:"status"` Amount float64 `json:"amount"` Currency string `json:"currency"` Created string `json:"created"` Note string `json:"note"` Rrn string `json:"rrn"` Is3D bool `json:"is_3d"` }
type CardPayOrderResponse ¶
type CardPayOrderResponse struct {
RedirectUrl string `json:"redirect_url"`
}
type CardPayPaymentData ¶
type CardPayRecurringData ¶
type CardPayRecurringDataFiling ¶
type CardPayRecurringDataFiling struct {
Id string `json:"id"`
}
type CardPayRefundData ¶
type CardPayRefundRequest ¶
type CardPayRefundRequest struct { Request *CardPayRequest `json:"request"` MerchantOrder *CardPayMerchantOrder `json:"merchant_order"` PaymentData *CardPayRecurringDataFiling `json:"payment_data"` RefundData *CardPayRefundData `json:"refund_data"` }
type CardPayRefundResponse ¶
type CardPayRefundResponse struct { PaymentMethod string `json:"payment_method"` MerchantOrder *CardPayMerchantOrder `json:"merchant_order"` RefundData *CardPayRefundResponseRefundData `json:"refund_data"` PaymentData *CardPayRefundResponsePaymentData `json:"payment_data"` Customer *CardPayRefundResponseCustomer `json:"customer"` CardAccount interface{} `json:"card_account,omitempty"` EwalletAccount interface{} `json:"ewallet_account,omitempty"` }
func (*CardPayRefundResponse) IsSuccessStatus ¶
func (m *CardPayRefundResponse) IsSuccessStatus() bool
type CardPayRequest ¶
type CardPayReturnUrls ¶
type Centrifugo ¶
type Centrifugo struct {
// contains filtered or unexported fields
}
func (*Centrifugo) GetChannelToken ¶
func (c *Centrifugo) GetChannelToken(subject string, expire int64) string
type CentrifugoInterface ¶
type Commission ¶
type Commission Entity
type DashboardReportProcessor ¶
type DashboardReportProcessor struct { Db mongodb.SourceInterface Collection string Match bson.M GroupBy string DbQueryFn func(ctx context.Context, receiver interface{}) (interface{}, error) Cache database.CacheInterface CacheKey string CacheExpire time.Duration Errors map[string]*billingpb.ResponseErrorMessage }
func (*DashboardReportProcessor) ExecuteGrossRevenueAndVatReports ¶
func (m *DashboardReportProcessor) ExecuteGrossRevenueAndVatReports(ctx context.Context, receiver interface{}) (interface{}, error)
func (*DashboardReportProcessor) ExecuteReport ¶
func (m *DashboardReportProcessor) ExecuteReport(ctx context.Context, receiver interface{}) (interface{}, error)
func (*DashboardReportProcessor) ExecuteRevenueByCountryReport ¶
func (m *DashboardReportProcessor) ExecuteRevenueByCountryReport(ctx context.Context, receiver interface{}) (interface{}, error)
func (*DashboardReportProcessor) ExecuteRevenueDynamicReport ¶
func (m *DashboardReportProcessor) ExecuteRevenueDynamicReport(ctx context.Context, receiver interface{}) (interface{}, error)
func (*DashboardReportProcessor) ExecuteSalesTodayReport ¶
func (m *DashboardReportProcessor) ExecuteSalesTodayReport(ctx context.Context, receiver interface{}) (interface{}, error)
func (*DashboardReportProcessor) ExecuteSourcesReport ¶
func (m *DashboardReportProcessor) ExecuteSourcesReport(ctx context.Context, receiver interface{}) (interface{}, error)
func (*DashboardReportProcessor) ExecuteTotalTransactionsAndArpuReports ¶
func (m *DashboardReportProcessor) ExecuteTotalTransactionsAndArpuReports(ctx context.Context, receiver interface{}) (interface{}, error)
type DashboardReportProcessorInterface ¶
type DashboardReportProcessorInterface interface { ExecuteReport(interface{}) (interface{}, error) ExecuteGrossRevenueAndVatReports(interface{}) (interface{}, error) ExecuteTotalTransactionsAndArpuReports(interface{}) (interface{}, error) ExecuteRevenueDynamicReport(interface{}) (interface{}, error) ExecuteRevenueByCountryReport(interface{}) (interface{}, error) ExecuteSalesTodayReport(interface{}) (interface{}, error) ExecuteSourcesReport(interface{}) (interface{}, error) }
type DashboardRepository ¶
type DashboardRepository Repository
func (*DashboardRepository) GetBaseReport ¶
func (m *DashboardRepository) GetBaseReport( ctx context.Context, merchantId, period string, ) (*billingpb.DashboardBaseReports, error)
func (*DashboardRepository) GetBaseRevenueByCountryReport ¶
func (m *DashboardRepository) GetBaseRevenueByCountryReport( ctx context.Context, merchantId, period string, ) (*billingpb.DashboardRevenueByCountryReport, error)
func (*DashboardRepository) GetBaseSalesTodayReport ¶
func (m *DashboardRepository) GetBaseSalesTodayReport( ctx context.Context, merchantId, period string, ) (*billingpb.DashboardSalesTodayReport, error)
func (*DashboardRepository) GetBaseSourcesReport ¶
func (m *DashboardRepository) GetBaseSourcesReport( ctx context.Context, merchantId, period string, ) (*billingpb.DashboardSourcesReport, error)
func (*DashboardRepository) GetMainReport ¶
func (m *DashboardRepository) GetMainReport( ctx context.Context, merchantId, period string, ) (*billingpb.DashboardMainReport, error)
func (*DashboardRepository) GetRevenueDynamicsReport ¶
func (m *DashboardRepository) GetRevenueDynamicsReport( ctx context.Context, merchantId, period string, ) (*billingpb.DashboardRevenueDynamicReport, error)
func (*DashboardRepository) NewDashboardReportProcessor ¶
func (m *DashboardRepository) NewDashboardReportProcessor( merchantId, period, cacheKeyMask string, status interface{}, db mongodb.SourceInterface, cache database.CacheInterface, ctx context.Context, ) (*DashboardReportProcessor, error)
type DashboardRepositoryInterface ¶
type DashboardRepositoryInterface interface { GetMainReport(context.Context, string, string) (*billingpb.DashboardMainReport, error) GetRevenueDynamicsReport(context.Context, string, string) (*billingpb.DashboardRevenueDynamicReport, error) GetBaseReport(context.Context, string, string) (*billingpb.DashboardBaseReports, error) GetBaseRevenueByCountryReport(context.Context, string, string) (*billingpb.DashboardRevenueByCountryReport, error) GetBaseSalesTodayReport(context.Context, string, string) (*billingpb.DashboardSalesTodayReport, error) GetBaseSourcesReport(context.Context, string, string) (*billingpb.DashboardSourcesReport, error) }
type EmailConfirmToken ¶
type Gate ¶ added in v1.2.0
type Gate interface { CreatePayment(order *billingpb.Order, successUrl, failUrl string, requisites map[string]string) (string, error) ProcessPayment(order *billingpb.Order, message proto.Message, raw, signature string) error IsRecurringCallback(request proto.Message) bool GetRecurringId(request proto.Message) string CreateRefund(order *billingpb.Order, refund *billingpb.Refund) error ProcessRefund(order *billingpb.Order, refund *billingpb.Refund, message proto.Message, raw, signature string) error }
func NewCardPayMock ¶
func NewCardPayMock() Gate
func NewPaymentSystemMockError ¶
func NewPaymentSystemMockError() Gate
func NewPaymentSystemMockOk ¶
func NewPaymentSystemMockOk() Gate
type GrossRevenueAndVatReports ¶
type GrossRevenueAndVatReports struct { GrossRevenue *billingpb.DashboardAmountItemWithChart `bson:"gross_revenue"` Vat *billingpb.DashboardAmountItemWithChart `bson:"vat"` }
type Key ¶
type Key Entity
func (*Key) CancelById ¶
func (*Key) CountKeysByProductPlatform ¶
func (*Key) FindUnfinished ¶
func (*Key) FinishRedeemById ¶
type KeyProductRepository ¶
type KeyProductRepository Repository
func (*KeyProductRepository) GetById ¶
func (h *KeyProductRepository) GetById(ctx context.Context, id string) (*billingpb.KeyProduct, error)
func (*KeyProductRepository) Update ¶
func (h *KeyProductRepository) Update(ctx context.Context, keyProduct *billingpb.KeyProduct) error
type KeyRepositoryInterface ¶
type KeyRepositoryInterface interface { Insert(context.Context, *billingpb.Key) error GetById(context.Context, string) (*billingpb.Key, error) ReserveKey(context.Context, string, string, string, int32) (*billingpb.Key, error) CancelById(context.Context, string) (*billingpb.Key, error) FinishRedeemById(context.Context, string) (*billingpb.Key, error) CountKeysByProductPlatform(context.Context, string, string) (int64, error) FindUnfinished(context.Context) ([]*billingpb.Key, error) }
type MerchantTariffRatesInterface ¶
type MerchantTariffRatesInterface interface { GetPaymentTariffsBy(context.Context, *billingpb.GetMerchantTariffRatesRequest) ([]*billingpb.MerchantTariffRatesPayment, error) GetTariffsSettings(ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest) (*billingpb.MerchantTariffRatesSettings, error) GetBy(ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest) (*billingpb.GetMerchantTariffRatesResponseItems, error) GetCacheKeyForGetBy(*billingpb.GetMerchantTariffRatesRequest) (string, error) }
type MerchantsTariffRatesRepository ¶
type MerchantsTariffRatesRepository Repository
func (*MerchantsTariffRatesRepository) GetBy ¶
func (h *MerchantsTariffRatesRepository) GetBy( ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest, ) (*billingpb.GetMerchantTariffRatesResponseItems, error)
func (*MerchantsTariffRatesRepository) GetCacheKeyForGetBy ¶
func (h *MerchantsTariffRatesRepository) GetCacheKeyForGetBy(req *billingpb.GetMerchantTariffRatesRequest) (string, error)
func (*MerchantsTariffRatesRepository) GetPaymentTariffsBy ¶
func (h *MerchantsTariffRatesRepository) GetPaymentTariffsBy( ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest, ) ([]*billingpb.MerchantTariffRatesPayment, error)
func (*MerchantsTariffRatesRepository) GetTariffsSettings ¶
func (h *MerchantsTariffRatesRepository) GetTariffsSettings( ctx context.Context, in *billingpb.GetMerchantTariffRatesRequest, ) (*billingpb.MerchantTariffRatesSettings, error)
type OrderCreateRequestProcessor ¶
type OrderCreateRequestProcessor struct { *Service // contains filtered or unexported fields }
func (*OrderCreateRequestProcessor) UserCountryExists ¶
func (v *OrderCreateRequestProcessor) UserCountryExists() bool
type OrderView ¶
type OrderView Entity
func (*OrderView) CountTransactions ¶
func (*OrderView) GetOrderBy ¶
func (*OrderView) GetPaylinkStat ¶
func (*OrderView) GetPaylinkStatByCountry ¶
func (*OrderView) GetPaylinkStatByDate ¶
func (*OrderView) GetPaylinkStatByReferrer ¶
func (*OrderView) GetPaylinkStatByUtm ¶
func (*OrderView) GetPaylinkStatMatchQuery ¶
func (*OrderView) GetPublicByOrderId ¶ added in v1.2.0
func (*OrderView) GetRoyaltySummary ¶
func (*OrderView) GetTransactionsPrivate ¶
type OrderViewServiceInterface ¶
type OrderViewServiceInterface interface { CountTransactions(ctx context.Context, match bson.M) (n int64, err error) GetTransactionsPublic(ctx context.Context, match bson.M, limit, offset int64) (result []*billingpb.OrderViewPublic, err error) GetTransactionsPrivate(ctx context.Context, match bson.M, limit, offset int64) (result []*billingpb.OrderViewPrivate, err error) GetRoyaltySummary(ctx context.Context, merchantId, currency string, from, to time.Time) (items []*billingpb.RoyaltyReportProductSummaryItem, total *billingpb.RoyaltyReportProductSummaryItem, err error) GetOrderBy(ctx context.Context, id, uuid, merchantId string, receiver interface{}) (interface{}, error) GetPaylinkStat(ctx context.Context, paylinkId, merchantId string, from, to int64) (*billingpb.StatCommon, error) GetPaylinkStatByCountry(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error) GetPaylinkStatByReferrer(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error) GetPaylinkStatByDate(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error) GetPaylinkStatByUtm(ctx context.Context, paylinkId, merchantId string, from, to int64) (result *billingpb.GroupStatCommon, err error) GetPublicByOrderId(ctx context.Context, merchantId string) (*billingpb.OrderViewPublic, error) }
type Paylink ¶
type Paylink Entity
func (Paylink) CountByQuery ¶
func (Paylink) GetByIdAndMerchant ¶
func (Paylink) GetListByQuery ¶
func (Paylink) GetPaylinkVisits ¶
type PaylinkServiceInterface ¶
type PaylinkServiceInterface interface { CountByQuery(ctx context.Context, query bson.M) (n int64, err error) GetListByQuery(ctx context.Context, query bson.M, limit, offset int64) (result []*billingpb.Paylink, err error) GetById(ctx context.Context, id string) (pl *billingpb.Paylink, err error) GetByIdAndMerchant(ctx context.Context, id, merchantId string) (pl *billingpb.Paylink, err error) IncrVisits(ctx context.Context, id string) error GetUrl(ctx context.Context, id, merchantId, urlMask, utmSource, utmMedium, utmCampaign string) (string, error) Delete(ctx context.Context, id, merchantId string) error Insert(ctx context.Context, pl *billingpb.Paylink) error Update(ctx context.Context, pl *billingpb.Paylink) error UpdatePaylinkTotalStat(ctx context.Context, id, merchantId string) error GetPaylinkVisits(ctx context.Context, id string, from, to int64) (int64, error) }
type PaymentChannelCostMerchant ¶
type PaymentChannelCostMerchant Entity
func (PaymentChannelCostMerchant) Delete ¶
func (h PaymentChannelCostMerchant) Delete(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error
func (PaymentChannelCostMerchant) Get ¶
func (h PaymentChannelCostMerchant) Get( ctx context.Context, merchantId string, name string, payoutCurrency string, region string, country string, mccCode string, ) (c []*internalPkg.PaymentChannelCostMerchantSet, err error)
func (PaymentChannelCostMerchant) GetAllForMerchant ¶
func (h PaymentChannelCostMerchant) GetAllForMerchant( ctx context.Context, merchantId string, ) (*billingpb.PaymentChannelCostMerchantList, error)
func (PaymentChannelCostMerchant) GetById ¶
func (h PaymentChannelCostMerchant) GetById(ctx context.Context, id string) (*billingpb.PaymentChannelCostMerchant, error)
func (*PaymentChannelCostMerchant) Insert ¶
func (h *PaymentChannelCostMerchant) Insert(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error
func (PaymentChannelCostMerchant) MultipleInsert ¶
func (h PaymentChannelCostMerchant) MultipleInsert(ctx context.Context, obj []*billingpb.PaymentChannelCostMerchant) error
func (PaymentChannelCostMerchant) Update ¶
func (h PaymentChannelCostMerchant) Update(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error
type PaymentChannelCostMerchantInterface ¶
type PaymentChannelCostMerchantInterface interface { MultipleInsert(ctx context.Context, obj []*billingpb.PaymentChannelCostMerchant) error Update(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error GetById(ctx context.Context, id string) (*billingpb.PaymentChannelCostMerchant, error) Get(ctx context.Context, merchantId, name, payoutCurrency, region, country, mccCode string) ([]*internalPkg.PaymentChannelCostMerchantSet, error) Delete(ctx context.Context, obj *billingpb.PaymentChannelCostMerchant) error GetAllForMerchant(ctx context.Context, merchantId string) (*billingpb.PaymentChannelCostMerchantList, error) }
type PaymentChannelCostSystem ¶
type PaymentChannelCostSystem Entity
func (PaymentChannelCostSystem) Delete ¶
func (h PaymentChannelCostSystem) Delete(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error
func (PaymentChannelCostSystem) Get ¶
func (h PaymentChannelCostSystem) Get( ctx context.Context, name, region, country, mccCode, operatingCompanyId string, ) (*billingpb.PaymentChannelCostSystem, error)
func (PaymentChannelCostSystem) GetAll ¶
func (h PaymentChannelCostSystem) GetAll(ctx context.Context) (*billingpb.PaymentChannelCostSystemList, error)
func (PaymentChannelCostSystem) GetById ¶
func (h PaymentChannelCostSystem) GetById(ctx context.Context, id string) (*billingpb.PaymentChannelCostSystem, error)
func (*PaymentChannelCostSystem) Insert ¶
func (h *PaymentChannelCostSystem) Insert(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error
func (PaymentChannelCostSystem) MultipleInsert ¶
func (h PaymentChannelCostSystem) MultipleInsert(ctx context.Context, obj []*billingpb.PaymentChannelCostSystem) error
func (PaymentChannelCostSystem) Update ¶
func (h PaymentChannelCostSystem) Update(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error
type PaymentChannelCostSystemInterface ¶
type PaymentChannelCostSystemInterface interface { MultipleInsert(ctx context.Context, obj []*billingpb.PaymentChannelCostSystem) error Update(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error GetById(ctx context.Context, id string) (*billingpb.PaymentChannelCostSystem, error) Get(ctx context.Context, name, region, country, mccCode, operatingCompanyId string) (*billingpb.PaymentChannelCostSystem, error) Delete(ctx context.Context, obj *billingpb.PaymentChannelCostSystem) error GetAll(ctx context.Context) (*billingpb.PaymentChannelCostSystemList, error) }
type PaymentCreateProcessor ¶
type PaymentCreateProcessor struct {
// contains filtered or unexported fields
}
func (*PaymentCreateProcessor) GetMerchantId ¶
func (v *PaymentCreateProcessor) GetMerchantId() string
type PaymentFormProcessor ¶
type PaymentFormProcessor struct {
// contains filtered or unexported fields
}
type PaymentMethod ¶
type PaymentMethod Entity
func (*PaymentMethod) GetAll ¶
func (h *PaymentMethod) GetAll(ctx context.Context) (map[string]*billingpb.PaymentMethod, error)
func (*PaymentMethod) GetByGroupAndCurrency ¶
func (h *PaymentMethod) GetByGroupAndCurrency( ctx context.Context, isProduction bool, group string, currency string, ) (*billingpb.PaymentMethod, error)
func (*PaymentMethod) GetById ¶
func (h *PaymentMethod) GetById(ctx context.Context, id string) (*billingpb.PaymentMethod, error)
func (*PaymentMethod) GetPaymentSettings ¶
func (h *PaymentMethod) GetPaymentSettings( paymentMethod *billingpb.PaymentMethod, currency string, mccCode string, operatingCompanyId string, paymentMethodBrand string, isProduction bool, ) (*billingpb.PaymentMethodParams, error)
func (*PaymentMethod) Insert ¶
func (h *PaymentMethod) Insert(ctx context.Context, pm *billingpb.PaymentMethod) error
func (*PaymentMethod) ListByOrder ¶ added in v1.2.0
func (h *PaymentMethod) ListByOrder( ctx context.Context, order *billingpb.Order, ) ([]*billingpb.PaymentMethod, error)
func (*PaymentMethod) MultipleInsert ¶
func (h *PaymentMethod) MultipleInsert(ctx context.Context, pm []*billingpb.PaymentMethod) error
func (*PaymentMethod) Update ¶
func (h *PaymentMethod) Update(ctx context.Context, pm *billingpb.PaymentMethod) error
type PaymentMethodInterface ¶
type PaymentMethodInterface interface { GetAll(ctx context.Context) (map[string]*billingpb.PaymentMethod, error) GetByGroupAndCurrency(ctx context.Context, isProduction bool, group string, currency string) (*billingpb.PaymentMethod, error) GetById(context.Context, string) (*billingpb.PaymentMethod, error) MultipleInsert(context.Context, []*billingpb.PaymentMethod) error Insert(context.Context, *billingpb.PaymentMethod) error Update(context.Context, *billingpb.PaymentMethod) error GetPaymentSettings(paymentMethod *billingpb.PaymentMethod, currency, mccCode, operatingCompanyId, paymentMethodBrand string, isProduction bool) (*billingpb.PaymentMethodParams, error) ListByOrder(ctx context.Context, order *billingpb.Order) ([]*billingpb.PaymentMethod, error) }
type PaymentMethods ¶
type PaymentMethods struct {
PaymentMethods []*billingpb.PaymentMethod `json:"payment_methods"`
}
type PaymentMinLimitSystem ¶
type PaymentMinLimitSystem Entity
func (PaymentMinLimitSystem) GetAll ¶
func (p PaymentMinLimitSystem) GetAll(ctx context.Context) (result []*billingpb.PaymentMinLimitSystem, err error)
func (PaymentMinLimitSystem) GetByCurrency ¶
func (p PaymentMinLimitSystem) GetByCurrency( ctx context.Context, currency string, ) (pmls *billingpb.PaymentMinLimitSystem, err error)
func (PaymentMinLimitSystem) MultipleInsert ¶
func (p PaymentMinLimitSystem) MultipleInsert( ctx context.Context, pmlsArray []*billingpb.PaymentMinLimitSystem, ) (err error)
func (PaymentMinLimitSystem) Upsert ¶
func (p PaymentMinLimitSystem) Upsert(ctx context.Context, pmls *billingpb.PaymentMinLimitSystem) (err error)
type PaymentMinLimitSystemInterface ¶
type PaymentMinLimitSystemInterface interface { GetByCurrency(ctx context.Context, currency string) (pmls *billingpb.PaymentMinLimitSystem, err error) GetAll(ctx context.Context) (result []*billingpb.PaymentMinLimitSystem, err error) Upsert(ctx context.Context, pmls *billingpb.PaymentMinLimitSystem) (err error) MultipleInsert(ctx context.Context, pmlsArray []*billingpb.PaymentMinLimitSystem) (err error) }
type PaymentSystemMockError ¶
type PaymentSystemMockError struct{}
func (*PaymentSystemMockError) CreatePayment ¶
func (*PaymentSystemMockError) CreateRefund ¶
func (*PaymentSystemMockError) GetRecurringId ¶
func (m *PaymentSystemMockError) GetRecurringId(request proto.Message) string
func (*PaymentSystemMockError) IsRecurringCallback ¶
func (m *PaymentSystemMockError) IsRecurringCallback(request proto.Message) bool
func (*PaymentSystemMockError) ProcessPayment ¶
type PaymentSystemMockOk ¶
type PaymentSystemMockOk struct{}
func (*PaymentSystemMockOk) CreatePayment ¶
func (*PaymentSystemMockOk) CreateRefund ¶
func (*PaymentSystemMockOk) GetRecurringId ¶
func (m *PaymentSystemMockOk) GetRecurringId(request proto.Message) string
func (*PaymentSystemMockOk) IsRecurringCallback ¶
func (m *PaymentSystemMockOk) IsRecurringCallback(request proto.Message) bool
func (*PaymentSystemMockOk) ProcessPayment ¶
type PaymentSystemService ¶
type PaymentSystemService Entity
func (PaymentSystemService) GetById ¶
func (h PaymentSystemService) GetById(ctx context.Context, id string) (*billingpb.PaymentSystem, error)
func (*PaymentSystemService) Insert ¶
func (h *PaymentSystemService) Insert(ctx context.Context, ps *billingpb.PaymentSystem) error
func (PaymentSystemService) MultipleInsert ¶
func (h PaymentSystemService) MultipleInsert(ctx context.Context, ps []*billingpb.PaymentSystem) error
func (*PaymentSystemService) Update ¶
func (h *PaymentSystemService) Update(ctx context.Context, ps *billingpb.PaymentSystem) error
type PayoutDocument ¶
type PayoutDocument Entity
func (*PayoutDocument) CountByQuery ¶
func (*PayoutDocument) FindByQuery ¶
func (h *PayoutDocument) FindByQuery( ctx context.Context, query bson.M, sorts []string, limit, offset int64, ) ([]*billingpb.PayoutDocument, error)
func (*PayoutDocument) GetBalanceAmount ¶
func (*PayoutDocument) GetById ¶
func (h *PayoutDocument) GetById(ctx context.Context, id string) (pd *billingpb.PayoutDocument, err error)
func (*PayoutDocument) GetByIdAndMerchant ¶
func (h *PayoutDocument) GetByIdAndMerchant( ctx context.Context, id, merchantId string, ) (pd *billingpb.PayoutDocument, err error)
func (*PayoutDocument) GetLast ¶
func (h *PayoutDocument) GetLast( ctx context.Context, merchantId, currency string, ) (pd *billingpb.PayoutDocument, err error)
func (*PayoutDocument) Insert ¶
func (h *PayoutDocument) Insert(ctx context.Context, pd *billingpb.PayoutDocument, ip, source string) (err error)
func (*PayoutDocument) Update ¶
func (h *PayoutDocument) Update(ctx context.Context, pd *billingpb.PayoutDocument, ip, source string) error
type PayoutDocumentServiceInterface ¶
type PayoutDocumentServiceInterface interface { Insert(ctx context.Context, document *billingpb.PayoutDocument, ip, source string) error Update(ctx context.Context, document *billingpb.PayoutDocument, ip, source string) error GetById(ctx context.Context, id string) (*billingpb.PayoutDocument, error) GetByIdAndMerchant(ctx context.Context, id, merchantId string) (*billingpb.PayoutDocument, error) CountByQuery(ctx context.Context, query bson.M) (int64, error) FindByQuery(ctx context.Context, query bson.M, sorts []string, limit, offset int64) ([]*billingpb.PayoutDocument, error) GetBalanceAmount(ctx context.Context, merchantId, currency string) (float64, error) GetLast(ctx context.Context, merchantId, currency string) (*billingpb.PayoutDocument, error) }
type Product ¶
type Product Entity
func (*Product) CountByProjectSku ¶
type ProductServiceInterface ¶
type ProductServiceInterface interface { Upsert(ctx context.Context, product *billingpb.Product) error GetById(context.Context, string) (*billingpb.Product, error) CountByProjectSku(context.Context, string, string) (int64, error) List(context.Context, string, string, string, string, int64, int64, int32) (int64, []*billingpb.Product) }
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
type RoyaltyReport ¶
type RoyaltyReport Entity
func (*RoyaltyReport) GetBalanceAmount ¶
func (*RoyaltyReport) GetById ¶
func (r *RoyaltyReport) GetById(ctx context.Context, id string) (rr *billingpb.RoyaltyReport, err error)
func (*RoyaltyReport) GetByPayoutId ¶
func (r *RoyaltyReport) GetByPayoutId(ctx context.Context, payoutId string) (result []*billingpb.RoyaltyReport, err error)
func (*RoyaltyReport) GetNonPayoutReports ¶
func (r *RoyaltyReport) GetNonPayoutReports( ctx context.Context, merchantId, currency string, ) (result []*billingpb.RoyaltyReport, err error)
func (*RoyaltyReport) GetReportExists ¶
func (r *RoyaltyReport) GetReportExists( ctx context.Context, merchantId, currency string, from, to time.Time, ) (report *billingpb.RoyaltyReport)
func (*RoyaltyReport) Insert ¶
func (r *RoyaltyReport) Insert(ctx context.Context, rr *billingpb.RoyaltyReport, ip, source string) (err error)
func (*RoyaltyReport) SetPayoutDocumentId ¶
func (*RoyaltyReport) UnsetPayoutDocumentId ¶
func (*RoyaltyReport) Update ¶
func (r *RoyaltyReport) Update(ctx context.Context, rr *billingpb.RoyaltyReport, ip, source string) error
type RoyaltyReportMerchant ¶
type RoyaltyReportServiceInterface ¶
type RoyaltyReportServiceInterface interface { Insert(ctx context.Context, document *billingpb.RoyaltyReport, ip, source string) error Update(ctx context.Context, document *billingpb.RoyaltyReport, ip, source string) error GetById(ctx context.Context, id string) (*billingpb.RoyaltyReport, error) GetNonPayoutReports(ctx context.Context, merchantId, currency string) ([]*billingpb.RoyaltyReport, error) GetByPayoutId(ctx context.Context, payoutId string) ([]*billingpb.RoyaltyReport, error) GetBalanceAmount(ctx context.Context, merchantId, currency string) (float64, error) GetReportExists(ctx context.Context, merchantId, currency string, from, to time.Time) (report *billingpb.RoyaltyReport) SetPayoutDocumentId(ctx context.Context, reportIds []string, payoutDocumentId, ip, source string) (err error) UnsetPayoutDocumentId(ctx context.Context, reportIds []string, ip, source string) (err error) SetPaid(ctx context.Context, reportIds []string, payoutDocumentId, ip, source string) (err error) UnsetPaid(ctx context.Context, reportIds []string, ip, source string) (err error) }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewBillingService ¶
func NewBillingService( db mongodb.SourceInterface, cfg *config.Config, geo proto.GeoIpService, rep recurringpb.RepositoryService, tax taxpb.TaxService, broker rabbitmq.BrokerInterface, redis redis.Cmdable, cache database.CacheInterface, curService currenciespb.CurrencyRatesService, documentSigner document_signerpb.DocumentSignerService, reporterService reporterpb.ReporterService, formatter paysuper_i18n.Formatter, postmarkBroker rabbitmq.BrokerInterface, casbinService casbinpb.CasbinService, ) *Service
func (*Service) AcceptInvite ¶
func (s *Service) AcceptInvite( ctx context.Context, req *billingpb.AcceptInviteRequest, res *billingpb.AcceptInviteResponse, ) error
func (*Service) AddOperatingCompany ¶
func (s *Service) AddOperatingCompany( ctx context.Context, req *billingpb.OperatingCompany, res *billingpb.EmptyResponseWithStatus, ) (err error)
func (*Service) AutoAcceptRoyaltyReports ¶
func (s *Service) AutoAcceptRoyaltyReports( ctx context.Context, _ *billingpb.EmptyRequest, _ *billingpb.EmptyResponse, ) error
func (*Service) AutoCreatePayoutDocuments ¶
func (s *Service) AutoCreatePayoutDocuments( ctx context.Context, req *billingpb.EmptyRequest, rsp *billingpb.EmptyResponse, ) error
func (*Service) CalcAnnualTurnovers ¶
func (s *Service) CalcAnnualTurnovers(ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.EmptyResponse) error
func (*Service) CancelRedeemKeyForOrder ¶
func (s *Service) CancelRedeemKeyForOrder( ctx context.Context, req *billingpb.KeyForOrderRequest, res *billingpb.EmptyResponseWithStatus, ) error
func (*Service) ChangeCodeInOrder ¶
func (s *Service) ChangeCodeInOrder(ctx context.Context, req *billingpb.ChangeCodeInOrderRequest, res *billingpb.ChangeCodeInOrderResponse) error
func (*Service) ChangeMerchant ¶
func (s *Service) ChangeMerchant( ctx context.Context, req *billingpb.OnboardingRequest, rsp *billingpb.ChangeMerchantResponse, ) error
func (*Service) ChangeMerchantData ¶
func (s *Service) ChangeMerchantData( ctx context.Context, req *billingpb.ChangeMerchantDataRequest, rsp *billingpb.ChangeMerchantDataResponse, ) error
func (*Service) ChangeMerchantManualPayouts ¶
func (s *Service) ChangeMerchantManualPayouts( ctx context.Context, req *billingpb.ChangeMerchantManualPayoutsRequest, rsp *billingpb.ChangeMerchantManualPayoutsResponse, ) error
func (*Service) ChangeMerchantPaymentMethod ¶
func (s *Service) ChangeMerchantPaymentMethod( ctx context.Context, req *billingpb.MerchantPaymentMethodRequest, rsp *billingpb.MerchantPaymentMethodResponse, ) (err error)
func (*Service) ChangeMerchantStatus ¶
func (s *Service) ChangeMerchantStatus( ctx context.Context, req *billingpb.MerchantChangeStatusRequest, rsp *billingpb.ChangeMerchantStatusResponse, ) error
func (*Service) ChangeProject ¶
func (*Service) ChangeRoleForAdminUser ¶
func (s *Service) ChangeRoleForAdminUser(ctx context.Context, req *billingpb.ChangeRoleForAdminUserRequest, res *billingpb.EmptyResponseWithStatus) error
func (*Service) ChangeRoleForMerchantUser ¶
func (s *Service) ChangeRoleForMerchantUser(ctx context.Context, req *billingpb.ChangeRoleForMerchantUserRequest, res *billingpb.EmptyResponseWithStatus) error
func (*Service) ChangeRoyaltyReport ¶
func (s *Service) ChangeRoyaltyReport( ctx context.Context, req *billingpb.ChangeRoyaltyReportRequest, rsp *billingpb.ResponseError, ) error
func (*Service) CheckInviteToken ¶
func (s *Service) CheckInviteToken( ctx context.Context, req *billingpb.CheckInviteTokenRequest, res *billingpb.CheckInviteTokenResponse, ) error
func (*Service) CheckProjectRequestSignature ¶
func (s *Service) CheckProjectRequestSignature( ctx context.Context, req *billingpb.CheckProjectRequestSignatureRequest, rsp *billingpb.CheckProjectRequestSignatureResponse, ) error
func (*Service) CheckSkuAndKeyProject ¶
func (s *Service) CheckSkuAndKeyProject(ctx context.Context, req *billingpb.CheckSkuAndKeyProjectRequest, rsp *billingpb.EmptyResponseWithStatus) error
func (*Service) ConfirmUserEmail ¶
func (s *Service) ConfirmUserEmail( ctx context.Context, req *billingpb.ConfirmUserEmailRequest, rsp *billingpb.ConfirmUserEmailResponse, ) error
func (*Service) CreateAccountingEntry ¶
func (s *Service) CreateAccountingEntry( ctx context.Context, req *billingpb.CreateAccountingEntryRequest, rsp *billingpb.CreateAccountingEntryResponse, ) error
func (*Service) CreateNotification ¶
func (s *Service) CreateNotification( ctx context.Context, req *billingpb.NotificationRequest, rsp *billingpb.CreateNotificationResponse, ) error
func (*Service) CreateOrUpdateKeyProduct ¶
func (s *Service) CreateOrUpdateKeyProduct( ctx context.Context, req *billingpb.CreateOrUpdateKeyProductRequest, res *billingpb.KeyProductResponse, ) error
func (*Service) CreateOrUpdatePaylink ¶
func (s *Service) CreateOrUpdatePaylink( ctx context.Context, req *billingpb.CreatePaylinkRequest, res *billingpb.GetPaylinkResponse, ) (err error)
CreateOrUpdatePaylink create or modify payment link
func (*Service) CreateOrUpdatePaymentMethod ¶
func (s *Service) CreateOrUpdatePaymentMethod( ctx context.Context, req *billingpb.PaymentMethod, rsp *billingpb.ChangePaymentMethodResponse, ) error
func (*Service) CreateOrUpdatePaymentMethodProductionSettings ¶
func (s *Service) CreateOrUpdatePaymentMethodProductionSettings( ctx context.Context, req *billingpb.ChangePaymentMethodParamsRequest, rsp *billingpb.ChangePaymentMethodParamsResponse, ) error
func (*Service) CreateOrUpdatePaymentMethodTestSettings ¶
func (s *Service) CreateOrUpdatePaymentMethodTestSettings( ctx context.Context, req *billingpb.ChangePaymentMethodParamsRequest, rsp *billingpb.ChangePaymentMethodParamsResponse, ) error
func (*Service) CreateOrUpdateProduct ¶
func (*Service) CreateOrUpdateUserProfile ¶
func (s *Service) CreateOrUpdateUserProfile( ctx context.Context, req *billingpb.UserProfile, rsp *billingpb.GetUserProfileResponse, ) error
func (*Service) CreatePageReview ¶
func (s *Service) CreatePageReview( ctx context.Context, req *billingpb.CreatePageReviewRequest, rsp *billingpb.CheckProjectRequestSignatureResponse, ) error
func (*Service) CreatePayoutDocument ¶
func (s *Service) CreatePayoutDocument( ctx context.Context, req *billingpb.CreatePayoutDocumentRequest, res *billingpb.CreatePayoutDocumentResponse, ) error
func (*Service) CreateRefund ¶
func (s *Service) CreateRefund( ctx context.Context, req *billingpb.CreateRefundRequest, rsp *billingpb.CreateRefundResponse, ) error
func (*Service) CreateRoyaltyReport ¶
func (s *Service) CreateRoyaltyReport( ctx context.Context, req *billingpb.CreateRoyaltyReportRequest, rsp *billingpb.CreateRoyaltyReportRequest, ) error
func (*Service) CreateToken ¶
func (s *Service) CreateToken( ctx context.Context, req *billingpb.TokenRequest, rsp *billingpb.TokenResponse, ) error
func (*Service) DeleteAdminUser ¶
func (s *Service) DeleteAdminUser( ctx context.Context, req *billingpb.AdminRoleRequest, res *billingpb.EmptyResponseWithStatus, ) error
func (*Service) DeleteKeyProduct ¶
func (s *Service) DeleteKeyProduct( ctx context.Context, req *billingpb.RequestKeyProductMerchant, res *billingpb.EmptyResponseWithStatus, ) error
func (*Service) DeleteMerchantUser ¶
func (s *Service) DeleteMerchantUser( ctx context.Context, req *billingpb.MerchantRoleRequest, res *billingpb.EmptyResponseWithStatus, ) error
func (*Service) DeleteMoneyBackCostMerchant ¶
func (s *Service) DeleteMoneyBackCostMerchant( ctx context.Context, req *billingpb.PaymentCostDeleteRequest, res *billingpb.ResponseError, ) error
func (*Service) DeleteMoneyBackCostSystem ¶
func (s *Service) DeleteMoneyBackCostSystem( ctx context.Context, req *billingpb.PaymentCostDeleteRequest, res *billingpb.ResponseError, ) error
func (*Service) DeletePaylink ¶
func (s *Service) DeletePaylink( ctx context.Context, req *billingpb.PaylinkRequest, res *billingpb.EmptyResponseWithStatus, ) error
DeletePaylink deletes payment link
func (*Service) DeletePaymentChannelCostMerchant ¶
func (s *Service) DeletePaymentChannelCostMerchant( ctx context.Context, req *billingpb.PaymentCostDeleteRequest, res *billingpb.ResponseError, ) error
func (*Service) DeletePaymentChannelCostSystem ¶
func (s *Service) DeletePaymentChannelCostSystem( ctx context.Context, req *billingpb.PaymentCostDeleteRequest, res *billingpb.ResponseError, ) error
func (*Service) DeletePaymentMethodProductionSettings ¶
func (s *Service) DeletePaymentMethodProductionSettings( ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, rsp *billingpb.ChangePaymentMethodParamsResponse, ) error
func (*Service) DeletePaymentMethodTestSettings ¶
func (s *Service) DeletePaymentMethodTestSettings( ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, rsp *billingpb.ChangePaymentMethodParamsResponse, ) error
func (*Service) DeleteProduct ¶
func (s *Service) DeleteProduct(ctx context.Context, req *billingpb.RequestProduct, res *billingpb.EmptyResponse) error
func (*Service) DeleteProject ¶
func (s *Service) DeleteProject( ctx context.Context, req *billingpb.GetProjectRequest, rsp *billingpb.ChangeProjectResponse, ) error
func (*Service) DeleteSavedCard ¶
func (s *Service) DeleteSavedCard( ctx context.Context, req *billingpb.DeleteSavedCardRequest, rsp *billingpb.EmptyResponseWithStatus, ) error
func (*Service) FindAllOrders ¶
func (s *Service) FindAllOrders( ctx context.Context, req *billingpb.ListOrdersRequest, rsp *billingpb.ListOrdersResponse, ) error
func (*Service) FindAllOrdersPrivate ¶
func (s *Service) FindAllOrdersPrivate( ctx context.Context, req *billingpb.ListOrdersRequest, rsp *billingpb.ListOrdersPrivateResponse, ) error
func (*Service) FindAllOrdersPublic ¶
func (s *Service) FindAllOrdersPublic( ctx context.Context, req *billingpb.ListOrdersRequest, rsp *billingpb.ListOrdersPublicResponse, ) error
func (*Service) FindByZipCode ¶
func (s *Service) FindByZipCode( ctx context.Context, req *billingpb.FindByZipCodeRequest, rsp *billingpb.FindByZipCodeResponse, ) error
func (*Service) FinishRedeemKeyForOrder ¶
func (s *Service) FinishRedeemKeyForOrder( ctx context.Context, req *billingpb.KeyForOrderRequest, res *billingpb.GetKeyForOrderRequestResponse, ) error
func (*Service) FormatAmount ¶
func (*Service) GetAdminUserRole ¶
func (s *Service) GetAdminUserRole( ctx context.Context, req *billingpb.AdminRoleRequest, res *billingpb.UserRoleResponse, ) error
func (*Service) GetAdminUsers ¶
func (s *Service) GetAdminUsers(ctx context.Context, _ *billingpb.EmptyRequest, res *billingpb.GetAdminUsersResponse) error
func (*Service) GetAllMoneyBackCostMerchant ¶
func (s *Service) GetAllMoneyBackCostMerchant( ctx context.Context, req *billingpb.MoneyBackCostMerchantListRequest, res *billingpb.MoneyBackCostMerchantListResponse, ) error
func (*Service) GetAllMoneyBackCostSystem ¶
func (s *Service) GetAllMoneyBackCostSystem( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.MoneyBackCostSystemListResponse, ) error
func (*Service) GetAllPaymentChannelCostMerchant ¶
func (s *Service) GetAllPaymentChannelCostMerchant( ctx context.Context, req *billingpb.PaymentChannelCostMerchantListRequest, res *billingpb.PaymentChannelCostMerchantListResponse, ) error
func (*Service) GetAllPaymentChannelCostSystem ¶
func (s *Service) GetAllPaymentChannelCostSystem( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.PaymentChannelCostSystemListResponse, ) error
func (*Service) GetAmountForVirtualCurrency ¶
func (s *Service) GetAmountForVirtualCurrency(virtualAmount float64, group *billingpb.PriceGroup, prices []*billingpb.ProductPrice) (float64, error)
func (*Service) GetAvailableKeysCount ¶
func (s *Service) GetAvailableKeysCount( ctx context.Context, req *billingpb.GetPlatformKeyCountRequest, res *billingpb.GetPlatformKeyCountResponse, ) error
func (*Service) GetCommonUserProfile ¶
func (s *Service) GetCommonUserProfile( ctx context.Context, req *billingpb.CommonUserProfileRequest, rsp *billingpb.CommonUserProfileResponse, ) error
func (*Service) GetCountriesList ¶
func (s *Service) GetCountriesList( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.CountriesList, ) error
func (*Service) GetCountriesListForOrder ¶
func (s *Service) GetCountriesListForOrder( ctx context.Context, req *billingpb.GetCountriesListForOrderRequest, res *billingpb.GetCountriesListForOrderResponse, ) error
func (*Service) GetCountry ¶
func (*Service) GetDashboardBaseReport ¶
func (s *Service) GetDashboardBaseReport( ctx context.Context, req *billingpb.GetDashboardBaseReportRequest, rsp *billingpb.GetDashboardBaseReportResponse, ) error
func (*Service) GetDashboardMainReport ¶
func (s *Service) GetDashboardMainReport( ctx context.Context, req *billingpb.GetDashboardMainRequest, rsp *billingpb.GetDashboardMainResponse, ) error
func (*Service) GetDashboardRevenueDynamicsReport ¶
func (s *Service) GetDashboardRevenueDynamicsReport( ctx context.Context, req *billingpb.GetDashboardMainRequest, rsp *billingpb.GetDashboardRevenueDynamicsReportResponse, ) error
func (*Service) GetKeyByID ¶
func (s *Service) GetKeyByID( ctx context.Context, req *billingpb.KeyForOrderRequest, res *billingpb.GetKeyForOrderRequestResponse, ) error
func (*Service) GetKeyProduct ¶
func (s *Service) GetKeyProduct( ctx context.Context, req *billingpb.RequestKeyProductMerchant, res *billingpb.KeyProductResponse, ) error
func (*Service) GetKeyProductInfo ¶
func (s *Service) GetKeyProductInfo( ctx context.Context, req *billingpb.GetKeyProductInfoRequest, res *billingpb.GetKeyProductInfoResponse, ) error
func (*Service) GetKeyProducts ¶
func (s *Service) GetKeyProducts( ctx context.Context, req *billingpb.ListKeyProductsRequest, res *billingpb.ListKeyProductsResponse, ) error
func (*Service) GetKeyProductsForOrder ¶
func (s *Service) GetKeyProductsForOrder( ctx context.Context, req *billingpb.GetKeyProductsForOrderRequest, res *billingpb.ListKeyProductsResponse, ) error
func (*Service) GetMerchantBalance ¶
func (s *Service) GetMerchantBalance( ctx context.Context, req *billingpb.GetMerchantBalanceRequest, res *billingpb.GetMerchantBalanceResponse, ) error
func (*Service) GetMerchantBy ¶
func (s *Service) GetMerchantBy( ctx context.Context, req *billingpb.GetMerchantByRequest, rsp *billingpb.GetMerchantResponse, ) error
func (*Service) GetMerchantOnboardingCompleteData ¶
func (s *Service) GetMerchantOnboardingCompleteData( ctx context.Context, req *billingpb.SetMerchantS3AgreementRequest, rsp *billingpb.GetMerchantOnboardingCompleteDataResponse, ) error
func (*Service) GetMerchantPaymentMethod ¶
func (s *Service) GetMerchantPaymentMethod( ctx context.Context, req *billingpb.GetMerchantPaymentMethodRequest, rsp *billingpb.GetMerchantPaymentMethodResponse, ) error
func (*Service) GetMerchantTariffRates ¶
func (s *Service) GetMerchantTariffRates( ctx context.Context, req *billingpb.GetMerchantTariffRatesRequest, rsp *billingpb.GetMerchantTariffRatesResponse, ) error
func (*Service) GetMerchantUserRole ¶
func (s *Service) GetMerchantUserRole( ctx context.Context, req *billingpb.MerchantRoleRequest, res *billingpb.UserRoleResponse, ) error
func (*Service) GetMerchantUsers ¶
func (s *Service) GetMerchantUsers(ctx context.Context, req *billingpb.GetMerchantUsersRequest, res *billingpb.GetMerchantUsersResponse) error
func (*Service) GetMerchantsForUser ¶
func (s *Service) GetMerchantsForUser(ctx context.Context, req *billingpb.GetMerchantsForUserRequest, res *billingpb.GetMerchantsForUserResponse) error
func (*Service) GetMoneyBackCostMerchant ¶
func (s *Service) GetMoneyBackCostMerchant( ctx context.Context, req *billingpb.MoneyBackCostMerchantRequest, res *billingpb.MoneyBackCostMerchantResponse, ) error
func (*Service) GetMoneyBackCostSystem ¶
func (s *Service) GetMoneyBackCostSystem( ctx context.Context, req *billingpb.MoneyBackCostSystemRequest, res *billingpb.MoneyBackCostSystemResponse, ) error
func (*Service) GetNotification ¶
func (s *Service) GetNotification( ctx context.Context, req *billingpb.GetNotificationRequest, rsp *billingpb.Notification, ) error
func (*Service) GetOperatingCompaniesList ¶
func (s *Service) GetOperatingCompaniesList( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.GetOperatingCompaniesListResponse, ) (err error)
func (*Service) GetOperatingCompany ¶
func (s *Service) GetOperatingCompany( ctx context.Context, req *billingpb.GetOperatingCompanyRequest, res *billingpb.GetOperatingCompanyResponse, ) (err error)
func (*Service) GetOrderKeyProducts ¶
func (*Service) GetOrderKeyProductsAmount ¶
func (s *Service) GetOrderKeyProductsAmount(products []*billingpb.KeyProduct, group *billingpb.PriceGroup, platformId string) (float64, error)
func (*Service) GetOrderKeyProductsItems ¶
func (s *Service) GetOrderKeyProductsItems(products []*billingpb.KeyProduct, language string, group *billingpb.PriceGroup, platformId string) ([]*billingpb.OrderItem, error)
func (*Service) GetOrderPrivate ¶
func (s *Service) GetOrderPrivate( ctx context.Context, req *billingpb.GetOrderRequest, rsp *billingpb.GetOrderPrivateResponse, ) error
func (*Service) GetOrderProducts ¶
func (*Service) GetOrderProductsAmount ¶
func (*Service) GetOrderProductsItems ¶
func (*Service) GetOrderPublic ¶
func (s *Service) GetOrderPublic( ctx context.Context, req *billingpb.GetOrderRequest, rsp *billingpb.GetOrderPublicResponse, ) error
func (*Service) GetPaylink ¶
func (s *Service) GetPaylink( ctx context.Context, req *billingpb.PaylinkRequest, res *billingpb.GetPaylinkResponse, ) (err error)
GetPaylink returns one payment link
func (*Service) GetPaylinkStatByCountry ¶
func (s *Service) GetPaylinkStatByCountry( ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, res *billingpb.GetPaylinkStatCommonGroupResponse, ) (err error)
GetPaylinkStatByCountry returns stat groped by country for requested paylink and period
func (*Service) GetPaylinkStatByDate ¶
func (s *Service) GetPaylinkStatByDate( ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, res *billingpb.GetPaylinkStatCommonGroupResponse, ) (err error)
GetPaylinkStatByDate returns stat groped by date for requested paylink and period
func (*Service) GetPaylinkStatByReferrer ¶
func (s *Service) GetPaylinkStatByReferrer( ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, res *billingpb.GetPaylinkStatCommonGroupResponse, ) (err error)
GetPaylinkStatByReferrer returns stat grouped by referer hosts for requested paylink and period
func (*Service) GetPaylinkStatByUtm ¶
func (s *Service) GetPaylinkStatByUtm( ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, res *billingpb.GetPaylinkStatCommonGroupResponse, ) (err error)
GetPaylinkStatByUtm returns stat groped by utm labels for requested paylink and period
func (*Service) GetPaylinkStatTotal ¶
func (s *Service) GetPaylinkStatTotal( ctx context.Context, req *billingpb.GetPaylinkStatCommonRequest, res *billingpb.GetPaylinkStatCommonResponse, ) (err error)
GetPaylinkStatTotal returns total stat for requested paylink and period
func (*Service) GetPaylinkTransactions ¶ added in v1.1.0
func (s *Service) GetPaylinkTransactions( ctx context.Context, req *billingpb.GetPaylinkTransactionsRequest, res *billingpb.TransactionsResponse, ) error
func (*Service) GetPaylinkURL ¶
func (s *Service) GetPaylinkURL( ctx context.Context, req *billingpb.GetPaylinkURLRequest, res *billingpb.GetPaylinkUrlResponse, ) (err error)
GetPaylinkURL returns public url for Paylink
func (*Service) GetPaylinks ¶
func (s *Service) GetPaylinks( ctx context.Context, req *billingpb.GetPaylinksRequest, res *billingpb.GetPaylinksResponse, ) error
GetPaylinks returns list of all payment links
func (*Service) GetPaymentChannelCostMerchant ¶
func (s *Service) GetPaymentChannelCostMerchant( ctx context.Context, req *billingpb.PaymentChannelCostMerchantRequest, res *billingpb.PaymentChannelCostMerchantResponse, ) error
func (*Service) GetPaymentChannelCostSystem ¶
func (s *Service) GetPaymentChannelCostSystem( ctx context.Context, req *billingpb.PaymentChannelCostSystemRequest, res *billingpb.PaymentChannelCostSystemResponse, ) error
func (*Service) GetPaymentMethodProductionSettings ¶
func (s *Service) GetPaymentMethodProductionSettings( ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, rsp *billingpb.GetPaymentMethodSettingsResponse, ) error
func (*Service) GetPaymentMethodTestSettings ¶
func (s *Service) GetPaymentMethodTestSettings( ctx context.Context, req *billingpb.GetPaymentMethodSettingsRequest, rsp *billingpb.GetPaymentMethodSettingsResponse, ) error
func (*Service) GetPaymentMinLimitsSystem ¶
func (s *Service) GetPaymentMinLimitsSystem( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.GetPaymentMinLimitsSystemResponse, ) (err error)
func (*Service) GetPayoutDocument ¶
func (s *Service) GetPayoutDocument( ctx context.Context, req *billingpb.GetPayoutDocumentRequest, res *billingpb.PayoutDocumentResponse, ) (err error)
func (*Service) GetPayoutDocumentRoyaltyReports ¶
func (s *Service) GetPayoutDocumentRoyaltyReports( ctx context.Context, req *billingpb.GetPayoutDocumentRequest, res *billingpb.ListRoyaltyReportsResponse, ) error
func (*Service) GetPayoutDocuments ¶
func (s *Service) GetPayoutDocuments( ctx context.Context, req *billingpb.GetPayoutDocumentsRequest, res *billingpb.GetPayoutDocumentsResponse, ) error
func (*Service) GetPlatforms ¶
func (s *Service) GetPlatforms(ctx context.Context, req *billingpb.ListPlatformsRequest, rsp *billingpb.ListPlatformsResponse) error
func (*Service) GetPriceGroup ¶
func (s *Service) GetPriceGroup( ctx context.Context, req *billingpb.GetPriceGroupRequest, res *billingpb.PriceGroup, ) error
func (*Service) GetPriceGroupByCountry ¶
func (s *Service) GetPriceGroupByCountry( ctx context.Context, req *billingpb.PriceGroupByCountryRequest, res *billingpb.PriceGroup, ) error
func (*Service) GetPriceGroupByRegion ¶
func (s *Service) GetPriceGroupByRegion(ctx context.Context, req *billingpb.GetPriceGroupByRegionRequest, rsp *billingpb.GetPriceGroupByRegionResponse) error
func (*Service) GetPriceGroupCurrencies ¶
func (s *Service) GetPriceGroupCurrencies( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.PriceGroupCurrenciesResponse, ) error
func (*Service) GetPriceGroupCurrencyByRegion ¶
func (s *Service) GetPriceGroupCurrencyByRegion( ctx context.Context, req *billingpb.PriceGroupByRegionRequest, res *billingpb.PriceGroupCurrenciesResponse, ) error
func (*Service) GetProduct ¶
func (s *Service) GetProduct( ctx context.Context, req *billingpb.RequestProduct, rsp *billingpb.GetProductResponse, ) error
func (*Service) GetProductPrices ¶
func (s *Service) GetProductPrices(ctx context.Context, req *billingpb.RequestProduct, res *billingpb.ProductPricesResponse) error
func (*Service) GetProductsForOrder ¶
func (s *Service) GetProductsForOrder(ctx context.Context, req *billingpb.GetProductsForOrderRequest, res *billingpb.ListProductsResponse) error
func (*Service) GetProject ¶
func (s *Service) GetProject( ctx context.Context, req *billingpb.GetProjectRequest, rsp *billingpb.ChangeProjectResponse, ) error
func (*Service) GetRecommendedPriceByConversion ¶
func (s *Service) GetRecommendedPriceByConversion( ctx context.Context, req *billingpb.RecommendedPriceRequest, res *billingpb.RecommendedPriceResponse, ) error
func (*Service) GetRecommendedPriceByPriceGroup ¶
func (s *Service) GetRecommendedPriceByPriceGroup( ctx context.Context, req *billingpb.RecommendedPriceRequest, res *billingpb.RecommendedPriceResponse, ) error
func (*Service) GetRecommendedPriceTable ¶
func (s *Service) GetRecommendedPriceTable( ctx context.Context, req *billingpb.RecommendedPriceTableRequest, res *billingpb.RecommendedPriceTableResponse, ) error
func (*Service) GetRefund ¶
func (s *Service) GetRefund( ctx context.Context, req *billingpb.GetRefundRequest, rsp *billingpb.CreateRefundResponse, ) error
func (*Service) GetRoleList ¶
func (s *Service) GetRoleList(ctx context.Context, req *billingpb.GetRoleListRequest, res *billingpb.GetRoleListResponse) error
func (*Service) GetRoyaltyReport ¶
func (s *Service) GetRoyaltyReport( ctx context.Context, req *billingpb.GetRoyaltyReportRequest, rsp *billingpb.GetRoyaltyReportResponse, ) error
func (*Service) GetUserProfile ¶
func (s *Service) GetUserProfile( ctx context.Context, req *billingpb.GetUserProfileRequest, rsp *billingpb.GetUserProfileResponse, ) error
func (*Service) GetVatReport ¶ added in v1.2.0
func (s *Service) GetVatReport( ctx context.Context, req *billingpb.VatReportRequest, res *billingpb.VatReportResponse, ) error
func (*Service) GetVatReportTransactions ¶
func (s *Service) GetVatReportTransactions( ctx context.Context, req *billingpb.VatTransactionsRequest, res *billingpb.PrivateTransactionsResponse, ) error
func (*Service) GetVatReportsDashboard ¶
func (s *Service) GetVatReportsDashboard( ctx context.Context, req *billingpb.EmptyRequest, res *billingpb.VatReportsResponse, ) error
func (*Service) GetVatReportsForCountry ¶
func (s *Service) GetVatReportsForCountry( ctx context.Context, req *billingpb.VatReportsRequest, res *billingpb.VatReportsResponse, ) error
func (*Service) IncrPaylinkVisits ¶
func (s *Service) IncrPaylinkVisits( ctx context.Context, req *billingpb.PaylinkRequestById, res *billingpb.EmptyResponse, ) error
IncrPaylinkVisits adds a visit hit to stat
func (*Service) InviteUserAdmin ¶
func (s *Service) InviteUserAdmin( ctx context.Context, req *billingpb.InviteUserAdminRequest, res *billingpb.InviteUserAdminResponse, ) error
func (*Service) InviteUserMerchant ¶
func (s *Service) InviteUserMerchant( ctx context.Context, req *billingpb.InviteUserMerchantRequest, res *billingpb.InviteUserMerchantResponse, ) error
func (*Service) IsChangeDataAllow ¶
func (*Service) IsDbNotFoundError ¶
func (*Service) IsOrderCanBePaying ¶
func (s *Service) IsOrderCanBePaying( ctx context.Context, req *billingpb.IsOrderCanBePayingRequest, rsp *billingpb.IsOrderCanBePayingResponse, ) error
func (*Service) KeyDaemonProcess ¶
func (*Service) ListMerchantPaymentMethods ¶
func (s *Service) ListMerchantPaymentMethods( ctx context.Context, req *billingpb.ListMerchantPaymentMethodsRequest, rsp *billingpb.ListingMerchantPaymentMethod, ) error
func (*Service) ListMerchants ¶
func (s *Service) ListMerchants( ctx context.Context, req *billingpb.MerchantListingRequest, rsp *billingpb.MerchantListingResponse, ) error
func (*Service) ListNotifications ¶
func (s *Service) ListNotifications( ctx context.Context, req *billingpb.ListingNotificationRequest, rsp *billingpb.Notifications, ) error
func (*Service) ListProducts ¶
func (s *Service) ListProducts(ctx context.Context, req *billingpb.ListProductsRequest, res *billingpb.ListProductsResponse) error
func (*Service) ListProjects ¶
func (s *Service) ListProjects( ctx context.Context, req *billingpb.ListProjectsRequest, rsp *billingpb.ListProjectsResponse, ) error
func (*Service) ListRefunds ¶
func (s *Service) ListRefunds( ctx context.Context, req *billingpb.ListRefundsRequest, rsp *billingpb.ListRefundsResponse, ) error
func (*Service) ListRoyaltyReportOrders ¶
func (s *Service) ListRoyaltyReportOrders( ctx context.Context, req *billingpb.ListRoyaltyReportOrdersRequest, res *billingpb.TransactionsResponse, ) error
func (*Service) ListRoyaltyReports ¶
func (s *Service) ListRoyaltyReports( ctx context.Context, req *billingpb.ListRoyaltyReportsRequest, rsp *billingpb.ListRoyaltyReportsResponse, ) error
func (*Service) MarkNotificationAsRead ¶
func (s *Service) MarkNotificationAsRead( ctx context.Context, req *billingpb.GetNotificationRequest, rsp *billingpb.Notification, ) error
func (*Service) MerchantReviewRoyaltyReport ¶
func (s *Service) MerchantReviewRoyaltyReport( ctx context.Context, req *billingpb.MerchantReviewRoyaltyReportRequest, rsp *billingpb.ResponseError, ) error
func (*Service) OrderCreateByPaylink ¶
func (s *Service) OrderCreateByPaylink( ctx context.Context, req *billingpb.OrderCreateByPaylink, rsp *billingpb.OrderCreateProcessResponse, ) error
func (*Service) OrderCreateProcess ¶
func (s *Service) OrderCreateProcess( ctx context.Context, req *billingpb.OrderCreateRequest, rsp *billingpb.OrderCreateProcessResponse, ) error
func (*Service) OrderReCreateProcess ¶
func (s *Service) OrderReCreateProcess( ctx context.Context, req *billingpb.OrderReCreateProcessRequest, res *billingpb.OrderCreateProcessResponse, ) error
func (*Service) OrderReceipt ¶
func (s *Service) OrderReceipt( ctx context.Context, req *billingpb.OrderReceiptRequest, rsp *billingpb.OrderReceiptResponse, ) error
func (*Service) PaymentCallbackProcess ¶
func (s *Service) PaymentCallbackProcess( ctx context.Context, req *billingpb.PaymentNotifyRequest, rsp *billingpb.PaymentNotifyResponse, ) error
func (*Service) PaymentCreateProcess ¶
func (s *Service) PaymentCreateProcess( ctx context.Context, req *billingpb.PaymentCreateRequest, rsp *billingpb.PaymentCreateResponse, ) error
func (*Service) PaymentFormJsonDataProcess ¶
func (s *Service) PaymentFormJsonDataProcess( ctx context.Context, req *billingpb.PaymentFormJsonDataRequest, rsp *billingpb.PaymentFormJsonDataResponse, ) error
func (*Service) PaymentFormLanguageChanged ¶
func (s *Service) PaymentFormLanguageChanged( ctx context.Context, req *billingpb.PaymentFormUserChangeLangRequest, rsp *billingpb.PaymentFormDataChangeResponse, ) error
func (*Service) PaymentFormPaymentAccountChanged ¶
func (s *Service) PaymentFormPaymentAccountChanged( ctx context.Context, req *billingpb.PaymentFormUserChangePaymentAccountRequest, rsp *billingpb.PaymentFormDataChangeResponse, ) error
func (*Service) PaymentFormPlatformChanged ¶
func (s *Service) PaymentFormPlatformChanged(ctx context.Context, req *billingpb.PaymentFormUserChangePlatformRequest, rsp *billingpb.PaymentFormDataChangeResponse) error
func (*Service) PayoutDocumentPdfUploaded ¶
func (s *Service) PayoutDocumentPdfUploaded( ctx context.Context, req *billingpb.PayoutDocumentPdfUploadedRequest, res *billingpb.PayoutDocumentPdfUploadedResponse, ) error
func (*Service) ProcessBillingAddress ¶
func (s *Service) ProcessBillingAddress( ctx context.Context, req *billingpb.ProcessBillingAddressRequest, rsp *billingpb.ProcessBillingAddressResponse, ) error
func (*Service) ProcessOrderKeyProducts ¶
func (*Service) ProcessOrderProducts ¶
func (*Service) ProcessOrderVirtualCurrency ¶
func (*Service) ProcessRefundCallback ¶
func (s *Service) ProcessRefundCallback( ctx context.Context, req *billingpb.CallbackRequest, rsp *billingpb.PaymentNotifyResponse, ) error
func (*Service) ProcessVatReports ¶
func (s *Service) ProcessVatReports( ctx context.Context, req *billingpb.ProcessVatReportsRequest, res *billingpb.EmptyResponse, ) error
func (*Service) PublishKeyProduct ¶
func (s *Service) PublishKeyProduct( ctx context.Context, req *billingpb.PublishKeyProductRequest, res *billingpb.KeyProductResponse, ) error
func (*Service) ResendInviteAdmin ¶
func (s *Service) ResendInviteAdmin( ctx context.Context, req *billingpb.ResendInviteAdminRequest, res *billingpb.EmptyResponseWithStatus, ) error
func (*Service) ResendInviteMerchant ¶
func (s *Service) ResendInviteMerchant( ctx context.Context, req *billingpb.ResendInviteMerchantRequest, res *billingpb.EmptyResponseWithStatus, ) error
func (*Service) ReserveKeyForOrder ¶
func (s *Service) ReserveKeyForOrder( ctx context.Context, req *billingpb.PlatformKeyReserveRequest, res *billingpb.PlatformKeyReserveResponse, ) error
func (*Service) RoyaltyReportPdfUploaded ¶
func (s *Service) RoyaltyReportPdfUploaded( ctx context.Context, req *billingpb.RoyaltyReportPdfUploadedRequest, res *billingpb.RoyaltyReportPdfUploadedResponse, ) error
func (*Service) SetMerchantOperatingCompany ¶
func (s *Service) SetMerchantOperatingCompany( ctx context.Context, req *billingpb.SetMerchantOperatingCompanyRequest, rsp *billingpb.SetMerchantOperatingCompanyResponse, ) error
func (*Service) SetMerchantS3Agreement ¶
func (s *Service) SetMerchantS3Agreement( ctx context.Context, req *billingpb.SetMerchantS3AgreementRequest, rsp *billingpb.ChangeMerchantDataResponse, ) error
func (*Service) SetMerchantTariffRates ¶
func (s *Service) SetMerchantTariffRates( ctx context.Context, req *billingpb.SetMerchantTariffRatesRequest, rsp *billingpb.CheckProjectRequestSignatureResponse, ) error
func (*Service) SetMoneyBackCostMerchant ¶
func (s *Service) SetMoneyBackCostMerchant( ctx context.Context, req *billingpb.MoneyBackCostMerchant, res *billingpb.MoneyBackCostMerchantResponse, ) error
func (*Service) SetMoneyBackCostSystem ¶
func (s *Service) SetMoneyBackCostSystem( ctx context.Context, req *billingpb.MoneyBackCostSystem, res *billingpb.MoneyBackCostSystemResponse, ) error
func (*Service) SetPaymentChannelCostMerchant ¶
func (s *Service) SetPaymentChannelCostMerchant( ctx context.Context, req *billingpb.PaymentChannelCostMerchant, res *billingpb.PaymentChannelCostMerchantResponse, ) error
func (*Service) SetPaymentChannelCostSystem ¶
func (s *Service) SetPaymentChannelCostSystem( ctx context.Context, req *billingpb.PaymentChannelCostSystem, res *billingpb.PaymentChannelCostSystemResponse, ) error
func (*Service) SetPaymentMinLimitSystem ¶
func (s *Service) SetPaymentMinLimitSystem( ctx context.Context, req *billingpb.PaymentMinLimitSystem, res *billingpb.EmptyResponseWithStatus, ) (err error)
func (*Service) SetUserNotifyNewRegion ¶
func (s *Service) SetUserNotifyNewRegion( ctx context.Context, req *billingpb.SetUserNotifyRequest, _ *billingpb.EmptyResponse, ) error
func (*Service) SetUserNotifySales ¶
func (s *Service) SetUserNotifySales( ctx context.Context, req *billingpb.SetUserNotifyRequest, _ *billingpb.EmptyResponse, ) error
func (*Service) UnPublishKeyProduct ¶
func (s *Service) UnPublishKeyProduct( ctx context.Context, req *billingpb.UnPublishKeyProductRequest, res *billingpb.KeyProductResponse, ) error
func (*Service) UpdateCountry ¶
func (*Service) UpdateOrder ¶
func (*Service) UpdatePayoutDocument ¶
func (s *Service) UpdatePayoutDocument( ctx context.Context, req *billingpb.UpdatePayoutDocumentRequest, res *billingpb.PayoutDocumentResponse, ) error
func (*Service) UpdatePriceGroup ¶
func (s *Service) UpdatePriceGroup( ctx context.Context, req *billingpb.PriceGroup, res *billingpb.PriceGroup, ) error
func (*Service) UpdateProductPrices ¶
func (s *Service) UpdateProductPrices(ctx context.Context, req *billingpb.UpdateProductPricesRequest, res *billingpb.ResponseError) error
func (*Service) UpdateVatReportStatus ¶
func (s *Service) UpdateVatReportStatus( ctx context.Context, req *billingpb.UpdateVatReportStatusRequest, res *billingpb.ResponseError, ) error
func (*Service) UploadKeysFile ¶
func (s *Service) UploadKeysFile( ctx context.Context, req *billingpb.PlatformKeysFileRequest, res *billingpb.PlatformKeysFileResponse, ) error
type TariffRates ¶
type TariffRates struct {
Items []*billingpb.MerchantTariffRatesPayment `json:"items"`
}
type Token ¶
type Token struct { CustomerId string `json:"customer_id"` User *billingpb.TokenUser `json:"user"` Settings *billingpb.TokenSettings `json:"settings"` }
type TotalTransactionsAndArpuReports ¶
type TotalTransactionsAndArpuReports struct { TotalTransactions *billingpb.DashboardMainReportTotalTransactions `bson:"total_transactions"` Arpu *billingpb.DashboardAmountItemWithChart `bson:"arpu"` }
Source Files ¶
- accounting_entry.go
- bank_card.go
- cardpay.go
- centrifugo.go
- country.go
- dashboard.go
- dashboard_report_processor.go
- dashboard_repository.go
- entity.go
- key.go
- key_product.go
- merchant.go
- merchant_balance.go
- merchants_tariff_rates.go
- mock_payment_system.go
- money_back_cost_merchant.go
- money_back_cost_system.go
- onboarding.go
- operating_company.go
- order.go
- order_view.go
- paylink.go
- payment_channel_cost_merchant.go
- payment_channel_cost_system.go
- payment_method.go
- payment_min_limit_system.go
- payment_system.go
- payouts.go
- platform.go
- price_groups.go
- price_table.go
- product.go
- project.go
- recurring.go
- refund.go
- report.go
- royalty_report.go
- service.go
- test_helpers.go
- token.go
- turnovers.go
- user_profile.go
- users.go
- vat_reports.go
- zip_code.go
Click to show internal directories.
Click to hide internal directories.