Whapi

Bets API

The Bets API methods are used to place single, multiple and complex bets and to retrieve a customer’s bet history. When retrieving a customer’s bet history…

Media & content#openapi#entertainment

Fork copies the collection into your workspace, without the publisher's secrets, so you can add your own key and send requests. Star saves it to your starred APIs (Account › Marketplace) and helps others find it.

Overview

The Bets API methods are used to place single, multiple and complex bets and to retrieve a customer’s bet history. When retrieving a customer’s bet history you can organize the bets from the betting history in terms of date, bet type and whether the bet is settled or not. You can also specify what fields to be included/excluded or return a list of all default fields the method returns. The Bets API will also generate a bet delay if you’re placing a single/multiple bet in-Play by creating a time margin to negate the effects of major changes to the market (for example, goals during a football match). Note that in version 2 of our APIs, Bets API contains the functionality of both Bets API v1 and the Betslips API v1.

Endpoints 6

Bets

  • POSTPlaces a multiple or a complex bet./bet/complex?fields=string&include=string&exclude=stringPlaces a multiple or a complex bet.
  • POSTPlaces a single bet/bet/single?fields=string&include=string&exclude=stringPlaces a single bet. When placing a single bet using live inplay bets, the system might generate a bet delay to allow a time margin to negate the effects of…
  • POSTvalidateBetslip/betslips?expanded=stringOrganises the betslip when one or more selections are made. It returns a bet slip structure organised by betting opportunities.
  • GETReturns available free bets/freebets?fields=string&include=string&exclude=stringRetrieves the current free bets available for a customer.
  • GETRetrieves the customer’s bet history./history?dateFrom=string&dateTo=string&fields=string&include=string&exclude=string&page=1&pageSize=100&sort=transDateTime,asc&settled=trueRetrieves the customer’s bet history. Options are available to organise the history in terms of date, bet type and settled and unsettled bets. The maximum…
  • PUTAllows a trusted application to cash in a bet (take a return on a bet) on behalf of the customer/:betId/cashin?cashInValue=0.0&cashinBetDelayId=stringAllows a trusted application to cash in a bet (take a return on a bet) on behalf of the customer. If the customers monitor bets they can cash in a bet at any…

API details

Base URL
https://sandbox.whapi.com/v2/bets
Authentication
None declared in the description
Operations
6 operations on 6 pathsPOST 3GET 2PUT 1
Main resources
Bets 6
Response formats
application/json
Description format
OpenAPI 3.0.0, API version 2.0.0
Listed from
APIs.guru OpenAPI Directory (CC0-1.0)
Source updated

How to test the Bets API in Swastik Codes

  1. Open the APISelect “Fork & run in Swastik Codes” on this page. Sign in or create a free account if asked.
  2. Fork it into your workspaceChoose a workspace. You get your own copy of the Bets API collection, without the publisher's secrets.
  3. Add your credentialsOpen the collection's variables or an environment and enter your API key or token, if the API needs one.
  4. Send a requestPick an endpoint, for example “Places a multiple or a complex bet.” (POST /bet/complex?fields=string&include=string&exclude=string), and press Send. Check the response, add tests and run the whole collection with the runner.

Frequently asked questions

What is the Bets API?

The Bets API methods are used to place single, multiple and complex bets and to retrieve a customer’s bet history. When retrieving a customer’s bet history… It is listed under Media & content and has 6 endpoints.

Who publishes the Bets API?

It is listed from Whapi's public API description (an OpenAPI document), not published by Whapi on Swastik Codes. Anyone who controls whapi.com can claim the profile by adding a DNS TXT record.

What is the base URL of the Bets API?

Requests go to https://sandbox.whapi.com/v2/bets. Endpoint paths are added to this base URL.

How do I authenticate with the Bets API?

Its OpenAPI description does not declare an authentication scheme. Some endpoints may be open; check the provider's documentation before relying on that.

How many endpoints does the Bets API have?

6 operations on 6 paths (3 POST, 2 GET, 1 PUT). The largest groups are Bets.

Is forking the Bets API free?

Yes. Forking copies the collection into your workspace for free. It has been starred 0 times and forked 0 times.

Suggest an API

Tell us which public API is missing. We check it, then add it here with its endpoints when it has an OpenAPI (Swagger) description.