(Option 2) Use Amazon Tax Calculation Data to Create Invoices
Register through the VAT Calculation Services (VCS) program, use the Amazon tax calculation data to create data invoices, then upload the invoices using the Selling Partner API (SP-API).
This option can be used only with the Selling Partner API (SP-API). You must use the tax data provided by Amazon to create your invoices.
Use the following procedure to upload your invoices with the SP-API.
Step 1. Extract the tax calculation data for all your orders from the VAT invoice data report (VIDR).
The VIDR is a report that contains tax calculation details at the transaction level, and is only available to sellers who have enrolled in VCS. This report contains all the information required to generate an accurate VAT invoice for each shipment, whether seller-fulfilled or Fulfilled by Amazon (FBA). An order is available in this report immediately after its shipment has been dispatched.
API | Reports API |
---|---|
Operation | createReport |
reportType | GET_FLAT_FILE_VAT_INVOICE_DATA_REPORT or GET_XML_VAT_INVOICE_DATA_REPORT |
reportOptions |
With this option, the report includes shipment details for shipped orders whose order dates are within the past 90 days, and for which invoices are due and must be uploaded. This means all shipments where the invoice status is
The report includes shipments of all possible Default: |
You can determine when to schedule these reports. Amazon recommends scheduling at least twice a day so that invoices can be uploaded with a maximum delay of 12 hours (within the SLA of 24 hours) after the shipment has been dispatched.
An invoice is due for each shipment (not order) after the shipment has been dispatched. A shipment can have one of the statuses in the following table:
Invoice status | Description | Action required |
---|---|---|
InvoicePending | Shipment has been dispatched. | The seller must upload an invoice for the shipment. |
InvoiceProcessing | Seller has uploaded the invoice and Amazon is processing it. | No action is required from the seller at this point. Amazon will process the invoice. |
InvoiceUploaded | Seller has uploaded the invoice and Amazon has finished processing it. There was no error detected. | No action is required from the seller. Invoice successfully uploaded and is available to the customer in the Your Orders page. Customers can download the invoice at any time. |
InvoiceRejected | Seller has uploaded the invoice and Amazon has finished processing it. There were errors detected in the upload. | Seller must upload the invoice for this shipment again. |
CreditNotePending | In the case of a refund, the money has been returned to the buyer. In the case of a return, the item has been received in Amazon's fulfillment center for FBA orders, or has been authorized by the seller for seller fulfilled orders. | Credit Note is now due for this transaction. |
CreditNoteProcessing | Seller has uploaded the invoice and Amazon is processing it. | No action is required from the seller at this point. Amazon will process the credit note. |
CreditNoteUploaded | Seller has uploaded the credit note and Amazon has finished processing it. There was no error detected. | No action is required from the seller. Credit Note successfully uploaded and made available to the customer on the Your Orders page. |
CreditNoteRejected | Seller has uploaded the credit note and Amazon has finished processing it. There were errors detected in the upload. | Seller must upload the Credit Note for this transaction again. |
CreditNoteCreatedByAmazon | Amazon created a credit note for this transaction. | No action is required from the seller. |
NoTaxCalculated | Amazon could not calculate any tax for this transaction. This usually happens when the seller has not uploaded a VAT number for the country from where the shipment was dispatched. For example, the seller opted in for Pan EU FBA, and did not provide a VAT number of CZ. If a shipment is dispatched from CZ, Amazon is not able to calculate VAT. | Amazon will not calculate the VAT and the seller must upload the invoice for this transaction. The seller can upload the invoice in Seller Central or using Amazon Marketplace Web Service, following the Invoice Uploader Developer Guide. |
InvoiceCreatedByAmazon | Amazon created an invoice for this transaction. | No action is required from the seller. |
VIDR columns
The following table explains each VIDR column:
Field name | Definition | Example |
---|---|---|
order-id | Amazon's unique order identifier. Used for shipping confirmation and post-order processing. | 736-3563777-5518068 |
order-item-id | Amazon's unique order item identifier. Used for shipping confirmation and post-order processing. | 583563777345 |
shipping-id | Shipping ID for this shipment. | 409302382 |
fulfilled-by | The fulfillment channel for this order. | MFN or FBA |
order-date | Date the order was placed. | 17/05/2018 |
marketplace-id | The marketplace in which the order was placed. | DE, FR, UK, IT, ES |
recipient-name | Name of the recipient. | Mary Major |
buyer-name | Name of the buyer. | Diego Ramirez |
ship-service-level | Fulfillment service level paid for by the buyer when ordering the item. For example, standard or expedited. | Standard |
ship-address-1 | The first line of the Ship To address. | 123 Any Street |
ship-address-2 | Second line of Ship To address. | Apt. 12 |
ship-address-3 | Third line of Ship To address. | c/o Example Corp. |
ship-city | City of Ship To address. | Any City |
ship-state | State of Ship To address. | Any State |
ship-postal-code | Postal Code of Ship To address. | SL1 1QP |
ship-country | The international standard two-letter country code (ISO 3166-compliant). | UK |
ship-phone-number | Phone number of the shipping address. | 999999999 |
shipment-date | Date of dispatch of this shipment. | 20/05/2018 |
billing-name | Billing name. | Márcia Oliveira |
bill-address-1 | The first line of the billing address. | 100 Main Street |
bill-address-2 | The second line of the billing address. | Apt. 12 |
bill-address-3 | The third line of the billing address. | c/o AnyCompany |
bill-city | City of the billing address. | Any City |
bill-state | State of the billing address. | Any State |
bill-postal-code | Postal code of the billing address. | U7D 294 |
bill-country | The international standard two-letter country code (ISO 3166-compliant). | UK |
bill-phone-number | Phone number of the billing address. | 44234343 |
ship-from-city | City of Ship From address. | Any City |
ship-from-state | State of Ship From address. | Any State |
ship-from-country | Country of Ship From address. | UK |
ship-from-postal-code | Postal code of Ship From address. | D76 UT9 |
sku | Stock-keeping unit. Seller-defined unique identifier for a product. | sku123 |
product-name | Name of the product. | DJI CP.PT.03342 Spark - Battery Charging Hub |
quantity-purchased | Quantity purchased. | 1 |
currency | The currency used for the transaction. | GBP |
asin | ASIN of the product. | AY39345YE8K |
item-vat-incl-amount | VAT Inclusive item price. | 120.00 |
item-vat-amount | VAT amount of item price. | 20.00 |
item-vat-excl-amount | VAT exclusive item price. | 100.00 |
item-vat-rate | VAT rate of item price. | 0.20 |
gift-wrap-vat-incl-amount | Total VAT inclusive gift wrap. | 12.00 |
gift-wrap-vat-amount | Total VAT amount of gift wrap. | 2.00 |
gift-wrap-vat-excl-amount | Total VAT exclusive gift wrap. | 10.00 |
gift-wrap-vat-rate | Total VAT rate of gift price. | 0.20 |
shipping-vat-incl-amount | VAT inclusive shipping price. | 6.00 |
shipping-vat-amount | VAT amount of shipping price. | 1.00 |
shipping-vat-excl-amount | VAT exclusive shipping price. | 5.00 |
shipping-vat-rate | VAT rate of shipping price. | 0.20 |
item-promo-vat-incl-amount | Total VAT inclusive item promotion. | -0.12 |
item-promo-vat-amount | Total VAT amount item promotion. | -0.02 |
item-promo-vat-excl-amount | Total VAT exclusive item promotion. | -0.10 |
item-promo-vat-rate | Total VAT rate item promotion. | 0.20 |
item-promotion-id | Promotion ID for item promotion. | 136643052:AKY54VWVKS3JCY6T (This is an ID generated by Amazon; alphanumeric value) |
shipping-promo-vat-incl-amount | Total VAT inclusive shipping promotion. | -0.12 |
shipping-promo-vat-amount | Total VAT amount shipping promotion. | -0.02 |
shipping-promo-vat-excl-amount | Total VAT exclusive shipping promotion. | -0.10 |
shipping-promo-vat-rate | Total VAT rate shipping promotion. | 0.20 |
shipping-promotion-id | Promotion ID of shipping promotion. | 3943834723:BWJRJERIUDKERU (This is an ID generated by Amazon; alphanumeric value) |
gift-promo-vat-incl-amount | Total VAT inclusive gift wrap promotion. | -0.20 |
gift-promo-vat-amount | Total VAT amount gift wrap promotion. | -0.12 |
gift-promo-vat-excl-amount | Total VAT exclusive gift wrap promotion. | -0.02 |
gift-promo-vat-rate | Total VAT rate gift wrap promotion. | 0.10 |
gift-promotion-id | Promotion ID of gift wrap promotion. | 385934052:BWJRJDJSDS3JCY6T |
transaction-id | For shipments, this is the shipping ID. For returns, this is a unique transaction ID (different from shipping ID). | 409302382 (if it is a shipment); amzn1:crow:A0f6kWaFSV6ymAlMHe4VJw (if return or refund. In the case of return/refund, this is a unique transaction ID in alphanumeric format) |
transaction-type | Values can be shipment, refund, or return, depending on the type of transaction. | SHIPMENT, RETURN, REFUND |
is-amazon-invoiced | Indicates if Amazon creates an Invoice for this transaction. True if the seller uses VCS and chooses the option to allow Amazon to create the invoices, or if Amazon World Imports buys from the seller. The seller should not create Invoices for these transactions. Amazon will generate an invoice and make it available to the seller. | TRUE or FALSE |
invoice-status | Status of the invoice, described in detail in section 6.1. | Refer to section 6.1 for details on invoice status. |
invoice-status-description | Description of the invoice status, described in detail in section 6.1. | The detailed description of what the invoice status means. |
is-business-order | Was this order from Amazon Business website or B2C website? | TRUE or FALSE |
purchase-order-number | PO number (if supplied by the customer). | AB45-234934 (can be any string) |
seller-vat-number | VAT number of the seller used in VAT calculation. | DE111111111 |
buyer-vat-number | Buyer VAT number used in VAT calculation. | DE22222222 or blank if the customer does not have a VAT Number on Amazon. |
buyer-company-name | Company name of the buyer. | AnyCompany |
price-designation | Indicates if this is Business Price or Standard Price. | Business Price or Standard Price |
invoice-number | The invoice number provided by the seller. In the case of a PendingInvoices view, the column is blank because the invoice has not been uploaded. In the case of an All view, the column will contain the invoice number uploaded by the seller. | XXXX |
legacy-customer-order-item-id | This order item ID is the same as that found in FBA reports and MFN reports. If you want to match the individual line items from a VIDR to FBA or MFN reports, you can use this column. | 82840304120340 |
buyer-tax-registration-type | The tax type of the customer (if the customer has a tax registration number). | VAT/BusinessReg/CitizenId. In the Spain and Italy marketplaces, businesses could have Business Registration number (BusinessReg) or individuals could have tax IDs (CitizenID). |
is-buyer-physically-present | True if the customer is physically established in the country for which the tax number was provided in the buyer-vat-number column. | TRUE or FALSE |
is-seller-physically-present | True if the seller is physically established in the country for which the VAT number was provided in the seller-vat-number column. | TRUE or FALSE |
buyer-e-invoice-account-id | The e-invoice account ID of the customer. This is populated if the customer has provided an e-invoice account ID (which can be used to send the invoice to Sistema di Interscambio (SdI), if required). This column is specifically added for Italy e-invoicing law that came into effect in 2019, so that sellers can upload invoices to SdI. | XXXXXXXX |
recommended-invoice-format | Recommended invoice format to be submitted for tax authorities. If the value is PDF, you must upload the PDF invoice format to Amazon, and use the same PDF as the true invoice copy. If the recommended format is XML, then Amazon has determined that the customer is a B2B Customer in IT, and the seller is physically established in IT, thus the seller must upload an XML invoice in Sistema di Interscambio (SdI) according to the Italian law related to E-invoicing. The XML invoice available on SdI will be considered the true copy of the invoice. However, you must also upload a PDF invoice to Amazon. The PDF should contain additional text or a watermark indicating that this is a duplicate invoice. The customer can retrieve the original invoice from SdI. | PDF or XML. If the value in this column is XML, then the seller must additionally upload an XML invoice on SdI. If the value in this column in PDF, then the seller needs to upload the invoice only to Amazon through the Invoice Upload Feed Type. Note that regardless of the value in this column, the seller must always upload a PDF invoice to Amazon using the Invoice Upload feed type. |
Citation-en | This column provides the citation text in English. | We recommended that the seller use the citation text provided on the invoice. The seller is free to choose the language they want to use for citation, depending on the language on the invoice. |
Citation-de | This column provides the citation text in German. | We recommended that the seller use the citation text provided on the invoice. The seller is free to choose the language they want to use for citation, depending on the language on the invoice. |
Citation-es | This column provides the citation text in Spanish. | We recommended that the seller use the citation text provided on the invoice. The seller is free to choose the language they want to use for citation, depending on the language on the invoice. |
Citation-fr | This column provides the citation text in French. | We recommended that the seller use the citation text provided on the invoice. The seller is free to choose the language they want to use for citation, depending on the language on the invoice. |
Citation-it | This column provides the citation text in Italian. | We recommended that the seller use the citation text provided on the invoice. The seller is free to choose the language they want to use for citation, depending on the language on the invoice. |
Is-invoice-corrected | Indicates if this transaction referring to a previous corrected invoice. True if this transaction is a correction of a previous transaction. | TRUE or FALSE |
original-vat-invoice-number | The invoice number of the original shipment whose invoice has to be corrected. | The original invoice number. |
invoice-correction-details | Invoice amendment details describing changes on the invoice. This is only applicable for invoice amendment transaction. | New invoice issued after amending billing address on original VAT invoice. OR Credit note issued to amend billing address on original VAT invoice. |
Step 2. Create your own invoices based on the data from the VIDR report.
Download the VIDR report and use the information to compile your VAT invoice.
Step 3. Upload the invoices to Amazon using the Feeds API.
API | Feeds API |
---|---|
Operation | createFeed |
FeedType | UPLOAD_VAT_INVOICE |
marketplaceIds | Spain UK France Germany Italy Netherlands Poland Sweden Belgium |
feedOptions |
Note: Either OrderId or ShippingId is required when uploading an invoice. Amazon strongly recommends uploading an invoice against the shipping ID. If both order ID and shipping ID are specified, Amazon will ignore the order ID and upload the invoice against shipping ID. If neither is provided, an error might be returned. Possible errors are in the following sections.
Invoice upload examples:
Credit note example (
Do not add quotation marks around keys or values. Amazon only accepts the following characters: commas, forward slashes, backslashes, spaces, dashes, underscores, semi colons, colons, 0-9, A-Z, a-z, #. Amazon trims extra space. |
The throttling limit for the Invoicing Feed (UPLOAD_VAT_INVOICE) is one invoice upload every three seconds.
Sample Java code for creating the feedoptions:
Map<String, String> feedOptions = new HashMap<>(); // building parameter map
feedOptions.put("metadata:OrderId", "XXX-XXXXXXX-XXXXXXX");
feedOptions.put("metadata:TotalAmount", String.format(TOTALAMMOUNT));
feedOptions.put("metadata:TotalVATAmount", String.format(TOTALVATAMMOUNT));
feedOptions.put("metadata:InvoiceNumber", INVOICE_NUMBER);
String options = feedOptions.entrySet().stream()
.map(e -> String.format("%s=%s", e.getKey(), e.getValue()))
.collect(Collectors.joining(";"));
File pdfD = new File("<PATH TO PDF>");
byte[] pdfDocument = FileUtils.readFileToByteArray(pdfD); // read pdf document to byte array
String contentMD5 = Base64.encodeBase64String(pdfDocument); // building hash code
InputStream contentStream = new ByteArrayInputStream(pdfDocument); // inputstream of
SubmitFeedResponse response = submitFeed(contentStream, contentMD5, "_UPLOAD_VAT_INVOICE_", options, ContentType.OctetStream);
public SubmitFeedResponse submitFeed(InputStream, String contentMD5, String feedType, String feedOptions, ContentType contentType)
{
SubmitFeedRequest request = new SubmitFeedRequest();
request.setContentMD5(contentMD5);
request.setFeedContent(inputStream);
request.setFeedOptions(feedOptions);
request.setFeedType(feedType);
request.setMarketplaceIdList(new IdList(Arrays.asList(getMarketPlaces());
request.setMerchant(configuration.getAmazon().getSellerId());
request.setMWSAuthToken(configuration.getAmazon().getMwsAuthToken());
request.setContentType(contentType);
return getMarketplaceWebServiceClient().submitFeed(request);
}
Updated 15 days ago