class ClientRepository

Methods

Client|null
find(string|int $id)

Get a client by the given ID.

Client|null
findActive(string|int $id)

Get an active client by the given ID.

bool
allowsClient(Client $client)

Determine whether the current request may use the client.

personalAccessClient(string $provider)

Get the latest active personal access client for the given user provider.

create(string $name, array $grantTypes, array $redirectUris = [], string|null $provider = null, bool $confidential = true, Authenticatable|null $user = null)

Store a new client.

createPersonalAccessGrantClient(string $name, string|null $provider = null)

Store a new personal access token client.

createClientCredentialsGrantClient(string $name)

Store a new client credentials grant client.

createDeviceAuthorizationGrantClient(string $name, bool $confidential = true, Authenticatable|null $user = null)

Store a new device authorization grant client.

createAuthorizationCodeGrantClient(string $name, array $redirectUris, bool $confidential = true, Authenticatable|null $user = null, bool $enableDeviceFlow = false)

Store a new authorization code grant client.

bool
regenerateSecret(Client $client)

Regenerate the client secret.

Details

at line 18
Client|null find(string|int $id)

Get a client by the given ID.

Parameters

string|int $id

Return Value

Client|null

at line 38
Client|null findActive(string|int $id)

Get an active client by the given ID.

Parameters

string|int $id

Return Value

Client|null

at line 48
protected bool allowsClient(Client $client)

Determine whether the current request may use the client.

Parameters

Client $client

Return Value

bool

at line 61
Client personalAccessClient(string $provider)

Get the latest active personal access client for the given user provider.

Parameters

string $provider

Return Value

Client

Exceptions

RuntimeException

at line 88
protected Client create(string $name, array $grantTypes, array $redirectUris = [], string|null $provider = null, bool $confidential = true, Authenticatable|null $user = null)

Store a new client.

Parameters

string $name
array $grantTypes
array $redirectUris
string|null $provider
bool $confidential
Authenticatable|null $user

Return Value

Client

at line 116
Client createPersonalAccessGrantClient(string $name, string|null $provider = null)

Store a new personal access token client.

Parameters

string $name
string|null $provider

Return Value

Client

at line 126
Client createClientCredentialsGrantClient(string $name)

Store a new client credentials grant client.

Parameters

string $name

Return Value

Client

at line 138
Client createDeviceAuthorizationGrantClient(string $name, bool $confidential = true, Authenticatable|null $user = null)

Store a new device authorization grant client.

Parameters

string $name
bool $confidential
Authenticatable|null $user

Return Value

Client

at line 159
Client createAuthorizationCodeGrantClient(string $name, array $redirectUris, bool $confidential = true, Authenticatable|null $user = null, bool $enableDeviceFlow = false)

Store a new authorization code grant client.

Parameters

string $name
array $redirectUris
bool $confidential
Authenticatable|null $user
bool $enableDeviceFlow

Return Value

Client

at line 180
bool regenerateSecret(Client $client)

Regenerate the client secret.

Parameters

Client $client

Return Value

bool