Skip to main content
GET
/
earning_rules
List earning rules
curl --request GET \
  --url https://api.smile.io/v1/earning_rules \
  --header 'Authorization: Bearer <token>'
{
  "earning_rules": [
    {
      "id": 739246764,
      "name": "Place an order",
      "image_url": "https://platform.smile.io/images/earning/order-online.svg",
      "action_text": "null",
      "action_url": "null",
      "restricted_to_vip_tier_ids": [
        {}
      ],
      "reward": {
        "type": "points"
      },
      "reward_value": {
        "type": "variable",
        "variable": {
          "value": 5,
          "per_amount": 1
        },
        "fixed": {
          "value": 100
        }
      },
      "earning_limit": {
        "max": 5,
        "type": "rolling",
        "rolling": {
          "unit": "day",
          "unit_count": 30
        }
      }
    }
  ],
  "metadata": {
    "next_cursor": "aWQ6MixkaXJlY3Rpb246bmV4dA==",
    "previous_cursor": ""
  }
}
This endpoint requires the scope.
Results are sorted by id in descending order.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

limit
integer
default:50

The maximum number of earning rules to retrieve.

Required range: 1 <= x <= 250
cursor
string

Cursor for the page of earning rules to retrieve.

Response

200 - application/json
earning_rules
object[]
metadata
object