thereals0beit / bet365-scraper

Bet365.com soccer scraper
MIT License
86 stars 43 forks source link

Scrape specific events #1

Open marpagu opened 9 years ago

marpagu commented 9 years ago

Hi mate!

I have been searching the web in order to find ways to scrape specific events in bet365 web page. At this time, I have arrived at your repository, which seems to do more or less what I need.

The fact is that I have executed the code but I got the "Unexpected InPlay packet header" problem so I cannot get the odds from the page.

Apart from this, what I really want to do is the following. I choose some soccer games that will be played some days later. I then have their web pages in the mobile site, for example:

https://mobile.bet365.es/default.aspx?lng=&zn=0&apptype=&appversion=&rnd=18308#type=MarketCount;key=1-1-8-50340183-3-0-0-0-1-0-0-0-0-0-1-0-0-0-0-0-0;ip=0;lng=3

Is there a way that your code (and some modifications that I would perform) provides me this information? I mean, I would specify the web page and the programm would scrape the page and write the data from the site.

I am sorry if I am abusing of your time. Feel free to remove this issue if you consider it inproper.

Many thanks in advance and kind regards, Marcos

thereals0beit commented 8 years ago

Oh no, it's perfectly fine, the main issue is that I really don't have time to work on this anymore due to starting a new job. Feel free to fork it, but I probably won't revisit it.

marpagu commented 8 years ago

Many thanks.

The thing is that I cannot achieve to succesfully execute the code. I am getting the error I already mentioned: "Unexpected InPlay packet header".

This is the full string I got from the browser:

"Session ID: FAB7771A194A4099BB17A7AFD7484D82000003 Pow HTTPS Host: https://premlp-pt13.365lpodds.com:443 Pow Random Number: 1982546073 string(24) "100I1MIP08-V67V0uGRNe1V" Constant: 100 Pow Session Id: I1MIP08-V67V0uGRNe1V Unexpected InPlay packet headerbool(false) Script took 2.7748119831085 seconds! "

I do not want to make you waste your time but... Do you know how can I query a specific URL from the bet365 page? For example, the one I said in the previous comment:

https://mobile.bet365.es/default.aspx?lng=&zn=0&apptype=&appversion=&rnd=18308#type=MarketCount;key=1-1-8-50340183-3-0-0-0-1-0-0-0-0-0-1-0-0-0-0-0-0;ip=0;lng=3

If I get the code from this page, I will be able to parse it in order to gain the information I am interested in.

Again, thank you very much for your patience.

Kind regards, Marcos

corbinspicer68 commented 8 years ago

Got this working on localhost, but when uploading on a server seem to get Unexpected InPlay packet header.

I assume this is to do with bet365 rejecting the connection - maybe based on IP. Can anyone shed any light on how to get around this?

Thanks

corbinspicer68 commented 8 years ago

Ran on a private VPS and now works. Working on reducing the slowness now.

Does anyone know how to extract the minute of the match now?

emeryta commented 8 years ago

I'm testing the code on my hosting and removing "return false" near "Unexpected InPlay packet header" works for me this morning. Now the same code return to me void string instead the info of matches :( What happens?

On the other hand i'm interesting on technics to give the parameters requested by bet, for example, Where i can see the url, the parameters or the topics admitted.

Thanks!

corbinspicer68 commented 8 years ago

Please contact me on Skype if you want help,

My Skype is CorbinSpicer

Sent from my iPhone

On 15 Oct 2015, at 16:28, emeryta notifications@github.com wrote:

I'm testing the code on my hosting and removing "return false" near "Unexpected InPlay packet header" works for me this morning. Now the same code return to me void string instead the info of matches :( What happens?

On the other hand i'm interesting on technics to give the parameters requested by bet, for example, Where i can see the url, the parameters or the topics admitted.

Thanks!

— Reply to this email directly or view it on GitHub.

tomskigit commented 8 years ago

Awesome did you get this working for different in play events I cant figure it out.

corbinspicer68 commented 8 years ago

It seems Bet365 have cottoned onto this now, and the request is only working occasionally (it seems Bet365 have blocked the IP's for those trying to access this)

If anyone has a solution (using proxies is not really a solution, just a bad workaround), then let me know.

novakgio commented 6 years ago

It still not working.Any one found out a way out?