Buckets:
AnonymousSpottedToad/candidate_bucket / codebase /python /SHAdd0WTAka_Zen-Ai-Pentest /api /routes /v1 /metrics.py
| #!/usr/bin/env python3 | |
| """ | |
| Metrics API Endpoints | |
| Provides Prometheus-compatible metrics endpoint for monitoring. | |
| """ | |
| from fastapi import APIRouter, Response | |
| from fastapi.responses import PlainTextResponse | |
| from core.metrics import get_metrics_content_type, get_metrics_response | |
| router = APIRouter() | |
| async def metrics(): | |
| """ | |
| Get Prometheus-compatible metrics | |
| Returns metrics in Prometheus exposition format for monitoring | |
| with tools like Prometheus, Grafana, etc. | |
| """ | |
| metrics_data = get_metrics_response() | |
| return Response(content=metrics_data, media_type=get_metrics_content_type()) | |
Xet Storage Details
- Size:
- 674 Bytes
- Xet hash:
- 30d2bdbf6ed174bb042d0eec490f9953f37138b467b9cb31d636faec04e85c12
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.