getappmap / getappmap/appmap-js

OpenAPI: Optional route segments are split into multiple routes

Open
#1,007 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug openapi
Dominant language
TypeScript
Stars
53
Forks
18
Avg merge
3d 18h
Merged PRs (30d)
8

Description

Given the following Rails routing scheme: (/locale/:locale)/about

The following OpenAPI routes should be generated:

/locale/{locale}/about:
  ...
/about:
  ...

As of now we include the Rails-specific syntax in the route. This is not valid OpenAPI:

(/locale/{locale})/about:

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the TypeScript route-to-OpenAPI generation entry point and its tests. Reproduce the Rails route (/locale/:locale)/about and trace how optional segments are converted. Done means the output contains separate /locale/{locale}/about and /about paths without Rails-specific syntax.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi, typescript
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.