Create Invoice
Request Profile Table
| Element | @Attribute |
Description/Contents |
| CreateInvoice_RQ |
Root element of message. |
| @WebResUsername |
The WebRes username of the requesting agent. |
| @WebResPassword |
The WebRes password of the requesting agent. |
| Vouchers |
Start element for list of vouchers to be invoiced. |
| Voucher |
The voucher element. |
| @VoucherRef |
The voucher reference code. |
| @VoucherType |
The voucher type code. Typically "A" for an accommodation voucher or "O" for an operator voucher. |
Scenario:
You want to invoice a selection of accommodation vouchers with the codes: FD45D5, 8S9F6F, SA0E8F.
Example message:
<?xml version="1.0" encoding="utf-16"?>
<CreateInvoice_RQ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" WebResUsername="myuser" WebResPassword="mypassword">
<Vouchers xmlns="ResLink">
<Voucher VoucherRef="FD45D5" VoucherType="A" />
<Voucher VoucherRef="8S9F6F" VoucherType="A" />
<Voucher VoucherRef="SA0E8F" VoucherType="A" />
</Vouchers>
</CreateInvoice_RQ>
Response Profile Table
| Element | @Attribute |
Description/Contents |
| CreateInvoice_RS |
Root element of message. |
| @InvoiceNo |
The invoice number/ID for the created invoice. |
| Status |
Element indicating the return status of the transaction. |
| @Code |
A numerical code for the status. |
| @Message (optional) |
The message of the status. The messages (and corresponding codes) returned are:
| Code |
Message |
| 0 |
Create invoice successful. |
| 1 |
Failed to connect to database. ResLink was unable to connect to the target database. |
| 2 |
Some vouchers could not be invoiced. Some or all of the vouchers requested to be invoiced could not be for various reasons. Refer to errors list for more information. |
|
Example message:
<?xml version="1.0" encoding="utf-16"?>
<CreateInvoice_RS xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" InvoiceNo="4463">
<TimeStamp xmlns="ResLink">2009-01-21T09:59:26.4005942+10:00</TimeStamp>
<Errors xmlns="ResLink" />
<Warnings xmlns="ResLink" />
<Status Code="0" xmlns="ResLink" />
</CreateInvoice_RS>