Recreate PR #75: Remove ID fields from DTOs and enhance JWT tokens #89
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.
This PR recreates the changes from the previously merged PR #75 (Temp main post) to ensure the functionality can be merged again if needed.
Changes Made
DTO Structure Improvements
Idproperty fromCommentDTO: Internal database IDs are no longer exposed in the public API response for commentsIdproperty fromPostDTO: Internal database IDs are no longer exposed in the public API response for postsJWT Token Enhancement
FirstNameandLastNameclaims: JWT tokens now include user's first and last names for better identification throughout the applicationProject Compatibility
Why These Changes Matter
Security & Privacy
Removing internal database IDs from public DTOs prevents potential information leakage and follows API best practices by not exposing internal implementation details.
User Experience
Adding first and last names to JWT tokens enables:
API Consistency
The changes ensure that:
Testing
This PR maintains backward compatibility while improving the API design and user experience.
This pull request was created as a result of the following prompt from Copilot chat.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.