# Create sales invoice before shipping for advanced features

Source: https://developer.avalara.com/products/crossborder/integration-guides/avatax-for-cdit/ubx5418005795073/

Guide: AvaTax Cross-Border (Customs Duty and Import Tax)

# Create sales invoice before shipping for advanced features

Learn how to convert a quote to a sales invoice while preserving pricing commitments.

This example converts the original quote to a sales invoice, preserving the original pricing commitment between the Buyer and Seller. AvaTax will record this transaction; however, this transaction is for reference only and will not get committed for compliance reporting.

**Example request**

Convert the quote to an invoice, but do not commit it.

```
{
  "lines": [
    {
      "number": "1",
      "quantity": 1,
      "amount": 950,
      "itemCode": "SKU 1000.6",
      "taxCode": "P00000000",
      "description": "Cuban Links",
      "hsCode": "6204420090", // Send customs grade HS Codes by Country and pass to AvaTax
      "category" : "Man > Jewelry ; Gold > Bracelet", // Optionally send category; assuming only partial HS Code provided to get estimated duty
"taxIncluded": false,
"parameters": [
{
  "name": "NetWeight", // If applicable, API will raise an data validation exception if a parameter is missing
  "value": "5",
  "unit": "Pound"
},
{
  "name": "IsPreferredProgram",
  "value": true
},
{
  "name": "CountryOfManufacture",
  "value": "US"
}
      ]
    }
      // Send Freight and Insurance as separate lines where applicable with appropriate Avalara goods and Service Code
   ],
  "type": "SalesOrder",
  "companyCode": "DEFAULT",
  "date": "11-21-2021",
  "customerCode": "test-customer",
  "addresses": {
    "shipFrom": {
      "line1": "",
      "city": "",
      "region": "WA",
      "country": "US",
      "postalCode": "98110"
    },
    "shipTo": {
      "line1": "",
      "city": "",
      "region": "",
      "country": "DE",
      "postalCode": ""
    }
  },
  "isSellerImporterOfRecord": "true",
  "deliveryTerms": "DDP",
  "currencyCode": "USD",
  "commit": false
}
```