You can count the no. of Shipment generated for the specific order by order id in Magento 2.
Using Magento\Sales\Api\ShipmentRepositoryInterface interface you need to use getList() method with SearchCriteriaBuilder Object to add filter by order id.
Using Below code snippet, You can fetch the count of shipment for an order, Continue reading “Count total shipment for an order by order id Magento 2.”