getQueryParams()['type'] ?? 'liveness'; $data = [ 'ok' => true, 'framework' => 'Phred', 'type' => $type, 'timestamp' => time(), ]; // Readiness check could include DB connection check, etc. if ($type === 'readiness') { // Placeholder for actual checks $data['checks'] = [ 'database' => 'connected', 'storage' => 'writable', ]; } $etag = $this->generateEtag($data); if ($this->isFresh($request, $etag)) { return (new \Nyholm\Psr7\Factory\Psr17Factory())->createResponse(304); } return $this->factory->fromArray($data, 200, ['ETag' => $etag]); } }