Skip to content

Align DORA API routes with v1 prefix#260

Merged
2-Coatl merged 1 commit intodevelopfrom
feature/validate-callcentersite-api-against-documentation-13-33-39
Nov 18, 2025
Merged

Align DORA API routes with v1 prefix#260
2-Coatl merged 1 commit intodevelopfrom
feature/validate-callcentersite-api-against-documentation-13-33-39

Conversation

@2-Coatl
Copy link
Copy Markdown
Collaborator

@2-Coatl 2-Coatl commented Nov 18, 2025

Summary

  • update DORA routes and documentation strings to use the versioned /api/v1/dora/ prefix
  • refresh dashboard assets and data catalog descriptors to reference the new endpoints
  • add routing regression test to ensure only the versioned DORA API path is exposed

Testing

  • pytest tests/integration/test_dora_versioning.py -q

Codex Task

Copilot AI review requested due to automatic review settings November 18, 2025 13:33
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@2-Coatl 2-Coatl merged commit 507db0f into develop Nov 18, 2025
9 of 35 checks passed
@2-Coatl 2-Coatl deleted the feature/validate-callcentersite-api-against-documentation-13-33-39 branch November 18, 2025 13:42
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR aligns DORA API routes with the versioned /api/v1/dora/ prefix to establish a consistent API versioning strategy across the platform. The change ensures all DORA endpoints follow the same versioning pattern as other API modules (users, configuration, dashboard, etc.).

Key Changes:

  • Updated URL routing from /api/dora/ to /api/v1/dora/ in the main urlpatterns
  • Refreshed all docstrings in views to document the new versioned endpoints
  • Updated frontend fetch calls in the dashboard template to use versioned paths
  • Modified data catalog and ecosystem metadata to reference the new endpoint structure
  • Added routing regression tests to enforce versioned-only access

Reviewed Changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
api/callcentersite/callcentersite/urls.py Updated DORA route from /api/dora/ to /api/v1/dora/ prefix; accidentally removed users.urls line
api/callcentersite/tests/integration/test_dora_versioning.py New routing tests validate versioned endpoint availability and unversioned endpoint rejection; test coverage could be expanded
api/callcentersite/dora_metrics/views.py Updated all docstrings (26 functions) from /api/dora/ to /api/v1/dora/ for consistency
api/callcentersite/dora_metrics/templates/dora_metrics/dashboard.html Updated all fetch calls to chart endpoints to use /api/v1/dora/charts/ prefix
api/callcentersite/dora_metrics/data_catalog.py Updated API endpoint references and example query URLs in dataset descriptors to use versioned paths
api/callcentersite/dora_metrics/data_ecosystem.py Updated endpoint references in data lineage map to reflect versioned API structure
Comments suppressed due to low confidence (7)

api/callcentersite/dora_metrics/data_catalog.py:9

  • Import of 'datetime' is not used.
from datetime import datetime, timedelta

api/callcentersite/dora_metrics/data_catalog.py:10

  • Import of 'List' is not used.
from typing import Dict, List, Any, Optional

api/callcentersite/dora_metrics/data_catalog.py:12

  • Import of 'Count' is not used.
from django.db.models import Avg, Count, Max, Min, Q

api/callcentersite/dora_metrics/data_ecosystem.py:14

  • Import of 'datetime' is not used.
from datetime import datetime, timedelta

api/callcentersite/dora_metrics/data_ecosystem.py:15

  • Import of 'Optional' is not used.
from typing import Dict, List, Any, Optional

api/callcentersite/dora_metrics/data_ecosystem.py:17

  • Import of 'Max' is not used.
    Import of 'Min' is not used.
    Import of 'Count' is not used.
    Import of 'Avg' is not used.
from django.db.models import Count, Avg, Max, Min, Q

api/callcentersite/dora_metrics/views.py:6

  • Import of 'datetime' is not used.
from datetime import datetime, timedelta

path("api/v1/llamadas/", include("callcentersite.apps.llamadas.urls")),
path("api/v1/", include("callcentersite.apps.users.urls")),
path("api/dora/", include("dora_metrics.urls")),
path("api/v1/dora/", include("dora_metrics.urls")),
Copy link

Copilot AI Nov 18, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The removal of the users.urls line appears to be unintentional. This line includes user-related API routes at /api/v1/ and should not be removed as part of the DORA API versioning changes.

The current file still has this line at line 23:

path("api/v1/", include("callcentersite.apps.users.urls")),

This should be kept in the urlpatterns to maintain user authentication and management endpoints.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants