Skip to content

Sale Invoice

Sale Invoices are simplified invoices for B2C retail transactions where buyer tax information is not required.

Overview

AttributeValue
ServiceSaleInvoiceService
Tax DeductibleNo
Buyer InfoOptional
CQT SubmissionRequired

When to Use

  • Retail sales to individual consumers
  • Customer doesn't need tax deduction
  • Quick checkout scenarios
  • Anonymous sales

Required Fields

typescript
{
  // Seller (your company)
  seller: {
    taxCode: '0123456789',
    name: 'Your Company',
    address: '123 Street',
  },

  // Buyer (optional for sale invoices)
  buyer: {
    name: 'Walk-in Customer', // Can be generic
  },

  // Invoice details
  invoiceDate: new Date(),
  currencyCode: 'VND',

  // Items
  items: [
    {
      itemName: 'Product',
      quantity: 1,
      unitPrice: 50000,
      amount: 50000,
    },
  ],

  // Totals
  totalAmount: 50000,
  totalPayment: 50000,
}

Create Sale Invoice

typescript
import { SaleInvoiceService } from '@nx-3rd/iiapi';

const invoice = await this.saleInvoiceService.create({
  seller: {
    taxCode: process.env.COMPANY_TAX_CODE,
    name: process.env.COMPANY_NAME,
    address: process.env.COMPANY_ADDRESS,
  },

  buyer: {
    name: customerName || 'Khách lẻ', // Walk-in customer
  },

  invoiceDate: new Date(),
  currencyCode: 'VND',

  items: cartItems.map(item => ({
    itemName: item.name,
    unitName: item.unit || 'Cái',
    quantity: item.quantity,
    unitPrice: item.price,
    amount: item.quantity * item.price,
  })),

  totalAmount: cartTotal,
  totalPayment: cartTotal,
  paymentMethod: 'CASH',
});

Difference from VAT Invoice

AspectVAT InvoiceSale Invoice
Buyer tax codeRequiredNot required
Tax deductibleYesNo
VAT breakdownDetailedSimplified
Use caseB2BB2C retail

Proprietary and Confidential. Unauthorized copying, distribution, or use of this software is strictly prohibited.