Betfair graphs

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • silentman13.
    Junior Member
    • Feb 2013
    • 20

    #1

    Betfair graphs

    I'm trying to get Betfair graphs..

    Calling API-NG listMarketCatalogue, get this response :

    Code:
    Response: {"jsonrpc":"2.0","result":[{"marketId":"1.114325883","marketName":"Match Odds","totalMatched":8.015112000000002,"runners":[{"selectionId":344793,"runnerName":"TPS","handicap":0.0,"sortPriority":1},{"selectionId":1099216,"runnerName":"IFK Mariehamn","handicap":0.0,"sortPriority":2},{"selectionId":58805,"runnerName":"The Draw","handicap":0.0,"sortPriority":3}]}],"id":"1"}
    
    Market Name: Match Odds; Id: 1.114325883
    
    Runner Name: TPS; Selection Id: 344793
    
    Runner Name: IFK Mariehamn; Selection Id: 1099216
    
    Runner Name: The Draw; Selection Id: 58805
    So I'm trying to get the corresponding graph like this :

    http://uk.site.sports.betfair.com/be...&asianLineId=0

    But it's wrong.. What's the problem?

    I'm from Italy. Maybe I cannot access graphs?!?

    Thanks
  • silentman13.
    Junior Member
    • Feb 2013
    • 20

    #2
    Please someone from a non-Italy-country can at least test my url graphs?

    Do you see something? Is url in an incorrect format?

    Another question : Are graphs still available on betfair.com website?

    On betfair.it website aren't.....
    Only 3 markets available..... Bleah...

    Thanks

    Comment

    • gus
      Senior Member
      • Jan 2009
      • 134

      #3
      The link:
      Code:
      http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=1.114325883&selectionId=344793&asianLineId=0
      doesn't work from here (or probably abywhere else), because, although the marketId ( 1.114325883 )is correct for API-NG, it is incorrect for accessing the graph, but all you have to do is a bit of string parsing to remove the '1.' from this or any other marketId ... so should just be 114325883

      e.g. for the World Cup Football match England V Italy, England to win


      Code:
      http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=112173626&selectionId=58805&asianLineId=0
      http://uk.site.sports.betfair.com/be...&asianLineId=0

      Comment

      • silentman13.
        Junior Member
        • Feb 2013
        • 20

        #4
        Originally posted by gus View Post
        The link:
        Code:
        http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=1.114325883&selectionId=344793&asianLineId=0
        doesn't work from here (or probably abywhere else), because, although the marketId ( 1.114325883 )is correct for API-NG, it is incorrect for accessing the graph, but all you have to do is a bit of string parsing to remove the '1.' from this or any other marketId ... so should just be 114325883

        e.g. for the World Cup Football match England V Italy, England to win


        Code:
        http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=112173626&selectionId=58805&asianLineId=0
        http://uk.site.sports.betfair.com/be...&asianLineId=0
        Very goood job Gus! Thank you!

        Hope prefix '1.' in marketId is standard...

        PS: May the best team win tonight!

        Comment

        • betdynamics
          Junior Member
          • Sep 2010
          • 534

          #5
          The prefix in the marketId is actually the Exchange identifier, so "1." for UK and "2." for AUS

          Comment

          • silentman13.
            Junior Member
            • Feb 2013
            • 20

            #6
            Originally posted by betdynamics View Post
            The prefix in the marketId is actually the Exchange identifier, so "1." for UK and "2." for AUS
            Great information! Thank you too!

            Comment

            • silentman13.
              Junior Member
              • Feb 2013
              • 20

              #7
              After Gus information about Wallet prefix, I've made some changes to my application but it doesn't work..

              Here's another example :

              Code:
              Request: {"jsonrpc":"2.0","method":"SportsAPING/v1.0/listMarketCatalogue","id":"1","params":{"sort":"FIRST_TO_START","locale":"it_IT","marketProjection":["RUNNER_DESCRIPTION"],"maxResults":"1","filter":{"eventTypeIds":["1"],"marketTypeCodes":["MATCH_ODDS"],"marketStartTime":{"from":"2014-06-16T08:42:40.145Z"}}}}
              
              Response: {"jsonrpc":"2.0","result":[{"marketId":"1.113945928","marketName":"Esito Finale","totalMatched":6193.390360000001,"runners":[{"selectionId":18,"runnerName":"Germania","handicap":0.0,"sortPriority":1},{"selectionId":19,"runnerName":"Portogallo","handicap":0.0,"sortPriority":2},{"selectionId":58805,"runnerName":"Pareggio","handicap":0.0,"sortPriority":3}]}],"id":"1"}
              
              Market Name: Esito Finale; Id: 1.113945928
              
              Runner Name: Germania; Selection Id: 18
              
              Runner Name: Portogallo; Selection Id: 19
              
              Runner Name: Pareggio; Selection Id: 58805
              Here's the Betfair Url Graph :
              http://uk.site.sports.betfair.com/be...&asianLineId=0

              I don't see any graph and get an error

              Why?
              Thanks

              Comment

              • gus
                Senior Member
                • Jan 2009
                • 134

                #8
                I'm not entirely sure whether 'Esito Finale' is the same a s 'Match Odds', but if it is, then your MarketId doesn't look right:

                The addresses for Match Odds: Germany, Portugal, Draw, repectively are:

                Code:
                http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=112173628&selectionId=18&asianLineId=0
                
                 http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=112173628&selectionId=19&asianLineId=0
                
                http://uk.site.sports.betfair.com/betting/LoadRunnerInfoChartAction.do?marketId=112173628&selectionId=58805&asianLineId=
                0
                http://uk.site.sports.betfair.com/be...&asianLineId=0

                http://uk.site.sports.betfair.com/be...&asianLineId=0

                http://uk.site.sports.betfair.com/be...5&asianLineId=

                Comment

                • BigSprout
                  Junior Member
                  • Feb 2011
                  • 60

                  #9
                  silentman13,
                  I think you have an error in your URL, I tried yours and got an error.

                  I tried my Url (with your marketId/selectionId) and received a message saying the market has closed (or words to that effect)

                  The difference in our URL's is:

                  Yours
                  ......//LoadRunnerInfoChartAction.do....

                  Mine:
                  ......//LoadRunnerInfoAction.do....

                  i.e.
                  remove "Chart" from your URL and see if that is the problem

                  Hope this helps


                  ah,
                  Gus got in before me and it seems that it doesn't make any difference?
                  Last edited by BigSprout; 16-06-2014, 01:00 PM.

                  Comment

                  • silentman13.
                    Junior Member
                    • Feb 2013
                    • 20

                    #10
                    Originally posted by gus View Post
                    I'm not entirely sure whether 'Esito Finale' is the same a s 'Match Odds', but if it is, then your MarketId doesn't look right:

                    The addresses for Match Odds: Germany, Portugal, Draw, repectively are:

                    ...
                    Yes Gus. My example is the same as 'Match Odds' with locale it_IT as param.

                    I don't know why API-NG return different marketId for the same event...

                    The only difference between mine and your url is 'marketId'..

                    Can someone try this API NG request?

                    Code:
                    Request: {"jsonrpc":"2.0","method":"SportsAPING/v1.0/listMarketCatalogue","id":"1","params":{"sort":"FIRST_TO_START","locale":"en","marketProjection":["RUNNER_DESCRIPTION"],"maxResults":"1","filter":{"eventTypeIds":["1"],"marketTypeCodes":["MATCH_ODDS"],"marketStartTime":{"from":"2014-06-16T14:22:23.160Z"}}}}
                    Last edited by silentman13.; 16-06-2014, 01:32 PM.

                    Comment

                    • silentman13.
                      Junior Member
                      • Feb 2013
                      • 20

                      #11
                      Hi.

                      I'm using 'listMarketCatalogue' method like this :

                      Code:
                      Request: {"jsonrpc":"2.0","method":"SportsAPING/v1.0/listMarketCatalogue","id":"1","params":{"sort":"FIRST_TO_START","locale":"en","marketProjection":["RUNNER_DESCRIPTION"],"maxResults":"1","filter":{"eventTypeIds":["1"],"marketTypeCodes":["MATCH_ODDS"],"marketStartTime":{"from":"2014-06-16T14:22:23.160Z"}}}}
                      
                      Response: {"jsonrpc":"2.0","result":[{"marketId":"1.113945928","marketName":"Match Odds","totalMatched":10780.408415999998,"runners":[{"selectionId":18,"runnerName":"Germany","handicap":0.0,"sortPriority":1},{"selectionId":19,"runnerName":"Portugal","handicap":0.0,"sortPriority":2},{"selectionId":58805,"runnerName":"The Draw","handicap":0.0,"sortPriority":3}]}],"id":"1"}
                      
                      Market Name: Match Odds; Id: 1.113945928
                      
                      Runner Name: Germany; Selection Id: 18
                      
                      Runner Name: Portugal; Selection Id: 19
                      
                      Runner Name: The Draw; Selection Id: 58805
                      But Betfair graph use another marketId (112173628). Why?

                      http://uk.site.sports.betfair.com/be...&asianLineId=0

                      Thanks

                      Comment

                      • BetfairDeveloperProgram
                        Administrator
                        • Oct 2008
                        • 679

                        #12
                        Hi silentman13.

                        The graph URL's on the old version of the site carry the old marketId format, but those on the new version of the site match the format returned by API-NG i.e. http://www.betfair.com/exchange/foot...selectionId=18

                        Thanks

                        Neil

                        Comment

                        • silentman13.
                          Junior Member
                          • Feb 2013
                          • 20

                          #13
                          Originally posted by Betfair Developers Program View Post
                          Hi silentman13.

                          The graph URL's on the old version of the site carry the old marketId format, but those on the new version of the site match the format returned by API-NG i.e. http://www.betfair.com/exchange/foot...selectionId=18

                          Thanks

                          Neil
                          Thanks but, due to italian betfair restriction, I cannot access this url... What a sadness these kind of country limitations..

                          Example match odds - JJK vs Haka :
                          http://www.betfair.com/exchange/foot...ctionId=799035

                          I'm pretty sure you can access this url. I cannot

                          1) When will be enabled on betfair.it?
                          2) What about other sport's graphs url?

                          Thanks

                          Comment

                          Working...
                          X