Swagger Petstore - OpenAPI 3.0
SSwagger Petstore - OpenAPI 3.0
API ReferenceChangelog
GETList plants/plantsPOSTCreate a plant/plantsDELETEDelete a plant/plants/{id}
llms.txtPowered by Octri
DELETE/plants/{id}

Delete a plant

Deletes a single plant identified by its ID. Supply the plant's id to remove it; a 204 response confirms the deletion.

1 parameter
idintegerrequired

The identification number of the plant to delete.

2 status codes
204Returns no content after deleting the plant.
400Returned when an unexpected error occurs.
errorintegerrequired
messagestringrequired

Error handling

The id path parameter must be an integer identifying the plant to delete. A 400 is returned for an unexpected error.

import { OpenAPIPlantStore } from "swagger-petstore---openapi-3-0-sdk";

const client = new OpenAPIPlantStore({
  baseUrl: "/api/v3",
  auth: { bearerAuth: process.env.OPEN_API_TOKEN! },
});

await client.plants.delete({ id: 4355 });
Response
{
  "error": 1,
  "message": "This is an example message."
}
PreviousCreate a plant