> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ftn.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Plants

更新


## OpenAPI

````yaml api-reference/openapi.json put /plants/{id}
openapi: 3.1.0
info:
  title: OpenAPI Plant Store
  description: >-
    A sample API that uses a plant store as an example to demonstrate features
    in the OpenAPI specification
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: http://sandbox.mintlify.com
security:
  - bearerAuth: []
paths:
  /plants/{id}:
    put:
      description: Update a single plant based on the ID supplied
      parameters:
        - name: id
          in: path
          description: ID of plant to delete
          required: true
          schema:
            type: integer
            format: int64
      requestBody:
        description: Plant to add to the store
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/NewPlant'
        required: true
      responses:
        '204':
          description: Plant updated
          content: {}
        '400':
          description: unexpected error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    NewPlant:
      allOf:
        - $ref: '#/components/schemas/Plant'
        - required:
            - id
          type: object
          properties:
            id:
              description: Identification number of the plant
              type: integer
              format: int64
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
        message:
          type: string
    Plant:
      required:
        - name
      type: object
      properties:
        name:
          description: The name of the plant
          type: string
        tag:
          description: Tag to specify the type
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````