Skip to content

Upsert on re-syncing w/ cli  #920

Open
Open
@TheHumanJenkins

Description

@TheHumanJenkins

There is some unintentional behavior with the CLI allowing the creation/update on an oas re-sync. I would think if you pass an incorrect OAS ID on an update or re-sync it would result in an error.

I am able to pass a categoryID to this cli and it will create a new OAS definition; hence duplicating the spec within a project.

Unless the method is designed to be an upsert; but the documentation isn’t clear that if you pass an id that doesn’t exists it will create the oas using that id. Probably this is an unintentional design or docs are incorrect.

Docs:
This will edit (re-sync) an existing API definition (identified by --id) within your ReadMe project. This is the recommended approach for usage in CI environments.

rdme openapi [url-or-local-path-to-file] --id={existing-id}

Metadata

Metadata

Assignees

No one assigned

    Labels

    APIUnderlying issue is with the ReadMe API and not necessarily the `rdme` client itselfcommand:openapiIssues pertaining to the `openapi`, `validate`, `reduce`, or `swagger` commands

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions