How to Retrieve Price/Volume Over Time Data from Betfair API?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bet1111
    Junior Member
    • Dec 2023
    • 3

    #1

    How to Retrieve Price/Volume Over Time Data from Betfair API?

    I'm looking for a way to obtain the Price/Volume over time data similar to the graphs displayed on the Betfair website. Specifically, I want to know if there is a method to retrieve this information directly through the Betfair API, or if it's necessary to track and save the odds data manually over time.

    If the API does provide this data, could you please point me to the relevant endpoints or methods? Any sample code or documentation links would be greatly appreciated.

    Thanks in advance for your help!​
  • WTPooh
    Member
    • May 2012
    • 88

    #2
    Code:
    $"https://graphs.betfair.com/loadRunnerChart?marketId={marketId}&selectionId={selectionId}&handicap=0&alt=json"

    Comment

    • rye
      Junior Member
      • Sep 2019
      • 4

      #3
      Originally posted by WTPooh View Post
      Code:
      $"https://graphs.betfair.com/loadRunnerChart?marketId={marketId}&selectionId={selectionId}&handicap=0&alt=json"
      Thanks, the key is "&alt=json", I was looking for it.

      Comment

      • Naadurabiftu
        Junior Member
        • Sep 2024
        • 1

        #4
        Originally posted by WTPooh View Post
        Code:
        $"https://graphs.betfair.com/loadRunnerChart?marketId={marketId}&selectionId={selectionId}&handicap=0&alt=json"
        You have pointed out the important code. Can quickly access the program!

        Comment

        • Redeniol
          Junior Member
          • Sep 2024
          • 2

          #5
          Originally posted by WTPooh View Post
          Code:
          $"https://graphs.betfair.com/loadRunnerChart?marketId={marketId}&selectionId={selectionId}&handicap=0&alt=json"

          That's right! Good, thank you!

          Comment

          • ZanderKunze
            Junior Member
            • Nov 2024
            • 1

            #6
            Originally posted by WTPooh View Post
            Code:
            $"https://graphs.betfair.com/loadRunnerChart?marketId={marketId}&selectionId={selectionId}&handicap=0&alt=json"
            You are my savior, thank you.

            Comment

            • TerezaRodrigues
              Junior Member
              • Jul 2021
              • 4

              #7
              WTPooh rye Naadurabiftu Redeniol ZanderKunze Are you able to use it? Because I enter my credentials correctly and still get the "Just a moment..." block from Cloudflare. Could you send me the full code you are using to make the request please?

              Comment

              • WTPooh
                Member
                • May 2012
                • 88

                #8
                You don't need to enter your credentials to view this data. Try to open this link
                Code:
                https://graphs.betfair.com/loadRunnerChart?marketId=1.235476617&selectionId=56301&handicap=0&alt=json

                Comment

                • TerezaRodrigues
                  Junior Member
                  • Jul 2021
                  • 4

                  #9
                  WTPooh Yes, but if I try to follow a chart with a scheduled update, it starts returning a "Just a moment..." block made by Cloudflare. I wanted to mark the point where I made investment and follow the graphs on a single screen, but I don't think it's possible.

                  Comment

                  • WTPooh
                    Member
                    • May 2012
                    • 88

                    #10
                    google "cloudflare 403 error ". You might find a way to bypass it for your programming language.
                    Last edited by WTPooh; 09-11-2024, 05:06 PM.

                    Comment

                    • rye
                      Junior Member
                      • Sep 2019
                      • 4

                      #11
                      Originally posted by WTPooh View Post
                      google "cloudflare 403 error ". You might find a way to bypass it for your programming language.
                      When I open the link using a browser, the data is received correctly.
                      When I use CURL from PHP, a 403 error is returned. Is Betfair blocking this?​

                      Comment

                      • WTPooh
                        Member
                        • May 2012
                        • 88

                        #12
                        Code:
                        https://stackoverflow.com/questions/67344798/php-curl-access-to-website-with-cloudflare-2021
                        Read this, it might help.

                        Comment

                        • Danyaal
                          Junior Member
                          • Mar 2025
                          • 1

                          #13
                          same here with keepAlive token request, 403 forbidden from cloudflare, is there a way to bypass that thing?

                          Comment

                          Working...
                          X