The OAuth class

(PECL OAuth >= 0.99.1)

Introduction

The OAuth extension provides a simple interface to interact with data providers using the OAuth HTTP specification to protect private resources.

Class synopsis

classOAuth {
public$debug;
public$sslChecks;
public$debugInfo;
public__construct(
    string$consumer_key,
    string$consumer_secret,
    string$signature_method = OAUTH_SIG_METHOD_HMACSHA1,
    int$auth_type = 0
)
public__destruct(): void
publicenableDebug(): bool
publicfetch(
    string$protected_resource_url,
    array$extra_parameters = ?,
    string$http_method = ?,
    array$http_headers = ?
): mixed
publicgenerateSignature(string$http_method, string$url, mixed$extra_parameters = ?): string|false
publicgetAccessToken(
    string$access_token_url,
    string$auth_session_handle = ?,
    string$verifier_token = ?,
    string$http_method = ?
): array
publicgetCAPath(): array
publicgetRequestHeader(string$http_method, string$url, mixed$extra_parameters = ?): string|false
publicgetRequestToken(string$request_token_url, string$callback_url = ?, string$http_method = ?): array
publicsetAuthType(int$auth_type): bool
publicsetCAPath(string$ca_path = ?, string$ca_info = ?): mixed
publicsetNonce(string$nonce): mixed
publicsetRequestEngine(int$reqengine): void
publicsetSSLChecks(int$sslcheck): bool
publicsetTimestamp(string$timestamp): mixed
publicsetToken(string$token, string$token_secret): bool
publicsetVersion(string$version): bool
}

Properties

debug

sslChecks

debugInfo

Table of Contents

To Top