# frozen_string_literal: true # encoding: utf-8 # Options: =begin Date: 2026-11-07 04:16:29 Version: 10.42 Tip: To override a DTO option, remove "//" prefix before updating BaseUrl: https://s4w1.api.bettor.webhop.biz #MakePartial: True #MakeVirtual: True #MakeInternal: False #MakeDataContractsExtensible: False #AddReturnMarker: True #AddDescriptionAsComments: True #AddDataContractAttributes: False #AddIndexesToDataMembers: False #AddGeneratedCodeAttributes: False #AddResponseStatus: False #AddImplicitVersion: #InitializeCollections: False #ExportValueTypes: False IncludeTypes: PlaceBets.* #ExcludeTypes: #AddNamespaces: #AddDefaultXmlNamespace: http://schemas.servicestack.net/types =end require 'json' require 'servicestack' module ResponseStatus FAILURE = 0 SUCCESS = 1 end module IReturn def response_type() = T def get_type_name() = 'IReturn' 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 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 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 Bet include ServiceStack::DTO # @return [String] attr_accessor :id # @return [Integer] attr_accessor :ordinal_of_available_round_to_assign_to # @return [String] attr_accessor :content # @return [BigDecimal] attr_accessor :stake # @return [Dictionary] attr_accessor :payload def self.properties { id: { name: 'id' }, ordinal_of_available_round_to_assign_to: { name: 'ordinalOfAvailableRoundToAssignTo' }, content: { name: 'content' }, stake: { name: 'stake' }, payload: { name: 'payload' }, } end end class RecordDictionary < Hash end class Bet include ServiceStack::DTO # @return [String] attr_accessor :id # @return [String] attr_accessor :slip_id # @return [Ref] attr_accessor :bettor # @return [Origin] attr_accessor :origin # @return [DateTime] attr_accessor :placed_at # @return [String] attr_accessor :round_id # @return [String] attr_accessor :content # @return [BigDecimal] attr_accessor :stake # @return [BetOutcome] attr_accessor :outcome # @return [BigDecimal] attr_accessor :win # @return [BetProcessingStatus] attr_accessor :processing_status # @return [BetValidity] attr_accessor :validity # @return [Dictionary] attr_accessor :results # @return [Dictionary] attr_accessor :payload def self.properties { id: { name: 'id' }, slip_id: { name: 'slipId' }, bettor: { name: 'bettor', type: Ref }, origin: { name: 'origin', type: Origin }, placed_at: { name: 'placedAt', type: DateTime }, round_id: { name: 'roundId' }, content: { name: 'content' }, stake: { name: 'stake' }, outcome: { name: 'outcome' }, win: { name: 'win' }, processing_status: { name: 'processingStatus' }, validity: { name: 'validity' }, results: { name: 'results' }, payload: { name: 'payload' }, } end end class Bet include ServiceStack::DTO # @return [TrueClass] attr_accessor :is_found # @return [String] attr_accessor :bet_id # @return [String] attr_accessor :slip_id # @return [Object] attr_accessor :comb_stake def self.properties { is_found: { name: 'isFound' }, bet_id: { name: 'betId' }, slip_id: { name: 'slipId' }, comb_stake: { name: 'combStake' }, } end end # @DataContract class ResponseStatus include ServiceStack::DTO # @DataMember(Order=1) # @return [String] attr_accessor :error_code # @DataMember(Order=2) # @return [String] attr_accessor :message # @DataMember(Order=3) # @return [String] attr_accessor :stack_trace # @DataMember(Order=4) # @return [List] attr_accessor :errors # @DataMember(Order=5) # @return [Dictionary] attr_accessor :meta def self.properties { error_code: { name: 'errorCode' }, message: { name: 'message' }, stack_trace: { name: 'stackTrace' }, errors: { name: 'errors', type: [ServiceStack::ResponseError] }, meta: { name: 'meta' }, } end end # @Route("/cmd/bets/v2", "POST") class PlaceBets include ServiceStack::DTO # @return [String] attr_accessor :slip_id # @return [Ref] attr_accessor :bettor # @return [Origin] attr_accessor :origin # @return [DateTime] attr_accessor :placed_at # @return [List] attr_accessor :bets def self.properties { slip_id: { name: 'slipId' }, bettor: { name: 'bettor', type: Ref }, origin: { name: 'origin', type: Origin }, placed_at: { name: 'placedAt', type: DateTime }, bets: { name: 'bets', type: [Bet] }, } end def response_type() = ResponseStatus def get_type_name() = 'PlaceBets' def get_method() = 'POST' end