logout?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • bnl
    Junior Member
    • Nov 2012
    • 108

    #1

    logout?

    I'm thinking of migrating login/logout to api-ng this weekend.
    I've seen the approach of POST()ing user/pwd
    using the interactive approach, which I will try.

    (By the way, WHY does betfair want me to upload the PRIVATE key?)


    Anyway, I have not seen anything that I understand about logout?
    How does one logout?
    How do I use the below info?
    Anyone have a code sample?

    Code:
    Logout
    URL definition
    International jurisdictions:
    https://identitysso.betfair.com/api/logout
    ...
      
    Parameters
        product (mandatory) - The Application key to which the user is logging into.
        eg. Ljdiejje9399rew
        url (mandatory) - The url to which the the browser should be redirected in case of a successful logout. This will be https://www.betfair.com by default but additional URLs can be added to a whitelist by arrangement with Betfair.
        eg. https://www.betfair.com
    
     
    Cookies
    Name
    	
    Description
    mSsoToken (mandatory)	the value associated to the session token
    ssoid (mandatory)	the value associated to the session token
    loggedIn (mandatory)	A simple value of 'true'
    /Björn
  • clerk
    Junior Member
    • Feb 2014
    • 10

    #2
    Response to a request login
    {"token":"GOP59p3iWMYaxmbdOd4g5fn5bWbamPydQPfNDGq1 rvE=","product":"myAppKey","status":"SUCCESS","err or":""}


    Response to a request logout
    {"token":"GOP59p3iWMYaxmbdOd4g5fn5bWbamPydQPfNDGq1 rvE","product":"myAppKey","status":"SUCCESS","erro r":""}

    The only difference is in the sign "=" at the end of the token.
    Does this mean that the output of place?

    Comment

    • AlgoTrader
      Junior Member
      • Mar 2012
      • 243

      #3
      When HTTP request has HTTP header that asks JSON reply, then Betfair replies with JSON but not HTML.

      Accept: application/json
      Betfair Bots Made Easy

      Comment

      • clerk
        Junior Member
        • Feb 2014
        • 10

        #4
        Do not misunderstand. What do you mean?

        Comment

        • merecat_
          Junior Member
          • May 2009
          • 35

          #5
          "By the way, WHY does betfair want me to upload the PRIVATE key?"

          That's a good question, and I wondered the same when I read something somewhere along the lines... do not share your private key with anyone!!

          Like most people I'm an SSL ignoramus, using it every day but mostly in ignorance of how it really works.

          I used to think if communications were two way and traffic must be encrypted, then both parties need the means to decrypt, it's not good enough for one party to have both public and private keys, and the other to only have the public key (that is only good for encrypting). However it is possible to do this because the client with only the public key can dynamically create a key and pass it securely to the other client.

          I've just read up on it and am still none the wiser, one day I may actually understand it.

          Perhaps Betfair require the private key as a further means to authenticate users.

          Comment

          • bnl
            Junior Member
            • Nov 2012
            • 108

            #6
            "By the way, WHY does betfair want me to upload the PRIVATE key?"

            to answer myself,
            http://en.wikipedia.org/wiki/Public-key_cryptography

            That is THEY need to decrypt what I encrypt.
            So I encrynpt with a public key, and BF decryft my message with MY private key.
            Got It.

            BUT, POST()ing - using the interactive login - is much simpler.
            Why have two ways ?
            /Björn

            Comment

            Working...
            X