Skip to content

refactor(users): remove dead analytics endpoints and consolidate into profile

Summary

  • Removed 3 dead endpoints with zero consumers (frontend, CLI, and tests show no usage):
    • GET /{id}/edit-activity
    • GET /{id}/edit-metrics
    • GET /{id}/activity-summary
  • Added average_edits_per_record to GET /{id}/profile?include=summary under summary.edits — the only field not already present in the profile endpoint
  • Removed UserEditActivity and UserEditMetrics schemas from record_history.py and __init__.py
  • Net result: -163 lines, no data loss, no breaking changes

Test plan

  • GET /{id}/profile?include=summarysummary.edits.average_edits_per_record present
  • GET /{id}/edit-activity404 Not Found
  • GET /{id}/edit-metrics404 Not Found
  • GET /{id}/activity-summary404 Not Found

Checklist

  • Code follows project API guidelines
  • Documentation is updated (OpenAPI docs reflect removed endpoints)
  • Code adheres to project coding standards

Closes #121

Merge request reports

Loading