SmartAcc DynaMod Web API v2024.4 Build 0000 - Local

<back to all web services

CustomerPurchasesHistoryPOS

Customer Module - Enquiry

Customer Purchase History API

Requires Authentication
Required permission:CustomerPurchaseHistoryPOS-Enquiry.GET
The following routes are available for this service:
GET/Customers/PurchaseHistoryPOS/{AcCustomerID}Get purchase history records for a given Customer IDPurchase history included all databases (if configured any) Cash Sales
CustomerPurchasesHistoryPOS Parameters:
NameParameterData TypeRequiredDescription
AcCustomerIDpathstringNo
CustomerPurchasesHistoryPOSResponse Parameters:
NameParameterData TypeRequiredDescription
CustomerPurchaseHistoryPOSformList<CustomerPurchaseHistoryPOS>No
ResponseStatusformResponseStatusNo
CustomerPurchaseHistoryPOS Parameters:
NameParameterData TypeRequiredDescription
DocumentNoformstringNoDocument Number
AcLocationIDformstringNoLocation ID
AcLocationDescformstringNoLocation Description
AcSalesmanIDformstringNoSalesman ID
AcSalesmanNameformstringNoSalesman Name
AcSalesmanID_ItemformstringNoSalesman ID (Item Level)
AcSalesmanName_ItemformstringNoSalesman Name (Item Level)
DocumentDateformDateTimeNoDocument Date
AcStockIDformstringNoStock ID
AcStockUOMIDformstringNoStock UOM ID
ItemStockBarcodeformstringNoBarcode
ItemRemark1formstringNoItem Remark 1
StockDescription1formstringNoStock Description 1
StockDescription2formstringNoStock Description 2
ItemQuantityformdecimalNoQuantity
ItemUnitPriceformdecimalNoUnit Price
ItemGrossTotalformdecimalNoGross Total. Unit Price * Quantity
ItemDiscountAmountformdecimalNoItem Discount Amount
ItemTotalPriceformdecimalNoItem Total Price. Gross Total - Discount
ItemPriceWithGSTformdecimalNoItem Unit Price (with Tax)
ItemDiscountAmountWithGSTformdecimalNoDiscount Amount (with Tax)
ItemGSTAmountformdecimalNoTax Amount
CreateByformstringNoCreate By
DocumentTimeformDateTimeNoDocument Time
SourceDBNameformstringNoSource DB Name for the transaction
IsStockDiscontinuedformstringNoIs Stock discontinued? Y/N
StockDiscontinuedCreateByformstringNoStock discontinued create by.
StockDiscontinuedCreateDateformDateTimeNoStock discontinued create date.
StockDiscontinuedAcLocationIDformstringNoStock discontinued location ID.
StockDiscontinuedSourceDBNameformstringNoStock discontinued source DB name.

To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml

HTTP + XML

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

GET /Customers/PurchaseHistoryPOS/{AcCustomerID} HTTP/1.1 
Host: snr2u.com 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<CustomerPurchasesHistoryPOSResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/SmartDynaModWebAPI.ServiceModel">
  <CustomerPurchaseHistoryPOS xmlns:d2p1="http://schemas.datacontract.org/2004/07/SmartDynaModWebAPI.ServiceModel.Types">
    <d2p1:CustomerPurchaseHistoryPOS>
      <d2p1:AcLocationDesc>String</d2p1:AcLocationDesc>
      <d2p1:AcLocationID>String</d2p1:AcLocationID>
      <d2p1:AcSalesmanID>String</d2p1:AcSalesmanID>
      <d2p1:AcSalesmanID_Item>String</d2p1:AcSalesmanID_Item>
      <d2p1:AcSalesmanName>String</d2p1:AcSalesmanName>
      <d2p1:AcSalesmanName_Item>String</d2p1:AcSalesmanName_Item>
      <d2p1:AcStockID>String</d2p1:AcStockID>
      <d2p1:AcStockUOMID>String</d2p1:AcStockUOMID>
      <d2p1:CreateBy>String</d2p1:CreateBy>
      <d2p1:DocumentDate>0001-01-01T00:00:00</d2p1:DocumentDate>
      <d2p1:DocumentNo>String</d2p1:DocumentNo>
      <d2p1:DocumentTime>0001-01-01T00:00:00</d2p1:DocumentTime>
      <d2p1:IsStockDiscontinued>String</d2p1:IsStockDiscontinued>
      <d2p1:ItemDiscountAmount>0</d2p1:ItemDiscountAmount>
      <d2p1:ItemDiscountAmountWithGST>0</d2p1:ItemDiscountAmountWithGST>
      <d2p1:ItemGSTAmount>0</d2p1:ItemGSTAmount>
      <d2p1:ItemGrossTotal>0</d2p1:ItemGrossTotal>
      <d2p1:ItemPriceWithGST>0</d2p1:ItemPriceWithGST>
      <d2p1:ItemQuantity>0</d2p1:ItemQuantity>
      <d2p1:ItemRemark1>String</d2p1:ItemRemark1>
      <d2p1:ItemStockBarcode>String</d2p1:ItemStockBarcode>
      <d2p1:ItemTotalPrice>0</d2p1:ItemTotalPrice>
      <d2p1:ItemUnitPrice>0</d2p1:ItemUnitPrice>
      <d2p1:SourceDBName>String</d2p1:SourceDBName>
      <d2p1:StockDescription1>String</d2p1:StockDescription1>
      <d2p1:StockDescription2>String</d2p1:StockDescription2>
      <d2p1:StockDiscontinuedAcLocationID>String</d2p1:StockDiscontinuedAcLocationID>
      <d2p1:StockDiscontinuedCreateBy>String</d2p1:StockDiscontinuedCreateBy>
      <d2p1:StockDiscontinuedCreateDate>0001-01-01T00:00:00</d2p1:StockDiscontinuedCreateDate>
      <d2p1:StockDiscontinuedSourceDBName>String</d2p1:StockDiscontinuedSourceDBName>
    </d2p1:CustomerPurchaseHistoryPOS>
  </CustomerPurchaseHistoryPOS>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
</CustomerPurchasesHistoryPOSResponse>