forked from scalar/scalar
-
Notifications
You must be signed in to change notification settings - Fork 156
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Description
Path parameters defined in the OpenAPI specification are not being displayed in the operation details, making it unclear what parameters are required in the URL path.
Current Behavior
- Operations with path parameters are rendered
- Path parameters are not shown in the parameters section
- Users cannot see which path variables need to be provided
- Only query, header, and body parameters are visible
Expected Behavior
- Path parameters should appear in the parameters list
- Each path parameter should show:
- Parameter name
- Type
- Description
- Required status
- Example value
- Path parameters should be clearly distinguished from other parameter types
Steps to Reproduce
- Load an OpenAPI specification with path parameters
- Example:
GET /users/{userId}/posts/{postId} - Navigate to this operation in the API reference
- Check the parameters section
- Observe that
userIdandpostIdare not listed
Proposed Solution
Update the operation parameter rendering logic to include path parameters from the OpenAPI specification. This requires:
- Extracting path parameters from the operation object
- Adding them to the parameters list in the UI
- Ensuring proper formatting and labeling as "path" parameters
Technical Context
- Component:
api-reference - Involves OpenAPI specification parsing
- Vue component updates for parameter display
- May require updating parameter extraction logic
Download https://cap.so/ to record your screen (use Studio mode). Export as an mp4, and drag and drop into an issue comment below.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working