class OAuthRouteRegistrar

Methods

static string
url(string $name)

Get an OAuth route URL using the configured application origin.

void
register(string $client, Closure|array $handler, array|string $middleware = 'web', string|null $connectUri = null, string|null $callbackUri = null, string|null $clientMetadataUri = null, array $clientMetadata = [])

Register connection, callback and public metadata routes for a named client.

webClient(string $name)

Resolve a named client that supports OAuth.

Details

at line 23
static string url(string $name)

Get an OAuth route URL using the configured application origin.

Parameters

string $name

Return Value

string

at line 39
void register(string $client, Closure|array $handler, array|string $middleware = 'web', string|null $connectUri = null, string|null $callbackUri = null, string|null $clientMetadataUri = null, array $clientMetadata = [])

Register connection, callback and public metadata routes for a named client.

Routes persist for the worker lifetime and affect subsequent requests.

Parameters

string $client
Closure|array $handler

receives provider or client, token, and optional returnTo by parameter name

array|string $middleware
string|null $connectUri
string|null $callbackUri
string|null $clientMetadataUri
array $clientMetadata

Return Value

void

at line 110
protected WebClient webClient(string $name)

Resolve a named client that supports OAuth.

Parameters

string $name

Return Value

WebClient