Smile.io

App · 11 actions

Read customers, points, rewards and loyalty settings in Smile.io.

Actions

ActionWhat it does
Get customerGet customer.
Get points productGet points product.
Get points settingsGet points settings.
Get points transactionGet points transaction.
Get referral settingsGet referral settings.
List customersList customers.
List earning rulesList earning rules.
List points productsList points products.
List points transactionsList points transactions.
List reward fulfillmentsList reward fulfillments.
List vip tiersList vip tiers.

Get customer

Get customer.

Inputs

Customercustomer_idnumberRequired
ID of the customer (in Smile) to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "customer": {
      "created_at": "example",
      "date_of_birth": "example",
      "email": "example",
      "first_name": "example",
      "id": 1,
      "last_name": "example",
      "points_balance": 1,
      "referral_url": "example",
      "state": "candidate",
      "updated_at": "example",
      "vip_status": {
        "current_vip_period_end": "example",
        "delta_to_next_vip_tier": 1.0,
        "delta_to_retain_vip_tier": 1.0,
        "next_vip_tier_id": 1,
        "progress_value": 1.0,
        "vip_tier_expires_at": "example",
        "vip_tier_id": 1
      },
      "vip_tier_id": 1
    }
  }
}

Get points product

Get points product.

Inputs

Points productpoints_product_idnumberRequired
ID of the points product to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "points_product": {
      "created_at": "example",
      "exchange_description": "example",
      "exchange_type": "fixed",
      "id": 1,
      "points_price": 1,
      "reward": {
        "created_at": "example",
        "description": "example",
        "id": 1,
        "image_url": "example",
        "name": "example",
        "updated_at": "example"
      },
      "updated_at": "example",
      "variable_points_max": 1,
      "variable_points_min": 1,
      "variable_points_step": 1,
      "variable_points_step_reward_value": 1
    }
  }
}

Get points settings

Get points settings.

Inputs

None.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "points_settings": {
      "points_label": {
        "one": "example",
        "other": "example"
      }
    }
  }
}

Get points transaction

Get points transaction.

Inputs

Points transactionpoints_transaction_idnumberRequired
ID of the points transaction to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "points_transaction": {
      "created_at": "example",
      "customer_id": 1,
      "description": "example",
      "id": 1,
      "internal_note": "example",
      "points_change": 1,
      "updated_at": "example"
    }
  }
}

Get referral settings

Get referral settings.

Inputs

None.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "referral_settings": {
      "receiver_reward": {
        "image": {
          "content_type": "example",
          "url": "example"
        },
        "name": "example"
      },
      "sender_reward": {
        "image": {
          "content_type": "example",
          "url": "example"
        },
        "name": "example"
      },
      "status": "active"
    }
  }
}

List customers

List customers.

Inputs

Emailemailtext
Filter results to only customers with the provided email address.
Statestatetext
Filter results to only customers with the provided state.One of: candidate, member, disabled.
Updated at minupdated_at_mindate and time
Filter results to only customers updated after the provided date and time.
Limitlimitnumber
The maximum number of customers to retrieve.From 1 to 250.
Cursorcursortext
Cursor for the page of customers to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "customers": [],
    "metadata": {
      "next_cursor": "example",
      "previous_cursor": "example"
    }
  }
}

List earning rules

List earning rules.

Inputs

Limitlimitnumber
The maximum number of earning rules to retrieve.From 1 to 250.
Cursorcursortext
Cursor for the page of earning rules to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "earning_rules": [],
    "metadata": {
      "next_cursor": "example",
      "previous_cursor": "example"
    }
  }
}

List points products

List points products.

Inputs

Exchange typeexchange_typetext
Filter results to only points products with the provided `exchange_type`.One of: fixed, variable.
Page sizepage_sizenumber
The maximum number of points products to retrieve.From 1 to 250.
Pagepagenumber
The page of points products to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "points_products": []
  }
}

List points transactions

List points transactions.

Inputs

Customer idcustomer_idnumber
Filter results to only points transactions with the provided Smile customer ID.
Updated at minupdated_at_mindate and time
Filter results to only points transactions updated at or after the provided date and time.
Limitlimitnumber
The maximum number of points transactions to retrieve.From 1 to 250.
Cursorcursortext
Cursor for the page of points transactions to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "metadata": {
      "next_cursor": "example",
      "previous_cursor": "example"
    },
    "points_transactions": []
  }
}

List reward fulfillments

List reward fulfillments.

Inputs

Customer idcustomer_idnumber
Filter results to only reward fulfillments with the provided Smile customer ID.
Fulfillment statusfulfillment_statustext
Filter results to only reward fulfillments whose fulfillment status matches the provided value.One of: pending, issued, cancelled, failed.
Usage statususage_statustext
Filter results to only reward fulfillments whose usage status matches the provided values.One of: used, unused, untracked.
Updated at minupdated_at_mindate and time
Filter results to only reward fulfillments updated after the provided date and time.
Limitlimitnumber
The maximum number of reward fulfillments to retrieve.From 1 to 250.
Cursorcursortext
Cursor for the page of reward fulfillments to retrieve.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "metadata": {
      "next_cursor": "example",
      "previous_cursor": "example"
    },
    "reward_fulfillments": []
  }
}

List vip tiers

List vip tiers.

Inputs

None.

Outputs

dataobject
The response from Smile.io.
Example output
{
  "data": {
    "vip_tiers": []
  }
}

On this page