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 .xml suffix or ?format=xml

HTTP + XML

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: application/xml
Content-Type: application/xml
Content-Length: length

<GetUserNotifications xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Betting.WebApi.ServiceModel">
  <Id>String</Id>
</GetUserNotifications>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<UserNotifications xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Betting.ReadModel">
  <Id>String</Id>
  <Notifications xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:KeyValueOfstringUserNotifications.UserNotificationICRnA2uO>
      <d2p1:Key>String</d2p1:Key>
      <d2p1:Value>
        <DispatchedAt>0001-01-01T00:00:00</DispatchedAt>
        <Id>String</Id>
        <Notification xmlns:d5p1="http://schemas.datacontract.org/2004/07/Betting.Common">
          <d5p1:Data>
            <d2p1:KeyValueOfstringstring>
              <d2p1:Key>String</d2p1:Key>
              <d2p1:Value>String</d2p1:Value>
            </d2p1:KeyValueOfstringstring>
          </d5p1:Data>
          <d5p1:Severity>Success</d5p1:Severity>
          <d5p1:Type>Default</d5p1:Type>
        </Notification>
      </d2p1:Value>
    </d2p1:KeyValueOfstringUserNotifications.UserNotificationICRnA2uO>
  </Notifications>
</UserNotifications>