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

# Update a purchase order item

> Partially updates a purchase order item. Only fields included in the request body will be updated; omitted fields are left unchanged. Only items on custom draft purchase orders can be updated.

A **purchase order item** is a single line item on a purchase order, identifying the inventory being ordered, the quantity, and the price. The quantity specified in the payload is expected to be in the same unit of measure as the configured unit of measure for the inventory code.



## OpenAPI

````yaml patch /ext/v2/purchase-order-items/{purchase_order_item_id}/
openapi: 3.1.0
info:
  description: ''
  title: NinjaAPI
  version: 2.0.0
servers:
  - url: https://connect.vetcove.com/
security: []
paths:
  /ext/v2/purchase-order-items/{purchase_order_item_id}/:
    patch:
      tags:
        - Inventory
      summary: Update a purchase order item
      description: >-
        Partially updates a purchase order item. Only fields included in the
        request body will be updated; omitted fields are left unchanged. Only
        items on custom draft purchase orders can be updated.


        A **purchase order item** is a single line item on a purchase order,
        identifying the inventory being ordered, the quantity, and the price.
        The quantity specified in the payload is expected to be in the same unit
        of measure as the configured unit of measure for the inventory code.
      operationId: purchase_order_item_patch
      parameters:
        - description: The ID of the purchase order item
          in: path
          name: purchase_order_item_id
          required: true
          schema:
            description: The ID of the purchase order item
            title: Purchase Order Item Id
            type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PurchaseOrderItemPatchSchema'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExternalPurchaseOrderItemSchema'
          description: OK
      security:
        - ExternalAPIAuth: []
components:
  schemas:
    PurchaseOrderItemPatchSchema:
      properties:
        quantity:
          anyOf:
            - exclusiveMinimum: 0
              type: number
            - type: string
            - type: 'null'
          description: Updated quantity (must be greater than 0)
          title: Quantity
        sku:
          anyOf:
            - type: string
            - type: 'null'
          description: Updated SKU identifier
          title: Sku
        total_price:
          anyOf:
            - minimum: 0
              type: integer
            - type: 'null'
          description: Updated total price for this line item, in cents
          title: Total Price
      title: PurchaseOrderItemPatchSchema
      type: object
    ExternalPurchaseOrderItemSchema:
      properties:
        created:
          description: The datetime this object was created.
          format: date-time
          title: Created
          type: string
        id:
          description: The unique identifier for the purchase order item
          title: Id
          type: integer
        inventory_id:
          anyOf:
            - type: integer
            - type: 'null'
          description: The inventory id for this item
          title: Inventory Id
        inventory_shortcode:
          default: ''
          description: The inventory shortcode (human-readable code) for this item
          title: Inventory Shortcode
          type: string
        modified:
          description: >-
            The datetime this object was last modified; changes to related
            entities will not update this field.
          format: date-time
          title: Modified
          type: string
        quantity:
          anyOf:
            - type: number
            - type: string
          description: The quantity ordered
          title: Quantity
        sku:
          description: The SKU identifier for this item
          title: Sku
          type: string
        total_price:
          description: The total price for this line item, in cents
          title: Total Price
          type: integer
        unit_of_measure:
          description: The unit of measure for this item
          title: Unit Of Measure
          type: string
      required:
        - created
        - modified
        - id
        - inventory_id
        - sku
        - quantity
        - total_price
        - unit_of_measure
      title: ExternalPurchaseOrderItemSchema
      type: object
  securitySchemes:
    ExternalAPIAuth:
      scheme: bearer
      type: http

````