Exigo Web Services API v2022.12.19.1

GetBills

Gets existing customer bills

Input Properties

GetBillsRequest
PropertyData TypeNotes
CustomersInt32[]Optional. . Defaults to System.Int32[].
BillsInt32[]Optional. . Defaults to System.Int32[].
StartBillIDInt32Optional.
EndBillIDInt32Optional.
WarehouseID Int32Optional. Unique location for orders.
StatusType Int32Optional. Optional status of the bill (default is unpaid).
DatePaymentDueStartDateTimeOptional.
DatePaymentDueEndDateTimeOptional.
CurrencyCode StringOptional.
PayableType Int32Optional.
TaxablePeriodType Int32Optional.
TaxablePeriodID Int32Optional.

Output Properties

GetBillsResponse
PropertyData TypeNotes
BillItemsBillItem[]
BillItem
PropertyData TypeNotes
BillIDInt32
BillType Int32The type of bill record.
CustomerIDInt32Unique numeric identifier for a customer record.
WarehouseID Int32Unique location for orders.
PeriodID Int32
RunIDInt32
StatusType Int32Optional status of the bill (default is unpaid).
ReferenceString
NotesString
SubTotalDecimal
ShippingDecimal
TaxDecimal
AmountDecimal
CurrencyCode String
DateReceivedDateTime
DatePaymentDueDateTime
DateEnteredDateTime
CreatedByString
ModifiedByString
ModifiedDateDateTime
BillImageString
IsOtherIncomeBoolean
SourceType Int32Bill origination source.
PayableType Int32
TaxablePeriodType Int32
TaxablePeriodID Int32

Http Request

GET https://yourcompany-api.exigo.com/3.0/payout/bills?customers=1
  &bills=1
  &startBillID=1
  &endBillID=1
  &warehouseID=1
  &datePaymentDueStart=1
  &datePaymentDueEnd=1
  &currencyCode=usd
  &payableType=1
  &taxablePeriodType=1
  &taxablePeriodID=1
Authorization: Basic base64Encoded
                            

Http Response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8
Content-Length: length

{ "billItems": null, "result": null }

Soap Request

The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.

POST /3.0/ExigoApi.asmx HTTP/1.1
Host: lifewave-api.exigo.com
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "https://api.exigo.com/GetBills"

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Header> <ApiAuthentication xmlns="http://api.exigo.com/"> <LoginName>string</LoginName> <Password>string</Password> <Company>string</Company> <Identity>string</Identity> <RequestTimeUtc>dateTime</RequestTimeUtc> <Signature>string</Signature> </ApiAuthentication> </soap:Header> <soap:Body> <GetBillsRequest xmlns="http://api.exigo.com/"> <Customers> <int>int</int> </Customers> <Bills> <int>int</int> </Bills> <StartBillID>int</StartBillID> <EndBillID>int</EndBillID> <WarehouseID>int</WarehouseID> <StatusType>int</StatusType> <DatePaymentDueStart>dateTime</DatePaymentDueStart> <DatePaymentDueEnd>dateTime</DatePaymentDueEnd> <CurrencyCode>string</CurrencyCode> <PayableType>int</PayableType> <TaxablePeriodType>int</TaxablePeriodType> <TaxablePeriodID>int</TaxablePeriodID> </GetBillsRequest> </soap:Body> </soap:Envelope>

Soap Response

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: length

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <GetBillsResult xmlns="http://api.exigo.com/"> <BillItems> <BillItem> <BillID>int</BillID> <BillType>int</BillType> <CustomerID>int</CustomerID> <WarehouseID>int</WarehouseID> <PeriodID>int</PeriodID> <RunID>int</RunID> <StatusType>int</StatusType> <Reference>string</Reference> <Notes>string</Notes> <SubTotal>decimal</SubTotal> <Shipping>decimal</Shipping> <Tax>decimal</Tax> <Amount>decimal</Amount> <CurrencyCode>string</CurrencyCode> <DateReceived>dateTime</DateReceived> <DatePaymentDue>dateTime</DatePaymentDue> <DateEntered>dateTime</DateEntered> <CreatedBy>string</CreatedBy> <ModifiedBy>string</ModifiedBy> <ModifiedDate>dateTime</ModifiedDate> <BillImage>string</BillImage> <IsOtherIncome>boolean</IsOtherIncome> <SourceType>int</SourceType> <PayableType>int</PayableType> <TaxablePeriodType>int</TaxablePeriodType> <TaxablePeriodID>int</TaxablePeriodID> </BillItem> </BillItems> </GetBillsResult> </soap:Body> </soap:Envelope>

C# Rest Client

Install Nuget package Exigo.Api.Client

try

{

    //Create Api Client

    var api = new ExigoApiClient("yourcmpany", "yourlogin", "yourpassword");

 

    //Create Request

    var req = new GetBillsRequest();

 

 

    //Add Customers

    var customers = new List<Int32>();

    customers.Add(1);

    customers.Add(2);

 

    //Now attach the list to the request

    req.Customers = customers.ToArray();

 

    //Add Bills

    var bills = new List<Int32>();

    bills.Add(1);

    bills.Add(2);

 

    //Now attach the list to the request

    req.Bills = bills.ToArray();

    req.StartBillID = 1;

    req.EndBillID = 1;

    req.WarehouseID = 1;            //Unique location for orders

    req.DatePaymentDueStart = DateTime.Today;

    req.DatePaymentDueEnd = DateTime.Today;

    req.CurrencyCode = "usd";

    req.PayableType = 1;

    req.TaxablePeriodType = 1;

    req.TaxablePeriodID = 1;

 

    //Send Request to Server and Get Response

    var res = await api.GetBillsAsync(req);

 

    //Now examine the results:

 

    foreach (var billItem in res.BillItems)

    {

        Console.WriteLine("BillID: {0}", billItem.BillID);

        Console.WriteLine("CustomerID: {0}", billItem.CustomerID);

        Console.WriteLine("WarehouseID: {0}", billItem.WarehouseID);

        Console.WriteLine("PeriodID: {0}", billItem.PeriodID);

        Console.WriteLine("RunID: {0}", billItem.RunID);

        Console.WriteLine("Reference: {0}", billItem.Reference);

        Console.WriteLine("Notes: {0}", billItem.Notes);

        Console.WriteLine("SubTotal: {0}", billItem.SubTotal);

        Console.WriteLine("Shipping: {0}", billItem.Shipping);

        Console.WriteLine("Tax: {0}", billItem.Tax);

        Console.WriteLine("Amount: {0}", billItem.Amount);

        Console.WriteLine("CurrencyCode: {0}", billItem.CurrencyCode);

        Console.WriteLine("DateReceived: {0}", billItem.DateReceived);

        Console.WriteLine("DatePaymentDue: {0}", billItem.DatePaymentDue);

        Console.WriteLine("DateEntered: {0}", billItem.DateEntered);

        Console.WriteLine("CreatedBy: {0}", billItem.CreatedBy);

        Console.WriteLine("ModifiedBy: {0}", billItem.ModifiedBy);

        Console.WriteLine("ModifiedDate: {0}", billItem.ModifiedDate);

        Console.WriteLine("BillImage: {0}", billItem.BillImage);

        Console.WriteLine("IsOtherIncome: {0}", billItem.IsOtherIncome);

        Console.WriteLine("PayableType: {0}", billItem.PayableType);

        Console.WriteLine("TaxablePeriodType: {0}", billItem.TaxablePeriodType);

        Console.WriteLine("TaxablePeriodID: {0}", billItem.TaxablePeriodID);

    }

}

catch (Exception ex)

{

    Console.WriteLine("Error: " + ex.Message);

}

C# Soap Client

try

{

    //Create Main API Context Object

    ExigoApi api = new ExigoApi();

 

    //Create Authentication Header

    ApiAuthentication auth = new ApiAuthentication();

    auth.LoginName = "yourLoginName";

    auth.Password = "yourPassword";

    auth.Company = "yourCompany";

    api.ApiAuthenticationValue = auth;

 

    //Create Request

    GetBillsRequest req = new GetBillsRequest();

 

 

    //Add Customers

    List<Int32> customers = new List<Int32>();

    customers.Add(1);

    customers.Add(2);

 

    //Now attach the list to the request

    req.Customers = customers.ToArray();

 

    //Add Bills

    List<Int32> bills = new List<Int32>();

    bills.Add(1);

    bills.Add(2);

 

    //Now attach the list to the request

    req.Bills = bills.ToArray();

    req.StartBillID = 1;

    req.EndBillID = 1;

    req.WarehouseID = 1;            //Unique location for orders

    req.DatePaymentDueStart = DateTime.Today;

    req.DatePaymentDueEnd = DateTime.Today;

    req.CurrencyCode = "usd";

    req.PayableType = 1;

    req.TaxablePeriodType = 1;

    req.TaxablePeriodID = 1;

 

    //Send Request to Server and Get Response

    GetBillsResponse res = api.GetBills(req);

 

    //Now examine the results:

 

    foreach (BillItem billItem in res.BillItems)

    {

        Console.WriteLine("BillID: {0}", billItem.BillID);

        Console.WriteLine("CustomerID: {0}", billItem.CustomerID);

        Console.WriteLine("WarehouseID: {0}", billItem.WarehouseID);

        Console.WriteLine("PeriodID: {0}", billItem.PeriodID);

        Console.WriteLine("RunID: {0}", billItem.RunID);

        Console.WriteLine("Reference: {0}", billItem.Reference);

        Console.WriteLine("Notes: {0}", billItem.Notes);

        Console.WriteLine("SubTotal: {0}", billItem.SubTotal);

        Console.WriteLine("Shipping: {0}", billItem.Shipping);

        Console.WriteLine("Tax: {0}", billItem.Tax);

        Console.WriteLine("Amount: {0}", billItem.Amount);

        Console.WriteLine("CurrencyCode: {0}", billItem.CurrencyCode);

        Console.WriteLine("DateReceived: {0}", billItem.DateReceived);

        Console.WriteLine("DatePaymentDue: {0}", billItem.DatePaymentDue);

        Console.WriteLine("DateEntered: {0}", billItem.DateEntered);

        Console.WriteLine("CreatedBy: {0}", billItem.CreatedBy);

        Console.WriteLine("ModifiedBy: {0}", billItem.ModifiedBy);

        Console.WriteLine("ModifiedDate: {0}", billItem.ModifiedDate);

        Console.WriteLine("BillImage: {0}", billItem.BillImage);

        Console.WriteLine("IsOtherIncome: {0}", billItem.IsOtherIncome);

        Console.WriteLine("PayableType: {0}", billItem.PayableType);

        Console.WriteLine("TaxablePeriodType: {0}", billItem.TaxablePeriodType);

        Console.WriteLine("TaxablePeriodID: {0}", billItem.TaxablePeriodID);

    }

}

catch (Exception ex)

{

    Console.WriteLine("Error: " + ex.Message);

}

VB.Net

Try

    'Create Main API Context Object

    Dim api as new ExigoApi()

 

    'Create Authentication Header

    Dim auth as new ApiAuthentication()

    auth.LoginName = "yourLoginName"

    auth.Password = "yourPassword"

    auth.Company = "yourCompany"

    api.ApiAuthenticationValue = auth

 

    'Create Request

    Dim req as new GetBillsRequest()

 

 

    'Add Customers

    Dim customers As New List(Of Int32)()

    customers.Add(1)

    customers.Add(2)

 

    'Now attach the list to the request

    req.Customers = customers.ToArray()

 

    'Add Bills

    Dim bills As New List(Of Int32)()

    bills.Add(1)

    bills.Add(2)

 

    'Now attach the list to the request

    req.Bills = bills.ToArray()

    req.StartBillID = 1

    req.EndBillID = 1

    req.WarehouseID = 1

    req.DatePaymentDueStart = DateTime.Today

    req.DatePaymentDueEnd = DateTime.Today

    req.CurrencyCode = "usd"

    req.PayableType = 1

    req.TaxablePeriodType = 1

    req.TaxablePeriodID = 1

 

    'Send Request to Server and Get Response

    Dim res As GetBillsResponse = api.GetBills(req)

 

    'Now examine the results:

 

    For Each billItem As BillItem In res.BillItems

        Console.WriteLine("BillID: {0}", billItem.BillID)

        Console.WriteLine("CustomerID: {0}", billItem.CustomerID)

        Console.WriteLine("WarehouseID: {0}", billItem.WarehouseID)

        Console.WriteLine("PeriodID: {0}", billItem.PeriodID)

        Console.WriteLine("RunID: {0}", billItem.RunID)

        Console.WriteLine("Reference: {0}", billItem.Reference)

        Console.WriteLine("Notes: {0}", billItem.Notes)

        Console.WriteLine("SubTotal: {0}", billItem.SubTotal)

        Console.WriteLine("Shipping: {0}", billItem.Shipping)

        Console.WriteLine("Tax: {0}", billItem.Tax)

        Console.WriteLine("Amount: {0}", billItem.Amount)

        Console.WriteLine("CurrencyCode: {0}", billItem.CurrencyCode)

        Console.WriteLine("DateReceived: {0}", billItem.DateReceived)

        Console.WriteLine("DatePaymentDue: {0}", billItem.DatePaymentDue)

        Console.WriteLine("DateEntered: {0}", billItem.DateEntered)

        Console.WriteLine("CreatedBy: {0}", billItem.CreatedBy)

        Console.WriteLine("ModifiedBy: {0}", billItem.ModifiedBy)

        Console.WriteLine("ModifiedDate: {0}", billItem.ModifiedDate)

        Console.WriteLine("BillImage: {0}", billItem.BillImage)

        Console.WriteLine("IsOtherIncome: {0}", billItem.IsOtherIncome)

        Console.WriteLine("PayableType: {0}", billItem.PayableType)

        Console.WriteLine("TaxablePeriodType: {0}", billItem.TaxablePeriodType)

        Console.WriteLine("TaxablePeriodID: {0}", billItem.TaxablePeriodID)

    Next

Catch ex As Exception

    Console.WriteLine("Error: " & ex.Message)

End Try

PHP

Note: PHP is not officially supported.

<?php

try

{

    //Setup the SoapClient and Authentication

    $api = new SoapClient("http://api.exigo.com/3.0/ExigoApi.asmx?WSDL");

    $ns = "http://api.exigo.com/";

    $auth = array()

    $auth["LoginName"] = new SoapVar("yourLoginName",XSD_STRING,null,null,null,$ns);

    $auth["Password"] = new SoapVar("yourPassword",XSD_STRING,null,null,null,$ns);

    $auth["Company"] = new SoapVar("yourCompany",XSD_STRING,null,null,null,$ns);

    $headerBody = new SoapVar($auth, SOAP_ENC_OBJECT);

    $header = new SoapHeader($ns, 'ApiAuthentication', $headerBody);

    $api->__setSoapHeaders(array($header));

 

    //Create Request

 

 

    //Add Customers

 

 

 

    //Now attach the list to the request

    req.Customers = array(customer1,customer2);

 

    //Add Bills

 

 

 

    //Now attach the list to the request

    req.Bills = array(bill1,bill2);

    $req->StartBillID = 1;

    $req->EndBillID = 1;

    $req->WarehouseID = 1;

    $req->DatePaymentDueStart = 1;

    $req->DatePaymentDueEnd = 1;

    $req->CurrencyCode = "usd";

    $req->PayableType = 1;

    $req->TaxablePeriodType = 1;

    $req->TaxablePeriodID = 1;

 

    //Send Request to Server and Get Response

    $res = $api.GetBills($req);

 

    //Now examine the results:

}

catch (SoapFault $ex)

{

    echo "Error: ", $ex->getMessage();

}

?>

Java

Note: Java is not officially supported.

try

{

    //Create Main API Context Object

    ExigoApi api = new ExigoApi();

 

    //Create Authentication Header

    ApiAuthentication auth = new ApiAuthentication();

    auth.setLoginName("yourLoginName");

    auth.setPassword("yourPassword");

    auth.setCompany("yourCompany");

    api.setApiAuthenticationValue(auth);

 

    //Create Request

    GetBillsRequest req = new GetBillsRequest();

 

 

    //Add Customers

    ArrayOfSystem.Int32 customers = new ArrayOfSystem.Int32();

 

    Int32 customer1 = new Int32();

    customers.Add(customer1);

 

    Int32 customer2 = new Int32();

    customers.Add(customer2);

 

    //Now attach the list to the request

    req.setCustomers(customers);

 

    //Add Bills

    ArrayOfSystem.Int32 bills = new ArrayOfSystem.Int32();

 

    Int32 bill1 = new Int32();

    bills.Add(bill1);

 

    Int32 bill2 = new Int32();

    bills.Add(bill2);

 

    //Now attach the list to the request

    req.setBills(bills);

    req.setStartBillID(1);

    req.setEndBillID(1);

    req.setWarehouseID(1);

    req.setDatePaymentDueStart(1);

    req.setDatePaymentDueEnd(1);

    req.setCurrencyCode("usd");

    req.setPayableType(1);

    req.setTaxablePeriodType(1);

    req.setTaxablePeriodID(1);

 

    //Send Request to Server and Get Response

    GetBillsResponse res = api.getExigoApiSoap().getBills(req, auth);

 

    //Now examine the results:

}

catch (Exception ex)

{

    System.out.println("Error: " + ex.getMessage());

}

CSV

This method does not support csv output.