ruby-on-railsquickbooksqbxmlqbwc

QBXML SalesOrderAdd issue


I am trying to create SalesOrder through QBWebConnector (backend - Rails + qbwc), following Onscreen Reference for Intuit Software Development Kits, and it says that SalesOrderAdd requires only CustomerRef attribute, but QBXML validator says:

Line: 10
LinePos: 9
Src Text: </SalesOrderAdd>
Reason: Element content is incomplete according to the DTD/Schema.
Expecting: ClassRef, TemplateRef, TxnDate, RefNumber, BillAddress, ShipAddress, PONumber, TermsRef, DueDate, SalesRepRef, FOB, ShipDate.

QBXML Request is:

<?xml version="1.0" encoding="ISO-8859-1"?>
<?qbxml version="7.0"?>
<QBXML>
  <QBXMLMsgsRq onError="stopOnError">
    <SalesOrderAddRq>
      <SalesOrderAdd>
        <CustomerRef>
          <FullName>Test customer</FullName>
        </CustomerRef>
      </SalesOrderAdd>
    </SalesOrderAddRq>
  </QBXMLMsgsRq>
</QBXML>

Why is that? Can I change this behavior somehow (omit all tags except pointed as required in Onscreen Reference)?


Solution

  • The OSR is... less than perfect. But it does indicate there are additional required fields.

    You need to add at least one line item or group line.

    enter image description here