API DOCUMENTATION
    Try Unleashed Now Sandbox

    Sales Invoices

    The Invoices resource allows sales invoices to be listed and viewed. An individual sales invoice details can be viewed by appending its identifier (a GUID formatted as XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX) to the URI. Here are some example URIs:

    • /Invoices/E6E8163F-6911-40e9-B740-90E5A0A3A996 - Returns details of a particular sales invoice.
    • /Invoices/Page/1 - Returns the first page of 200 sales invoices.
    • /Invoices/1 - Returns the first page of 200 sales invoices.
    • /Invoices - Returns the first 200 sales invoices because page number 1 is the default.
    • /Invoices/3?pageSize=100 - Returns the third page of 100 sales invoices; ie. the 201st to 300th sales invoices.

    The full range of URIs and HTTP Verbs supported are:

    Operation HTTP Action
    List of paginated Sales Invoices GET /Invoices/Page/{pageNumber}
    View any Sales Invoice GET /Invoices/{id}

    GET Invoices

    These filters can be used with the GET Invoices endpoint:

    Filter Description
    pageSize Specifies the page size for pagination. Default page size is 200 invoices.

    Note: Requesting large numbers of invoices can be susceptible to poor network performance. Please reduce the page size if you experience delayed requests.
    customerCode Returns invoices that matches the specific customer code.
    startDate Returns invoices created after a specified date.
    endDate Returns invoices created before a specified date.
    modifiedSince Returns invoices created or edited after a specified date, must be UTC format.
    orderNumber Returns the invoices associated with the Sales Order Number.
    invoiceNumber Returns a single invoice with the specified invoice number. If set, it overrides all other filters.
    invoiceStatus Returns invoices with the specified status. Multiple selection can be specified as comma separated.For example: invoiceStatus=Completed,Parked. If no invoiceStatus filter is specified, then we exclude “Deleted” by default.
    serialBatch False by default. If set to true then the attributes SerialNumbers and BatchNumbers are displayed.

    Filters are used by adding the filter and value to the URI: /Invoices?customerCode=ACME&startDate=2012-01-01

    Tip: To efficiently retrieve a count of the invoices that match a filter, specify a pageSize of 0: /Invoices?invoiceStatus=Parked,Placed&pageSize=0. The default invoicing is by LastModifiedOn descending.

    Available Fields for Invoice:

    Property Type Length Notes
    BCSubTotal Nullable Decimal   Base Currency SubTotal
    BCTaxTotal Nullable Decimal   Base Currency TaxTotal
    BCTotal Nullable Decimal   Base Currency Total
    Comments String 2048  
    CreatedBy String 50  
    CreatedOn DateTime    
    Customer Customer   A subset of customer which comprises of customer code, customer name and currency id.
    DeliveryAddress Address collection    
    DeliveryInstruction String 500 Delivery instruction is retrieved from the Sales Order
    DueDate Nullable DateTime   UTC timezone only
    ExchangeRate Decimal    
    Guid Guid    
    InvoiceDate Nullable DateTime    
    InvoiceLines InvoiceLine collection    
    InvoiceNumber String 17  
    InvoiceStatus String 20  
    LastModifiedBy String 50  
    LastModifiedOn Nullable DateTime    
    OrderNumber String 17  
    PaymentTerm String 100  
    PostalAddress Address collection    
    QuoteNumber String 17  
    SubTotal Decimal    
    TaxTotal Decimal    
    Total Decimal    

    Available Fields for InvoiceLines:

    Property Type Length Notes
    BatchNumbers BatchNumber   A subset of batch tracked products.
    BCUnitPrice Decimal   Base Currency Unit Price
    Comments String 1024  
    DiscountRate Decimal    
    Guid Guid    
    InvoiceQuantity Decimal    
    LastModifiedOn Nullable DateTime    
    LineNumber Integer    
    LineTax Decimal    
    LineTaxCode String 50  
    LineType String   It will be noted as “Charge” if it’s a Charge Line
    LineTotal Decimal    
    OrderQuantity Decimal    
    Product Product   A subset of product which comprises of product code, description and guid.
    SerialNumbers SerialNumber   A subset of serialized products.
    TaxRate Nullable Decimal    
    UnitPrice Nullable Decimal    

    Examples for Response GET /Invoices

    show xml example
    show json example

    Use the API Sandbox to see how the object is rendered in JSON or XML.

    Note: An Unleashed account is required before you can use the API Sandbox.

    Trial accounts are also allowed to connect to the API.
    You can register a new account here: Register.