Load All Offers
POST/client/users/:correlation_id/offers
Loads all unaccepted offers that are currently ongoing as determined by their display date, start date and end date. This API accepts the same reply options as the single Respond to offer API, thereby allowing the following acceptance states: "ACCEPTED", "DECLINED", and "UNACCEPTED".
Request
Body
| Attribute | Definition | Format | Notes |
|---|---|---|---|
| acceptanceState | Whether or not the offer has been accepted | Enum: "ACCEPTED", "DECLINED", or "UNACCEPTED" |
Response
| Attribute | Definition | Format | Notes |
|---|---|---|---|
| accountID | The ID of the account associated with the offer | String | |
| offerCode | Primary key that identifies the offer | String | Unique string value |
| acceptanceDate | ISO-compliant date and time stamp when the offer was accepted | String | |
| acceptanceDateEpoch | Epoch date and time stamp of when the offer was accepted | Number | Epoch date and time are in milliseconds |
| acceptanceState | Whether or not the offer has been accepted | Enum: "ACCEPTED", "NONE", or "COMPLETED" | |
| effectiveDate | Start date/time which the offer becomes live | String | Valid ISO date or date-time string |
| expiryDate | Date/time which the offer expires | String | Valid ISO date or date-time string. If empty, the offer does not expire. |
| effectiveDateEpoch | Epoch date and time stamp of when the offer started | Number | Epoch date and time are in milliseconds |
| expiryDateEpoch | Epoch date and time stamp of when the offer expired | Number | Epoch date and time are in milliseconds |
| version | Version of the offer | Number | Incremented every time the offer is updated |
Error Responses
| statusCode | errorMessage | errorCode | Definition |
|---|---|---|---|
| 400 Bad Request | Invalid business unit(s) provided. | INVALID_BUSINESS_UNIT | |
| 400 Bad Request | Current date is after expiry date. | INVALID_REQUEST | Cannot load expired offer(s). |
Request
Responses
- 200
- 400
200 - All Accepted Offers Loaded
Response Headers
Date
Example:
Fri, 18 Dec 2020 19:44:16 GMTContent-Length
Example:
1751Connection
Example:
keep-alivex-amzn-RequestId
Example:
8f25feb6-0c79-4191-b685-cedde313655bReferrer-Policy
Example:
no-referrerX-XSS-Protection
Example:
1;mode=blockAccess-Control-Allow-Origin
Example:
*APPID
Example:
ES-CB-V1MSGID
Example:
66040025-2ea2-4782-bec1-466da63d35ceExpect-CT
Example:
max-age=86400Strict-Transport-Security
Example:
max-age=31536000Feature-Policy
Example:
vibrate 'none'; geolocation 'none'X-Frame-Options
Example:
sameoriginContent-Security-Policy
Example:
connect-src 'none';object-src https://*.cloudfront.net;script-src https://*.cloudfront.netMSGTIMESTAMP
Example:
December 18th 2020, 7:44:16x-amz-apigw-id
Example:
Xw32kFMwoAMFo7g=cache-control
Example:
no-cache, no-store, must-revalidateCORRELATIONID
Example:
cd4e126a-f0fa-c00e-f1e3-fc2d319203c7X-Content-Type-Options
Example:
nosniffX-Amzn-Trace-Id
Example:
Root=1-5fdd0690-2c344d38125d335a5507c936;Sampled=0400 - Business Unit Not Valid