use SellingPartnerApi\FeedTransformer\Transformer;
use SellingPartnerApi\FeedTransformer\FeedTypes\InventoryAvailability;
$feedPath = 'path/to/feed.xml';
$json = Transformer::fromFile(
InventoryAvailability::$feedType,
$feedPath,
'ATVPDKIKX0DER' // -> US Selling Partner API marketplace ID
);
$jsonFeedPath = 'path/to/new/feed.json';
file_put_contents($jsonFeedPath, json_encode($json));