Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Valid OpenAPI spec not parsed correctly when creating an API Connector #9860

Open
dannybaggett opened this issue Jan 14, 2022 · 2 comments
Open

Comments

@dannybaggett
Copy link

dannybaggett commented Jan 14, 2022

This is a...


[ ] Feature request
[ ] Regression (a behavior that used to work and stopped working in a new release)
[ x] Bug report  
[ ] Documentation issue or request

The problem

I have syndesis (1.13.2) running on locally via CRC. When I attempt to create an API Connector given a valid OpenAPI spec, it appears the UI is unable to parse the contents correctly. I get no operations listed and when I attempt to continue (click next button), I get a blank screen.

Expected behavior

Correctly list operations.

Screenshot

Main issue:
Screen Shot 2022-01-14 at 1 52 04 PM

Secondary problem (not sure if related to the first)
Screen Shot 2022-01-14 at 1 52 19 PM

Request and Response Data

API Endpoints and Schemas

Tasks involved / Steps to Reproduce

  1. Click Customizations -> API Client Connectors on left nav
  2. Click Create API Connector
  3. Upload a valid OpenAPI spec file
  4. Click Next
@dannybaggett
Copy link
Author

Here's a copy of the specification:

openapi: 3.0.2
info:
    title: New API
    version: 1.0.0
    description: Product System API
paths:
    /products:
        summary: Products
        description: Product Collection
        get:
            responses:
                '200':
                    $ref: '#/components/responses/ProductCollection'
            operationId: all-products
            summary: Product Collection
            description: Retrieve Product Collection
components:
    schemas:
        Product:
            title: Root Type for Product
            description: Product Resource
            required:
                - description
                - id
            type: object
            properties:
                id:
                    description: Product id
                    type: string
                name:
                    description: Product name
                    type: string
                description:
                    description: Product description
                    type: string
                isPublic:
                    format: int32
                    description: Flag to determine whether this is public
                    type: integer
            example:
                id: ajjkas-232n-asdnkkl-2223
                name: Product 1
                description: Product No. 1
                isPublic: 1
    responses:
        ProductCollection:
            content:
                application/json:
                    schema:
                        type: array
                        items:
                            $ref: '#/components/schemas/Product'
                    examples:
                        Product Collection:
                            value:
                                -
                                    id: 1231-2sdf-2esdvwe-fdger345
                                    name: Some Product
                                    description: This is some product
                                    isPublic: 1
                                -
                                    id: scwd2-2sdf-3e2wcd-23rcdw
                                    name: Another Product
                                    description: This is another product
            description: Product Collection Resource

@zregvart
Copy link
Member

Thanks for reporting this and providing the steps to reproduce with the OpenAPI document. I'm unable to reproduce this with 1.13.2 (3a4b315), for me the custom API client connector is created without an issue. Can you check the syndesis-server-* pod logs and the Network tab in the developer tools of your browser to see if there are any errors reported there?

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

2 participants