Improve documentation with search, API URLs, OpenAPI spec, and contract validation - #144
Merged
valoryyaa-byte merged 5 commits intoJul 28, 2026
Merged
Conversation
|
@chukwudiikeh 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! 🚀 |
…E_URL Replace http://localhost:8080 throughout API documentation with environment-configurable NEXT_PUBLIC_API_BASE_URL, defaulting to localhost for development. Add API_BASE_URL export to site config and update all API endpoint examples to use $API_BASE_URL placeholder with clear notes about configuration. Closes RWA-ToolKit#53 Co-Authored-By: chukwudiikeh <chukwudi.ikeh.232330@unn.edu.ng>
Add FlexSearch-powered documentation search with: - Keyword and title-based indexing of all doc pages - Real-time filtering with results displayed in dropdown - Keyboard shortcut (⌘K) to focus search input - Results grouped by section with excerpts - Integrated into sidebar for easy access Closes RWA-ToolKit#54 Co-Authored-By: chukwudiikeh <chukwudi.ikeh.232330@unn.edu.ng>
Add comprehensive OpenAPI 3.0 schema for the REST API at /openapi.json with: - All endpoints (stats, assets, holders, compliance, dividends) - Complete request/response schemas with descriptions - Proper HTTP status codes and error responses - Data types matching i128 handling (strings for large integers) - Server configurations for development and production URLs Closes RWA-ToolKit#55 Co-Authored-By: chukwudiikeh <chukwudi.ikeh.232330@unn.edu.ng>
Add comprehensive contract validation system to ensure documentation stays in sync: - Contract specifications in lib/contracts.ts with method signatures, auth, errors - Jest test suite validating all documented methods match contract specs - Validation checks for method parameter counts, contract addresses, auth requirements - Jest configuration with test discovery and coverage setup - Documentation of validation process in CONTRACT_VALIDATION.md - Note in Asset Token contract page referencing the validation system This enables CI/CD to catch documentation drift before deployment. Closes RWA-ToolKit#56 Co-Authored-By: chukwudiikeh <chukwudi.ikeh.232330@unn.edu.ng>
chukwudiikeh
force-pushed
the
feat/docs-improvements
branch
from
July 26, 2026 05:32
9584a8b to
14148ba
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.
Summary
This PR addresses all four documentation issues identified in the backlog:
http://localhost:8080instead of the real/base URL #53): Replace hardcoded localhost with environment-configurableNEXT_PUBLIC_API_BASE_URL/openapi.jsonfor SDK generation and validationChanges
Commit 1: Fix hardcoded localhost URLs (#53)
API_BASE_URLexport to site config$API_BASE_URLplaceholderCommit 2: Add client-side search (#54)
Commit 3: Add OpenAPI 3.0 specification (#55)
/openapi.jsonfor Swagger UI and SDK generationCommit 4: Add contract validation tests (#56)
lib/contracts.tswith method signatures, auth, errorsnpm testsupportCONTRACT_VALIDATION.mdTesting
All tests are configured and ready to run with
npm test. The contract validation ensures:Closes #54 , Closes #53 , Closes #55 , Closes #56