Flash Bet is an interactive module designed to provide quick and seamless betting options to your users. It is fully integrated with live match data, dynamically reacting to events occurring during the match.
Flash Bet is an optional feature that can be enabled within the Virtual Stadium configuration.
Enable Flash Bet Make sure that you have Flash Bet enabled
Moderation Setup
Add the desired Sportradar Entity ID (srEntityId) to the channel.

For custom adapter implementations, register your adapter using the SIR('registerAdapter', ...) method with a function that handles flash bet requests.
requestName string required
The request type identifier. For flash bet, this will be 'matchEventMarkets'.
Note that virtualStadium.matchEventMarkets will be also triggered at same time, but is deprecated and marked for removal.
Respond only to one (preferably matchEventMarkets). For the other, return undefined.
args GenericMatchEventMarketRequest required
Request parameters containing flash bet data and filters.
callback function optional
Callback function to return market data in the format (error, response) => void.
Callback Arguments:
error Error | null - Error object if request failed, otherwise nullresponse GenericMatchEventMarketResponse | undefined - Response object containing matchEventMarkets array. See Response object for details.Self-Service Adapter - Flash Bet Handler:
const onRequest = (requestName, args, callback) => {
if (requestName === 'matchEventMarkets') {
// Store callback so that you can update market status
matchEventMarketsCallback[args.id] = callback;
// Check args for event data
switch (args.event.sport.id) {
case 1: // Soccer
// Handle events for soccer...
break;
case 5: // Tennis
if (args.matchEvent.type === "GAME_WON") {
if (args.matchEvent.metadata.set_number === 1) {
// Fetch market for first game won
subscribe({eventId: args.event.id}, (error, market) => {
if (market) {
// Convert to Response object
const response = {
matchEventMarkets: [
{
id: // fill from market
name: // fill from market
status: {
status: // fill from market
},
outcomes: [
{
id: // fill from market
name: // fill from market
oddsDecimal: // fill from market
},
//...
]
}
]
}
matchEventMarketsCallback[args.id](undefined, response);
} else {
// Handle error, if critical call matchEventMarketsCallback[args.id](error);
}
})
} else {
// Handle different markets for non first games...
}
}
}
// Return cleanup function if needed
return () => {
// Cleanup logic
};
}
};
SIR('registerAdapter', onRequest);The GenericMatchEventMarketRequest object contains all the information about the match event and context needed to fetch appropriate flash bet markets.
matchEvent MatchEvent required
Information about the specific match event that triggered the flash bet. See MatchEvent object for details.
event Event required
The sporting event information including sport ID and identifiers.
channelId string optional
The Virtual Stadium channel identifier where the flash bet is being displayed.
tag string optional
Tag associated with the channel from which this event originated.
id string optional
Unique identifier for this flash bet request. Use this to store and retrieve the callback for later updates.
args example:
{
"matchEvent": {
"type": "GAME_WON",
"metadata": {
"set_number": "1"
}
},
"event": {
"id": "sr:match:12345678",
"srEventId": "sr:match:12345678",
"externalId": null,
"sport": {
"id": "5"
}
},
"channelId": "ATP_02.11.25_player1_vs_player2",
"tag": "tennis",
"id": "9KnG_Rbnf72Mbh-9-YpOAF3EwStbws35_5Ai1KAXTykKnS1uH5Pc-K4RmuVlLLnN-sr:match:65216662"
}The Event object contains information about the sporting event.
id string required
Unique identifier for the event.
srEventId string optional
Sportradar Entity ID (srEntityId) as set on channel.

externalId string | null optional
Client ID as set on channel.

sport Sport required
Sport information containing at minimum the sport ID.
Event Example:
{
"id": "sr:match:12345678",
"srEventId": "sr:match:12345678",
"externalId": null,
"sport": {
"id": "5"
}
}The Sport object contains information about the sport type.
id string | number required
Unique identifier for the sport.
1 - Soccer/Football2 - Basketball5 - TennisSport Example:
{
"id": "5",
}The MatchEvent object contains details about the specific event that occurred during the match.
type string required
The type of event that occurred (e.g., "GAME_WON", "GOAL", "YELLOW_CARD", etc.).
metadata object optional
Additional contextual information about the event, such as set numbers, period information, etc.
MatchEvent Example:
{
"type": "GAME_WON",
"metadata": {
"set_number": "1"
}
}The Error object is passed to the callback when the market request fails.
name string required
The name of the error type.
message string required
Human-readable error message describing what went wrong.
stack string optional
Stack trace for debugging purposes.
Error Example:
{
"name": "MarketNotFoundError",
"message": "Market not available for this event",
"stack": "Error: Market not available for this event\n at fetchMarket..."
}The response object returned to the callback containing market data.
matchEventMarkets Market[] required
Array of Market objects containing betting markets for the match event.
Response Example:
{
"matchEventMarkets": [
{
"id": "market_123",
"name": "Next Game Winner - Set 1",
"status": {
"status": "active"
},
"outcomes": [
{
"id": "outcome_1",
"name": "Competitor 1",
"oddsDecimal": 1.85
},
{
"id": "outcome_2",
"name": "Competitor 2",
"oddsDecimal": 2.10
}
]
}
]
}The Market object contains betting market data.
id string | number required
Unique identifier for the market.
name string required
Display name for the market (e.g., "Next Game Winner").
outcomes Outcome[] required
Array of betting outcomes/selections available in this market.
externalId string | number optional
Your unique identifier for the market.
status MarketStatus optional
Market status object with status string:
"active" - Odds are provided and you can accept bets on the market"deactivated" - Odds are no longer provided for this market (can go back to active)"suspended" - Odds continue to be provided but you should not accept bets for a short time (bet stop)"settled" - Bet settlement messages have been sent for this market, no further odds will be provided"cancelled" - This market has been cancelled, no further odds will be providedspecifier object optional
Specifiers provide a consistent and descriptive way to define additional parameters that uniquely identify a market. Read more about specifiers.
srMarket object optional
Sportradar market data with id and optional specifiers.
odds OddsObject optional
Odds object with decimalValue (number) and displayValue (string).
Refer to your bet data structure documentation for the complete Market and Outcome schema including odds format, metadata, and additional properties.
Market Example:
{
"id": "market_123",
"name": "Next Game Winner - Set 1",
"status": {
"status": "active"
},
"outcomes": [
{
"id": "outcome_1",
"name": "Competitor 1",
"oddsDecimal": 1.85
},
{
"id": "outcome_2",
"name": "Competitor 2",
"oddsDecimal": 2.10
}
]
}The Outcome object represents a betting selection within a market.
id string | number required
Unique identifier for the outcome.
name string optional
Display name for the outcome (e.g., "Player 1", "Over 2.5").
oddsDecimal number optional
Numeric decimal odds value in EU odds format. Used for displaying the odds change indicator. If the odds attribute is not defined, this value will be used and formatted according to the widget loader settings.
odds string | number optional
Odds value as will be displayed.
externalId string | number optional
Your unique identifier for the outcome.
competitor string optional
Competitor identifier if outcome is tied to a specific team/player.
status object optional
Outcome status with isActive boolean property.
isSelected boolean optional
Whether this outcome is currently selected.
srOutcomeId string optional
Sportradar outcome identifier.
isRecommended boolean optional
Whether this outcome is recommended.
Outcome Example:
{
"id": "outcome_1",
"name": "Competitor 1",
"oddsDecimal": 1.85,
"odds": "1.85",
"status": {
"isActive": true
}
}If a market becomes suspended while being displayed (for example, right before a goal and until the goal has been observed/confirmed), you can suspend it for a period of time.
By default, this suspension lasts 65 seconds, but it can be adjusted via the moderation interface.
To achieve this, the corresponding adapter callback needs to be triggered with the updated payload, setting the market status to suspended.

If you wish to disable the market outcomes but keep the countdown active, set the status to deactivated.
Suspended Market Example:
const match = {
id: 'sr:match:12345',
status: { status: 'suspended' },
name: 'Next Team To Score',
outcomes: [
{
id: 'outcome_1',
status: { isActive: true },
name: 'Team A',
oddsDecimal: 1.67
},
{
id: 'outcome_2',
status: { isActive: true },
name: 'Team B',
oddsDecimal: 3.0
}
]
};
// Trigger the callback with suspended market
matchEventMarketsCallback[args.id](undefined, {
matchEventMarkets: [match]
});Deactivated Market Example:
const match = {
id: 'sr:match:12345',
status: { status: 'deactivated' },
name: 'Next Team To Score',
outcomes: [
{
id: 'outcome_1',
status: { isActive: true },
name: 'Team A',
oddsDecimal: 1.67
},
{
id: 'outcome_2',
status: { isActive: true },
name: 'Team B',
oddsDecimal: 3.0
}
]
};
// Trigger the callback with deactivated market
matchEventMarketsCallback[args.id](undefined, {
matchEventMarkets: [match]
});