SubmitCode
From ePrize Developers Wiki
(Difference between revisions)
(New page: ==Summary== Perform a code submission for a user '''Resource''' POST api/v1/submitCode '''Parameters''' memberId code '''Example Call''' http://demo-loyalty.promodev.eprize.com/api/v...) |
(→Summary) |
||
Line 5: | Line 5: | ||
'''Resource''' | '''Resource''' | ||
- | POST | + | POST api/v1/submitCode |
- | api/v1/submitCode | + | |
'''Parameters''' | '''Parameters''' | ||
- | memberId | + | * memberId |
- | code | + | * code |
- | + | ||
- | + | ||
- | + | ||
Example Request Body: | Example Request Body: | ||
- | { | + | { |
- | + | "memberId": 278000000118 | |
- | + | “code”: “TwilightPony” | |
- | } | + | } |
Example Response: Success | Example Response: Success | ||
- | { | + | { |
- | + | "success" : true, | |
- | + | “points” : 150 | |
- | } | + | } |
Example Response: Member Id not Found | Example Response: Member Id not Found | ||
- | { | + | { |
- | + | "Error": { | |
- | + | "Code": "error.business.Validation", | |
- | + | "Message": "Error for attribute: Member Id\nThis information is required.\n" | |
+ | } | ||
} | } | ||
- | } | ||
Example Response: Invalid Code | Example Response: Invalid Code | ||
- | { | + | { |
- | + | "Error": { | |
- | + | "Code": "error.generic.mergeValue", | |
- | + | "Message": "This is an invalid code." | |
+ | } | ||
} | } | ||
- | } |
Current revision
Summary
Perform a code submission for a user
Resource
POST api/v1/submitCode
Parameters
- memberId
- code
Example Request Body:
{ "memberId": 278000000118 “code”: “TwilightPony” }
Example Response: Success
{ "success" : true, “points” : 150 }
Example Response: Member Id not Found
{ "Error": { "Code": "error.business.Validation", "Message": "Error for attribute: Member Id\nThis information is required.\n" } }
Example Response: Invalid Code
{ "Error": { "Code": "error.generic.mergeValue", "Message": "This is an invalid code." } }