Deem Offers API Documentation

User Saved Deals

A saved deal let’s a user keep a list of deals for future reference.

List all user’s saved deals

Returns an array of saved deal representations.

GET /users/:user_id/saved_deals

Parameters

count (optional)
Boolean Returns the count instead of the list. If present, per_page and page will be ignored.
per_page (optional)
Integer Limits the size of the list. Default is 100. Max is 1000.
page (optional)
Integer Returns the list corresponding to the page number if the result cannot be displayed in a single page. Default is 1.

Response

Status: 200 OK
{
  "status": "success",
  "saved_deals": [
    {
      "id": "adf93kd",
      "deal_id": "dk9d931",
      "user_id": "dk39dk2"
    }
  ]
}

Create a saved deal

Creates a saved deal for a user and a deal.

POST /saved_deals

Parameters

deal_id
String Id of the deal
user_id
String Id of the user

Response

Status: 200 OK
{
  "status": "success",
  "saved_deal": {
    "id": "adf93kd",
    "deal_id": "dk9d931",
    "user_id": "dk39dk2"
  }
}

Delete a saved deal

Deletes a saved deal.

DELETE /saved_deals/:saved_deal_id

Response

Status: 200 OK
{
  "status": "success"
}