Skip to content

Feature Request: Add delete command to CLI to remove APIs from Microcks #294

@DivyanshuVortex

Description

@DivyanshuVortex

Description :

Currently, the Microcks CLI allows users to import and test APIs, but there is no native way to delete an API directly from the command line. This makes it difficult to maintain clean environments, especially in CI/CD pipelines where we often want to clean up older, unused iterations of an API or tear down temporary mock services.

Describe the solution you'd like

I would like to see a new microcks delete command added to the CLI.

The command should:

  • Take the API name and version as a single argument (e.g., <serviceName:version>).
  • Look up the internal service ID using the Microcks REST API.
  • Safely delete the target service.
  • Return a clear success or failure message.

Proposed Usage:
microcks delete "MyService:1.0"

Describe alternatives you've considered

The only current alternative is to manually write curl scripts to first query the /api/services/search endpoint to find the system id and then issue a DELETE request, or to manage deletions manually through the Web UI. Having this integrated into the CLI is much cleaner.

Metadata

Metadata

Assignees

No one assigned

    Labels

    component/cligoPull requests that update go codekind/featureNew feature implementation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions