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

# Convert Medication To Product

> Convert a medication to a product.

This changes the item's polymorphic type from MEDICATION to PRODUCT by:
1. Verifying the item exists and is a medication
2. Removing the medication subclass row
3. Creating a product subclass row
4. Updating the type on the base item table



## OpenAPI

````yaml post /inventory/items/{item_id}/convert-to-product
openapi: 3.1.0
info:
  title: Decoda API
  description: External API documentation for the Decoda Health platform.
  version: '1.0'
servers: []
security: []
paths:
  /inventory/items/{item_id}/convert-to-product:
    post:
      tags:
        - Items
      summary: Convert Medication To Product
      description: |-
        Convert a medication to a product.

        This changes the item's polymorphic type from MEDICATION to PRODUCT by:
        1. Verifying the item exists and is a medication
        2. Removing the medication subclass row
        3. Creating a product subclass row
        4. Updating the type on the base item table
      operationId: >-
        convert_medication_to_product_inventory_items__item_id__convert_to_product_post
      parameters:
        - name: TENANT
          in: header
          required: true
          schema:
            type: string
            title: Tenant
          description: The tenant you are making this request on behalf of
        - name: API-KEY
          in: header
          required: true
          schema:
            type: string
            title: Api-Key
          description: Your api key
        - name: item_id
          in: path
          required: true
          schema:
            type: string
            title: Item Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: boolean
                title: >-
                  Response Convert Medication To Product Inventory Items  Item
                  Id  Convert To Product Post
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````