Skip to main content
Explore common integration scenarios and learn how to implement them using the ClearLine POS API. Each use case includes a business overview, technical approach, required endpoints, and working code examples.

šŸ›’ Process POS Transaction → Trigger Loyalty

When a customer completes a purchase at the point of sale, automatically record the transaction and award loyalty points or trigger marketing actions based on their purchase behavior.
This workflow involves three key steps:
  1. Start Interaction - Initialize a POS session for the terminal
  2. Send Transaction - Submit transaction details with customer data, items, amounts, and payment info
  3. Handle Response - Process loyalty points awarded and any triggered campaigns
API Endpoints Used:
Include customer contact information in the transaction request to enable loyalty tracking and marketing campaign triggers.

Learn More

View complete transaction API reference →

šŸŽŸļø Validate Coupon at Checkout

Enable cashiers to scan or enter coupon codes during checkout and validate them in real-time before applying discounts.
Workflow:
  1. Lookup Coupon - Search for a coupon by code
  2. Validate Coupon - Check coupon status and eligibility
  3. Apply Discount - Use coupon information to calculate discount in your POS
  4. Record Usage - Include coupon details in the transaction
API Endpoints Used:
The validate endpoint confirms the coupon exists and is active. Your POS system is responsible for applying business rules like minimum purchase amounts and calculating the actual discount.
These endpoints verify coupon existence and status. Your POS system must implement discount calculation logic based on the coupon details returned.

Learn More

View complete coupons API reference →

šŸ“ŗ Display Marketing Content with Widgets

Show interactive marketing content on customer-facing displays that customers can engage with to join loyalty programs, view offers, or receive digital receipts via QR code or SMS.
Workflow:
  1. List Widgets - Get available marketing actions for the location
  2. Start Widget Session - Launch a widget for customer interaction
  3. Show QR Code - Display QR code for mobile engagement
  4. Send Message - Deliver content via SMS/email
API Endpoints Used:Widget Types:
  • Loyalty enrollment
  • Promotion signup
  • Digital receipt delivery
  • Survey/feedback collection
Widgets are configured in the ClearLine admin portal. The list endpoint returns only active widgets for your location.

Learn More

View complete widgets API reference →

šŸ”„ Sync Product Catalog

Maintain an up-to-date product catalog in ClearLine by automatically syncing products, categories, and promotions from your POS or inventory management system on a scheduled basis.
Sync Strategies:API Endpoints Used:
  • POST /pos/{posSystemId}/company/{posCompanyId}/import/products - Import products
  • POST /pos/{posSystemId}/company/{posCompanyId}/import/productCategories - Import categories
  • POST /pos/{posSystemId}/company/{posCompanyId}/import/promotions - Import promotions
Data Requirements:
  • Product ID (unique identifier)
  • Product name
  • Price and category
  • Manufacturer (optional)
Optimization Tips:
  • Batch products in groups of 500-1000 for optimal performance
  • Schedule during off-peak hours (2-5 AM)
  • Implement retry logic with exponential backoff
  • Monitor sync completion and error rates

Learn More

View complete import API reference →

šŸ”§ Error Recovery & Retry Logic

Build resilient POS integrations that gracefully handle network failures, API errors, and timeout scenarios without losing transaction data or frustrating customers.
Common Error Scenarios:
  • Network timeouts (slow connection)
  • 5xx server errors (temporary API issues)
  • 4xx client errors (invalid requests)
  • Authentication failures (expired tokens)
  • Rate limiting (too many requests)
Retry Strategies:Best Practices:
  • Implement exponential backoff (1s, 2s, 4s, 8s…)
  • Log all retry attempts for debugging
  • Queue failed transactions for later submission
  • Display clear error messages to cashiers
  • Provide manual retry option in POS UI
Monitoring & Alerting:
  • Track retry rates in your monitoring system
  • Alert on high failure rates (>5% of requests)
  • Monitor average retry count per request
  • Set up alerts for queue depth (>100 failed requests)

Learn More

View error handling best practices →

Next Steps

Quick Start Guide

Get started with your first API integration

API Reference

Explore all available endpoints and parameters

Authentication Guide

Learn how to authenticate with ClearLine API

POS Integration

Detailed guides for POS integration workflows