Get Invoice
Request Profile Table
Element | @Attribute |
Description/Contents |
GetInvoice_RQ |
Root element of message. |
@WebResUsername |
The WebRes username of the requesting agent. |
@WebResPassword |
The WebRes password of the requesting agent. |
@InvoiceNo |
The number/ID for the invoice being requested. |
Scenario:
You want to get the details for invoice number 4961.
Example message:
<?xml version="1.0" encoding="utf-16"?>
<GetInvoice_RQ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" WebResUsername="myuser" WebResPassword="mypassword" InvoiceNo="4961" />
Response Profile Table
Element | @Attribute |
Description/Contents |
GetInvoice_RS |
Root element of message. |
Invoice |
Element indicating a package. |
@ID |
The invoice number/ID. |
@CreationDate |
The date/time the invoice was created. |
Items |
Element indicated a list of invoice items. |
InvoiceItem |
Element defining an invoice item. |
@VoucherRef |
The voucher reference code |
@VoucherType |
The voucher type code. Usually "A" for an accommodation voucher or "O" for an operator voucher. |
@Booking |
The booking number the voucher is for. |
@SupplierRef (optional) |
The suppliers reference code for the voucher. |
@Description |
The voucher description. |
@NetCost |
The net cost of the voucher. |
@Currency |
Currency code for the voucher. |
@Quantity |
The quantity of the voucher allocated. |
@TotalNetCost |
The total net cost of the specified quantity of vouchers. |
TotalQuantity |
The total number of vouchers on this invoice. |
TotalCost |
The total cost of the vouchers on this invoice. |
Currency |
Currency code for the invoice. |
Example message:
<?xml version="1.0" encoding="utf-16"?>
<GetInvoice_RS xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<TimeStamp xmlns="ResLink">2009-01-21T11:02:55.0032118+10:00</TimeStamp>
<Errors xmlns="ResLink" />
<Warnings xmlns="ResLink" />
<Invoice ID="4961" CreationDate="2009-01-20T15:12:41" xmlns="ResLink">
<Items>
<InvoiceItem VoucherRef="WRNWD1" VoucherType="O" Booking="1236" SupplierRef="" Description="Pride of Airlie" NetCost="0" Quantity="1" TotalNetCost="0" Currency="AUD" />
<InvoiceItem VoucherRef="T69YGO" VoucherType="A" Booking="1269" Description="Accommodation Voucher " NetCost="15" Quantity="1" TotalNetCost="15" Currency="AUD" />
<InvoiceItem VoucherRef="LH779L" VoucherType="A" Booking="1310" Description="Accommodation Voucher " NetCost="15" Quantity="1" TotalNetCost="15" Currency="AUD" />
<InvoiceItem VoucherRef="OXY6ME" VoucherType="A" Booking="1321" Description="Accommodation Voucher " NetCost="15" Quantity="2" TotalNetCost="30" Currency="AUD" />
<InvoiceItem VoucherRef="IQQDEV" VoucherType="A" Booking="1322" Description="Accommodation Voucher " NetCost="15" Quantity="3" TotalNetCost="45" Currency="AUD" />
<InvoiceItem VoucherRef="LAZ9AV" VoucherType="A" Booking="1371" Description="Accommodation Voucher " NetCost="15" Quantity="4" TotalNetCost="60" Currency="AUD" />
</Items>
<TotalQuantity>12</TotalQuantity>
<TotalCost>165</TotalCost>
<Currency>AUD</Currency>
</Invoice>
</GetInvoice_RS>