Feature/request validation middleware#113
Merged
ayomideadeniran merged 4 commits intoStellarDevHub:mainfrom Mar 26, 2026
Merged
Feature/request validation middleware#113ayomideadeniran merged 4 commits intoStellarDevHub:mainfrom
ayomideadeniran merged 4 commits intoStellarDevHub:mainfrom
Conversation
I added 'Helping vs Hand-holding' and 'Constructive Feedback' sections to support our learning environment while maintaining professional standards. This addresses issue StellarDevHub#29 by providing clear guidance for educational interactions.
I added the missing 'jobs:' section to the ci.yml file to ensure proper GitHub Actions workflow execution. This fix prevents workflow failures and ensures CI runs properly on pull requests.
I added zod dependency and created reusable validation middleware with comprehensive error handling. This addresses issue StellarDevHub#31 by providing standardized API request validation with descriptive 400 error messages.
I created unit tests to verify request validation works correctly with proper error handling. Tests cover valid requests, invalid requests with detailed error messages, and unexpected errors.
|
@soomtochukwu Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
Contributor
|
Pr under review. |
Contributor
|
Well implemented, i will merge this now. |
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
This pull request implements a comprehensive request validation middleware system for the Web3 Student Lab backend API. The implementation uses zod for type-safe validation and provides reusable middleware functions that can be applied across all API endpoints. This replaces manual validation logic with a standardized approach that returns consistent 400 error responses with detailed field-level validation messages, improving API reliability and developer experience.
Reference Issues
Closes #31
Type of Change
Checklist:
Additional Testing Notes: