0

I am trying to send some data to an app, and they using Oauth 1.0a , but i never use it. I tryed to look here for some help and i tryed to look for tutos too but i didnt understand anything. I found this link : http://oauth.net/code/

But honestly i didnt understand how to. The api use Oauth1.0a «2-legged»

$conskey = '<key>';
$conssec = '<secret>';
try {
$oauth = new OAuth($conskey, $conssec, OAUTH_SIG_METHOD_HMACSHA1, OAUTH_AUTH_TYPE_AUTHORIZATION);
$oauth->enableDebug();
$data = new stdClass();
...
$ret = $oauth->fetch('url', json_encode($data), OAUTH_HTTP_METHOD_POST, array('Content-Type' => 'application/json', 'Accept' => 'application/json'));
}

if someone can help how to use Oauth1.0a with php , and if it's possible to use it with codeigniter 3. Thank you.

Enigma_20
  • 1
  • 1
  • I assure you no, I read a lot of articles and did a lot of research – Enigma_20 Feb 09 '21 at 15:48
  • So you read the spec and came up empty? Because the alternative is that I read the spec. Which I have no reason to do. – GetSet Feb 09 '21 at 15:57
  • yes but how to use the class OAuth, since it s not a native PHP class. Must I add something to my site and if yes how to call – Enigma_20 Feb 09 '21 at 16:59
  • OAuth2.0 is not a native PHP class either. Something you would have realized if you did any exhaustive research. Dont seems like you prefer APIs – GetSet Feb 09 '21 at 17:07

0 Answers0