Problems with Place Order

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • BigSprout
    Junior Member
    • Feb 2011
    • 60

    #1

    Problems with Place Order

    Hi, I am having problems with placing a bet and would appreciate a hand in identifing my error with the json request.

    This is a horse race in Aus for a Lay bet of size $5 @ price of $1.01 - I understand that id=1 is for the UK exchange and id=2 is for the Aus exchange, anyway the jsonrequest:

    Code:
    {"jsonrpc":"2.0","method":"SportsAPING/v1.0/placeOrders","params":{"marketId":"2.100952240","instructions":[{"selectionId":8497273,"handicap":0.0,"side":"LAY","orderType":"LIMIT","limitOrder":{"size":5.0,"Price":1.01,"persistenceType":"LAPSE"}}],"customRef":"Lay_Win Test Bet"},"id":2}

    and the response:

    Code:
    {"jsonrpc":"2.0","error":{"code":-32602,"message":"DSC-0018"},"id":2}

    I have switched to the live AppKey before sending the request and there is funds in my Aus wallet

    cheers Les



    Update - noted it should be customerRef instead of customRef, I have changed that but still get the same error
    Last edited by BigSprout; 02-05-2014, 04:53 AM. Reason: Noted an error
  • waynebrayn
    Junior Member
    • Feb 2010
    • 7

    #2
    I think the ID should also be 1 for the Australian exchange.

    Comment

    • BigSprout
      Junior Member
      • Feb 2011
      • 60

      #3
      Tks Wayne,

      I have tried id=1, but it didn't seem to make any difference (tried id=9 as well), I don't think the id does anything at the moment as even calling marketCatologue or marketBook with id=1,2 or 9 worked, but no joy with placeOrders.

      I am doing something basically wrong and just can't put my finger on it

      cheers Les

      Comment

      • BigSprout
        Junior Member
        • Feb 2011
        • 60

        #4
        Quick Update

        Changed id to id=1 & amended customerRef:
        MarketId & SelectionId are valid as I tried them on the visualiser

        Code:
        {"jsonrpc":"2.0","method":"SportsAPING/v1.0/placeOrders","params":{"marketId":"2.100952252","instructions":[{"selectionId":8421143,"handicap":0,"side":"LAY","orderType":"LIMIT","limitOrder":{"size":5.0,"Price":1.01,"persistenceType":"LAPSE"}}],"customerRef":"LayWinTestBet"},"id":1}
        same response:
        Code:
        {"jsonrpc":"2.0","error":{"code":-32602,"message":"DSC-0018"},"id":1}

        Comment

        • betdynamics
          Junior Member
          • Sep 2010
          • 534

          #5
          In the limitOrder part of the request, change "Price" to "price"

          Comment

          • BigSprout
            Junior Member
            • Feb 2011
            • 60

            #6
            Thanks betdynamics, I believed it was something stupid that I was doing wrong, but I just couldn't pick it

            cheers Les

            Comment

            Working...
            X