PHP Класс TwitterOAuth, phergie

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$connecttimeout * Set connect timeout.
$decode_json * Decode returned json data.
$format * Respons format.
$host * Set up the API root URL.
$http_code * Contains the last HTTP status code returned.
$http_info * Contains the last HTTP headers returned.
$ssl_verifypeer * Verify SSL Cert.
$timeout * Set timeout default.
$url * Contains the last API call.
$useragent * Set the useragnet.

Открытые методы

Метод Описание
__construct ( $consumer_key, $consumer_secret, $oauth_token = NULL, $oauth_token_secret = NULL ) construct TwitterOAuth object
accessTokenURL ( ) Set API URLS
authenticateURL ( )
authorizeURL ( )
delete ( $url, $parameters = [] ) DELETE wrapper for oAuthReqeust.
get ( $url, $parameters = [] ) GET wrapper for oAuthRequest.
getAccessToken ( $oauth_verifier ) Exchange request token and secret for an access token and secret, to sign API calls.
getAuthorizeURL ( $token, $sign_in_with_twitter = TRUE ) Get the authorize URL
getHeader ( $ch, $header ) Get the header info to store.
getRequestToken ( $oauth_callback ) Get a request_token from Twitter
getXAuthToken ( $username, $password ) One time exchange of username and password for access token and secret.
http ( $url, $method, $postfields = NULL ) : API Make an HTTP request
lastAPICall ( )
lastStatusCode ( ) Debug helpers
oAuthRequest ( $url, $method, $parameters ) Format and sign an OAuth / API request
post ( $url, $parameters = [] ) POST wrapper for oAuthRequest.
requestTokenURL ( )

Описание методов

__construct() публичный Метод

construct TwitterOAuth object
public __construct ( $consumer_key, $consumer_secret, $oauth_token = NULL, $oauth_token_secret = NULL )

accessTokenURL() публичный Метод

Set API URLS
public accessTokenURL ( )

authenticateURL() публичный Метод

public authenticateURL ( )

authorizeURL() публичный Метод

public authorizeURL ( )

delete() публичный Метод

DELETE wrapper for oAuthReqeust.
public delete ( $url, $parameters = [] )

get() публичный Метод

GET wrapper for oAuthRequest.
public get ( $url, $parameters = [] )

getAccessToken() публичный Метод

Exchange request token and secret for an access token and secret, to sign API calls.
public getAccessToken ( $oauth_verifier )

getAuthorizeURL() публичный Метод

Get the authorize URL
public getAuthorizeURL ( $token, $sign_in_with_twitter = TRUE )

getHeader() публичный Метод

Get the header info to store.
public getHeader ( $ch, $header )

getRequestToken() публичный Метод

Get a request_token from Twitter
public getRequestToken ( $oauth_callback )

getXAuthToken() публичный Метод

One time exchange of username and password for access token and secret.
public getXAuthToken ( $username, $password )

http() публичный Метод

Make an HTTP request
public http ( $url, $method, $postfields = NULL ) : API
Результат API results

lastAPICall() публичный Метод

public lastAPICall ( )

lastStatusCode() публичный Метод

Debug helpers
public lastStatusCode ( )

oAuthRequest() публичный Метод

Format and sign an OAuth / API request
public oAuthRequest ( $url, $method, $parameters )

post() публичный Метод

POST wrapper for oAuthRequest.
public post ( $url, $parameters = [] )

requestTokenURL() публичный Метод

public requestTokenURL ( )

Описание свойств

$connecttimeout публичное свойство

* Set connect timeout.
public $connecttimeout

$decode_json публичное свойство

* Decode returned json data.
public $decode_json

$format публичное свойство

* Respons format.
public $format

$host публичное свойство

* Set up the API root URL.
public $host

$http_code публичное свойство

* Contains the last HTTP status code returned.
public $http_code

$http_info публичное свойство

* Contains the last HTTP headers returned.
public $http_info

$ssl_verifypeer публичное свойство

* Verify SSL Cert.
public $ssl_verifypeer

$timeout публичное свойство

* Set timeout default.
public $timeout

$url публичное свойство

* Contains the last API call.
public $url

$useragent публичное свойство

* Set the useragnet.
public $useragent