AXIAM PHP SDK

AccessDecision
in package

FinalYes

The full outcome of an access check, including the CONTRACT.md ยง11 rule 9 `reason_code`.

AuthzRestClient::checkAccess() and AuthzRestClient::batchCheck() return bare bools that predate this field and cannot carry it; use AuthzRestClient::checkAccessDecision() / AuthzRestClient::batchCheckDecisions() when the distinction matters.

Table of Contents

Properties

$allowed  : bool
$reason  : string|null
$reasonCode  : string|null

Methods

__construct()  : mixed

Properties

Methods

__construct()

public __construct(bool $allowed, string|null $reason, string|null $reasonCode) : mixed
Parameters
$allowed : bool

Whether the checked action is permitted. This property alone carries the outcome โ€” $reasonCode explains it and never contradicts it.

$reason : string|null

The server's human-readable explanation, when it sent one.

$reasonCode : string|null

ReasonCode::ALLOWED, ReasonCode::NO_GRANT or ReasonCode::DENIED_BY_RULE.

The two refusals mean opposite things to the person on the other end.* no_grant says ask an admin for access; denied_by_rule says an admin has already decided. An application that cannot tell them apart sends users to raise tickets that will be refused โ€” which is why the contract forbids collapsing them into a bare false.

null when the server omits the field, so a newer SDK against an older server degrades rather than failing. An unrecognised value is surfaced verbatim and never changes $allowed โ€” which is why this is a string rather than an enum.

On this page

Search results