Payment providers
Connect Shopify
Set up Shopify tracking, pass the click ID and verify a credited purchase.
This guide connects your customer checkout to Slice. It is separate from the payment method you add in Billing and the bank details publishers add in Payouts.
This provider connection is in beta. Complete a purchase and refund test before relying on it for a live program.
1. Before you start
- Create your business, product and campaign in Slice. An owner or admin can change payment integrations.
- Open Payment providers, select the correct product and choose Test mode first. Each product and mode has its own connection.
- A Shopify store where you can manage notification webhooks and edit the online-store theme.
- For testing, use a development/test store and a test payment gateway. Do not connect a production store's paid orders to Slice Test mode.
Choose one reporting path for each sale: a provider webhook connection or your own Conversions API integration. If your site already reports purchases to Slice, review it before enabling a second path; different order identifiers can produce duplicate sales.
2. Connect the provider
In Slice, open Shopify and click Connect to prepare this product's webhook URL. Keep the panel open while you configure the provider.
- In Shopify admin, open Settings, then Notifications, then Webhooks, then Create webhook.
- Choose the event, format JSON, and paste the URL from Slice. Create one for Order payment and one for Refund creation.
- At the bottom of the Webhooks page Shopify shows the secret your webhooks are signed with. Copy it.
- In your theme, add the click ID to the cart so it reaches the order: call /cart/update.js with attributes: { slice_click_id: window.Slice.clickId() } once on page load.
Select these events. If the provider has friendly event labels, use the matching labels shown in the instructions above:
orders/paid
refunds/createReturn to Slice, paste the shopify webhook signing secret and click Connect Shopify. Saving the secret does not prove checkout attribution works yet.
3. Pass the publisher's click ID
On your website, load slice.js on every landing page. It stores the visitor's sclid in the slice_click_id cookie. Your backend can read that cookie when creating checkout; in the browser, window.Slice.clickId() returns the same value after the script loads.
<script src="https://takeslice.com/slice.js" async></script>A cart attribute named slice_click_id, set once when the page loads. Keep the existing checkout configuration in the example below and add the attribution field; the snippets show the integration point, not a complete checkout. Only send an ID matching clk_ followed by 32 hexadecimal characters. Omit it if no valid click is available.
<script>
window.addEventListener("load", function () {
var id = window.Slice && window.Slice.clickId();
if (!id) return;
fetch("/cart/update.js", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ attributes: { slice_click_id: id } }),
});
});
</script>- Set the cart attribute before the customer proceeds to checkout. Use the store's locale-aware cart/update.js endpoint and preserve existing theme logic.
- The example applies to an online-store cart. Headless stores, Buy Now buttons, express flows and third-party checkouts need a developer to verify how the attribute reaches the order.
- Use the webhook signing secret shown for the admin-created webhook configuration, not a Storefront access token. A custom app's API secret belongs to a different webhook setup.
4. Test delivery and attribution
- Use Shopify's test notification to check delivery only; a sample order does not prove attribution.
- Follow a Slice test link to your test storefront, add an item to the cart and complete a paid test order. Check that the order carries the slice_click_id note attribute.
- Confirm orders/paid creates an attributed conversion, then refund the test order and check refunds/create.
Connected means credentials were saved. A received event means a delivery reached Slice. Only an attributed conversion proves the sale was credited to a publisher. Use a test link and matching sandbox purchase for the full check; test conversions create no money.
5. Switch to Live
Return to the same product's Payment providers page and choose Live. Create the production connection separately with the production account, endpoint and credentials. Do not reuse a test click for a live purchase. Confirm the production checkout carries attribution before sharing live publisher links.
Troubleshooting
- Invalid signature: confirm that the webhook was created in Shopify admin with the matching signing secret and JSON format.
- Order has no attribution: inspect note_attributes on the paid-order payload. A cart update that happens after checkout starts may be too late.
- A delivery stopped arriving: check Shopify's notification webhook configuration and delivery failures, then send a fresh test.
- No event in Slice: check the provider's delivery log, selected events and full HTTPS URL. Localhost cannot receive external webhooks without a public tunnel.
- No credited conversion: check the click ID, selected product, test/live mode, paid amount and currency. Slice currently supports EUR, USD and GBP.
- Disconnecting a webhook provider does not remove the endpoint from that provider's dashboard. Remove or disable it there too. Stripe endpoint removal is attempted automatically.
Official provider documentation
Provider instructions checked against the references below on 29 October 2026. Provider dashboards can change; the event names and attribution fields above describe what Slice currently handles.