Integrations
Script that integrate Rating Captain with any system.
To integrate your website with our system you have to paste this code into your order summary page.
<script>
var RatingCaptain_data_script = {
/* REQUIRED | Email, on this address will be send message */
"email": "{$order->email}",
/* REQUIRED | Order in your system, this field should be unique */
"external_id": "{$order->id}",
/* Optional - Customer name or name and surname. */
"name":"{$order->name}",
/* Optional - Customer phone. */
"phone":"{$order->phone}",
/* Optional - Products in this order, each product must have id name and price. */
"products": [
{
"id": "{$product->id}",
"name": "{$product->name}",
"price": "{$product->price}",
"imageUrl": "{$product->image}",
"sku": "{$product->sku}",
"product_url": "{$product->url}"
},
]
}
</script>
<script src="https://ratingcaptain.com/api/js_v2/[Your website token]"></script>
*Each item in bold must be properly configured depending on your system.
*my.Website token you can take from: Website page.
<script>
var rc_products = {/literal}[{foreach from=$items item=i name=list}
{
'id': '{$i->product_id}',
'name': '{$i->name}',
'price': '{$i->price_gross|money_without_currency}',
'imageUrl': '{$i->product->images[0]->url|product_img_url:th100}'
},
{/foreach}]{literal};
var RatingCaptain_data_script = {
"email": '{client_email}',
"external_id": '{order_id}',
"products": rc_products
}
</script>
<script src="https://ratingcaptain.com/api/js_v2/[Your website token]"></script>
<script>
var rc_products = [{products}
{
"id": "{products.product_id}",
"price": "{products.float_price}",
"imageUrl": "{products.img}",
"name": "{products.name}"
},
{/products}];
var RatingCaptain_data_script = {
"email": '{email}',
"external_id": '{order_id}',
"products": rc_products
}
</script>
<script src="https://ratingcaptain.com/api/js_v2/[Your website token]"></script>
<script>
var RatingCaptain_data_script = {
"email": "[[email]]",
"external_id": "[[orderid]]"
}
</script>
<script src="https://ratingcaptain.com/api/js_v2/[Your website token]"></script>
If you want integrate your website with backend, you can use our PHP library.
See in GitHub
Also you can find our Ecommerce plugins.
1. WooCommerce
- Download WooCommerce plugin
How to install:
1. Download WooCommerce plugin from link above
2. Go to Plugins -> Add plugin page
3. Upload ZIP file that you download in first step.
4. Enable plugin
5. Go to Settings -> RatingCaptain Page
6. Insert your website API key. You can get your key here https://ratingcaptain.com/app/website
7. Save changes
8. Your order will be integrate with Ratingcaptain system when you change status to completed.
See Tutorial Video
3. Prestashop Plugin
- Download prestashop 1.7 plugin
- Download prestashop 1.6 plugin
How to install:
1. Go to "Modules" section
2. Upload file downloaded from section above
3. Configure plugin
4. Insert API key from website https://ratingcaptain.com/app/website => Website Token
5. Save changes
See tutorial Video
4. Shoplo
- Go to Settings panel
- Go to Conversion and tracking tab
- Paste code below in thank you script section
5. SHOPER
- Go to "Add-ons and integrations"
- Go to "Own integrations"
- Paste this code into "Order confirmation" section
5. GoShop
- Go to Store configuration -> Preferences
- Go to external codes section
- In order confirmation section paste code below