Hi
I'm not sure if this should be in the excel topic or automation. But essentially I am wondering does BetAngel have any API that would allow you to Place a bet (Lay in this case) on a certain selection in a certain market at a certain price from an external application.
I have an application that figures out certain selections I should lay each day at SP and then writes them to a CSV file. So I now want to read those selections from the CSV file and place the bets in the market. I would like this all to be completely automated and I currently have the first part running on a batch job.
I know the excel sheets for betAngel offer a type of API for betAngel but from what I know it does involve some manual intervention to link the spreadsheets to the markets in guardians etc.
I am most comfortable working in Java but if this can be achieved in VBA in excel then I'm happy to get my hands dirty with that either.
Any advice would be much appreciated.
Thanks in advance
Bernard
Read selections from CSV file and Lay the horses at SP
-
- Posts: 3140
- Joined: Sun Jan 31, 2010 8:06 pm
The Betfair API is very easy to connect too especially if you're already competent with a programming language like java. If you already have an application writing to csv I'd probably consider sending the bets direct to the API rather than csv. You state you're laying at SP so no reason to wait for the scheduled off and you can set a max lay price with the BSP.
The only fly in the ointment is you now have to pay £299 for the API keys if you don't already have them. If you don't want to go the APi route a little digging of the http requests off the site should be enough to recreate the URLs you'd need to place bets via a browser which can then be automated.
If you don't want to code your own app plenty of Betfair apps can step thru the markets whilst connected to excel so I'd imagine BA can do the same and loading a CSV into excel is simple enough to code to reload at set times say after you're selection process has run.
The only fly in the ointment is you now have to pay £299 for the API keys if you don't already have them. If you don't want to go the APi route a little digging of the http requests off the site should be enough to recreate the URLs you'd need to place bets via a browser which can then be automated.
If you don't want to code your own app plenty of Betfair apps can step thru the markets whilst connected to excel so I'd imagine BA can do the same and loading a CSV into excel is simple enough to code to reload at set times say after you're selection process has run.
-
- Posts: 5
- Joined: Fri Jul 03, 2015 9:25 pm
Thanks for the reply. Ye I have been thinking paying for the API might be the cleanest approach but as you said it's the £299 that is the only thing holding me back and was thinking is BA had an API then I could just call through that instead of having to Pay for betfairs directly.
I think I'll investigate what can be done with excel first and if I'm not happy with the solution then I might look down the API route. Thanks for your help.
Bernard
I think I'll investigate what can be done with excel first and if I'm not happy with the solution then I might look down the API route. Thanks for your help.
Bernard
I created something along those lines a while ago
viewtopic.php?f=31&t=15021
The only difference being is that the runner list is populated via what is already on the sheets rather than from a csv file.
You could import your csv sheet and get the formulas in each cell (L9 for example), to point to that sheet.
viewtopic.php?f=31&t=15021
The only difference being is that the runner list is populated via what is already on the sheets rather than from a csv file.
You could import your csv sheet and get the formulas in each cell (L9 for example), to point to that sheet.
-
- Posts: 5
- Joined: Fri Jul 03, 2015 9:25 pm
Thanks for that Nigel this could be a good alternative.
One question do would I need to re-connect the spreadsheet to guardian everyday?
As I am looking for something that I would be able to set up once and then just let it work off a timer or batch job to read in the selections and execute the required bets say 10s before the off for the required races.
Is this something that is possible with excel and bet angel.
Thanks
Bernard
One question do would I need to re-connect the spreadsheet to guardian everyday?
As I am looking for something that I would be able to set up once and then just let it work off a timer or batch job to read in the selections and execute the required bets say 10s before the off for the required races.
Is this something that is possible with excel and bet angel.
Thanks
Bernard
Yes, just load the races you are interested in in the morning.
Theres a countdown timer here
viewtopic.php?f=19&t=15130
that could be adjusted for your needs.
Theres a countdown timer here
viewtopic.php?f=19&t=15130
that could be adjusted for your needs.
-
- Posts: 5
- Joined: Fri Jul 03, 2015 9:25 pm
Ok perfect thanks very much for your help.
Bernard
Bernard