Get list of Inventory Stock in MSI Magento 2.

Inventory Stock in the Multi-Source (MSI) module are used for mapping a sales channel to source locations in Magento 2.

You can see a list of available Stocks from the Stores -> Inventory -> Stocks link.

You can get a list of stocks available for the system using the StockRepositoryInterface of Inventory API module.

I have created a simple Model class to get all the stocks,

Call function to fetch a list of stocks,

Using Inventory Stocks you can retrieve the list of stocks available in the system.