sarafu-api/remote/account_service.go

21 lines
1.0 KiB
Go
Raw Normal View History

2025-01-11 18:29:16 +01:00
package remote
import (
"context"
"git.grassecon.net/grassrootseconomics/sarafu-api/models"
2025-01-11 18:29:16 +01:00
dataserviceapi "github.com/grassrootseconomics/ussd-data-service/pkg/api"
)
type AccountService interface {
2025-01-11 18:29:16 +01:00
CheckBalance(ctx context.Context, publicKey string) (*models.BalanceResult, error)
CreateAccount(ctx context.Context) (*models.AccountResult, error)
TrackAccountStatus(ctx context.Context, publicKey string) (*models.TrackStatusResult, error)
FetchVouchers(ctx context.Context, publicKey string) ([]dataserviceapi.TokenHoldings, error)
FetchTransactions(ctx context.Context, publicKey string) ([]dataserviceapi.Last10TxResponse, error)
VoucherData(ctx context.Context, address string) (*models.VoucherDataResult, error)
TokenTransfer(ctx context.Context, amount, from, to, tokenAddress string) (*models.TokenTransferResponse, error)
2025-01-14 14:57:18 +01:00
CheckAliasAddress(ctx context.Context, alias string) (*models.AliasAddress, error)
2025-01-14 14:53:29 +01:00
RequestAlias(ctx context.Context, hint string, publicKey string) (*models.RequestAliasResult, error)
2025-01-11 18:29:16 +01:00
}