Skip to content

feat: added OpenAPI 3.0 and 3.1 schema validation - #49

Merged
zaghaghi merged 1 commit into
mainfrom
25-enhance-error-messages-when-input-is-not-a-valid-openapi
Mar 28, 2026
Merged

zaghaghi merged 1 commit into
mainfrom
25-enhance-error-messages-when-input-is-not-a-valid-openapi

Conversation

@zaghaghi

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown

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 primarily adds OpenAPI 3.0 and 3.1 JSON Schema documents to the repository and introduces a new Rust dependency intended to support schema validation, alongside a few small Rust refactors/formatting changes.

Changes:

  • Added OpenAPI 3.0 and 3.1 JSON schema files under assets/.
  • Added the boon dependency (and updated Cargo.lock accordingly).
  • Minor Rust cleanups: standardize ratatui imports, reformat a syntect import block, and replace .last() with .next_back() in ParameterEditor.

Reviewed changes

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

Show a summary per file
File Description
src/panes/tags.rs Standardizes ratatui import style.
src/panes/response_viewer.rs Standardizes ratatui import style.
src/panes/response.rs Standardizes ratatui import style.
src/panes/request.rs Standardizes ratatui import style.
src/panes/history.rs Standardizes ratatui import style.
src/panes/body_editor.rs Standardizes ratatui import style.
src/panes/apis.rs Standardizes ratatui import style.
src/panes/address.rs Standardizes ratatui import style.
src/panes/parameter_editor.rs Uses .next_back() to remove the last matching header/query item index.
src/components/schema_viewer.rs Expands syntect import formatting for readability.
assets/openapi-3.1-schema.json Adds OpenAPI 3.1 JSON Schema document.
assets/openapi-3.0-schema.json Adds OpenAPI 3.0 JSON Schema document.
Cargo.toml Adds boon dependency.
Cargo.lock Locks new transitive dependencies (incl. boon).
CLAUDE.md Adds repository documentation / workflow notes.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Cargo.toml
Comment on lines 32 to 35
humansize = "2.1.3"
json5 = "0.4.1"
boon = { version = "0.6.1", default-features = false }
lazy_static = "1.4.0"

Copilot AI Mar 28, 2026

Copy link

Choose a reason for hiding this comment

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

The PR adds the boon dependency and two OpenAPI JSON schema assets, but there are no references to boon or these schema files anywhere in the Rust codebase. As-is this looks like unused baggage and also doesn’t align with the PR title (“schema validation”). Either wire these into the actual validation flow (and add a code path that loads/embeds the schemas), or drop the dependency/assets from this PR until the validation implementation lands.

Copilot uses AI. Check for mistakes.
@zaghaghi
zaghaghi merged commit d9b900b into main Mar 28, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enhance error messages when input is not a valid openapi

2 participants