Skip to main content
This guide walks you through integrating Pillar8 into your checkout to start receiving decision packages. The integration is lightweight and requires no changes to your existing payment stack.
1

Add Pillar8 to Checkout

Install the Pillar8 client in your checkout environment.The component:
  • Captures checkout context (device, country, cart, payment methods)
  • Sends a request to the Pillar8 decision engine
  • Receives a decision package in real time
2

Call the Optimize API

Your checkout integration sends a request to:POST /api/shopify/checkout-optimize

Example Request

{
  "shop_domain": "example.myshopify.com",
  "cart_value": 85,
  "currency_code": "EUR",
  "country_code": "DE",
  "device_type": "mobile",
  "checkoutToken": "abc123",
  "default_fops": ["card", "paypal", "klarna"],
  "presented_payment_methods": ["card", "paypal", "klarna"]
}
3

Receive Decision Package

Pillar8 returns a decision package for the checkout session.

Example Response

{
  "status": "ok",
  "ab_variant": "optimize",
  "was_optimized": true,
  "shadow_engine": {
    "scored": [
      { "code": "paypal", "score": 0.82 },
      { "code": "card", "score": 0.74 }
    ]
  },
  "gating_passed": true
}
4

Apply the Decision

Use the decision package to:
  • Display an advisory recommendation to the shopper
  • Highlight or emphasize specific payment methods
  • Adjust checkout behavior
5

Send Transaction Outcome (Webhook)

Configure your backend to send transaction outcomes to Pillar8.POST /api/shopify/webhooks/order-completedThis enables Pillar8 to:
  • Learn from actual payment outcomes
  • Improve future decisions
  • Measure impact
Typical integration time: a few hours to a couple of days

What Does Not Change

  • Your PSP integrations remain unchanged
  • Your orchestration layer remains unchanged
  • Your payment routing remains unchanged
Pillar8 operates before payment execution.

Next Steps

  • See API for full endpoint definitions
  • Review Architecture to understand system flow
  • Check Platforms → Shopify for platform-specific details