treasurer/internal/payment_provider/provider.go
2025-06-09 16:19:07 +03:00

18 lines
618 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package payment_provider
import (
"context"
"gitea.pena/PenaSide/treasurer/internal/errors"
"gitea.pena/PenaSide/treasurer/internal/models"
"gitea.pena/PenaSide/treasurer/internal/models/yandex"
"github.com/gofiber/fiber/v2"
)
type PaymentProvider interface {
GetName() string
RegisterWebhookHandlers(router fiber.Router)
GetSupportedPaymentMethods() []models.PaymentType
// todo потом нужно будет сделать так чтобы работало не только с yandex.Receipt
CreateInvoice(ctx context.Context, request *models.CreatePayment[yandex.Receipt]) (string, errors.Error)
}