Coupons

The coupons resource is very basic. All of the mobile coupons you've created through the SlickText dashboard are available through the API. The following actions can be performed on this resource...

Retrieve All Coupons

By default, the first set of 20 coupons will be returned, but you can modify this number with limit and offset values in the query string. The max limit for a single request is 10,000.

GET https://api.slicktext.com/v1/coupons?limit=30&offset=10

Example response:


                    {
                        "meta": {
                            "limit": 20,
                            "offset": 0,
                            "total": 2
                        },
                        "links": {
                            "self": "https://api.slicktext.com/v1/coupons/"
                        },
                        "coupons": [
                            {
                                "id": 114557,
                                "couponHash": "628a5631d7e8f8a8d2e4R185689f0f9a",
                                "couponName": "Tom's Grill - Weekend Special",
                                "couponDescription": "Used only on the weekends",
                                "couponLink": "https://slkt.io/xyz",
                                "created": "2017-10-28 19:20:07"
                            },
                            {
                                "id": 114558,
                                "couponHash": "92dha631d5e8f8a8d2e4R1856f9f3f9a",
                                "couponName": "Tom's Grill - Weekday Special",
                                "couponDescription": "Used only on the weekdays",
                                "couponLink": "https://slkt.io/xGz",
                                "created": "2017-10-28 19:22:11"
                            }
                        ]

                    }
                    

Retrieve a Specific Coupon

Retrieves the single coupon with the id equal to {id}

GET https://api.slicktext.com/v1/coupons/{id}

Example response:


                    {

                        "links": {
                            "self": "http://api.slicktext.com/v1/coupons/1157"
                        },
                        "coupon": {
                            "id": 114558,
                            "couponHash": "92dha631d5e8f8a8d2e4R1856f9f3f9a",
                            "couponName": "Tom's Grill - Weekday Special",
                            "couponDescription": "Used only on the weekdays",
                            "couponLink": "https://slkt.io/xGz",
                            "created": "2017-10-28 19:22:11"
                        }
                    }