API is one of the means of communication between sites, software, or scripts. In our case, the API means that BetWasp provides data about the surebets and/or valuebets, along with the rules for setting up and using them. And on the part of the user, such data is to be used in making software, and scripts to automate a betting process.
Setting up and getting REST API data
At the very beginning, you must to choose a list of your preferred bookmakers, but not more than 10. Then you upload this list onto the pricing page, and after some time you get a cost estimate for accessing the selected API data. Once the application is approved, you must execute the payment.
Important: you can check the current status of the application in your Account. In total, an application for the access to API data can have 4 statuses:
- Pending: the application has not yet been considered / is still being considered by the BetWasp team (the application is being processed within 48 hours from the moment of its submission).
- Ready for payment: the application has been confirmed, and is awaiting payment.
- Paid: API data access is available.
- Expired: the data access subscription has expired.
After getting access to the API data, you will be able to customize the information you receive based on your needs. You can do this using the "Multifilters" tab in your Account. More detailed information on setting up filters can be found in our “Manual”.
Important note: for the convenience of use of the API, either commit to memory, or write down the ID number of the configured filter.
After setting up the filters, you need to check the correctness of the information received. You can verify the correct setting as follows:
- go to the API results (either in prematch or in live mode);
- select the type of API (surebets / value bets);
- use any of the configured filters.
At the next step, you must get a key to access the API. The token will be generated as an alphanumeric code, it will be unique, allowing only a specific user to access specific information. You can find your token on the API tab in your Account.
As last step, you must enter the filter data (id) and a unique token into the Swagger docs to get the URL to the information generated in accordance with the specified settings. For value bets use "valuebet-controller", and for the surebets use "surebet-controller". It should also be noted that Swagger has different links for prematch and live modes:
- link for the prematch mode: https://rest-api-pr.betwasp.com/doc.html ;
- link for the live mode: https://rest-api-lv.betwasp.com/doc.html.
Entering data into the Swagger documentation is quite simple:
- Click on the “POST” button;
- Click on the “Try it out” button;
- Enter data in the displayed fields ("access_token" is for entering the unique token, "search_filter" – for entering the id number of the specified settings);
- Click on the "Execute" button.
After said 5 steps, you will get the data related to "API prematch" and/or "API live" modes. The received data is ready for synchronization with third-party software and scripts using the generated Curl.