ResourceServer
Less than 1 minute
ResourceServer
class ResourceServerProperties
config
private Options $configType: Hazaar\OAuth\ResourceServer\Options
jwt
private JWT $jwtType: Hazaar\Auth\Session\Backend\JWT
Methods
__construct
public __construct(array|Options|null $config): voidParameters
| Parameter | Type | Description |
|---|---|---|
$config | array | Hazaar\OAuth\ResourceServer\Options |
metadata
RFC 9728 protected resource metadata document.
public metadata(): arrayReturns: array
metadataURL
The URL this resource's RFC 9728 metadata document is expected to be served from.
public metadataURL(): stringReturns: string
Used to populate the resource_metadata parameter of the WWW-Authenticate challenge (RFC 9728 §5.1). Configure oauth.resource.metadata_url explicitly if the metadata document isn't served from the well-known path derived from resource.
verify
Verifies a bearer access token and returns its claims.
public verify(string $token, array $requiredScope): AccessTokenClaimsReturns: Hazaar\OAuth\AccessTokenClaims
Parameters
| Parameter | Type | Description |
|---|---|---|
$token | string | |
$requiredScope | array | scopes the caller must have to proceed; empty to skip the check |
Generated by Hazaar API Doc Generator on Sun, 23 Aug 2026 10:49:43 +0000