intuit partner platform - Fetch Data from Quickbook -


hello guys i'm new quickbooks. there data in quickbooks i'm trying retrieve quickbooks returning nothing. can figure out i'm doing wrong. i'm trying retrieve data

quickbooks. php

$servicetype = intuitservicestype::qbo; $realmid = $this->ci->session->userdata('realmid'); $token = unserialize($this->ci->session->userdata('token')); $requestvalidator = new oauthrequestvalidator($token["oauth_token"],                     $token["oauth_token_secret"],                     $this->ci->config->item('oauth_consumer_key'),                     $this->ci->config->item('oauth_consumer_secret')); $servicecontext = new servicecontext($realmid, $servicetype, $requestvalidator); $dataservice = new dataservice($servicecontext); $entities = $dataservice->query("select * salesreceipt"); error_log(print_r($entities , true)); 

can tell me i'm doing wrong.

the first thing should in case this, turn on logging, , post logs.

there not can tell here without seeing logs.

with said, it's worth nothing error:

instead of dataservice tried using quickbooks_ipp_services_salesreceipt it's giving me error salesrecipt class not defined

is because class totally separate, unrelated php code library. if want use class, should is:

.

$salesreceiptservice = new quickbooks_ipp_service_salesreceipt(); $salesreceipts = $salesreceiptservice->query($context, $realm, "select * salesreceipt startposition 1 maxresults 10");  foreach ($salesreceipts $salesreceipt) {     print('receipt # ' . $salesreceipt->getdocnumber() . ' has total of $' . $salesreceipt->gettotalamt() . "\n");  } 

if still have trouble, can http request/response this:

print($ipp->lasterror($context)); print("\n\n\n\n"); print('request [' . $ipp->lastrequest() . ']'); print("\n\n\n\n"); print('response [' . $ipp->lastresponse() . ']'); 

more examples can found here:


Comments

Popular posts from this blog

c# - How Configure Devart dotConnect for SQLite Code First? -

c++ - Clear the memory after returning a vector in a function -

erlang - Saving a digraph to mnesia is hindered because of its side-effects -