Skip to content

ClientType

Distinguishes a human end-user from a machine/service caller, per the RFC 9068 rule applied by ClientTypeResolverInterface: Service when the token’s sub equals its client_id/azp, otherwise User.

A Service client type is what flips a request to sessionless (no session started at all) for a stateless firewall.

enum ClientType: string

Since1.0.0
SourceSecurity/Auth/ClientType.php
CaseValueDescription
User'user'A human end-user, authenticated on their own behalf.
Service'service'A machine/service caller (e.g.
PropertyTypeDescription
$namestringreadonly.
$valuestringreadonly.
MethodDescription
cases(): array
[`from(stringint $value): static`](#from)
[`tryFrom(stringint $value): ?static`](#tryfrom)

public static function cases(): array

Returns array

public static function from(string|int $value): static

ParameterTypeDescription
$value`string““int`

Returns static

public static function tryFrom(string|int $value): ?static

ParameterTypeDescription
$value`string““int`

Returns ?``static