Retrieve Fulfillment Information for Redemption

Request Details

Item Value
Description This endpoint will allow client to retrieve stored fulfillment information for a redemption.
Method GET
Endpoint https://[environment]api[client_id].crowdtwist.com/v2/users/[user_id]/redemption/[redemption_id]/
fulfillments?api_key=[api_key]&id_type=[id_type]
Content Type application/json

Request

Field Name Sample Value Required Format Description
URL PARAMETERS
user_id alice@crowdtwist.com Yes String User ID of the user for whom the reward will be redeemed.
The user ID can be:
– Email Address
– Facebook User ID
– Twitter User ID
– CrowdTwist ID
– Third Party ID
– Username
– Mobile Phone Number
redemption_id 6575765 Yes Integer This is the redemption order id obtained via redemption push.
QUERY PARAMETERS
api_key QWERTYUIOP Yes String  
id_type email No String Type of ID being sent, defaults will be Crowdtwist ID if not specified.
The type of ID can be:
– email
– facebook_user_id
– twitter_user_id
– id (CrowdTwist ID) – default ID if id_type is not specified
– third_party_id
– username
– mobile_phone_number

Response

Response Body

Field Name Sample Value Required Format Description
user_id 4534653 Yes Integer This is the internal crowdtwist identifier which uniquely identifies user.
redemption_id 642446 Yes Integer This is the variation ID of the reward.
first_name John Yes String User shipping first name.
last_name George Yes String User shipping last name.
street_address_1 110 east 23rd st Yes String Address line 1.
street_address_2 Floor 7 Yes String Address line 2.
country USA Yes String Country.
state NY Yes String State.
city New York Yes String City.
postal_code 10010 Yes String Postal Code.
phone_number 555-3333-444 Yes String Phone Number
tracking_info See the TRACKING INFO ARRAY section. Yes Array This returns redemption tracking information.
TRACKING INFO ARRAY        
tracking_number ABFTGDB34352 Yes String This is the shipment tracking number.
vendor_name UPS Yes String This is the shipment vendor.
fulfillment_date "2012-04-23T18:25:43Z" Yes String This is the date when item was fulfilled.
quantity 3 Yes Integer This is the quantity of reward fulfilled.
fulfillment_id 46445665 Yes Integer This is the identifier which uniquely identifies a fulfillment record.


Error Responses

Field Name Sample Value Required Format Description
error Field value is empty. Yes String This is a short form of the error.
message Value of field [fieldname] must not be empty. Yes String This is a detailed message around the error specifying, as specifically as possible, what the fields are that are missing or where exactly the error is.


Error Response Codes

Error Error Code Description Reason
Input Error 4xx Returned whenever the request is missing required fields, including situations in which the body is malformed (e.g. HTTP method not supported, receipt not found, etc.). – missing_data
– not_unique
– receipt_not_found
– invalid_amount
– invalid_currency
– invalid_date
– invalid_custom_field
– invalid
Server Error 5xx HTTP error status code is returned due to an error that occurred in the backend. – internal_error: unexpected error occurred in the CrowdTwist backend
– missing_field
– invalid_data
– not_configured: error occurs when an configuration has not been configured yet


Example Response Codes

Response Code Error Message
404 page_not_found User does not exist.
404 not_found Redemption not found.
400 required_property_missing Missing [fieldname] required field.

Samples

Sample Request

GET https://api.crowdtwist.com/v2/users/customer123/redemption?api_key=QWERTYUIOP&id_type=username


Sample Response Body

{ "user_id": 565999853, "redemption_id": 565675, "first_name": "John", "last_name": "George", "street_address_1": "110 east 23rd st", "street_address_2": "APT 1", "country": "USA", "state": "NY", "city": "New York", "postal_code": "10010", "phone_number": "456468948", "tracking_info": [ { "tracking_number": "A564FG16756757", "vendor_name": "UPS", "fulfillment_id": 4689568, "fulfillment_date": "2018-04-23T18:25:43Z", "quantity": 1 }, { "tracking_number": "4967834537", "vendor_name": "USPS", "fulfillment_id": 5689568, "fulfillment_date": "2019-04-23T18:25:43Z", "quantity": 2 } ] }


Sample Error Response

{ "error": "not_found", "message": "Redemption not found." }