IAB XML Schema Definition:
/inter_alliance_billing/wwa_iabinvoice_1.0.0.xsd
<?xml version="1.0" encoding="UTF-8"?>
<!-- Auto-generated XML Document STi-EI Export Invoice Version 1.0.0 -->
<Invoice xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.wwalliance.com/wiki/images/e/ed/WWA_IABInvoice_1.0.0.xsd">
<Envelope>
<SenderID>edi_abc_prod</SenderID>
<ReceiverID>HKHKG01</ReceiverID>
<Password>test12345</Password>
<Type>WWA_IABInvoice_1.0.0</Type>
<Version>1.0.0</Version>
<EnvelopeID>1382041398452123</EnvelopeID>
</Envelope>
<InvoiceDetails>
<SCAC>ABCS</SCAC>
<InvoiceOfficeCode>DEHAM02</InvoiceOfficeCode>
<InvoiceNumber>12345678</InvoiceNumber>
<Type>S</Type>
<InvoiceMode>E</InvoiceMode>
<InvoiceApplyTo/>
<ReferenceType>2</ReferenceType>
<PayorReference>mbl12345678</PayorReference>
<InvoiceDate>2013-11-13</InvoiceDate>
<InvoiceDueDays>30</InvoiceDueDays>
<InvoiceDueDate>2013-12-13</InvoiceDueDate>
<InvoiceAmount>739.84</InvoiceAmount>
<InvoiceCurrency>USD</InvoiceCurrency>
<ROE>1.000</ROE>
<LocalCurrency>USD</LocalCurrency>
<Comments/>
<FileNumber>abc12345678</FileNumber>
<MasterBillOfLadingNumber>mbl12345678</MasterBillOfLadingNumber>
<HouseBillOfLadingNumber/>
<ArrivalNoticeNumber/>
<InvoicePartnerDetails>
<IssuerDetails>
<Name>ABC Shipping Pvt Ltd</Name>
<Address>hamburg</Address>
<DeliverTo/>
<City>Hamburg</City>
<PostalCode>4569</PostalCode>
<StateProvince/>
<Country>DE</Country>
<Phone/>
<Email/>
</IssuerDetails>
<PayorDetails>
<Name>Shipco Transport Inc</Name>
<PayorContact>TEST</PayorContact>
<Address>HongKong</Address>
<DeliverTo/>
<City>HongKong</City>
<PostalCode>059</PostalCode>
<StateProvince/>
<Country>HK</Country>
<Phone/>
<Email/>
</PayorDetails>
</InvoicePartnerDetails>
<ChargeDetails>
<ChargeCode>INL</ChargeCode>
<ChargeName>Inland Freight</ChargeName>
<ChargeDescription>634004597 - Freight Charges</ChargeDescription>
<Rate>95.96</Rate>
<Quantity>4.09</Quantity>
<Basis>LS</Basis>
<ForeignCurrency>USD</ForeignCurrency>
<ROE>1.00</ROE>
<LocalCurrency>USD</LocalCurrency>
<LocalAmount>392.47</LocalAmount>
<Tax>N</Tax>
</ChargeDetails>
<ChargeDetails>
<ChargeCode>INL</ChargeCode>
<ChargeName>Inland Freight</ChargeName>
<ChargeDescription>634004598 - Freight Charges</ChargeDescription>
<Rate>95.96</Rate>
<Quantity>2.62</Quantity>
<Basis>LS</Basis>
<ForeignCurrency>USD</ForeignCurrency>
<ROE>1.00</ROE>
<LocalCurrency>USD</LocalCurrency>
<LocalAmount>251.41</LocalAmount>
<Tax>N</Tax>
</ChargeDetails>
<ChargeDetails>
<ChargeCode>INL</ChargeCode>
<ChargeName>Inland Freight</ChargeName>
<ChargeDescription>634004599 - Freight Charges</ChargeDescription>
<Rate>95.96</Rate>
<Quantity>1.00</Quantity>
<Basis>LS</Basis>
<ForeignCurrency>USD</ForeignCurrency>
<ROE>1.00</ROE>
<LocalCurrency>USD</LocalCurrency>
<LocalAmount>95.96</LocalAmount>
<Tax>N</Tax>
</ChargeDetails>
<TotalAmountDetails>
<LocalCurrency>USD</LocalCurrency>
<LocalAmountExclTax>739.84</LocalAmountExclTax>
<LocalAmount>739.84</LocalAmount>
<ROE>1.00</ROE>
<ForeignCurrency>USD</ForeignCurrency>
</TotalAmountDetails>
<CargoDetails>
<Pieces>30</Pieces>
<Packaging>BOX</Packaging>
<Commodity>PALLET SLAC 7 BOXES</Commodity>
<Weight>11441.28</Weight>
<Volume>125.36</Volume>
<UOM>M</UOM>
</CargoDetails>
<CargoDetails>
<Pieces>30</Pieces>
<Packaging>BOX</Packaging>
<Commodity>PALLET SLAC 7 BOXES</Commodity>
<Weight>11441.28</Weight>
<Volume>125.36</Volume>
<UOM>M</UOM>
</CargoDetails>
<InvoiceDocumentation>
<ImageLink/>
<Image/>
<ContentType/>
</InvoiceDocumentation>
</InvoiceDetails>
</Invoice>
<?xml version="1.0" encoding="UTF-8"?>
<!-- Auto-generated XML Document STi-EI Import Invoice Version 1.0.0 -->
<Invoice xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.wwalliance.com/wiki/images/e/ed/WWA_IABInvoice_1.0.0.xsd">
<Envelope>
<SenderID>edi_xyz_prod</SenderID>
<ReceiverID>BEANR01</ReceiverID>
<Password>test123456</Password>
<Type>WWA_IABInvoice_1.0.0</Type>
<Version>1.0.0</Version>
<EnvelopeID>1281031299453123</EnvelopeID>
</Envelope>
<InvoiceDetails>
<SCAC>XYZA</SCAC>
<InvoiceOfficeCode>INBOM01</InvoiceOfficeCode>
<InvoiceNumber>1234567890</InvoiceNumber>
<Type>C</Type>
<InvoiceMode>I</InvoiceMode>
<InvoiceApplyTo>9876543210</InvoiceApplyTo>
<ReferenceType>3</ReferenceType>
<PayorReference>HBL1234567890</PayorReference>
<InvoiceDate>2014-11-13</InvoiceDate>
<InvoiceDueDays>40</InvoiceDueDays>
<InvoiceDueDate>2014-12-23</InvoiceDueDate>
<InvoiceAmount>1028.75</InvoiceAmount>
<InvoiceCurrency>USD</InvoiceCurrency>
<ROE>1.000</ROE>
<LocalCurrency>USD</LocalCurrency>
<Comments>"HBL123456789 is HouseBill of Lading worth $850"</Comments>
<FileNumber>xyz123456789</FileNumber>
<MasterBillOfLadingNumber>MBL123456789</MasterBillOfLadingNumber>
<HouseBillOfLadingNumber/>
<ArrivalNoticeNumber>INB123456789</ArrivalNoticeNumber>
<InvoicePartnerDetails>
<IssuerDetails>
<Name>Shipco Transport Pvt Ltd</Name>
<Address>Antewrp</Address>
<DeliverTo>John Smith</DeliverTo>
<City>Antewerp</City>
<PostalCode>456789</PostalCode>
<StateProvince/>
<Country>BE</Country>
<Phone/>
<Email/>
</IssuerDetails>
<PayorDetails>
<Name>Shipco Transport Inc</Name>
<PayorContact>TEST</PayorContact>
<Address>HongKong</Address>
<DeliverTo/>
<City>HongKong</City>
<PostalCode>059</PostalCode>
<StateProvince/>
<Country>HK</Country>
<Phone/>
<Email/>
</PayorDetails>
</InvoicePartnerDetails>
<ChargeDetails>
<ChargeCode>OFR</ChargeCode>
<ChargeName>Ocean Freight</ChargeName>
<ChargeDescription>634004597 -Ocean Freight Charges inclusive of all taxes</ChargeDescription>
<Rate>80.99</Rate>
<Quantity>7</Quantity>
<Basis>LS</Basis>
<ForeignCurrency>USD</ForeignCurrency>
<ROE>1.00</ROE>
<LocalCurrency>USD</LocalCurrency>
<LocalAmount>566.93</LocalAmount>
<Tax>N</Tax>
</ChargeDetails>
<ChargeDetails>
<ChargeCode>INL</ChargeCode>
<ChargeName>Inland Freight</ChargeName>
<ChargeDescription>634004598 - Freight Charges</ChargeDescription>
<Rate>80.99</Rate>
<Quantity>3.62</Quantity>
<Basis>LS</Basis>
<ForeignCurrency>USD</ForeignCurrency>
<ROE>1.00</ROE>
<LocalCurrency>USD</LocalCurrency>
<LocalAmount>293.18</LocalAmount>
<Tax>N</Tax>
</ChargeDetails>
<ChargeDetails>
<ChargeCode>INL</ChargeCode>
<ChargeName>Inland Freight</ChargeName>
<ChargeDescription>634004599 - Freight Charges</ChargeDescription>
<Rate>80.99</Rate>
<Quantity>2.00</Quantity>
<Basis>LS</Basis>
<ForeignCurrency>USD</ForeignCurrency>
<ROE>1.00</ROE>
<LocalCurrency>USD</LocalCurrency>
<LocalAmount>161.98</LocalAmount>
<Tax>Y</Tax>
</ChargeDetails>
<TaxDetails>
<TaxType>Indirect</TaxType>
<TaxName>Custom Duty</TaxName>
<TaxPercentage>2</TaxPercentage>
<TaxableAmount>6.66</TaxableAmount>
<TaxAmount>6.66</TaxAmount>
</TaxDetails>
<TotalTaxDetails>
<TaxType>Indirect</TaxType>
<TaxName>Custom Duty</TaxName>
<TaxPercentage>2</TaxPercentage>
<TaxableAmount>6.66</TaxableAmount>
<TaxAmount>6.66</TaxAmount>
</TotalTaxDetails>
<TotalAmountDetails>
<LocalCurrency>USD</LocalCurrency>
<LocalAmountExclTax>1022.09</LocalAmountExclTax>
<LocalAmount>1028.75</LocalAmount>
<ROE>1.00</ROE>
<ForeignCurrency>USD</ForeignCurrency>
</TotalAmountDetails>
<CargoDetails>
<Pieces>30</Pieces>
<Packaging>BOX</Packaging>
<Commodity>PALLET SLAC 7 BOXES</Commodity>
<Weight>11441.28</Weight>
<Volume>125.36</Volume>
<UOM>M</UOM>
</CargoDetails>
<CargoDetails>
<Pieces>30</Pieces>
<Packaging>BOX</Packaging>
<Commodity>PALLET SLAC 7 BOXES</Commodity>
<Weight>11441.28</Weight>
<Volume>125.36</Volume>
<UOM>M</UOM>
</CargoDetails>
<InvoiceDocumentation>
<ImageLink/>
<Image/>
<ContentType/>
</InvoiceDocumentation>
</InvoiceDetails>
</Invoice>
Field | Content | Length | Input |
Envelope | |||
SenderID | Sender ID to identify sender, edi user name of the member. | 50 | Required |
ReceiverID | Receiver ID to identify receiver, WWA Member Office. | 100 | Required |
Password | Password as assigned by WWA, the XML password | 100 | Required |
Type | Message type, ‘WWA_IABInvoice_1.0.0’. | 50 | Required |
Version | Message version, should be 1.0.0 | 8 | Required |
EnvelopeID | Unique ID for message to have a follow up option. | 40 | Required |
Invoice Details | Details of Invoice | ||
SCAC | Scac Code of sending Member. | 4 | Required |
InvoiceOfficeCode | Office code of sending member e.g. USNYC01,INBOM01. | 7 | Required |
InvoiceNumber | WWA Member Invoice Number/Credit Note Number. | 25 | Required |
Type | 'S' for Standard/Original or 'C' for Credit. | 1 | Required |
InvoiceMode | "I" = "Import", "E" = "Export". | 1 | Required |
InvoiceApplyTo | Invoice number for which Credit invoice is raised. Should never be same as Invoice Number | 25 | Optional |
ReferenceType | #"1"=Container #"2"=MBL #"3"=HBL #"4"=Others | 1 | Required |
PayorReference | Payor Reference | 50 | Required |
InvoiceDate | The Date of the Invoice (YYYY-MM-DD) NOTE: The Invoice Date should be within 7 days from the date of submission |
10 | Required |
InvoiceDueDays | Invoice credit period. | 3 | Required |
InvoiceDueDate | Invoice Due date (YYYY-MM-DD) | 10 | Required |
InvoiceAmount | Amount of the Invoice NOTE: Amount should not be negative in case of original Invoice |
10 | Required |
InvoiceCurrency | Sending member's currency code i.e INR, EUR. | 3 | Required |
ROE | Rate of Exchange | 7 | Required |
LocalCurrency | Sending member's currency code i.e INR,EUR. | 3 | Optional |
Comments | Any remarks for the invoice. | 100 | Optional |
FileNumber | File Number of the Shipment. | 25 | Optional |
MasterBillOfLadingNumber | MasterBillOfLading of the Shipment | 25 | Optional |
HouseBillOfLadingNumber | HouseBillOfLadding Number of the shipment. | 20 | Optional |
ArrivalNoticeNumber | ArrivalNotice Number of the shipment. | 20 | Optional |
Invoice Partner Details | Details of Invoice Partner | ||
IssuerDetails | Details of Issuer | ||
Name | Name of the Issuer Partner. | 40 | Required |
Address | Address of the Issuer. | 100 | Required |
TaxID | Vat ID of the Issuer. | 30 | Optional |
DeliverTo | Issuer person's name. | 50 | Required |
City | City. | 40 | Optional |
StateProvince | State or Province. | 40 | Optional |
PostalCode | Postal Code. | 10 | Optional |
Country | Country in 2 Characters e.g US, IN etc. | 2 | Required |
Phone | Phone Number. | 20 | Optional |
Email Address. | 50 | Optional | |
PayorDetails | Details of Payor | ||
Name | Name of the Bill To Partner. | 40 | Required |
PayorContact | Person Reference. | 50 | Optional |
Address | Address of the Bill To. | 100 | Required |
TaxID | Vat ID of the Payor. | 30 | Optional |
DeliverTo | Bill To person's name. | 50 | Required |
City | City. | 40 | Optional |
StateProvince | State or Province. | 40 | Optional |
PostalCode | Postal Code. | 10 | Optional |
Country | Country in 2 Characters e.g US,IN etc. | 2 | Required |
Phone | Phone Number. | 20 | Optional |
Email Address. | 50 | Optional | |
ChargeDetails | Details of Charge | ||
ChargeCode | Type of Charge code OFR,SEC etc. | 5 | Required |
ChargeName | Name of the charge e.g. Ocean Freight etc. | 50 | Required |
ChargeDescription | Description of the charge e.g.About Ocean Freight etc. | 100 | Required |
Rate | Charge Rate. | 25 | Required |
Quantity | Quantity | 15 | Required |
Basis | Charge Basis. | 7 | Optional |
LocalCurrency | Sending member's currency code i.e INR,EUR. | 3 | Required |
LocalAmount | Amount of respective charge. | 7 | Required |
ROE | Rate of exchange. | 7 | Optional |
ForeignCurrency | Receiving member's currency code i.e USD,EUR. | 3 | Optional |
Tax | Y or N, If Y then details are mandatory else optional | 1 | Required If Y |
TaxDetails | Details of Tax | ||
TaxType | Type of Tax | 10 | Required |
TaxName | Name of Tax | 15 | Required |
TaxPercentage | Rate of Percentage | 5 | Required |
TaxableAmount | Taxable amount | 25 | Required |
TaxAmount | Tax amount | 25 | Required |
TotalTaxDetails | Details of Total Tax | ||
TaxType | Type of Tax | 10 | Required |
TaxName | Name of Tax | 15 | Required |
TaxPercentage | Rate of Percentage | 5 | Required |
TaxableAmount | Taxable amount | 25 | Required |
TaxAmount | Tax amount | 25 | Required |
TotalAmountDetails | Details of Total Amount | ||
LocalCurrency | Sending member's currency code i.e INR,EUR. | 3 | Required |
LocalAmountExclTax | Amont of respective charge excluding tax | 15 | Required |
LocalAmount | Amount of respective charge. | 15 | Required |
ROE | Rate of Exchange | 7 | Optional |
ForeignCurrency | Receiving member's currency code i.e USD,EUR. | 3 | Optional |
CargoDetails | Details of Cargo | ||
Pieces | The Number of Pieces for the Shipment | 3 | Optional |
Packaging | The Packagin of the Shipment. | 20 | Optional |
Commodity | The Commodity Description of the Shipment. | 254 | Optional |
Weight | The Weight of the Shipment. | 10 | Optional |
Volume | The Volume of the Shipment. | 10 | Optional |
UOM | Unit of Measure. 'E' for imperial or 'M' for Metric. | 1 | Optional |
Invoice Documentation Details | Details of Invoice Documentation | ||
ImageLink | HTTP URL to the pdf, HTML, png, gif or jpeg documentation file. | 999 | IF <ImageLink> is specified, <Image> is Optional |
Image | Base64binary encode pdf, html, png, gif, jpeg. | 999 | IF <Image> is specified, <ImageLink> is Optional |
ContentType | Type of image I.e application/pdf, application/html, image/png, image/gif, image/jpeg | 999 | Required |
IABInvoice Acknowledgment XML Schema Definition:
/inter_alliance_billing/wwa_iabinvoice_1.0.0.xsd
<?xml version="1.0"?>
<InvoiceAcknowledgement xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<InvoiceAcknowledgementEnvelope>
<SenderID>edi_transglory_prod</SenderID>
<ReceiverID>INBOM01</ReceiverID>
<Password>TEST12345</Password>
<Type>Invoice_Acknowledgement</Type>
<Version>1.0.0</Version>
<EnvelopeID>b776a8f2-367e-4ac1-978b-3324c7c1f3af</EnvelopeID>
</InvoiceAcknowledgementEnvelope>
<InvoiceAcknowledgementDetails>
<InvoiceNumber>TEST20140927S03</InvoiceNumber>
<InvoiceType>I</InvoiceType>
<ReferenceType>2</ReferenceType>
<PayorReference>mbl1234567</PayorReference>
<StatusCode>305</StatusCode>
<StatusDateTimeDetails>
<Date>2014-10-14</Date>
<Time>10:55:00</Time>
</StatusDateTimeDetails>
<Description>Invoice TEST20140927S03 is disputed.</Description>
<InvoiceDate>2014-10-14</InvoiceDate>
<InvoiceTime>10:00:00</InvoiceTime>
<UUID></UUID>
</InvoiceAcknowledgementDetails>
</InvoiceAcknowledgement
Field | Content | Length | Input |
Envelope | |||
SenderID | Sender ID to identify sender, edi user name of the member. | 50 | Required |
ReceiverID | Receiver ID to identify receiver, WWA Member Office. | 100 | Required |
Password | Password as assigned by WWA, the XML password | 100 | Required |
Type | Message type, ‘WWA_Invoice_Ack_XML’. | 50 | Required |
Version | Message version, should be 1.0.0 | 8 | Required |
EnvelopeID | Unique ID for message to have a follow up option. | 40 | Required |
IABInvoice Acknowledgement Details | |||
InvoiceNumber | WWA Member Invoice Number. | 25 | Required |
HouseBillOfLadingNumber | HouseBillOfLadding Number of the shipment. | 20 | Required for Export Invoice |
ArrivalNoticeNumber | ArrivalNotice Number of the shipment. | 20 | Required for Import Invoice |
InvoiceType | 'I' for Import or 'E' for Export. | 1 | Required |
ReferenceType | #"1"=Container, #"2"=MBL, #"3"=HBL, #"4"=Others | 1 | Required |
PayorReference | WWA Customer Reference | 50 | Optional |
StatusCode | Status of Invoice. "301" = Invoice Approved, "302" = Invoice Paid, "303" = Invoice Reject, "304" = Invoice TechnicalReject,"305" = Invoice BusinessDisputed,"306" = Invoice file received successfully, "307" = Invoice TechnicalAccept | 3 | Required |
Description | Description of Invoice / reason for invoice rejection, etc | 100 | optional |
StatusDateTimeDetails | |||
Date | Date of Status of Invoice. | 10 | Required |
Time | Time of Status of Invoice. | 10 | Required |
InvoiceDate | The Date of the Invoice (YYYY-MM-DD). | 10 | Required |
InvoiceTime | Invoice Time (Default Time Zone: GMT) | 10 | Optional |
UUID | Unique document identifier. | 50 | Optional |
Invoice : {SCAC}_INVOICE_{TYPE}_{INVOICE_TYPE}_{INVOICE_MODE}_{INVOICE_NUMBER}.{Date}.{hhmmss}.{ms}.XML Invoice
Acknowledgement: {SCAC}_INVOICEACK_{TYPE}_{INVOICE_TYPE}_{INVOICE_MODE}_{INVOICE_NUMBER}.{Date}.{hhmmss}.{ms}.XML
SCAC : Member SCAC Code
TYPE : S=Standard,C=Credit
INVOICE_TYPE : M
INVOICE_MODE : Export=E,IMPORT=I
SHPT_INVOICE_S_M_E_20292873.20140606.062223.679.XML
TMGB_INVOICEACK_S_M_E_20292874.20140606.062223.679.XML
Example :
/home/edi_teamglobal_prod/upload/invoice_xml/
/home/edi_shipco_prod/upload/invoice_xml/
/home/edi_teamglobal_prod/upload/invoice_acknowledgement
- When all valid data for an invoice is received, has posted successfully in the WWA member’s
system and will be paid based on payment terms.
- If the accounting team verifies the invoice details and find them correct then this status
should be triggered to WWA
- When the Invoice has been successfully paid by the WWA member.
- When the invoice is rejected for reasons such as incorrect payor data, charge details, date,
address, etc. Reason for the rejection is included in the “Description” section of the
acknowledgement.
- There could be various reasons other than "Invoice BusinessDisputed" (see details under status
305 below) e.g. if the invoice does not contain correct handling office code then this status
should be triggered to WWA.
- When the invoice transmitted does not meet the IAB invoice schema structure.
- If the Invoice EDI file was not processed in the WWA member's system due to structural issues
e.g. data mismatch as per schema, improper XML, etc. then this status should be triggered to WWA.
- If the accounting team finds any discrepancy in the invoice details (Invoice amount, shipment
numbers,references etc) then this status should be triggered to WWA.
- If the Invoice EDI file was processed successfully in the WWA member's system then this status
code should be triggered to WWA.