Betting.WebApi

<back to all web services

GetUserNotifications

Requires Authentication
The following routes are available for this service:
All Verbs/qry/users/notifications
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 GetUserNotifications
{
    open var id:String? = null
}

open class UserNotifications
{
    open var id:String? = null
    open var n:Int? = null
    open var s:Int? = null
    open var i:Int? = null
    open var w:Int? = null
    open var e:Int? = null
    open var notifications:HashMap<String,UserNotification>? = null
}

open class UserNotification
{
    open var id:String? = null
    open var notification:Notification? = null
    open var dispatchedAt:Date? = null
}

open class Notification
{
    open var severity:Severity? = null
    @SerializedName("type") open var Type:NotificationType? = null
    @SerializedName("data") open var Data:RecordDictionary<String, String>? = null
}

enum class Severity(val value:Int)
{
    @SerializedName("0") Success(0),
    @SerializedName("1") Info(1),
    @SerializedName("2") Warning(2),
    @SerializedName("3") Error(3),
}

enum class NotificationType(val value:Int)
{
    @SerializedName("0") Default(0),
    @SerializedName("1") SlipDeliveryConfirmationRequest(1),
    @SerializedName("2") SlipDeliveryIssueResolved(2),
}

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

Kotlin GetUserNotifications 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/users/notifications HTTP/1.1 
Host: api.sbbet.ath.cx 
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,
	n: 1,
	s: 1,
	i: 0,
	w: 0,
	e: 0,
	notifications: 
	{
		String: 
		{
			id: String,
			notification: 
			{
				severity: 0,
				type: 0,
				data: 
				{
					String: String
				}
			},
			dispatchedAt: 0001-01-01
		}
	}
}