php - Unable to Call Reconnect API -


i trying connect reconncet api of quickbooks. says me 'this api requires authorization' dont understand mean.

$nonce = <random string>;     $time = time();      $url = "https://appcenter.intuit.com/api/v1/connection/reconnect?oauth_consumer_key=qyprdxncjbz7mv8zujvlc155xtmeoe&oauth_nonce=$nonce&oauth_signature=eidxzulefveroxdbrt58nitvc2imtcqjoczy81bl%26nyxwe3eewpmkx5qm9fwzotzjw7jupahaaa9z74ch&oauth_signature_method=plaintext&oauth_timestamp=$time&oauth_token=qyprd2p9wwof6mn8phszdk6rlwtcph0neezqhkwdokxdl2aq&oauth_version=1.0";      $params = array     (         19913 => 1,         10002 => $url,         10023 => array             (              ),          10102 => '',         41 => 0,         64 => 0,         81 => 0     );     $ch = curl_init();     curl_setopt_array($ch, $params);     $response = curl_exec($ch);     print_r($response);  

please me on problem. need this.

thanks in advance

the reconnect api requires pass in valid set of oauth headers in order authenticate, can renew soon-to-expire oauth tokens.

the important thing realize here you can't invent oauth header string, there's specific signing algorithm have follow.

by hard-coding posted above, there's no way valid oauth headers.

unless you're familiar oauth , want roll own, use existing quickbooks php library already has reconnect api support.

if want roll own (you don't) read , implement spec.


Comments

Popular posts from this blog

html - Sizing a high-res image (~8MB) to display entirely in a small div (circular, diameter 100px) -

java - IntelliJ - No such instance method -

identifier - Is it possible for an html5 document to have two ids? -