Skip to content
This repository has been archived by the owner on Nov 11, 2023. It is now read-only.

Support of parameters refs in operation level and path-level in DELETE requests #324

Open
andriyor opened this issue Dec 14, 2020 · 1 comment

Comments

@andriyor
Copy link

Describe the bug

➜ restful-react import --file example.yaml --output generated.tsx
Error: The path params id can't be found in parameters (GetUserById)

example file

openapi: 3.0.1
info:
  title: user API
  version: 1.0.0
paths:
  /user/{id}:
    parameters:
      - $ref: '#/components/parameters/id'
    delete:
      operationId: GetUserById
      parameters:
        - $ref: '#/components/parameters/bearer'
      responses:
        '200':
          description: OK
components:
  parameters:
    bearer:
      name: bearer
      in: header
      description: JWT Bearer token
      required: false
      schema:
        type: object
    id:
      name: id
      in: path
      description: User ID.
      required: true
      schema:
          type: string

To Reproduce
Steps to reproduce the behavior:

Run restful-react import --file example.yaml --output generated.tsx

Expected behavior
No errors.

Desktop (please complete the following information):

  • OS: Ubuntu
  • Library: v15
@andriyor
Copy link
Author

similar issue #259

@andriyor andriyor changed the title Support of parameters refs in operation level and path-level Support of parameters refs in operation level and path-level in DELETE requests Dec 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant