Skip to content
Cartly Developers

Webhooks

Receive real-time notifications when events occur in a Cartly store.

Available Events

Subscribe to these webhook event types

NameTypeRequiredDescription
order.createdeventNoFired when a new order is placed
order.updatedeventNoFired when order status changes
order.paideventNoFired when payment is confirmed
product.createdeventNoFired when a product is created
product.updatedeventNoFired when a product is modified
product.deletedeventNoFired when a product is deleted
customer.createdeventNoFired when a customer registers
app.uninstalledeventNoFired when your app is uninstalled

Verify Webhook Signature (HMAC-SHA256)

javascript
const crypto = require('crypto');

function verifyWebhook(body, signature, secret) {
  const hmac = crypto.createHmac('sha256', secret);
  hmac.update(body, 'utf8');
  const digest = hmac.digest('hex');
  return crypto.timingSafeEqual(
    Buffer.from(signature),
    Buffer.from(digest)
  );
}

Retry Policy

Cartly retries failed webhook deliveries up to 5 times with exponential backoff. After 5 consecutive failures, the subscription is automatically disabled. Re-enable it from the admin panel or via the API.

Expected Response

Your endpoint must return a 2xx status code within 10 seconds. Any other response (or timeout) is treated as a failure.