Developers
  • Introduction
  • Integration
    • Spring Boot Starter
      • Overview
      • Setup your project
      • Product search
      • Invoicing
      • Merchant side invoicing
      • Merchant side purchase control
      • Loyalty cards
      • Home delivery
      • Marketing & Offers
    • Custom Integration
      • Overview
      • Connection node
        • Get node version endpoint
        • Get node health endpoint
      • Product search
        • Pageable product list search endpoint
        • Product bacrode search endpoint
        • Product name search endpoint
        • Product category search endpoint
      • Invoicing
        • Receive invoice endpoint
      • Merchant side invoicing
        • Create receipt endpoint
        • Confirm receipt payment endpoint
      • Merchant side purchase control
        • Receive purchase check endpoint
        • Send purchase check result
        • Ask for purchase check data resend
      • Loyalty cards
        • Loyalty card registration endpoint
        • Loyalty card bonus endpoint
      • Home delivery
        • Receive order endpoint
        • Receive order update endpoint
        • Update order status
        • Find order by id
        • Find order by invoice id
        • Find order by institution invoice id
      • Marketing & Offers
        • Find offers endpoint
  • General
    • Data object descriptions
      • HealthStatus
      • DefaultOffer
      • DiscountOffer
      • ProductRelatedOffer
      • OfferType
      • OfferClassification
      • Order
      • OrderStatusChangeLog
      • ColorTheme
      • LoyaltyCard
      • DefaultLoyaltyCard
      • BonusLoyaltyCard
      • LoyaltyCardType
      • LoyaltyCardValidationType
      • Shipment
      • ShipmentStatus
      • Category
      • Addition
      • Address
      • Currency
      • BuyerParty
      • Campaign
      • CampaignCode
      • ClientCard
      • Information
      • Inspection
      • Invoice
      • LangCode
      • Price
      • Product
      • Quantity
      • SellerParty
      • Total
      • TotalVAT
      • Translatable
      • Receipt
      • ReceiptProduct
      • ReceiptLoyaltyCard
      • ReceiptCategory
      • VAT
    • Request & Responses
      • NodeHealthResponse
      • NodeVersionResponse
      • OfferSearchRequest
      • PickupOrderStatusChangeRequest
      • LoyaltyCardBonusResponse
      • LoyaltyCardBonusRequest
      • LoyaltyCardRegistrationResponse
      • LoyaltyCardRegistrationRequest
      • PurchaseControlCheckResendRequest
      • PurchaseControlResult
      • PurchaseControlCheckResponse
      • PurchaseControlCheckRequest
      • ReceiptPaymentConfirmationRequest
      • InstitutionRequest
      • Pageable
      • PageRequest
      • CreateReceiptRequest
      • ProductSearchRequest
    • Campaign standard
Powered by GitBook
On this page
  • General Flow
  • Configuration
  • Implementation

Was this helpful?

  1. Integration
  2. Spring Boot Starter

Merchant side invoicing

Smarts offers merchant side invoice processing.

Implementation is OPTIONAL

General Flow

  1. Customer scans products to shopping cart.

  2. Smarts will send shopping cart to merchant when customer is ready to pay for the purchase.

  3. Merchant will response with generated receipt

  4. Customer will pay for receipt.

  5. Smarts will send receipt payment confirmation to merchant.

Configuration

Visit your store configuration page in Smarts manager UI. Switch store side invoicing to ON position and implement SDK required methods.

Implementation

You only need to create a new class, implement ReceiptAdapter interface and fill all required methods. API endpoints for merchant side invoicing are created automatically and secured with token.

It is important to add @Component annotation on top of the class. There is no restriction for class name or location in your project. Our SDK will find your implementation based on the interface (DI).

import ee.smarts.common.v1.Entities.receipt.Receipt;
import ee.smarts.common.v1.requests.CreateReceiptRequest;
import ee.smarts.common.v1.requests.ReceiptPaymentConfirmationRequest;
import ee.smarts.starter.adapter.ReceiptAdapter;
import org.springframework.stereotype.Component;
@Component
public class ReceiptAdapterImpl implements ReceiptAdapter {
    @Override
    public Receipt create(CreateReceiptRequest request) {
        // implement this method
        return null;
    }
    @Override

    public void confirmationListener(ReceiptPaymentConfirmationRequest request) {
        // implement this method
    } 
}

There is additional step for customer in payment process when using merchant side invoicing. Smarts shows generated receipt to customer before they are able to pay for the purchase.

PreviousInvoicingNextMerchant side purchase control

Last updated 5 years ago

Was this helpful?