API Events HttpResponseReceivedEvent - evansims/openfga-php GitHub Wiki

Event fired when an HTTP response is received from the OpenFGA API. This event contains both the request and response for complete telemetry tracking.

Table of Contents


Namespace

OpenFGA\Events


Source

View source code


Implements


Methods

getEventId

public function getEventId(): string

Get the unique identifier for this event.

View source


Returns

string — A unique identifier for the event instance


getEventType

public function getEventType(): string

Get the name/type of this event.

View source


Returns

string — The event type identifier


getException

public function getException(): ?Throwable

View source


Returns

Throwable | null


getModelId

public function getModelId(): ?string

View source


Returns

string | null


getOccurredAt

public function getOccurredAt(): DateTimeImmutable

Get when this event occurred.

View source


Returns

DateTimeImmutable — The timestamp when the event was created


getOperation

public function getOperation(): string

View source


Returns

string


getPayload

public function getPayload(): array

Get the event payload data.

View source


Returns

array — The event data


getRequest

public function getRequest(): Psr\Http\Message\RequestInterface

View source


Returns

Psr\Http\Message\RequestInterface


getResponse

public function getResponse(): ?Psr\Http\Message\ResponseInterface

View source


Returns

Psr\Http\Message\ResponseInterface | null


getStoreId

public function getStoreId(): ?string

View source


Returns

string | null


isPropagationStopped

public function isPropagationStopped(): bool

Check if event propagation should be stopped.

View source


Returns

bool — True if propagation should be stopped


isSuccessful

public function isSuccessful(): bool

View source


Returns

bool


stopPropagation

public function stopPropagation(): void

Stop event propagation to remaining listeners.

View source


Returns

void

⚠️ **GitHub.com Fallback** ⚠️