Module: Api::OddsRecover

Included in:
Betradar::Client
Defined in:
lib/betradar/api/odds_recover.rb

Instance Method Summary collapse

Instance Method Details

#event_odds(event_id, event_type = 'sr:match', product = 'pre', request_id = -1)) ⇒ Object

Recover sport event Request to resend all odds for all markets for a sport event.



17
18
19
# File 'lib/betradar/api/odds_recover.rb', line 17

def event_odds(event_id, event_type = 'sr:match', product = 'pre', request_id = -1)
  post("#{product}/odds/events/#{event_type}:#{event_id}/initiate_request?request_id=#{request_id}")
end

#full_odds_recovery(product = 'pre', request_id = -1)) ⇒ Object

Request full odds recovery Do recovery of odds over the feed. Subscribes client to feed messages.



11
12
13
# File 'lib/betradar/api/odds_recover.rb', line 11

def full_odds_recovery(product = 'pre', request_id = -1)
  post("#{product}/recovery/initiate_request?request_id=#{request_id}")
end

#recovery_after_timestamp(after, product = 'pre', request_id = -1)) ⇒ Object

Request recovery since after timestamp Do recovery of odds and stateful messages over the feed. Subscribes client to feed messages.



5
6
7
# File 'lib/betradar/api/odds_recover.rb', line 5

def recovery_after_timestamp(after, product = 'pre', request_id = -1)
  post("#{product}/recovery/initiate_request?after=#{after}&request_id=#{request_id}")
end

#stateful_messages(event_id, event_type = 'sr:match', product = 'pre', request_id = -1)) ⇒ Object

Recover stateful-messages for a sport event Request to resend all stateful-messages (BetSettlement, RollbackBetSettlement, BetCancel, UndoBetCancel) for a sport event.



24
25
26
# File 'lib/betradar/api/odds_recover.rb', line 24

def stateful_messages(event_id, event_type = 'sr:match', product = 'pre', request_id = -1)
  post("#{product}/stateful_messages/events/#{event_type}:#{event_id}/initiate_request?request_id=#{request_id}")
end