MCPcopy Create free account
hub / github.com/Roy3838/Observer / get_creator_log

Function get_creator_log

api/compute.py:43–58  ·  view source on GitHub ↗

(Admin) Agent Creator conversations for one UTC day. User ids are hashed at write time. Entries expire after CREATOR_LOG_TTL_HOURS (32h by default), so only today and yesterday are retrievable. Monitoring calls are never logged.

(
    date: str | None = Query(
        None,
        description="UTC day to read, YYYY-MM-DD. Defaults to today. The nightly "
                    "digest routine runs at ~00:15 UTC and should ask for yesterday.",
        pattern=r"^\d{4}-\d{2}-\d{2}$",
    ),
    limit: int | None = Query(None, gt=0, description="Cap the number of entries returned, newest first."),
    is_admin: bool = Depends(get_admin_access),
)

Source from the content-addressed store, hash-verified

41
42@compute_router.get("/admin/creator-log", tags=["Admin"], summary="Get Agent Creator conversations for a day")
43async def get_creator_log(
44 date: str | None = Query(
45 None,
46 description="UTC day to read, YYYY-MM-DD. Defaults to today. The nightly "
47 "digest routine runs at ~00:15 UTC and should ask for yesterday.",
48 pattern=r"^\d{4}-\d{2}-\d{2}$",
49 ),
50 limit: int | None = Query(None, gt=0, description="Cap the number of entries returned, newest first."),
51 is_admin: bool = Depends(get_admin_access),
52):
53 """
54 (Admin) Agent Creator conversations for one UTC day. User ids are hashed at
55 write time. Entries expire after CREATOR_LOG_TTL_HOURS (32h by default), so
56 only today and yesterday are retrievable. Monitoring calls are never logged.
57 """
58 return await creator_log.get_log(day=date, limit=limit)
59
60@compute_router.get("/quota", summary="Check remaining API credits for the authenticated user")
61async def check_quota_endpoint(current_user: AuthUser):

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected