Fetch prize
From ePrize Developers Wiki
API Home Page :: Games and Awards
Summary
Look up information about a prize. The redemption of a token will return a prize in the response if the user is a winner, but will not provide information about the prize itself. This resource is used to return information on a prize.
Important: a 200 OK response from this resource does not indicate a user has won the prize. A win should only be interpreted as such during token redemption.
Also note that the prize description may not make sense to a consumer. The created application is expected to translate the name appropriately before displaying it to the user.
Resource
/v1/{apikey}/game/{game}/prize/{prize}
Valid Methods
GET
Resource Arguments
Note: resource arguments are always required.
apikey: Your API Key.
gameId: Game Identifier for the Sweepstakes into which the entry will be awarded. (A constant value provided to you by Helloworld)
prize: Identifier for the prize retrieved after a win during a token redemption.
Parameters Required
None
Example: Requesting a Valid Prize
Summary
This demonstrates a good request for a prize that exists.
Response
HTTP Status Code: 200 OK
<?xml version="1.0" encoding="UTF-8"?> <result ver="1.0"> <prize> <id>{prize}</id> <description>{prize-description}</description> <game>{game}</game> </prize> </result>
Example: Requesting An Invalid Prize
Summary
This demonstrates a good request for a prize that does not exist.
Response
HTTP Status Code: 404 Not Found
<?xml version="1.0" encoding="UTF-8"?> <result ver="1.0"> <status>0</status> </result>