| All Verbs | /qry/rounds/draw/diagnostics |
|---|
import Foundation
import ServiceStack
public class GetDrawDignostics : Codable
{
public var id:String
required public init(){}
}
public class DrawDiagnostics : Codable
{
public var id:String
public var initializationInfo:Initialization
public var sequenceGenerationInfo:SequenceGeneration
public var bestFitFinderInfo:BestFitFinder
public var purgerInfo:Purger
public var duration:Int
public var stimulationResponses:[StimulationResponse]
public var localCodePot:LocalCodePotInfo
public var superWin:SuperWinInfo
public var happyHour:HappyHourInfo
public var reasoning:String
public var configuration:AccumulatorConfiguration
public var syphonInfo:SyphonInfo
required public init(){}
}
public class Initialization : Codable
{
public var dataLoadDuration:Int
public var betsCollectionsCreationDuration:Int
public var combinationsOccuranceLookupInitializationDuration:Int
required public init(){}
}
public class SequenceGeneration : Codable
{
public var nrOfThreads:Int
public var nrOfResultsProbed:Int
public var duration:Int
public var avgSinglePassDuration:Int
required public init(){}
}
public class BestFitFinder : Codable
{
public var targetAmount:Double
public var awardedAmount:Double
public var deviation:Double
public var deviationPct:Double
public var sequenceResultType:String
public var isJackPot5Drawn:Bool
public var filteringPeriod:Int
public var winCountOrder:SortingOrder
public var minAmount:Double
public var maxAmount:Double
required public init(){}
}
public enum SortingOrder : Int, Codable
{
case None = 0
case Ascending = 1
case Descending = 2
}
public class Purger : Codable
{
public var prevalentStake:Double
public var poolPurger:String
public var qualifiedPools:[QualifiedPool]
required public init(){}
}
public class QualifiedPool : Codable
{
public var id:Int
public var name:String
public var coefficient:Double
public var availableAmount:Double
public var awardedAmount:Double
public var targetBet:Bet
required public init(){}
}
public class Bet : Codable
{
public var isFound:Bool
public var betId:String
public var slipId:String
public var combStake:String
required public init(){}
}
public class StimulationResponse : Codable
{
public var stimulationId:String
public var status:ResponseStatus
public var failureReason:String
public var slipId:String
public var betId:String
public var amountAwarded:Double
required public init(){}
}
public class LocalCodePotInfo : Codable
{
public var isActive:Bool
public var current:CurrentRoundInfo
public var winners:[WinnerByCode]
required public init(){}
}
public class CurrentRoundInfo : Codable
{
public var roundId:String
public var amount:Double
public var inertCode:String
required public init(){}
}
public class WinnerByCode : Codable
{
public var roundId:String
public var drawnAtUtc:Date
public var slipId:String
public var betId:String
public var code:String
public var amount:Double
public var origin:Origin
public var bettor:Ref
public var locationAddressOrBettorInfo:String
required public init(){}
}
public class Origin : Codable
{
public var application:BettingApp
public var ip:String
public var organization:RefEx
public var region:Ref
public var locationGroup:Ref
public var location:RefEx
public var device:RefEx
public var clerk:Ref
required public init(){}
}
public class BettingApp : Codable
{
public var name:String
public var version:String
required public init(){}
}
public class RefEx : Ref
{
public var data:RecordDictionary<String, String>
required public init(){ super.init() }
private enum CodingKeys : String, CodingKey {
case data
}
required public init(from decoder: Decoder) throws {
try super.init(from: decoder)
let container = try decoder.container(keyedBy: CodingKeys.self)
data = try container.decodeIfPresent(RecordDictionary<String, String>.self, forKey: .data)
}
public override func encode(to encoder: Encoder) throws {
try super.encode(to: encoder)
var container = encoder.container(keyedBy: CodingKeys.self)
if data != nil { try container.encode(data, forKey: .data) }
}
}
public class Ref : Codable
{
public var id:String
public var val:String
required public init(){}
}
public class RecordDictionary<TKey : Codable, TVal : Codable> : List<TKey:TVal>
{
required public init(){ super.init() }
required public init(from decoder: Decoder) throws {
try super.init(from: decoder)
}
public override func encode(to encoder: Encoder) throws {
try super.encode(to: encoder)
}
}
public class SuperWinInfo : Codable
{
public var durationInMs:Int
required public init(){}
}
public class HappyHourInfo : Codable
{
public var isHappyHour:Bool
public var oddsModifier:Double
public var roundPoolBonusPct:Double
required public init(){}
}
public class AccumulatorConfiguration : AccumulatorConfiguration
{
public var id:String
public var updatedAt:Date
required public init(){ super.init() }
private enum CodingKeys : String, CodingKey {
case id
case updatedAt
}
required public init(from decoder: Decoder) throws {
try super.init(from: decoder)
let container = try decoder.container(keyedBy: CodingKeys.self)
id = try container.decodeIfPresent(String.self, forKey: .id)
updatedAt = try container.decodeIfPresent(Date.self, forKey: .updatedAt)
}
public override func encode(to encoder: Encoder) throws {
try super.encode(to: encoder)
var container = encoder.container(keyedBy: CodingKeys.self)
if id != nil { try container.encode(id, forKey: .id) }
if updatedAt != nil { try container.encode(updatedAt, forKey: .updatedAt) }
}
}
public class SyphonInfo : Codable
{
public var bettors:[String:Syphon]
public var locations:[String:Syphon]
public var hasSyphons:Bool
public var totalSyphonsInRound:Int
required public init(){}
}
public class Syphon : Codable
{
public var id:String
public var name:String
public var type:SyphonType
public var nrOfCombinations:Int
required public init(){}
}
public enum SyphonType : Int, Codable
{
case Location = 0
case Bettor = 1
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /qry/rounds/draw/diagnostics HTTP/1.1
Host: s4w2.api.bettor.cc
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
id: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
id: String,
initializationInfo:
{
dataLoadDuration: 0,
betsCollectionsCreationDuration: 0,
combinationsOccuranceLookupInitializationDuration: 0
},
sequenceGenerationInfo:
{
nrOfThreads: 0,
nrOfResultsProbed: 0,
duration: 0,
avgSinglePassDuration: 0
},
bestFitFinderInfo:
{
targetAmount: 0,
awardedAmount: 0,
deviation: 0,
deviationPct: 0,
sequenceResultType: String,
isJackPot5Drawn: False,
filteringPeriod: 0,
winCountOrder: 0,
minAmount: 0,
maxAmount: 0
},
purgerInfo:
{
prevalentStake: 0,
poolPurger: String,
qualifiedPools:
[
{
id: 0,
name: String,
coefficient: 0,
availableAmount: 0,
awardedAmount: 0,
targetBet:
{
isFound: False,
betId: String,
slipId: String,
combStake: {}
}
}
]
},
duration: 0,
stimulationResponses:
[
{
stimulationId: String,
status: 0,
failureReason: String,
slipId: String,
betId: String,
amountAwarded: 0
}
],
localCodePot:
{
durationInMs: 0
},
superWin:
{
durationInMs: 0
},
happyHour:
{
isHappyHour: False,
oddsModifier: 0,
roundPoolBonusPct: 0
},
reasoning: String,
configuration:
{
pools:
[
{
id: 0,
name: String,
rtp: 0,
reserveRTP: 0,
totalRTP: 0
}
],
prevalentStake: 0,
purgeThresholdModifier: 0,
locationOptimizationLevel: 0,
jackPot5ThresholdInterval:
{
start: 0,
end: 0
},
deviationCategorySpanInPct: 0,
deviationCategoryThresholdAmount: 0,
roundPoolCircuitBreakerThreshold: 0,
lowWinCountAffinityInPct: 0,
winCountOrderAffinity:
[
{
order: 0,
probability: 0
}
],
highRollerSettings:
{
pools:
[
{
id: 0,
name: String,
isActive: False,
contributionToRoundPoolPct: 0,
caps:
{
plusCoef: 0,
minusCoef: 0,
maxAmountInPrevalentStakes: 0
}
}
],
categoryThresholds:
[
{
category: 0,
threshold: 0
}
]
},
overflowCoefficientPoolsToRound: False,
antiSyphonProtectionOverride: False,
fraudDetectionConfig:
{
antiSyphon:
{
combinationCountPerRoundThresholdPct: 0,
excludedLocations:
[
{
id: String,
val: String
}
],
includeRoundPctAsBettorSyphonCriteria: False,
isActive: False
}
},
debugConfig:
{
logLocationStats: False,
logBettorSats: False
}
},
syphonInfo:
{
bettors:
{
String:
{
id: String,
name: String,
type: 0,
nrOfCombinations: 0
}
},
locations:
{
String:
{
id: String,
name: String,
type: 0,
nrOfCombinations: 0
}
},
hasSyphons: True,
totalSyphonsInRound: 2
}
}