Skip to main content

6.3 Betslips Messages

These messages update the state of an open betslip. They are sent in response to betslips requests.

Available message types:

6.3.1 betslip: betslip opened or updated

A betslip has been opened by an Open Betslip command.

The format of this message is the same returned in the synchronous response.

6.3.2 pmm: price and min/max stake returned by a bookie

A bookie has returned a PMM for an offer on a betslip.

Fields:

betslip_id [ string ]

The random UUID of the betslip that requested the PMM.

sport [ string ]

The sport of the event.

event_id [ string ]

The opaque id of the event.

bookie [ string ]

The bookie of the bookie account.

username [ string ]

The username of the bookie account.

bet_type [ string ]

The bet type of the PMM.

status [ object ]

An object describing the result of the PMM. This will contain at least one key, code. code will be one of:

  • success

    The bookie account was successfully queried and the attached price list has the latest prices from the bookie.

  • failed

    We were unable to either reach the bookie due to technical reasons (e.g. network issues, or problems with either our servers or the bookie's), or that the response we received from the bookie was rejected (e.g. they returned the wrong data).

    For this status, the parent object will always contain a second key, reason, with more details about the error.

    Note that an error from the bookie may result in a temporary blacklist on a bookie account or offer. In such cases MollyBet will replace the account on the betslip with another one and try again, if possible.

  • blacklist

    This account is currently blacklisted and we're searching for a bookie account that can replace it.

price_list [ list[object{bookie: object (optional), effective: object}, ...] ]

List of available prices offered on this account. bookie is the prices list as offered by the bookie, effective takes modifiers such as commissions or referral fees into account. Both lists are PMM objects with attributes:

  • price [ float ]:

    The decimal price of the offer.

  • min [ list[string, float] ]:

    The minimum stake that can be placed, as a 2-items [ currency code, amount ] list.

  • max [ list[string, float] ]:

    The maximum stake that can be placed, as a 2-items [ currency code, amount ] list.

Example:

{
"betslip_id": "b2e936565fea4d778c38269ab1667f17",
"sport": "fb",
"event_id": "2016-10-26,245,234",
"bookie": "bf",
"username": "_40a78ed8_",
"bet_type": "for,h",
"status": {"code": "success"},
"price_list": [
{
"bookie": {"price": 2.16, "max": ["GBP", 5.4], "min": ["GBP", 2.0]},
"effective": {"price": 2.1368, "max": ["GBP", 5.4], "min": ["GBP", 2.0]}
},
{
"bookie": {"price": 2.12, "min": ["GBP", 2.0], "max": ["GBP", 278.57]},
"effective": {"price": 2.0976, "min": ["GBP", 2.0], "max": ["GBP", 278.57]}
}
]
}

6.3.3 betslip_closed: betslip no longer exists

A betslip was closed.

Fields:

betslip_id [ string ]

The id of the betslip closed.

close_reason [ string ]

The reason the betslip was closed (such as explicit_close_request or timeout).