Witam.
Chciałem uzykać odpowiedz czy jest możliwe połączenie sie z infaktem bez podawania hasła i loginu a korzystania tylko i wyłącznie z KEY i SECRET. Chce skorzystać z kodu Jana Kondratowicza, musze skorzystać wiec z funkcji która oczekuje ode mnie hasła i loginu. czy jest mozliwość zeby to ominąć i uzyskać TOKEN?
public function authorize($username, $password) {
$parameters['x_auth_username'] = $username;
$parameters['x_auth_password'] = $password;
$parameters['x_auth_mode'] = 'client_auth';
$oauth_request = OAuth\Request::from_consumer_and_token($this->consumer, null, 'GET', $this->requestTokenUrl);
$oauth_request->sign_request($this->signatureMethod, $this->consumer, null);
$response = $this->http($oauth_request->to_url(), 'GET');
$this->token = new OAuth\Token($response['oauth_token'], $response['oauth_token_secret']);
$oauth_request = OAuth\Request::from_consumer_and_token($this->consumer, $this->token, 'POST', $this->accessTokenUrl, $parameters);
$oauth_request->sign_request($this->signatureMethod, $this->consumer, $this->token);
$response = $this->http($oauth_request->to_url(), 'GET');
$this->token = new OAuth\Consumer($token_array['oauth_token'], $token_array['oauth_token_secret']);
return true;
}