Incorrect swagger output for timeseries values
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 28
- Forks
- 25
- Avg merge
- 4d 22h
- Merged PRs (30d)
- 20
Description
Originally from https://github.com/HydrologicEngineeringCenter/cwms-data-api-client-javascript/issues/3 and reported by @jbkolze
The "values" key in the TimeSeries return object is defined in the OpenAPI as an array of arrays of objects. The actual returned object is just an array of arrays of numbers (with no actual definition/structure). This is causing typing issues when using the cwmsjs library with TypeScript.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with cwms-swagger.json at lines 9308-9334 and inspect the TimeSeries return object's values schema. Compare that definition with the reported response shape in the issue: an array of arrays of numbers. Update the OpenAPI definition so generated TypeScript typings match the actual response, then verify the resulting schema or client types.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- openapi, typescript
- Domain
- api
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 70/100