With the fast proliferation of hydrogen vehicles in the transportation industry, hydrogen refueling stations (HRSs) are expected to be crucial components of smart grids in the coming years. This work proposes a two-layer framework for optimal islanding operation of a multi-energy microgrid (MG) integrated with prosumer HRSs. Each HRS is capable of exchanging power with the MG and is equipped with different technologies including solar panels, battery, hydrogen storage, and electrolyzer. In the frst layer, the robust self-scheduling problem of each HRS is solved independently to obtain the optimal transacted electricity with the upstream MG considering the uncertainty of the electricity price. Robust optimization technique, which is used to handle the uncertainty of the price in the frst layer, enables the HRSs to exchange power with the MG in a risk-averse way. Also, in the second layer, the expected operational cost of the islanded multi-energy MG with the employment of a scenariobased technique to deal with the wind power uncertainty is minimized based on the obtained results of the frst layer. An isolated 33-bus system with the integration of diesel generators, wind turbines, mobile storage systems, and combined heat and power (CHP) units is conducted as the multi-energy MG of this paper to validate the applicability of the model. Additionally, the impact of the consideration of mobile storage systems in the MG on the operational cost is also investigated. The obtained results confrm the effectiveness of the proposed two-layer optimization framework to supply three kinds of demand including power, hydrogen, and heat under the worst scenario for the price of transacted electricity.