Six4Win.WebApi

<back to all web services

GetRecentJackpotWinners

The following routes are available for this service:
GET/qry/recentJackpotWinners
# frozen_string_literal: true
# encoding: utf-8


require 'json'
require 'servicestack'


class BettingApp
    include ServiceStack::DTO

    # @return [String]
    attr_accessor :name
    # @return [String]
    attr_accessor :version

    def self.properties
        {
            name: { name: 'name' },
            version: { name: 'version' },
        }
    end

end

class Ref
    include ServiceStack::DTO

    # @return [String]
    attr_accessor :id
    # @return [String]
    attr_accessor :val

    def self.properties
        {
            id: { name: 'id' },
            val: { name: 'val' },
        }
    end

end

class RefEx < Ref
    # @return [RecordDictionary]
    attr_accessor :data

    def self.properties
        {
            data: { name: 'data', type: RecordDictionary },
        }
    end

end

class Origin
    include ServiceStack::DTO

    # @return [BettingApp]
    attr_accessor :application
    # @return [String]
    attr_accessor :ip
    # @return [RefEx]
    attr_accessor :organization
    # @return [Ref]
    attr_accessor :region
    # @return [Ref]
    attr_accessor :location_group
    # @return [RefEx]
    attr_accessor :location
    # @return [RefEx]
    attr_accessor :device
    # @return [Ref]
    attr_accessor :clerk

    def self.properties
        {
            application: { name: 'application', type: BettingApp },
            ip: { name: 'ip' },
            organization: { name: 'organization', type: RefEx },
            region: { name: 'region', type: Ref },
            location_group: { name: 'locationGroup', type: Ref },
            location: { name: 'location', type: RefEx },
            device: { name: 'device', type: RefEx },
            clerk: { name: 'clerk', type: Ref },
        }
    end

end

class RecentJackpot5Winner
    include ServiceStack::DTO

    # @return [String]
    attr_accessor :slip_id
    # @return [String]
    attr_accessor :bet_id
    # @return [BigDecimal]
    attr_accessor :winnings_amount
    # @return [Origin]
    attr_accessor :origin
    # @return [DateTime]
    attr_accessor :placed_at
    # @return [Dictionary]
    attr_accessor :payload
    # @return [String]
    attr_accessor :results
    # @return [Ref]
    attr_accessor :bettor
    # @return [String]
    attr_accessor :round_id

    def self.properties
        {
            slip_id: { name: 'slipId' },
            bet_id: { name: 'betId' },
            winnings_amount: { name: 'winningsAmount' },
            origin: { name: 'origin', type: Origin },
            placed_at: { name: 'placedAt', type: DateTime },
            payload: { name: 'payload' },
            results: { name: 'results' },
            bettor: { name: 'bettor', type: Ref },
            round_id: { name: 'roundId' },
        }
    end

end

class RecentJackpot5Winners
    include ServiceStack::DTO

    # @return [String]
    attr_accessor :id
    # @return [Queue]
    attr_accessor :recent_winners

    def self.properties
        {
            id: { name: 'id' },
            recent_winners: { name: 'recentWinners', type: [RecentJackpot5Winner] },
        }
    end

end

class GetRecentJackpotWinners
    include ServiceStack::DTO

    def response_type() = RecentJackpot5Winners
    def get_type_name() = 'GetRecentJackpotWinners'
end

class RecordDictionary < Hash
end

Ruby GetRecentJackpotWinners DTOs

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

HTTP + OTHER

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

GET /qry/recentJackpotWinners HTTP/1.1 
Host: s4w1.api.bettor.webhop.biz 
Accept: text/jsonl
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{"id":"RecentJackpotWinners-1","recentWinners":[]}