feat(backend): added profiling

This commit is contained in:
ITQ
2025-07-24 16:57:47 +03:00
parent 0eec2f2187
commit 925f820bfd
7 changed files with 59 additions and 0 deletions
+2
View File
@@ -4,6 +4,7 @@ from uuid import UUID
from django.http import Http404, HttpRequest
from django.shortcuts import get_object_or_404
from ninja import Router
from silk.profiling.profiler import silk_profile
from api.v1 import schemas as global_schemas
from api.v1.ads import schemas
@@ -21,6 +22,7 @@ router = Router(tags=["ads"])
status.NOT_FOUND: global_schemas.NotFoundError,
},
)
@silk_profile("Get Advertisment")
def get_advertisment(
request: HttpRequest, client_id: UUID
) -> tuple[status, Campaign]: