Six4Win.WebApi

<back to all web services

GetRecentWins

The following routes are available for this service:
All Verbs/qry/wins/recent
import java.math.*
import java.util.*
import java.io.InputStream
import net.servicestack.client.*
import com.google.gson.annotations.*
import com.google.gson.reflect.*


open class GetRecentWins
{
}

open class RecentWins
{
    open var id:String? = null
    open var wins:ArrayList<Win>? = null
    open var maxSize:Int? = null
    open var threshold:BigDecimal? = null
}

open class Win
{
    open var id:Long? = null
    open var sId:Long? = null
    open var bettor:Ref? = null
    open var origin:Origin? = null
    open var placedAt:Date? = null
    open var roundId:Long? = null
    open var content:String? = null
    open var stake:BigDecimal? = null
    open var outcome:BetOutcome? = null
    open var amount:BigDecimal? = null
    open var processingStatus:BetProcessingStatus? = null
    open var validity:BetValidity? = null
    open var results:HashMap<String,String>? = null
    open var payload:HashMap<String,String>? = null
}

open class Ref
{
    open var id:String? = null
    @SerializedName("val") open var Val:String? = null
}

open class Origin
{
    open var application:BettingApp? = null
    open var ip:String? = null
    open var organization:RefEx? = null
    open var region:Ref? = null
    open var locationGroup:Ref? = null
    open var location:RefEx? = null
    open var device:RefEx? = null
    open var clerk:Ref? = null
}

open class BettingApp
{
    open var name:String? = null
    open var version:String? = null
}

open class RefEx : Ref()
{
    @SerializedName("data") open var Data:RecordDictionary<String, String>? = null
}

open class RecordDictionary<TKey, TVal> : HashMap<TKey,TVal>()
{
}

enum class BetOutcome(val value:Int)
{
    @SerializedName("0") Unknown(0),
    @SerializedName("1") Lost(1),
    @SerializedName("2") Won(2),
    @SerializedName("3") Void(3),
}

enum class BetProcessingStatus(val value:Int)
{
    @SerializedName("0") Open(0),
    @SerializedName("1") Closed(1),
}

enum class BetValidity(val value:Int)
{
    @SerializedName("0") Valid(0),
    @SerializedName("1") Canceled(1),
    @SerializedName("2") Void(2),
    @SerializedName("3") Reverted(3),
}

Kotlin GetRecentWins 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/wins/recent HTTP/1.1 
Host: s4w2.api.bettor.cc 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

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

{
	id: String,
	wins: 
	[
		{
			id: 0,
			sId: 0,
			bettor: 
			{
				id: String,
				val: 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
				}
			},
			placedAt: 0001-01-01,
			roundId: 0,
			content: String,
			stake: 0,
			outcome: 0,
			amount: 0,
			processingStatus: 0,
			validity: 0,
			results: 
			{
				String: String
			},
			payload: 
			{
				String: String
			}
		}
	],
	maxSize: 0,
	threshold: 0
}