caleta

package
v0.7.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 1, 2023 License: MIT Imports: 26 Imported by: 0

Documentation

Overview

Package caleta module for provider Caleta

Package caleta provides primitives to interact with the openapi HTTP API.

Code generated by github.com/four-fingers/oapi-codegen version v0.0.0-20221219135408-9237c9743c67 DO NOT EDIT.

Package caleta provides primitives to interact with the openapi HTTP API.

Code generated by github.com/four-fingers/oapi-codegen version v0.0.0-20221219135408-9237c9743c67 DO NOT EDIT.

Index

Constants

View Source
const (
	ProviderName = "caleta"
)
View Source
const TimestampFormat = "2006-01-02 15:04:05.999999-07:00"

Variables

This section is empty.

Functions

func NewAPIClient added in v0.6.0

func NewAPIClient(client rest.HTTPClientJSONInterface, config configs.ProviderConf) (*apiClient, error)

func NewCaletaService added in v0.6.0

func NewCaletaService(apiClient API, config configs.ProviderConf) (*caletaService, error)

func NewOperatorRouter

func NewOperatorRouter(config configs.ProviderConf, httpClient rest.HTTPClientJSONInterface) (*provider.Router, error)

func NewProviderRouter

func NewProviderRouter(config configs.ProviderConf, service StrictServerInterface) (*provider.Router, error)

func NewSigner

func NewSigner(privateKey []byte) (auth.Signer, error)

NewSigner accepts a PEM private rsa key and creates a new signer

func NewVerifier

func NewVerifier(publicKey []byte) (auth.Verifier, error)

NewVerifier accepts a PEM public key and creates a new verifier

func Routes

func Routes(wrapper ServerInterfaceWrapper) []provider.Route

func VerifySignature

func VerifySignature(v auth.Verifier) fiber.Handler

VerifySignature middleware for verifying auth signature header

Types

type API added in v0.6.0

type API interface {
	// contains filtered or unexported methods
}

type AuthConf

type AuthConf struct {
	// OperatorId configured in Caletas system
	OperatorID string `mapstructure:"operator_id"`
	// SigningKey Used to sign outgoing requests
	SigningKey string `mapstructure:"signing_key"`
	// VerificationKey Used to verify incoming requests
	VerificationKey string `mapstructure:"verification_key"`
}

type BalanceResponse

type BalanceResponse struct {
	// Balance We use integers to represent the amount of money. To convert real float value to integer we multiply it by 100000. Example: $3.56 must be represented as 356000
	Balance *MoneyAmount `json:"balance,omitempty"`

	// Currency ISO 4217 currency code. Following enum contains all currencies supported by our system. Existing of currency in this list doesn't mean that all providers support native game play with it. Please contact us to know which provider supports which currencies.
	Currency *Currency `json:"currency,omitempty"`

	// RequestUuid Standard 16-byte UUID. This id can be seen as network layer action. An id of an action that is generated for each our call to Operator. Used to sync Hub88 and Operator sides for debugging purposes. Operator has to respond with the same request_uuid as the one that was received in request.
	RequestUuid RequestUuid `json:"request_uuid"`

	// Status Response status usage:<br/>RS_OK - when transaction was processed correctly or was already processed before.<br/>RS_ERROR_UNKNOWN - use this when you need a generic error code<br/>RS_ERROR_TIMEOUT - when the server was disconnected by timeout<br/>RS_ERROR_INVALID_TOKEN - when token never existed or is not associated to this player.<br/>RS_ERROR_INVALID_GAME - when the game doesn't exist<br/>RS_ERROR_WRONG_CURRENCY - when the currency is not active or does not exist<br/>RS_ERROR_NOT_ENOUGH_MONEY - when user is short of money<br/>RS_ERROR_USER_DISABLED when user is banned or inactive<br/>RS_ERROR_INVALID_SIGNATURE - when signature doesn't match<br/>RS_ERROR_TOKEN_EXPIRED - when a new token exists (this rule applies only for /wallet/bet)<br/>RS_ERROR_WRONG_SYNTAX - message can't be decoded to JSON<br/>RS_ERROR_WRONG_TYPES - i.e. when a type should be integer and came as string<br/>RS_ERROR_DUPLICATE_TRANSACTION - when the same transaction_uuid appears but for a different user, round and game, otherwise returns RS_OK<br/>RS_ERROR_TRANSACTION_DOES_NOT_EXIST - when doing a 'win' transaction and the 'bet' transaction id doesn't exist<br/>RS_ERROR_TRANSACTION_ROLLED_BACK - when a 'win' transaction happens in name of a rolled back transaction (when receiving a 'rollback' replies with 'RS_OK'<br/>RS_ERROR_BET_LIMIT_EXCEEDED - when the user exceeded its limits
	Status Status `json:"status"`

	// User Unique User ID in the Operator�s system. In case of DEMO gameplay, this parameter may be omitted.
	User *User `json:"user,omitempty"`
}

BalanceResponse defines model for BalanceResponse.

type BlockedCountries

type BlockedCountries = []Country

BlockedCountries List of blocked countries. Game shouldn�t be shown and launched for users from these countries.

type CampaignUuid

type CampaignUuid = string

CampaignUuid Each Free Bet campaign contains an unique identifier on Caleta side. Campaings holds information of game where Free Bet will happen, total of spins, bet value and period of campaign.

type Category

type Category string

Category Game category. Following enum contains all possible values.

const (
	Baccarat       Category = "Baccarat"
	BetOnPoker     Category = "Bet On Poker"
	Bingo          Category = "Bingo"
	Blackjack      Category = "Blackjack"
	CasualGames    Category = "Casual Games"
	FixedOdds      Category = "Fixed Odds"
	JackpotSlots   Category = "Jackpot Slots"
	LiveBaccarat   Category = "Live Baccarat"
	LiveBlackjack  Category = "Live Blackjack"
	LiveDealer     Category = "Live Dealer"
	LiveDice       Category = "Live Dice"
	LiveGames      Category = "Live Games"
	LiveKeno       Category = "Live Keno"
	LiveLottery    Category = "Live Lottery"
	LiveRoulette   Category = "Live Roulette"
	Lottery        Category = "Lottery"
	Multiplayer    Category = "Multiplayer"
	PlayerProps    Category = "Player Props"
	Poker          Category = "Poker"
	Roulette       Category = "Roulette"
	ScratchCards   Category = "Scratch Cards"
	Sportsbook     Category = "Sportsbook"
	TableGames     Category = "Table Games"
	Unknown        Category = "Unknown"
	VideoBingo     Category = "Video Bingo"
	VideoPoker     Category = "Video Poker"
	VideoSlots     Category = "Video Slots"
	VirtualSports  Category = "Virtual Sports"
	WheelOfFortune Category = "Wheel of Fortune"
)

Defines values for Category.

type Country

type Country string

Country User's country ISO 3166-1 code. Following enum contains all supported values.

const (
	AE Country = "AE"
	AF Country = "AF"
	AG Country = "AG"
	AI Country = "AI"
	AL Country = "AL"
	AM Country = "AM"
	AO Country = "AO"
	AQ Country = "AQ"
	AR Country = "AR"
	AS Country = "AS"
	AT Country = "AT"
	AU Country = "AU"
	AW Country = "AW"
	AX Country = "AX"
	AZ Country = "AZ"
	BA Country = "BA"
	BB Country = "BB"
	BD Country = "BD"
	BE Country = "BE"
	BF Country = "BF"
	BG Country = "BG"
	BH Country = "BH"
	BI Country = "BI"
	BJ Country = "BJ"
	BL Country = "BL"
	BM Country = "BM"
	BN Country = "BN"
	BO Country = "BO"
	BQ Country = "BQ"
	BR Country = "BR"
	BS Country = "BS"
	BT Country = "BT"
	BV Country = "BV"
	BW Country = "BW"
	BY Country = "BY"
	BZ Country = "BZ"
	CA Country = "CA"
	CC Country = "CC"
	CD Country = "CD"
	CF Country = "CF"
	CG Country = "CG"
	CH Country = "CH"
	CI Country = "CI"
	CK Country = "CK"
	CL Country = "CL"
	CM Country = "CM"
	CN Country = "CN"
	CO Country = "CO"
	CR Country = "CR"
	CU Country = "CU"
	CV Country = "CV"
	CW Country = "CW"
	CX Country = "CX"
	CY Country = "CY"
	CZ Country = "CZ"
	DE Country = "DE"
	DJ Country = "DJ"
	DK Country = "DK"
	DM Country = "DM"
	DO Country = "DO"
	DZ Country = "DZ"
	EC Country = "EC"
	EE Country = "EE"
	EG Country = "EG"
	EH Country = "EH"
	ER Country = "ER"
	ES Country = "ES"
	ET Country = "ET"
	FI Country = "FI"
	FJ Country = "FJ"
	FK Country = "FK"
	FM Country = "FM"
	FO Country = "FO"
	FR Country = "FR"
	GA Country = "GA"
	GB Country = "GB"
	GD Country = "GD"
	GE Country = "GE"
	GF Country = "GF"
	GG Country = "GG"
	GH Country = "GH"
	GI Country = "GI"
	GL Country = "GL"
	GM Country = "GM"
	GN Country = "GN"
	GP Country = "GP"
	GQ Country = "GQ"
	GR Country = "GR"
	GS Country = "GS"
	GT Country = "GT"
	GU Country = "GU"
	GW Country = "GW"
	GY Country = "GY"
	HK Country = "HK"
	HM Country = "HM"
	HN Country = "HN"
	HR Country = "HR"
	HT Country = "HT"
	HU Country = "HU"
	ID Country = "ID"
	IE Country = "IE"
	IL Country = "IL"
	IM Country = "IM"
	IN Country = "IN"
	IO Country = "IO"
	IQ Country = "IQ"
	IR Country = "IR"
	IS Country = "IS"
	IT Country = "IT"
	JE Country = "JE"
	JM Country = "JM"
	JO Country = "JO"
	JP Country = "JP"
	KE Country = "KE"
	KG Country = "KG"
	KH Country = "KH"
	KI Country = "KI"
	KM Country = "KM"
	KN Country = "KN"
	KP Country = "KP"
	KR Country = "KR"
	KW Country = "KW"
	KY Country = "KY"
	KZ Country = "KZ"
	LA Country = "LA"
	LB Country = "LB"
	LC Country = "LC"
	LI Country = "LI"
	LK Country = "LK"
	LR Country = "LR"
	LS Country = "LS"
	LT Country = "LT"
	LU Country = "LU"
	LV Country = "LV"
	LY Country = "LY"
	MA Country = "MA"
	MC Country = "MC"
	MD Country = "MD"
	ME Country = "ME"
	MF Country = "MF"
	MG Country = "MG"
	MH Country = "MH"
	MK Country = "MK"
	ML Country = "ML"
	MM Country = "MM"
	MN Country = "MN"
	MO Country = "MO"
	MP Country = "MP"
	MQ Country = "MQ"
	MR Country = "MR"
	MS Country = "MS"
	MT Country = "MT"
	MU Country = "MU"
	MV Country = "MV"
	MW Country = "MW"
	MX Country = "MX"
	MY Country = "MY"
	MZ Country = "MZ"
	NA Country = "NA"
	NC Country = "NC"
	NE Country = "NE"
	NF Country = "NF"
	NG Country = "NG"
	NI Country = "NI"
	NL Country = "NL"
	NO Country = "NO"
	NP Country = "NP"
	NR Country = "NR"
	NU Country = "NU"
	NZ Country = "NZ"
	OM Country = "OM"
	PA Country = "PA"
	PE Country = "PE"
	PF Country = "PF"
	PG Country = "PG"
	PH Country = "PH"
	PK Country = "PK"
	PL Country = "PL"
	PM Country = "PM"
	PN Country = "PN"
	PR Country = "PR"
	PS Country = "PS"
	PT Country = "PT"
	PW Country = "PW"
	PY Country = "PY"
	QA Country = "QA"
	RE Country = "RE"
	RO Country = "RO"
	RS Country = "RS"
	RU Country = "RU"
	RW Country = "RW"
	SA Country = "SA"
	SB Country = "SB"
	SC Country = "SC"
	SD Country = "SD"
	SE Country = "SE"
	SG Country = "SG"
	SH Country = "SH"
	SI Country = "SI"
	SJ Country = "SJ"
	SK Country = "SK"
	SL Country = "SL"
	SM Country = "SM"
	SN Country = "SN"
	SO Country = "SO"
	SR Country = "SR"
	SS Country = "SS"
	ST Country = "ST"
	SV Country = "SV"
	SX Country = "SX"
	SY Country = "SY"
	SZ Country = "SZ"
	TC Country = "TC"
	TD Country = "TD"
	TF Country = "TF"
	TG Country = "TG"
	TH Country = "TH"
	TJ Country = "TJ"
	TK Country = "TK"
	TL Country = "TL"
	TM Country = "TM"
	TN Country = "TN"
	TO Country = "TO"
	TR Country = "TR"
	TT Country = "TT"
	TV Country = "TV"
	TW Country = "TW"
	TZ Country = "TZ"
	UA Country = "UA"
	UG Country = "UG"
	UM Country = "UM"
	US Country = "US"
	UY Country = "UY"
	UZ Country = "UZ"
	VA Country = "VA"
	VC Country = "VC"
	VE Country = "VE"
	VG Country = "VG"
	VI Country = "VI"
	VN Country = "VN"
	VU Country = "VU"
	WF Country = "WF"
	WS Country = "WS"
	XX Country = "XX"
	YE Country = "YE"
	YT Country = "YT"
	ZA Country = "ZA"
	ZM Country = "ZM"
	ZW Country = "ZW"
)

Defines values for Country.

type Currency

type Currency string

Currency ISO 4217 currency code. Following enum contains all currencies supported by our system. Existing of currency in this list doesn't mean that all providers support native game play with it. Please contact us to know which provider supports which currencies.

const (
	AED  Currency = "AED"
	AFN  Currency = "AFN"
	ALL  Currency = "ALL"
	AMD  Currency = "AMD"
	ANG  Currency = "ANG"
	AOA  Currency = "AOA"
	ARS  Currency = "ARS"
	AUD  Currency = "AUD"
	AWG  Currency = "AWG"
	AZN  Currency = "AZN"
	BAM  Currency = "BAM"
	BBD  Currency = "BBD"
	BDT  Currency = "BDT"
	BGN  Currency = "BGN"
	BHD  Currency = "BHD"
	BIF  Currency = "BIF"
	BMD  Currency = "BMD"
	BND  Currency = "BND"
	BOB  Currency = "BOB"
	BRL  Currency = "BRL"
	BSD  Currency = "BSD"
	BTN  Currency = "BTN"
	BWP  Currency = "BWP"
	BYR  Currency = "BYR"
	BZD  Currency = "BZD"
	CAD  Currency = "CAD"
	CHF  Currency = "CHF"
	CLP  Currency = "CLP"
	CNY  Currency = "CNY"
	COP  Currency = "COP"
	CRC  Currency = "CRC"
	CUC  Currency = "CUC"
	CUP  Currency = "CUP"
	CVE  Currency = "CVE"
	CZK  Currency = "CZK"
	DJF  Currency = "DJF"
	DKK  Currency = "DKK"
	DOP  Currency = "DOP"
	DZD  Currency = "DZD"
	EGP  Currency = "EGP"
	ERN  Currency = "ERN"
	ETB  Currency = "ETB"
	ETH  Currency = "ETH"
	EUR  Currency = "EUR"
	FJD  Currency = "FJD"
	FKP  Currency = "FKP"
	GBP  Currency = "GBP"
	GEL  Currency = "GEL"
	GHS  Currency = "GHS"
	GIP  Currency = "GIP"
	GMD  Currency = "GMD"
	GNF  Currency = "GNF"
	GTQ  Currency = "GTQ"
	GYD  Currency = "GYD"
	HKD  Currency = "HKD"
	HNL  Currency = "HNL"
	HRK  Currency = "HRK"
	HTG  Currency = "HTG"
	HUF  Currency = "HUF"
	IDR  Currency = "IDR"
	ILS  Currency = "ILS"
	INR  Currency = "INR"
	IQD  Currency = "IQD"
	IRR  Currency = "IRR"
	ISK  Currency = "ISK"
	JMD  Currency = "JMD"
	JOD  Currency = "JOD"
	JPY  Currency = "JPY"
	KES  Currency = "KES"
	KGS  Currency = "KGS"
	KHR  Currency = "KHR"
	KMF  Currency = "KMF"
	KPW  Currency = "KPW"
	KRW  Currency = "KRW"
	KWD  Currency = "KWD"
	KYD  Currency = "KYD"
	KZT  Currency = "KZT"
	LAK  Currency = "LAK"
	LBP  Currency = "LBP"
	LKR  Currency = "LKR"
	LRD  Currency = "LRD"
	LSL  Currency = "LSL"
	LTC  Currency = "LTC"
	LTL  Currency = "LTL"
	LYD  Currency = "LYD"
	MAD  Currency = "MAD"
	MBTC Currency = "mBTC"
	MDL  Currency = "MDL"
	METH Currency = "mETH"
	MGA  Currency = "MGA"
	MKD  Currency = "MKD"
	MLTC Currency = "mLTC"
	MMK  Currency = "MMK"
	MNT  Currency = "MNT"
	MOP  Currency = "MOP"
	MRO  Currency = "MRO"
	MUR  Currency = "MUR"
	MVR  Currency = "MVR"
	MWK  Currency = "MWK"
	MXN  Currency = "MXN"
	MYR  Currency = "MYR"
	MZN  Currency = "MZN"
	NAD  Currency = "NAD"
	NGN  Currency = "NGN"
	NIO  Currency = "NIO"
	NOK  Currency = "NOK"
	NPR  Currency = "NPR"
	NZD  Currency = "NZD"
	OMR  Currency = "OMR"
	PAB  Currency = "PAB"
	PEN  Currency = "PEN"
	PGK  Currency = "PGK"
	PHP  Currency = "PHP"
	PKR  Currency = "PKR"
	PLN  Currency = "PLN"
	PYG  Currency = "PYG"
	QAR  Currency = "QAR"
	RON  Currency = "RON"
	RSD  Currency = "RSD"
	RUB  Currency = "RUB"
	RWF  Currency = "RWF"
	SAR  Currency = "SAR"
	SBD  Currency = "SBD"
	SCR  Currency = "SCR"
	SDG  Currency = "SDG"
	SEK  Currency = "SEK"
	SGD  Currency = "SGD"
	SLL  Currency = "SLL"
	SOC  Currency = "SOC"
	SOS  Currency = "SOS"
	SRD  Currency = "SRD"
	SSP  Currency = "SSP"
	SYP  Currency = "SYP"
	SZL  Currency = "SZL"
	THB  Currency = "THB"
	TJS  Currency = "TJS"
	TMT  Currency = "TMT"
	TND  Currency = "TND"
	TOP  Currency = "TOP"
	TRY  Currency = "TRY"
	TTD  Currency = "TTD"
	TWD  Currency = "TWD"
	TZS  Currency = "TZS"
	UAH  Currency = "UAH"
	UBTC Currency = "uBTC"
	UETH Currency = "uETH"
	UGX  Currency = "UGX"
	ULTC Currency = "uLTC"
	USD  Currency = "USD"
	UYU  Currency = "UYU"
	UZS  Currency = "UZS"
	VEF  Currency = "VEF"
	VND  Currency = "VND"
	VUV  Currency = "VUV"
	WST  Currency = "WST"
	XCD  Currency = "XCD"
	XOF  Currency = "XOF"
	XPF  Currency = "XPF"
	XXX  Currency = "XXX"
	YER  Currency = "YER"
	ZAR  Currency = "ZAR"
	ZMW  Currency = "ZMW"
	ZWD  Currency = "ZWD"
)

Defines values for Currency.

type Game

type Game struct {
	// BlockedCountries List of blocked countries. Game shouldn�t be shown and launched for users from these countries.
	BlockedCountries BlockedCountries `json:"blocked_countries"`

	// Category Game category. Following enum contains all possible values.
	Category Category `json:"category"`

	// Enabled Shows whether game is enabled or not
	Enabled bool `json:"enabled"`

	// GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)
	GameId GameId `json:"game_id"`

	// Name Verbose game name
	Name string `json:"name"`

	// Platforms List of supported platforms
	Platforms []Platform `json:"platforms"`

	// Product Name of the game product (Game Provider).
	Product Product `json:"product"`

	// UrlBackground Game background image URL
	UrlBackground string `json:"url_background"`

	// UrlThumb Game preview image URL
	UrlThumb string `json:"url_thumb"`
}

Game Caleta game item

type GameCode

type GameCode = string

GameCode Unique Game Code on Caleta system. Can be obtained from `/api/game/list` endpoint. This variable intends to replace `game_id`.

type GameId

type GameId = int

GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)

type GameLaunchType added in v0.6.0

type GameLaunchType string
const (
	Static  GameLaunchType = "static"
	Request GameLaunchType = "request"
)

type GameListBody

type GameListBody struct {
	// OperatorId Unique identifier of Operator at Caleta Gaming System. Used to authorize incoming requests. Can be obtained Caleta back office after Operator is registered and set up Caleta system.
	OperatorId OperatorId `json:"operator_id"`
}

GameListBody defines model for game_list_body.

type GameRoundBody

type GameRoundBody struct {
	// OperatorId Unique identifier of Operator at Caleta Gaming System. Used to authorize incoming requests. Can be obtained Caleta back office after Operator is registered and set up Caleta system.
	OperatorId OperatorId `json:"operator_id"`

	// Round Game round id. Used to relate all bets and wins in one round. All transactions related to the same round will have the same value in this field. It's unique through whole system.
	Round *Round `json:"round,omitempty"`

	// SubPartnerId Id of Operator's sub-partner (brand, whitelabel, site, etc.) which uses same integration and credentials as Operator.
	SubPartnerId *SubPartnerId `json:"sub_partner_id,omitempty"`

	// TransactionUuid Unique wallet transaction.
	TransactionUuid *TransactionUuid `json:"transaction_uuid,omitempty"`

	// User Unique User ID in the Operator�s system. In case of DEMO gameplay, this parameter may be omitted.
	User *User `json:"user,omitempty"`
}

GameRoundBody defines model for game_round_body.

type GameUrlBody

type GameUrlBody struct {
	// Country User's country ISO 3166-1 code. Following enum contains all supported values.
	Country Country `json:"country"`

	// Currency ISO 4217 currency code. Following enum contains all currencies supported by our system. Existing of currency in this list doesn't mean that all providers support native game play with it. Please contact us to know which provider supports which currencies.
	Currency Currency `json:"currency"`

	// DepositUrl Some games have button that redirects User to page where he can deposit money. Put your URL to deposit page here.
	DepositUrl *string `json:"deposit_url,omitempty"`

	// GameCode Unique Game Code on Caleta system. Can be obtained from `/api/game/list` endpoint. This variable intends to replace `game_id`.
	GameCode GameCode `json:"game_code"`

	// GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)
	GameId *GameId `json:"game_id,omitempty"`

	// Lang Supported ISO 639-1 language code, default is 'en'.
	Lang Language `json:"lang"`

	// LobbyUrl Most games have a `Home` button that redirects the User back to the lobby. Put the lobby URL here.
	LobbyUrl string `json:"lobby_url"`

	// OperatorId Unique identifier of Operator at Caleta Gaming System. Used to authorize incoming requests. Can be obtained Caleta back office after Operator is registered and set up Caleta system.
	OperatorId OperatorId `json:"operator_id"`

	// SubPartnerId Id of Operator's sub-partner (brand, whitelabel, site, etc.) which uses same integration and credentials as Operator.
	SubPartnerId SubPartnerId `json:"sub_partner_id"`

	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token *Token `json:"token,omitempty"`

	// User Unique User ID in the Operator�s system. In case of DEMO gameplay, this parameter may be omitted.
	User *User `json:"user,omitempty"`
}

GameUrlBody defines model for game_url_body.

type GamelistJSONRequestBody

type GamelistJSONRequestBody = GameListBody

GamelistJSONRequestBody defines body for Gamelist for application/json ContentType.

type GamelistParams

type GamelistParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key associated with provided operator_id.
	XAuthSignature string `json:"X-Auth-Signature"`
}

GamelistParams defines parameters for Gamelist.

type GameroundJSONRequestBody

type GameroundJSONRequestBody = GameRoundBody

GameroundJSONRequestBody defines body for Gameround for application/json ContentType.

type GameroundParams

type GameroundParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key associated with provided operator_id.
	XAuthSignature string `json:"X-Auth-Signature"`
}

GameroundParams defines parameters for Gameround.

type Games

type Games = []Game

Games defines model for Games.

type GameurlJSONRequestBody

type GameurlJSONRequestBody = GameUrlBody

GameurlJSONRequestBody defines body for Gameurl for application/json ContentType.

type GameurlParams

type GameurlParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key associated with provided operator_id.
	XAuthSignature string `json:"X-Auth-Signature"`
}

GameurlParams defines parameters for Gameurl.

type InlineResponse200

type InlineResponse200 struct {
	// Url Landing URL of chosen game
	Url *string `json:"url,omitempty"`
}

InlineResponse200 defines model for inline_response_200.

type InlineResponse2001

type InlineResponse2001 struct {
	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token *Token `json:"token,omitempty"`
}

InlineResponse2001 defines model for inline_response_200_1.

type InlineResponse404

type InlineResponse404 struct {
	// Error Reason why request failed
	Error *string `json:"error,omitempty"`
}

InlineResponse404 defines model for inline_response_404.

type IsFree

type IsFree = bool

IsFree Flag which shows that transaction was generated by a promotional tool (FreeSpins, etc). Usually, these transactions are credited to bonus wallets (if available).

type Language

type Language string

Language Supported ISO 639-1 language code, default is 'en'.

const (
	De Language = "de"
	En Language = "en"
	Es Language = "es"
	Ja Language = "ja"
	Ko Language = "ko"
	Pt Language = "pt"
	Ru Language = "ru"
	Th Language = "th"
	Tr Language = "tr"
	Vi Language = "vi"
	Zh Language = "zh"
)

Defines values for Language.

type MiddlewareFunc

type MiddlewareFunc fiber.Handler

type MoneyAmount

type MoneyAmount = int

MoneyAmount We use integers to represent the amount of money. To convert real float value to integer we multiply it by 100000. Example: $3.56 must be represented as 356000

type MsgTimestamp added in v0.5.0

type MsgTimestamp caletaDate

MsgTimestamp Event or transaction timestamp in UTC

func (*MsgTimestamp) UnmarshalJSON added in v0.5.0

func (c *MsgTimestamp) UnmarshalJSON(in []byte) error

func (*MsgTimestamp) UnmarshalText added in v0.5.0

func (c *MsgTimestamp) UnmarshalText(text []byte) error

UnmarshalText is actually preferred when parsing header params

type OperatorId

type OperatorId = string

OperatorId Unique identifier of Operator at Caleta Gaming System. Used to authorize incoming requests. Can be obtained Caleta back office after Operator is registered and set up Caleta system.

type Platform

type Platform string

Platform User's platform. Affects what kind of game layout will be returned. `GPL_MOBILE` for mobiles and `GPL_DESKTOP` for desktop mode. Some Providers ignore this option and choose mode based on User's browser attributes (user-agent, resolution, ratio, orientation).

const (
	GPLDESKTOP Platform = "GPL_DESKTOP"
	GPLMOBILE  Platform = "GPL_MOBILE"
)

Defines values for Platform.

type Product

type Product = string

Product Name of the game product (Game Provider).

type RequestUuid

type RequestUuid = string

RequestUuid Standard 16-byte UUID. This id can be seen as network layer action. An id of an action that is generated for each our call to Operator. Used to sync Hub88 and Operator sides for debugging purposes. Operator has to respond with the same request_uuid as the one that was received in request.

type RewardUuid

type RewardUuid = string

RewardUuid This holds the uuid of a reward given to a player on Caleta side. Rewards holds information about which campaigns belong, player, quantity left of Free Bets.

type Round

type Round = string

Round Game round id. Used to relate all bets and wins in one round. All transactions related to the same round will have the same value in this field. It's unique through whole system.

type RoundClosed

type RoundClosed = bool

RoundClosed Denotes when the round is closed

type ServerInterface

type ServerInterface interface {

	// (POST /wallet/balance)
	Walletbalance(c *fiber.Ctx, params WalletbalanceParams) error

	// (POST /wallet/bet)
	Walletbet(c *fiber.Ctx, params WalletbetParams) error

	// (POST /wallet/check)
	Walletcheck(c *fiber.Ctx, params WalletcheckParams) error

	// (POST /wallet/rollback)
	Walletrollback(c *fiber.Ctx, params WalletrollbackParams) error

	// (POST /wallet/win)
	Transactionwin(c *fiber.Ctx, params TransactionwinParams) error
}

ServerInterface represents all server handlers.

func NewStrictHandler

func NewStrictHandler(ssi StrictServerInterface, middlewares []StrictMiddlewareFunc) ServerInterface

type ServerInterfaceWrapper

type ServerInterfaceWrapper struct {
	Handler ServerInterface
}

ServerInterfaceWrapper converts contexts to parameters.

func (*ServerInterfaceWrapper) Transactionwin

func (siw *ServerInterfaceWrapper) Transactionwin(c *fiber.Ctx) error

Transactionwin operation middleware

func (*ServerInterfaceWrapper) Walletbalance

func (siw *ServerInterfaceWrapper) Walletbalance(c *fiber.Ctx) error

Walletbalance operation middleware

func (*ServerInterfaceWrapper) Walletbet

func (siw *ServerInterfaceWrapper) Walletbet(c *fiber.Ctx) error

Walletbet operation middleware

func (*ServerInterfaceWrapper) Walletcheck

func (siw *ServerInterfaceWrapper) Walletcheck(c *fiber.Ctx) error

Walletcheck operation middleware

func (*ServerInterfaceWrapper) Walletrollback

func (siw *ServerInterfaceWrapper) Walletrollback(c *fiber.Ctx) error

Walletrollback operation middleware

type Status

type Status string

Status Response status usage:<br/>RS_OK - when transaction was processed correctly or was already processed before.<br/>RS_ERROR_UNKNOWN - use this when you need a generic error code<br/>RS_ERROR_TIMEOUT - when the server was disconnected by timeout<br/>RS_ERROR_INVALID_TOKEN - when token never existed or is not associated to this player.<br/>RS_ERROR_INVALID_GAME - when the game doesn't exist<br/>RS_ERROR_WRONG_CURRENCY - when the currency is not active or does not exist<br/>RS_ERROR_NOT_ENOUGH_MONEY - when user is short of money<br/>RS_ERROR_USER_DISABLED when user is banned or inactive<br/>RS_ERROR_INVALID_SIGNATURE - when signature doesn't match<br/>RS_ERROR_TOKEN_EXPIRED - when a new token exists (this rule applies only for /wallet/bet)<br/>RS_ERROR_WRONG_SYNTAX - message can't be decoded to JSON<br/>RS_ERROR_WRONG_TYPES - i.e. when a type should be integer and came as string<br/>RS_ERROR_DUPLICATE_TRANSACTION - when the same transaction_uuid appears but for a different user, round and game, otherwise returns RS_OK<br/>RS_ERROR_TRANSACTION_DOES_NOT_EXIST - when doing a 'win' transaction and the 'bet' transaction id doesn't exist<br/>RS_ERROR_TRANSACTION_ROLLED_BACK - when a 'win' transaction happens in name of a rolled back transaction (when receiving a 'rollback' replies with 'RS_OK'<br/>RS_ERROR_BET_LIMIT_EXCEEDED - when the user exceeded its limits

const (
	RSERRORBETLIMITEXCEEDED        Status = "RS_ERROR_BET_LIMIT_EXCEEDED"
	RSERRORDUPLICATETRANSACTION    Status = "RS_ERROR_DUPLICATE_TRANSACTION"
	RSERRORINVALIDGAME             Status = "RS_ERROR_INVALID_GAME"
	RSERRORINVALIDSIGNATURE        Status = "RS_ERROR_INVALID_SIGNATURE"
	RSERRORINVALIDTOKEN            Status = "RS_ERROR_INVALID_TOKEN"
	RSERRORNOTENOUGHMONEY          Status = "RS_ERROR_NOT_ENOUGH_MONEY"
	RSERRORTIMEOUT                 Status = "RS_ERROR_TIMEOUT"
	RSERRORTOKENEXPIRED            Status = "RS_ERROR_TOKEN_EXPIRED"
	RSERRORTRANSACTIONDOESNOTEXIST Status = "RS_ERROR_TRANSACTION_DOES_NOT_EXIST"
	RSERRORTRANSACTIONROLLEDBACK   Status = "RS_ERROR_TRANSACTION_ROLLED_BACK"
	RSERRORUNKNOWN                 Status = "RS_ERROR_UNKNOWN"
	RSERRORUSERDISABLED            Status = "RS_ERROR_USER_DISABLED"
	RSERRORWRONGCURRENCY           Status = "RS_ERROR_WRONG_CURRENCY"
	RSERRORWRONGSYNTAX             Status = "RS_ERROR_WRONG_SYNTAX"
	RSERRORWRONGTYPES              Status = "RS_ERROR_WRONG_TYPES"
	RSOK                           Status = "RS_OK"
)

Defines values for Status.

type StrictHandlerFunc

type StrictHandlerFunc func(ctx *fiber.Ctx, args interface{}) (interface{}, error)

type StrictMiddlewareFunc

type StrictMiddlewareFunc func(f StrictHandlerFunc, operationID string) StrictHandlerFunc

type StrictServerInterface

type StrictServerInterface interface {

	// (POST /wallet/balance)
	Walletbalance(ctx context.Context, request WalletbalanceRequestObject) (WalletbalanceResponseObject, error)

	// (POST /wallet/bet)
	Walletbet(ctx context.Context, request WalletbetRequestObject) (WalletbetResponseObject, error)

	// (POST /wallet/check)
	Walletcheck(ctx context.Context, request WalletcheckRequestObject) (WalletcheckResponseObject, error)

	// (POST /wallet/rollback)
	Walletrollback(ctx context.Context, request WalletrollbackRequestObject) (WalletrollbackResponseObject, error)

	// (POST /wallet/win)
	Transactionwin(ctx context.Context, request TransactionwinRequestObject) (TransactionwinResponseObject, error)
}

StrictServerInterface represents all server handlers.

type SubPartnerId

type SubPartnerId = string

SubPartnerId Id of Operator's sub-partner (brand, whitelabel, site, etc.) which uses same integration and credentials as Operator.

type SupplierUser

type SupplierUser = string

SupplierUser The name of the user in Provider's system (in case Operator needs to find user in Provder's back office or report problem with the user). If value is NULL, the Operator can search for their own user_id.

type Token

type Token = string

Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.

type TransactionUuid

type TransactionUuid = string

TransactionUuid Unique wallet transaction.

type Transactionwin200JSONResponse

type Transactionwin200JSONResponse BalanceResponse

func (Transactionwin200JSONResponse) VisitTransactionwinResponse

func (response Transactionwin200JSONResponse) VisitTransactionwinResponse(ctx *fiber.Ctx) error

type TransactionwinJSONRequestBody

type TransactionwinJSONRequestBody = WalletWinBody

TransactionwinJSONRequestBody defines body for Transactionwin for application/json ContentType.

type TransactionwinParams

type TransactionwinParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key sent to operator.
	XAuthSignature string        `json:"X-Auth-Signature"`
	XMsgTimestamp  *MsgTimestamp `json:"X-Msg-Timestamp,omitempty"`
}

TransactionwinParams defines parameters for Transactionwin.

type TransactionwinRequestObject

type TransactionwinRequestObject struct {
	Params TransactionwinParams
	Body   *TransactionwinJSONRequestBody
}

type TransactionwinResponseObject

type TransactionwinResponseObject interface {
	VisitTransactionwinResponse(ctx *fiber.Ctx) error
}

type User

type User = string

User Unique User ID in the Operator�s system. In case of DEMO gameplay, this parameter may be omitted.

type WalletBalanceBody

type WalletBalanceBody struct {
	// GameCode Unique Game Code on Caleta system. Can be obtained from `/api/game/list` endpoint. This variable intends to replace `game_id`.
	GameCode GameCode `json:"game_code"`

	// GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)
	GameId *GameId `json:"game_id,omitempty"`

	// RequestUuid Standard 16-byte UUID. This id can be seen as network layer action. An id of an action that is generated for each our call to Operator. Used to sync Hub88 and Operator sides for debugging purposes. Operator has to respond with the same request_uuid as the one that was received in request.
	RequestUuid RequestUuid `json:"request_uuid"`

	// SupplierUser The name of the user in Provider's system (in case Operator needs to find user in Provder's back office or report problem with the user). If value is NULL, the Operator can search for their own user_id.
	SupplierUser SupplierUser `json:"supplier_user"`

	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token Token `json:"token"`
}

WalletBalanceBody defines model for wallet_balance_body.

type WalletBetBody

type WalletBetBody struct {
	// Amount We use integers to represent the amount of money. To convert real float value to integer we multiply it by 100000. Example: $3.56 must be represented as 356000
	Amount MoneyAmount `json:"amount"`

	// Bet Field for metadata related to transaction, such as type of bet, value, time, etc. Differs from game to game. Not relevant for transaction processing procedure but could be useful for statistics or activity backtracking.
	Bet *string `json:"bet,omitempty"`

	// CampaignUuid Each Free Bet campaign contains an unique identifier on Caleta side. Campaings holds information of game where Free Bet will happen, total of spins, bet value and period of campaign.
	CampaignUuid *CampaignUuid `json:"campaign_uuid,omitempty"`

	// Currency ISO 4217 currency code. Following enum contains all currencies supported by our system. Existing of currency in this list doesn't mean that all providers support native game play with it. Please contact us to know which provider supports which currencies.
	Currency Currency `json:"currency"`

	// GameCode Unique Game Code on Caleta system. Can be obtained from `/api/game/list` endpoint. This variable intends to replace `game_id`.
	GameCode GameCode `json:"game_code"`

	// GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)
	GameId *GameId `json:"game_id,omitempty"`

	// IsFree Flag which shows that transaction was generated by a promotional tool (FreeSpins, etc). Usually, these transactions are credited to bonus wallets (if available).
	IsFree IsFree `json:"is_free"`

	// RequestUuid Standard 16-byte UUID. This id can be seen as network layer action. An id of an action that is generated for each our call to Operator. Used to sync Hub88 and Operator sides for debugging purposes. Operator has to respond with the same request_uuid as the one that was received in request.
	RequestUuid RequestUuid `json:"request_uuid"`

	// RewardUuid This holds the uuid of a reward given to a player on Caleta side. Rewards holds information about which campaigns belong, player, quantity left of Free Bets.
	RewardUuid *RewardUuid `json:"reward_uuid,omitempty"`

	// Round Game round id. Used to relate all bets and wins in one round. All transactions related to the same round will have the same value in this field. It's unique through whole system.
	Round Round `json:"round"`

	// RoundClosed Denotes when the round is closed
	RoundClosed RoundClosed `json:"round_closed"`

	// SupplierUser The name of the user in Provider's system (in case Operator needs to find user in Provder's back office or report problem with the user). If value is NULL, the Operator can search for their own user_id.
	SupplierUser SupplierUser `json:"supplier_user"`

	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token Token `json:"token"`

	// TransactionUuid Unique wallet transaction.
	TransactionUuid TransactionUuid `json:"transaction_uuid"`
}

WalletBetBody defines model for wallet_bet_body.

type WalletCheckBody

type WalletCheckBody struct {
	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token Token `json:"token"`
}

WalletCheckBody defines model for wallet_check_body.

type WalletRollbackBody

type WalletRollbackBody struct {
	// GameCode Unique Game Code on Caleta system. Can be obtained from `/api/game/list` endpoint. This variable intends to replace `game_id`.
	GameCode GameCode `json:"game_code"`

	// GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)
	GameId *GameId `json:"game_id,omitempty"`

	// IsFree Flag which shows that transaction was generated by a promotional tool (FreeSpins, etc). Usually, these transactions are credited to bonus wallets (if available).
	IsFree *IsFree `json:"is_free,omitempty"`

	// ReferenceTransactionUuid Unique identifier of the transaction that this transaction is referencing. In case of rollback, this field will contain transaction_uuid of the transaction which needs to be rolled back. In case of win, there will be transaction_uuid of the bet to which this win is related.
	ReferenceTransactionUuid string `json:"reference_transaction_uuid"`

	// RequestUuid Standard 16-byte UUID. This id can be seen as network layer action. An id of an action that is generated for each our call to Operator. Used to sync Hub88 and Operator sides for debugging purposes. Operator has to respond with the same request_uuid as the one that was received in request.
	RequestUuid RequestUuid `json:"request_uuid"`

	// Round Game round id. Used to relate all bets and wins in one round. All transactions related to the same round will have the same value in this field. It's unique through whole system.
	Round Round `json:"round"`

	// RoundClosed Denotes when the round is closed
	RoundClosed RoundClosed `json:"round_closed"`

	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token Token `json:"token"`

	// TransactionUuid Unique wallet transaction.
	TransactionUuid TransactionUuid `json:"transaction_uuid"`

	// User Unique User ID in the Operator�s system. In case of DEMO gameplay, this parameter may be omitted.
	User *User `json:"user,omitempty"`
}

WalletRollbackBody defines model for wallet_rollback_body.

type WalletService added in v0.6.0

type WalletService struct {
	PamClient pam.PamClient
	APIClient API
}

func NewWalletService added in v0.6.0

func NewWalletService(pamClient pam.PamClient, apiClient API) *WalletService

NewService Create new caleta wallet service

func (*WalletService) Transactionwin added in v0.6.0

@Id CaletaWin @Summary Win @Description Called when the user wins (credit). @Tags Caleta @Accept json @Produce json @Param req body TransactionwinJSONRequestBody true "Request body" @Param X-Auth-Signature header string true "Signature for request" @Success 200 {object} Transactionwin200JSONResponse @Failure 400 {object} Transactionwin200JSONResponse @Router /providers/caleta/wallet/win [post]

func (*WalletService) Walletbalance added in v0.6.0

@Id CaletaBalance @Summary Balance @Description Should return wallet balance for current player. @Tags Caleta @Accept json @Produce json @Param req body WalletbalanceJSONRequestBody true "Request body" @Param X-Auth-Signature header string true "Signature for request" @Success 200 {object} Walletbalance200JSONResponse @Failure 400 {object} Walletbalance200JSONResponse @Router /providers/caleta/wallet/balance [post]

func (*WalletService) Walletbet added in v0.6.0

@Id CaletaBet @Summary Bet @Description Called when the user places a bet (debit). @Tags Caleta @Accept json @Produce json @Param req body WalletbetJSONRequestBody true "Request body" @Param X-Auth-Signature header string true "Signature for request" @Success 200 {object} Walletbet200JSONResponse @Failure 400 {object} Walletbet200JSONResponse @Router /providers/caleta/wallet/bet [post]

func (*WalletService) Walletcheck added in v0.6.0

@Id CaletaCheck @Summary Check @Description OPTIONAL - Change the initial token received for a new one that will be used on wallet transactions. @Tags Caleta @Accept json @Produce json @Param req body WalletcheckJSONRequestBody true "Request body" @Param X-Auth-Signature header string true "Signature for request" @Success 200 {object} Walletcheck200JSONResponse @Failure 400 {object} Walletcheck200JSONResponse @Router /providers/caleta/wallet/check [post]

func (*WalletService) Walletrollback added in v0.6.0

@Id CaletaRollback @Summary Rollback @Description Called when there is need to roll back the effect of the referenced transaction. @Tags Caleta @Accept json @Produce json @Param req body WalletrollbackJSONRequestBody true "Request body" @Param X-Auth-Signature header string true "Signature for request" @Success 200 {object} Walletrollback200JSONResponse @Failure 400 {object} Walletrollback200JSONResponse @Router /providers/caleta/wallet/rollback [post]

type WalletWinBody

type WalletWinBody struct {
	// Amount We use integers to represent the amount of money. To convert real float value to integer we multiply it by 100000. Example: $3.56 must be represented as 356000
	Amount MoneyAmount `json:"amount"`

	// Bet Field for metadata related to transaction, such as type of bet, value, time, etc. Differs from game to game. Not relevant for transaction processing procedure but could be useful for statistics or activity backtracking.
	Bet *string `json:"bet,omitempty"`

	// CampaignUuid Each Free Bet campaign contains an unique identifier on Caleta side. Campaings holds information of game where Free Bet will happen, total of spins, bet value and period of campaign.
	CampaignUuid *CampaignUuid `json:"campaign_uuid,omitempty"`

	// Currency ISO 4217 currency code. Following enum contains all currencies supported by our system. Existing of currency in this list doesn't mean that all providers support native game play with it. Please contact us to know which provider supports which currencies.
	Currency Currency `json:"currency"`

	// GameCode Unique Game Code on Caleta system. Can be obtained from `/api/game/list` endpoint. This variable intends to replace `game_id`.
	GameCode GameCode `json:"game_code"`

	// GameId Deprecated: Use `game_code` instead.<br/>Unique game ID Caleta system. Can be obtained from `/api/game/list` endpoint.<br/>Note: this value may change from each server (staging, production)
	GameId *GameId `json:"game_id,omitempty"`

	// IsFree Flag which shows that transaction was generated by a promotional tool (FreeSpins, etc). Usually, these transactions are credited to bonus wallets (if available).
	IsFree IsFree `json:"is_free"`

	// JackpotWin This field is included if a jackpot win occurred. The reported value indicate how much of the win amount was contributed to from winning the jackpot. This value is represented as an integer similar to amount.
	JackpotWin *int `json:"jackpot_win,omitempty"`

	// ReferenceTransactionUuid Unique identifier of the transaction that this transaction is referencing. In case of rollback, this field will contain transaction_uuid of the transaction which needs to be rolled back. In case of win, there will be transaction_uuid of the bet to which this win is related.
	ReferenceTransactionUuid string `json:"reference_transaction_uuid"`

	// RequestUuid Standard 16-byte UUID. This id can be seen as network layer action. An id of an action that is generated for each our call to Operator. Used to sync Hub88 and Operator sides for debugging purposes. Operator has to respond with the same request_uuid as the one that was received in request.
	RequestUuid RequestUuid `json:"request_uuid"`

	// RewardUuid This holds the uuid of a reward given to a player on Caleta side. Rewards holds information about which campaigns belong, player, quantity left of Free Bets.
	RewardUuid *RewardUuid `json:"reward_uuid,omitempty"`

	// Round Game round id. Used to relate all bets and wins in one round. All transactions related to the same round will have the same value in this field. It's unique through whole system.
	Round Round `json:"round"`

	// RoundClosed Denotes when the round is closed
	RoundClosed RoundClosed `json:"round_closed"`

	// SupplierUser The name of the user in Provider's system (in case Operator needs to find user in Provder's back office or report problem with the user). If value is NULL, the Operator can search for their own user_id.
	SupplierUser SupplierUser `json:"supplier_user"`

	// Token Operator's back end generates a token associated with the User, game, his or her current currency and maybe other parameters depending on the Operator's preferences. The token acts as an ID parameter for the game session. It is important that the currency is not changed during the current game session. If the User changes the currency or display unit, the Operator's backend needs to generate a new token and re-open the game with new token. In case of DEMO gameplay, this parameter may be omitted.<br/>A token should be valid for all bet transactions until a new one is generated, expired tokens should continue be valid for Win/Rollback transactions if is related to a previous existing bet.
	Token Token `json:"token"`

	// TransactionUuid Unique wallet transaction.
	TransactionUuid TransactionUuid `json:"transaction_uuid"`
}

WalletWinBody defines model for wallet_win_body.

type Walletbalance200JSONResponse

type Walletbalance200JSONResponse BalanceResponse

func (Walletbalance200JSONResponse) VisitWalletbalanceResponse

func (response Walletbalance200JSONResponse) VisitWalletbalanceResponse(ctx *fiber.Ctx) error

type WalletbalanceJSONRequestBody

type WalletbalanceJSONRequestBody = WalletBalanceBody

WalletbalanceJSONRequestBody defines body for Walletbalance for application/json ContentType.

type WalletbalanceParams

type WalletbalanceParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key sent to operator.
	XAuthSignature string `json:"X-Auth-Signature"`
}

WalletbalanceParams defines parameters for Walletbalance.

type WalletbalanceRequestObject

type WalletbalanceRequestObject struct {
	Params WalletbalanceParams
	Body   *WalletbalanceJSONRequestBody
}

type WalletbalanceResponseObject

type WalletbalanceResponseObject interface {
	VisitWalletbalanceResponse(ctx *fiber.Ctx) error
}

type Walletbet200JSONResponse

type Walletbet200JSONResponse BalanceResponse

func (Walletbet200JSONResponse) VisitWalletbetResponse

func (response Walletbet200JSONResponse) VisitWalletbetResponse(ctx *fiber.Ctx) error

type WalletbetJSONRequestBody

type WalletbetJSONRequestBody = WalletBetBody

WalletbetJSONRequestBody defines body for Walletbet for application/json ContentType.

type WalletbetParams

type WalletbetParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key sent to operator.
	XAuthSignature string        `json:"X-Auth-Signature"`
	XMsgTimestamp  *MsgTimestamp `json:"X-Msg-Timestamp,omitempty"`
}

WalletbetParams defines parameters for Walletbet.

type WalletbetRequestObject

type WalletbetRequestObject struct {
	Params WalletbetParams
	Body   *WalletbetJSONRequestBody
}

type WalletbetResponseObject

type WalletbetResponseObject interface {
	VisitWalletbetResponse(ctx *fiber.Ctx) error
}

type Walletcheck200JSONResponse

type Walletcheck200JSONResponse InlineResponse2001

func (Walletcheck200JSONResponse) VisitWalletcheckResponse

func (response Walletcheck200JSONResponse) VisitWalletcheckResponse(ctx *fiber.Ctx) error

type WalletcheckJSONRequestBody

type WalletcheckJSONRequestBody = WalletCheckBody

WalletcheckJSONRequestBody defines body for Walletcheck for application/json ContentType.

type WalletcheckParams

type WalletcheckParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key associated with provided operator_id.
	XAuthSignature string `json:"X-Auth-Signature"`
}

WalletcheckParams defines parameters for Walletcheck.

type WalletcheckRequestObject

type WalletcheckRequestObject struct {
	Params WalletcheckParams
	Body   *WalletcheckJSONRequestBody
}

type WalletcheckResponseObject

type WalletcheckResponseObject interface {
	VisitWalletcheckResponse(ctx *fiber.Ctx) error
}

type Walletrollback200JSONResponse

type Walletrollback200JSONResponse BalanceResponse

func (Walletrollback200JSONResponse) VisitWalletrollbackResponse

func (response Walletrollback200JSONResponse) VisitWalletrollbackResponse(ctx *fiber.Ctx) error

type WalletrollbackJSONRequestBody

type WalletrollbackJSONRequestBody = WalletRollbackBody

WalletrollbackJSONRequestBody defines body for Walletrollback for application/json ContentType.

type WalletrollbackParams

type WalletrollbackParams struct {
	// XAuthSignature RSA-SHA256 is used to sign the request body using the private key. The signature is validated using the public key sent to operator.
	XAuthSignature string        `json:"X-Auth-Signature"`
	XMsgTimestamp  *MsgTimestamp `json:"X-Msg-Timestamp,omitempty"`
}

WalletrollbackParams defines parameters for Walletrollback.

type WalletrollbackRequestObject

type WalletrollbackRequestObject struct {
	Params WalletrollbackParams
	Body   *WalletrollbackJSONRequestBody
}

type WalletrollbackResponseObject

type WalletrollbackResponseObject interface {
	VisitWalletrollbackResponse(ctx *fiber.Ctx) error
}

Directories

Path Synopsis
Package auth defines auth helpers
Package auth defines auth helpers

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL