project: align OpenAPI schemas with actual API responses and introduce DTO service contracts - #342 - #354
Open
ol-zayatsm wants to merge 3 commits into
Open
project: align OpenAPI schemas with actual API responses and introduce DTO service contracts - #342#354ol-zayatsm wants to merge 3 commits into
ol-zayatsm wants to merge 3 commits into
Conversation
ol-nata
self-requested a review
August 24, 2026 15:54
ol-nata
suggested changes
Aug 24, 2026
ol-nata
left a comment
Collaborator
There was a problem hiding this comment.
bublik/mcp/tools.py:172(outside this diff):list_projects()now returnslist[ProjectDTO], notlist[dict]— annotation/docstring are stale.bublik/mcp/tools.py:182(outside this diff):get_project()now returnsProjectDTO, notdict— annotation is stale.
| tags=[PROJECT_TAG], | ||
| ), | ||
| retrieve=extend_schema( | ||
| summary='Get project name', |
Collaborator
There was a problem hiding this comment.
nit: summary says "Get project name", but the response returns the whole project (ID + name), not just the name field.
ol-zayatsm
force-pushed
the
project_swagger_upd
branch
from
August 27, 2026 09:47
f54bfd3 to
348363d
Compare
Replace dict-based and model-based service responses with typed DTOs to introduce explicit and structured data contracts across service boundaries and move serialization to API boundary to improve separation of concerns between service layer and API layers. Fixed annotations for functions in mcp tools file to match new updates. Signed-off-by: Mikhail Zayats <mikhail.zayats@oktetlabs.ru>
Remove pagination from ProjectViewSet to align the generated list documentation with the actual API behavior. Signed-off-by: Mikhail Zayats <mikhail.zayats@oktetlabs.ru>
Ensure consistency between OpenAPI schemas and API responses by introducing explicit request/response serializers and binding them via drf-spectacular. Signed-off-by: Mikhail Zayats <mikhail.zayats@oktetlabs.ru>
ol-zayatsm
force-pushed
the
project_swagger_upd
branch
from
August 27, 2026 15:28
348363d to
6f3f005
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Summary
Update API v2 OpenAPI schema definitions for project endpoints and introduce
DTOs for project service responses to keep API documentation and service-layer
contracts aligned with the actual response payloads.
Changes
and badge endpoints.
model instances where applicable.