Six4Win.WebApi

<back to all web services

GetFeed

The following routes are available for this service:
All Verbs/qry/feed
package dtos

import (
	"time"
)

type RoundStatus int

const (
	RoundStatusPending    RoundStatus = 0
	RoundStatusInProgress RoundStatus = 1
	RoundStatusEnded      RoundStatus = 2
)

type CountdownConfiguration struct {
	LockdownStepFromEnd       int `json:"lockdownStepFromEnd,omitempty"`
	AssertLockdownStepFromEnd int `json:"assertLockdownStepFromEnd,omitempty"`
}

type DrawConfiguration struct {
	IntroIntervalInMs     int `json:"introIntervalInMs,omitempty"`
	AnimationIntervalInMs int `json:"animationIntervalInMs,omitempty"`
	OutroIntervalInMs     int `json:"outroIntervalInMs,omitempty"`
}

type RTPStrategies int

const (
	RTPStrategiesRNG         RTPStrategies = 0
	RTPStrategiesAccumulator RTPStrategies = 1
)

type HappyHourConfiguration struct {
	IsHappyHour                                        bool    `json:"isHappyHour,omitempty"`
	OddsModifier                                       float64 `json:"oddsModifier,omitempty"`
	RoundPoolBonusPct                                  float64 `json:"roundPoolBonusPct,omitempty"`
	UseOnlyRoundPoolWithNoOptimizations                bool    `json:"useOnlyRoundPoolWithNoOptimizations,omitempty"`
	OverrideSyphonCombinationCountPerRoundThreshold    bool    `json:"overrideSyphonCombinationCountPerRoundThreshold,omitempty"`
	SyphonCombinationCountPerRoundThresholdPctOverride float64 `json:"syphonCombinationCountPerRoundThresholdPctOverride,omitempty"`
}

type RoundConfiguration struct {
	Coefficients               *RecordList[float32]    `json:"coefficients,omitempty"`
	IsDoubleTripleActive       bool                    `json:"isDoubleTripleActive,omitempty"`
	IsJackpot5Active           bool                    `json:"isJackpot5Active,omitempty"`
	CountdownDurationInSeconds int                     `json:"countdownDurationInSeconds,omitempty"`
	CountdownConfiguration     *CountdownConfiguration `json:"countdownConfiguration,omitempty"`
	DrawConfiguration          *DrawConfiguration      `json:"drawConfiguration,omitempty"`
	ResultsDurationInSeconds   int                     `json:"resultsDurationInSeconds,omitempty"`
	RtpStrategy                RTPStrategies           `json:"rtpStrategy,omitempty"`
	HappyHourConfiguration     *HappyHourConfiguration `json:"happyHourConfiguration,omitempty"`
}

type BettingApp struct {
	Name    *string `json:"name,omitempty"`
	Version *string `json:"version,omitempty"`
}

type Ref struct {
	Id  string `json:"id"`
	Val string `json:"val"`
}

type RefEx struct {
	Ref
	Data RecordDictionary[string, string] `json:"data"`
}

type Origin struct {
	Application   *BettingApp `json:"application,omitempty"`
	Ip            *string     `json:"ip,omitempty"`
	Organization  *RefEx      `json:"organization,omitempty"`
	Region        *Ref        `json:"region,omitempty"`
	LocationGroup *Ref        `json:"locationGroup,omitempty"`
	Location      *RefEx      `json:"location,omitempty"`
	Device        *RefEx      `json:"device,omitempty"`
	Clerk         *Ref        `json:"clerk,omitempty"`
}

type JackPot5Winner struct {
	BetId            *string           `json:"betId,omitempty"`
	NrOfCombinations int               `json:"nrOfCombinations,omitempty"`
	WinningsAmount   float64           `json:"winningsAmount,omitempty"`
	Origin           *Origin           `json:"origin,omitempty"`
	Bettor           *Ref              `json:"bettor,omitempty"`
	Payload          map[string]string `json:"payload,omitempty"`
}

type Jackpot5Info struct {
	IsHit             bool             `json:"isHit,omitempty"`
	AmountAccumulated float64          `json:"amountAccumulated,omitempty"`
	AmountAwarded     float64          `json:"amountAwarded,omitempty"`
	NrOfWinners       int              `json:"nrOfWinners,omitempty"`
	JackPot5Winners   []JackPot5Winner `json:"jackPot5Winners,omitempty"`
}

type SuperWinWinner struct {
	IsDrawn                     bool      `json:"isDrawn,omitempty"`
	DrawnAtUtc                  time.Time `json:"drawnAtUtc,omitempty"`
	RoundId                     *string   `json:"roundId,omitempty"`
	BetId                       *string   `json:"betId,omitempty"`
	SlipId                      *string   `json:"slipId,omitempty"`
	Origin                      *Origin   `json:"origin,omitempty"`
	Bettor                      *Ref      `json:"bettor,omitempty"`
	Code                        *string   `json:"code,omitempty"`
	Amount                      float64   `json:"amount,omitempty"`
	LocationAddressOrBettorInfo *string   `json:"locationAddressOrBettorInfo,omitempty"`
}

type SuperWinInfo struct {
	IsActive         bool            `json:"isActive,omitempty"`
	Winner           *SuperWinWinner `json:"winner,omitempty"`
	AvailableAmount  float64         `json:"availableAmount,omitempty"`
	AllPrizesAwarded bool            `json:"allPrizesAwarded,omitempty"`
}

type WinnerByCode struct {
	RoundId                     *string   `json:"roundId,omitempty"`
	DrawnAtUtc                  time.Time `json:"drawnAtUtc,omitempty"`
	SlipId                      *string   `json:"slipId,omitempty"`
	BetId                       *string   `json:"betId,omitempty"`
	Code                        *string   `json:"code,omitempty"`
	Amount                      float64   `json:"amount,omitempty"`
	Origin                      *Origin   `json:"origin,omitempty"`
	Bettor                      *Ref      `json:"bettor,omitempty"`
	LocationAddressOrBettorInfo *string   `json:"locationAddressOrBettorInfo,omitempty"`
}

type GlobalCodePotInfo struct {
	IsActive     bool          `json:"isActive,omitempty"`
	IsDrawn      bool          `json:"isDrawn,omitempty"`
	Winner       *WinnerByCode `json:"winner,omitempty"`
	InertCode    *string       `json:"inertCode,omitempty"`
	Accumulation float64       `json:"accumulation,omitempty"`
}

type Stages int

const (
	StagesNone       Stages = 0
	StagesCountdown  Stages = 1
	StagesProcessing Stages = 2
	StagesDraw       Stages = 3
	StagesResults    Stages = 4
)

type RoundProgress struct {
	Stage        Stages    `json:"stage,omitempty"`
	Step         int       `json:"step,omitempty"`
	Steps        int       `json:"steps,omitempty"`
	UtcTimestamp time.Time `json:"utcTimestamp,omitempty"`
}

type Round struct {
	Id                *string             `json:"id,omitempty"`
	CreatedAt         time.Time           `json:"createdAt,omitempty"`
	UpdatedAt         time.Time           `json:"updatedAt,omitempty"`
	ShouldStartAtUtc  time.Time           `json:"shouldStartAtUtc,omitempty"`
	StartedAtUtc      time.Time           `json:"startedAtUtc,omitempty"`
	Status            RoundStatus         `json:"status,omitempty"`
	Configuration     *RoundConfiguration `json:"configuration,omitempty"`
	Sequence          *string             `json:"sequence,omitempty"`
	Jackpot5Info      *Jackpot5Info       `json:"jackpot5Info,omitempty"`
	SuperWinInfo      *SuperWinInfo       `json:"superWinInfo,omitempty"`
	GlobalCodePotInfo *GlobalCodePotInfo  `json:"globalCodePotInfo,omitempty"`
	Progress          *RoundProgress      `json:"progress,omitempty"`
	IsLocked          bool                `json:"isLocked,omitempty"`
	IsCalculated      bool                `json:"isCalculated,omitempty"`
}

type Feed struct {
	Id                *string            `json:"id,omitempty"`
	Round             *Round             `json:"round,omitempty"`
	LastJackpot5Info  *Jackpot5Info      `json:"lastJackpot5Info,omitempty"`
	SuperWinInfo      *SuperWinInfo      `json:"superWinInfo,omitempty"`
	GlobalCodePotInfo *GlobalCodePotInfo `json:"globalCodePotInfo,omitempty"`
}

type GetFeed struct {
}

type RecordList[T any] []T

type RecordDictionary[TKey any, TVal any] map[TKey]TVal

Go GetFeed DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /qry/feed HTTP/1.1 
Host: s4w2.api.bettor.webhop.biz 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	id: String,
	round: 
	{
		id: String,
		createdAt: 0001-01-01,
		updatedAt: 0001-01-01,
		shouldStartAtUtc: 0001-01-01,
		startedAtUtc: 0001-01-01,
		status: 0,
		configuration: 
		{
			coefficients: 
			[
				0
			],
			isDoubleTripleActive: False,
			isJackpot5Active: False,
			countdownDurationInSeconds: 0,
			countdownConfiguration: 
			{
				lockdownStepFromEnd: 0,
				assertLockdownStepFromEnd: 0
			},
			drawConfiguration: 
			{
				introIntervalInMs: 0,
				animationIntervalInMs: 0,
				outroIntervalInMs: 0
			},
			resultsDurationInSeconds: 0,
			rtpStrategy: 0,
			happyHourConfiguration: 
			{
				isHappyHour: False,
				oddsModifier: 0,
				roundPoolBonusPct: 0,
				useOnlyRoundPoolWithNoOptimizations: False,
				overrideSyphonCombinationCountPerRoundThreshold: False,
				syphonCombinationCountPerRoundThresholdPctOverride: 0
			}
		},
		sequence: String,
		jackpot5Info: 
		{
			isHit: False,
			amountAccumulated: 0,
			amountAwarded: 0,
			nrOfWinners: 0,
			jackPot5Winners: 
			[
				{
					betId: String,
					nrOfCombinations: 0,
					winningsAmount: 0,
					origin: 
					{
						application: 
						{
							name: String,
							version: String
						},
						ip: String,
						organization: 
						{
							data: 
							{
								String: String
							},
							id: String,
							val: String
						},
						region: 
						{
							id: String,
							val: String
						},
						locationGroup: 
						{
							id: String,
							val: String
						},
						location: 
						{
							data: 
							{
								String: String
							},
							id: String,
							val: String
						},
						device: 
						{
							data: 
							{
								String: String
							},
							id: String,
							val: String
						},
						clerk: 
						{
							id: String,
							val: String
						}
					},
					bettor: 
					{
						id: String,
						val: String
					},
					payload: 
					{
						String: String
					}
				}
			]
		},
		superWinInfo: 
		{
			isActive: False,
			winner: 
			{
				isDrawn: False,
				drawnAtUtc: 0001-01-01,
				roundId: String,
				betId: String,
				slipId: String,
				origin: 
				{
					application: 
					{
						name: String,
						version: String
					},
					ip: String,
					organization: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					region: 
					{
						id: String,
						val: String
					},
					locationGroup: 
					{
						id: String,
						val: String
					},
					location: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					device: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					clerk: 
					{
						id: String,
						val: String
					}
				},
				bettor: 
				{
					id: String,
					val: String
				},
				code: String,
				amount: 0,
				locationAddressOrBettorInfo: String
			},
			availableAmount: 0,
			allPrizesAwarded: False
		},
		globalCodePotInfo: 
		{
			isActive: False,
			isDrawn: True,
			winner: 
			{
				roundId: String,
				drawnAtUtc: 0001-01-01,
				slipId: String,
				betId: String,
				code: String,
				amount: 0,
				origin: 
				{
					application: 
					{
						name: String,
						version: String
					},
					ip: String,
					organization: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					region: 
					{
						id: String,
						val: String
					},
					locationGroup: 
					{
						id: String,
						val: String
					},
					location: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					device: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					clerk: 
					{
						id: String,
						val: String
					}
				},
				bettor: 
				{
					id: String,
					val: String
				},
				locationAddressOrBettorInfo: String
			},
			inertCode: String,
			accumulation: 0
		},
		progress: 
		{
			stage: 0,
			step: 0,
			steps: 0,
			utcTimestamp: 0001-01-01
		},
		isLocked: False,
		isCalculated: False
	},
	lastJackpot5Info: 
	{
		isHit: False,
		amountAccumulated: 0,
		amountAwarded: 0,
		nrOfWinners: 0,
		jackPot5Winners: 
		[
			{
				betId: String,
				nrOfCombinations: 0,
				winningsAmount: 0,
				origin: 
				{
					application: 
					{
						name: String,
						version: String
					},
					ip: String,
					organization: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					region: 
					{
						id: String,
						val: String
					},
					locationGroup: 
					{
						id: String,
						val: String
					},
					location: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					device: 
					{
						data: 
						{
							String: String
						},
						id: String,
						val: String
					},
					clerk: 
					{
						id: String,
						val: String
					}
				},
				bettor: 
				{
					id: String,
					val: String
				},
				payload: 
				{
					String: String
				}
			}
		]
	},
	superWinInfo: 
	{
		isActive: False,
		winner: 
		{
			isDrawn: False,
			drawnAtUtc: 0001-01-01,
			roundId: String,
			betId: String,
			slipId: String,
			origin: 
			{
				application: 
				{
					name: String,
					version: String
				},
				ip: String,
				organization: 
				{
					data: 
					{
						String: String
					},
					id: String,
					val: String
				},
				region: 
				{
					id: String,
					val: String
				},
				locationGroup: 
				{
					id: String,
					val: String
				},
				location: 
				{
					data: 
					{
						String: String
					},
					id: String,
					val: String
				},
				device: 
				{
					data: 
					{
						String: String
					},
					id: String,
					val: String
				},
				clerk: 
				{
					id: String,
					val: String
				}
			},
			bettor: 
			{
				id: String,
				val: String
			},
			code: String,
			amount: 0,
			locationAddressOrBettorInfo: String
		},
		availableAmount: 0,
		allPrizesAwarded: False
	},
	globalCodePotInfo: 
	{
		isActive: False,
		isDrawn: True,
		winner: 
		{
			roundId: String,
			drawnAtUtc: 0001-01-01,
			slipId: String,
			betId: String,
			code: String,
			amount: 0,
			origin: 
			{
				application: 
				{
					name: String,
					version: String
				},
				ip: String,
				organization: 
				{
					data: 
					{
						String: String
					},
					id: String,
					val: String
				},
				region: 
				{
					id: String,
					val: String
				},
				locationGroup: 
				{
					id: String,
					val: String
				},
				location: 
				{
					data: 
					{
						String: String
					},
					id: String,
					val: String
				},
				device: 
				{
					data: 
					{
						String: String
					},
					id: String,
					val: String
				},
				clerk: 
				{
					id: String,
					val: String
				}
			},
			bettor: 
			{
				id: String,
				val: String
			},
			locationAddressOrBettorInfo: String
		},
		inertCode: String,
		accumulation: 0
	}
}