221 lines
7.7 KiB
Go
221 lines
7.7 KiB
Go
package domain
|
|
|
|
type ProviderRequest struct {
|
|
BrandID string `json:"brandId"`
|
|
ExtraData bool `json:"extraData,omitempty"`
|
|
Size int `json:"size,omitempty"`
|
|
Page int `json:"page,omitempty"`
|
|
}
|
|
|
|
type ProviderResponse struct {
|
|
Items []struct {
|
|
ProviderID string `json:"providerId"`
|
|
ProviderName string `json:"providerName"`
|
|
LogoForDark string `json:"logoForDark"`
|
|
LogoForLight string `json:"logoForLight"`
|
|
} `json:"items"`
|
|
}
|
|
|
|
type GameListRequest struct {
|
|
BrandID string `json:"brandId"`
|
|
ProviderID string `json:"providerId"`
|
|
Size int `json:"size,omitempty"`
|
|
Page int `json:"page,omitempty"`
|
|
}
|
|
|
|
type GameEntity struct {
|
|
GameID string `json:"gameId"`
|
|
ProviderID string `json:"providerId"`
|
|
Name string `json:"name"`
|
|
DeviceType string `json:"deviceType"`
|
|
Category string `json:"category"`
|
|
HasDemoMode bool `json:"hasDemoMode"`
|
|
HasFreeBets bool `json:"hasFreeBets"`
|
|
}
|
|
|
|
type GameStartRequest struct {
|
|
SessionID string `json:"sessionId"`
|
|
ProviderID string `json:"providerId"`
|
|
GameID string `json:"gameId"`
|
|
Language string `json:"language"`
|
|
PlayerID string `json:"playerId"`
|
|
Currency string `json:"currency"`
|
|
DeviceType string `json:"deviceType"`
|
|
Country string `json:"country"`
|
|
IP string `json:"ip"`
|
|
BrandID string `json:"brandId"`
|
|
UserAgent string `json:"userAgent,omitempty"`
|
|
LobbyURL string `json:"lobbyUrl,omitempty"`
|
|
CashierURL string `json:"cashierUrl,omitempty"`
|
|
PlayerName string `json:"playerName,omitempty"`
|
|
}
|
|
|
|
type DemoGameRequest struct {
|
|
ProviderID string `json:"providerId"`
|
|
GameID string `json:"gameId"`
|
|
Language string `json:"language"`
|
|
DeviceType string `json:"deviceType"`
|
|
IP string `json:"ip"`
|
|
BrandID string `json:"brandId"`
|
|
PlayerID string `json:"playerId,omitempty"`
|
|
Country string `json:"country,omitempty"`
|
|
}
|
|
|
|
type GameStartResponse struct {
|
|
StartGameURL string `json:"startGameUrl"`
|
|
}
|
|
|
|
type BalanceRequest struct {
|
|
SessionID string `json:"sessionId"`
|
|
ProviderID string `json:"providerId"`
|
|
PlayerID string `json:"playerId"`
|
|
Currency string `json:"currency"`
|
|
BrandID string `json:"brandId"`
|
|
GameID string `json:"gameId,omitempty"`
|
|
}
|
|
|
|
type BalanceResponse struct {
|
|
Real struct {
|
|
Currency string `json:"currency"`
|
|
Amount float64 `json:"amount"`
|
|
} `json:"real"`
|
|
Bonus *struct {
|
|
Currency string `json:"currency"`
|
|
Amount float64 `json:"amount"`
|
|
} `json:"bonus,omitempty"`
|
|
}
|
|
|
|
type BetRequest struct {
|
|
SessionID string `json:"sessionId"`
|
|
BetType string `json:"betType"`
|
|
TransactionID string `json:"transactionId"`
|
|
GameID string `json:"gameId"`
|
|
GameType string `json:"gameType"`
|
|
PlayerID string `json:"playerId"`
|
|
RoundID string `json:"roundId"`
|
|
ProviderID string `json:"providerId"`
|
|
CorrelationID string `json:"correlationId"`
|
|
BrandID string `json:"brandId"`
|
|
JackpotID string `json:"jackpotId,omitempty"`
|
|
JackpotContribution float64 `json:"jackpotContribution,omitempty"`
|
|
IsAdjustment bool `json:"isAdjustment,omitempty"`
|
|
Amount struct {
|
|
Amount float64 `json:"amount"`
|
|
Currency string `json:"currency"`
|
|
} `json:"amount"`
|
|
}
|
|
|
|
type WinRequest struct {
|
|
SessionID string `json:"sessionId"`
|
|
WinType string `json:"winType"` // WIN_ORDINARY, WIN_FREE, WIN_JACKPOT
|
|
TransactionID string `json:"transactionId"`
|
|
GameID string `json:"gameId"`
|
|
GameType string `json:"gameType"` // CRASH or OTHER
|
|
PlayerID string `json:"playerId"`
|
|
RoundID string `json:"roundId"`
|
|
CorrelationID string `json:"correlationId"`
|
|
ProviderID string `json:"providerId"`
|
|
BrandID string `json:"brandId"`
|
|
RewardID string `json:"rewardId,omitempty"`
|
|
IsCashOut bool `json:"isCashOut,omitempty"`
|
|
Amount struct {
|
|
Amount float64 `json:"amount"`
|
|
Currency string `json:"currency"`
|
|
} `json:"amount"`
|
|
}
|
|
|
|
type CancelRequest struct {
|
|
SessionID string `json:"sessionId"`
|
|
CancelType string `json:"cancelType"` // CANCEL_BET, CANCEL_ROUND, CANCEL_TRANSACTION
|
|
TransactionID string `json:"transactionId"`
|
|
RefTransactionID string `json:"refTransactionId,omitempty"`
|
|
GameID string `json:"gameId"`
|
|
PlayerID string `json:"playerId"`
|
|
GameType string `json:"gameType"`
|
|
RoundID string `json:"roundId"`
|
|
CorrelationID string `json:"correlationId,omitempty"`
|
|
ProviderID string `json:"providerId"`
|
|
BrandID string `json:"brandId"`
|
|
AdjustmentRefund *struct {
|
|
Amount float64 `json:"amount"`
|
|
Currency string `json:"currency"`
|
|
} `json:"adjustmentRefund,omitempty"`
|
|
}
|
|
|
|
type WinResponse struct {
|
|
WalletTransactionID string `json:"walletTransactionId"`
|
|
Real BalanceDetail `json:"real"`
|
|
Bonus *BalanceDetail `json:"bonus,omitempty"`
|
|
UsedRealAmount float64 `json:"usedRealAmount,omitempty"`
|
|
UsedBonusAmount float64 `json:"usedBonusAmount,omitempty"`
|
|
}
|
|
|
|
type BetResponse struct {
|
|
WalletTransactionID string `json:"walletTransactionId"`
|
|
Real BalanceDetail `json:"real"`
|
|
Bonus *BalanceDetail `json:"bonus,omitempty"`
|
|
UsedRealAmount float64 `json:"usedRealAmount,omitempty"`
|
|
UsedBonusAmount float64 `json:"usedBonusAmount,omitempty"`
|
|
}
|
|
|
|
type CancelResponse struct {
|
|
WalletTransactionID string `json:"walletTransactionId"`
|
|
Real BalanceDetail `json:"real"`
|
|
Bonus *BalanceDetail `json:"bonus,omitempty"`
|
|
UsedRealAmount float64 `json:"usedRealAmount,omitempty"`
|
|
UsedBonusAmount float64 `json:"usedBonusAmount,omitempty"`
|
|
}
|
|
|
|
type BalanceDetail struct {
|
|
Currency string `json:"currency"`
|
|
Amount float64 `json:"amount"`
|
|
}
|
|
// Request
|
|
type GamingActivityRequest struct {
|
|
FromDate string `json:"fromDate"` // YYYY-MM-DD
|
|
ToDate string `json:"toDate"` // YYYY-MM-DD
|
|
ProviderID string `json:"providerId,omitempty"` // Optional
|
|
Currencies []string `json:"currencies,omitempty"` // Optional
|
|
GameIDs []string `json:"gameIds,omitempty"` // Optional
|
|
ExcludeFreeWin *bool `json:"excludeFreeWin,omitempty"` // Optional
|
|
Page int `json:"page,omitempty"` // Optional, default 1
|
|
Size int `json:"size,omitempty"` // Optional, default 100
|
|
PlayerIDs []string `json:"playerIds,omitempty"` // Optional
|
|
BrandID string `json:"brandId"` // Required
|
|
}
|
|
|
|
// Response
|
|
type GamingActivityResponse struct {
|
|
Items []GamingActivityItem `json:"items"`
|
|
Meta PaginationMeta `json:"meta"`
|
|
}
|
|
|
|
type GamingActivityItem struct {
|
|
TransactionID string `json:"transactionId"`
|
|
SessionID string `json:"sessionId"`
|
|
RoundID string `json:"roundId"`
|
|
CorrelationID string `json:"correlationId"`
|
|
RoundType string `json:"roundType"`
|
|
ActionType string `json:"actionType"`
|
|
ProviderID string `json:"providerId"`
|
|
BrandID string `json:"brandId"`
|
|
PlayerID string `json:"playerId"`
|
|
GameID string `json:"gameId"`
|
|
Amount float64 `json:"amount"`
|
|
Currency string `json:"currency"`
|
|
CreatedAt string `json:"createdAt"`
|
|
AmountEur float64 `json:"amountEur"`
|
|
AmountUsd float64 `json:"amountUsd"`
|
|
RefTransactionID string `json:"refTransactionId,omitempty"`
|
|
RefRoundType string `json:"refRoundType,omitempty"`
|
|
RefActionType string `json:"refActionType,omitempty"`
|
|
}
|
|
|
|
type PaginationMeta struct {
|
|
TotalItems int `json:"totalItems"`
|
|
ItemCount int `json:"itemCount"`
|
|
ItemsPerPage int `json:"itemsPerPage"`
|
|
TotalPages int `json:"totalPages"`
|
|
CurrentPage int `json:"currentPage"`
|
|
}
|