Skip to content
docsv0.1.0

LiveRespondedEvent

POST event: {@see \Milpa\Live\Http\LiveEndpoint::handle()} is about to return a response for a request that passed security and reached `live.request`. A request rejected earlier (bad method, missing fields, CSRF, invalid signature/replay, unknown component, unauthorized action) never reaches `live.request` and therefore never reaches this event either — those failures are visible to callers via the returned {@see LiveHttpResponse} itself, not via an event. Dispatched as `live.responded` — pure notification, readonly, no slot. **Short-circuit visibility invariant.** Mirrors {@see ComponentHandledEvent}: whether `live.request` was intercepted (short-circuited or vetoed) or the component's own `handle()` ran normally, this event MUST still fire, with {@see $intercepted} set accordingly.

LiveRespondedEvent::__construct()

public function __construct(Milpa\Live\ValueObjects\InteractionRequest $interaction, Milpa\Live\Http\LiveHttpResponse $response, bool $intercepted = false):

Parameters

Parameters of __construct()
NameTypeDescription
$interactionMilpa\Live\ValueObjects\InteractionRequest
$responseMilpa\Live\Http\LiveHttpResponse
$interceptedbool