Fetch token

From ePrize Developers Wiki

Revision as of 16:10, 24 March 2009 by Brian-quail (Talk | contribs)
Jump to: navigation, search

API Home Page :: Games and Awards

Summary

TODO: Fill me in.





Example: Requesting A Valid Token

Summary

This demonstrates a good request for a token that exists.


Response

HTTP Status Code: 200 OK


<?xml version="1.0" encoding="UTF-8" ?>
<result ver="ePrize Web Services 1.0">
  <result>
    <token>
      <id>1</id>
      <user>Bill</user>
      <game>12345-1234-1234-1234</game>
    </token>
  </result>
  <status>1</status>
</result>


Request representation: empty

Response:
200 OK
game: {game},
profile: {profile},
redeemed: {redeemed?},
awards: [
  prizes: [
    /v1/{apikey}/game/{game1}/prize/{prize},
    ...
  ],
  tokens: [
    /v1/{apikey}/game/{game2}/token/{token},
    ...
  ]
]
actions: [
  redeem: /v1/{apikey}/game/{game}/token/{token}
]

Response if token doesn't exist:
404 Not Found

The redeem action does not appear on tokens that may not be redeemed.

Personal tools