The very first call top sendRequestXML() for each session will send you a strHCPResponse from QuickBooks. It will look like this:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<sendRequestXML xmlns="http://developer.intuit.com/">
<ticket>a05fd1b411f6e22adbb5717f96876b5b</ticket>
<strHCPResponse><?xml version="1.0" ?>
<QBXML>
<QBXMLMsgsRs>
<HostQueryRs requestID="0" statusCode="0" statusSeverity="Info" statusMessage="Status OK">
<HostRet>
<ProductName>QuickBooks Pro 2006</ProductName>
<MajorVersion>16</MajorVersion>
<MinorVersion>0</MinorVersion>
<Country>US</Country>
<SupportedQBXMLVersion>1.0</SupportedQBXMLVersion>
<SupportedQBXMLVersion>1.1</SupportedQBXMLVersion>
<SupportedQBXMLVersion>2.0</SupportedQBXMLVersion>
<SupportedQBXMLVersion>2.1</SupportedQBXMLVersion>
<SupportedQBXMLVersion>3.0</SupportedQBXMLVersion>
<SupportedQBXMLVersion>4.0</SupportedQBXMLVersion>
<SupportedQBXMLVersion>4.1</SupportedQBXMLVersion>
<SupportedQBXMLVersion>5.0</SupportedQBXMLVersion>
<IsAutomaticLogin>false</IsAutomaticLogin>
<QBFileMode>SingleUser</QBFileMode>
</HostRet>
</HostQueryRs>
<CompanyQueryRs requestID="1" statusCode="0" statusSeverity="Info" statusMessage="Status OK">
<CompanyRet>
<IsSampleCompany>false</IsSampleCompany>
<CompanyName>Test Company 2</CompanyName>
<LegalCompanyName>Test Company 2</LegalCompanyName>
<FirstMonthFiscalYear>January</FirstMonthFiscalYear>
<FirstMonthIncomeTaxYear>January</FirstMonthIncomeTaxYear>
<CompanyType>General Business</CompanyType>
<TaxForm>OtherOrNone</TaxForm>
<DataExtRet>
<OwnerID>{57F3B9B6-86F1-4fcd-B1EF-166DE1813D20}</OwnerID>
<DataExtName>AppLock</DataExtName>
<DataExtType>STR255TYPE</DataExtType>
<DataExtValue>LOCKED:MACBOOK-WINDOWS:633772023577302500</DataExtValue>
</DataExtRet>
<DataExtRet>
<OwnerID>{57F3B9B6-86F1-4fcd-B1EF-166DE1813D20}</OwnerID>
<DataExtName>FileID</DataExtName>
<DataExtType>STR255TYPE</DataExtType>
<DataExtValue>{57F3B9B6-86F1-4fdc-B1EF-966DE1813D20}</DataExtValue>
</DataExtRet>
</CompanyRet>
</CompanyQueryRs>
<PreferencesQueryRs requestID="2" statusCode="0" statusSeverity="Info" statusMessage="Status OK">
<PreferencesRet>
<AccountingPreferences>
<IsUsingAccountNumbers>false</IsUsingAccountNumbers>
<IsRequiringAccounts>true</IsRequiringAccounts>
<IsUsingClassTracking>false</IsUsingClassTracking>
<IsUsingAuditTrail>true</IsUsingAuditTrail>
<IsAssigningJournalEntryNumbers>true</IsAssigningJournalEntryNumbers>
</AccountingPreferences>
<FinanceChargePreferences>
<AnnualInterestRate>0.00</AnnualInterestRate>
<MinFinanceCharge>0.00</MinFinanceCharge>
<GracePeriod>0</GracePeriod>
<IsAssessingForOverdueCharges>false</IsAssessingForOverdueCharges>
<CalculateChargesFrom>DueDate</CalculateChargesFrom>
<IsMarkedToBePrinted>false</IsMarkedToBePrinted>
</FinanceChargePreferences>
<JobsAndEstimatesPreferences>
<IsUsingEstimates>true</IsUsingEstimates>
<IsUsingProgressInvoicing>false</IsUsingProgressInvoicing>
<IsPrintingItemsWithZeroAmounts>false</IsPrintingItemsWithZeroAmounts>
</JobsAndEstimatesPreferences>
<PurchasesAndVendorsPreferences>
<IsUsingInventory>true</IsUsingInventory>
<DaysBillsAreDue>10</DaysBillsAreDue>
<IsAutomaticallyUsingDiscounts>false</IsAutomaticallyUsingDiscounts>
</PurchasesAndVendorsPreferences>
<ReportsPreferences>
<AgingReportBasis>AgeFromDueDate</AgingReportBasis>
<SummaryReportBasis>Accrual</SummaryReportBasis>
</ReportsPreferences>
<SalesAndCustomersPreferences>
<IsTrackingReimbursedExpensesAsIncome>false</IsTrackingReimbursedExpensesAsIncome>
<IsAutoApplyingPayments>true</IsAutoApplyingPayments>
<PriceLevels>
<IsUsingPriceLevels>true</IsUsingPriceLevels>
<IsRoundingSalesPriceUp>true</IsRoundingSalesPriceUp>
</PriceLevels>
</SalesAndCustomersPreferences>
<TimeTrackingPreferences>
<FirstDayOfWeek>Monday</FirstDayOfWeek>
</TimeTrackingPreferences>
<CurrentAppAccessRights>
<IsAutomaticLoginAllowed>false</IsAutomaticLoginAllowed>
<IsPersonalDataAccessAllowed>false</IsPersonalDataAccessAllowed>
</CurrentAppAccessRights>
</PreferencesRet>
</PreferencesQueryRs>
</QBXMLMsgsRs>
</QBXML>
</strHCPResponse>
<strCompanyFileName>C:\Documents and Settings\Keith Palmer Jr\Desktop\Accounting\QBW\Test Company 2.QBW</strCompanyFileName>
<qbXMLCountry>US</qbXMLCountry>
<qbXMLMajorVers>5</qbXMLMajorVers>
<qbXMLMinorVers>0</qbXMLMinorVers>
</sendRequestXML>
</soap:Body>
</soap:Envelope>
Every subsequent request will leave out the strHCPResponse data.
<?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <soap:Body> <sendRequestXML xmlns="http://developer.intuit.com/"> <ticket>a05fd1b411f6e22adbb5717f96876b5b</ticket> <strHCPResponse /> <strCompanyFileName>C:\Documents and Settings\Keith Palmer Jr\Desktop\Accounting\QBW\Test Company 2.QBW</strCompanyFileName> <qbXMLCountry>US</qbXMLCountry> <qbXMLMajorVers>5</qbXMLMajorVers> <qbXMLMinorVers>0</qbXMLMinorVers> </sendRequestXML> </soap:Body> </soap:Envelope>
Your response should be a valid SOAP response with the qbXML portion encoded as a SOAP value. The example below shows a qbXML RecievePaymentAdd request being sent back to the QuickBooks Web Connector.
<?xml version="1.0" encoding="UTF-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://developer.intuit.com/"> <SOAP-ENV:Body> <ns1:sendRequestXMLResponse> <ns1:sendRequestXMLResult><?xml version="1.0" encoding="utf-8"?> <?qbxml version="2.1"?> <QBXML> <QBXMLMsgsRq onError="stopOnError"> <ReceivePaymentAddRq requestID="UmVjZWl2ZVBheW1lbnRBZGR8MTE2"> <ReceivePaymentAdd> <CustomerRef> <ListID>90000-1241602188</ListID> </CustomerRef> <TxnDate>2009-05-06</TxnDate> <RefNumber>116</RefNumber> <TotalAmount>265.40</TotalAmount> <Memo>Payment for invoice #116</Memo> <IsAutoApply>true</IsAutoApply> </ReceivePaymentAdd> </ReceivePaymentAddRq> </QBXMLMsgsRq> </QBXML></ns1:sendRequestXMLResult> </ns1:sendRequestXMLResponse> </SOAP-ENV:Body> </SOAP-ENV:Envelope>