How to get static tile layer by index?

Hi,
can I somehow get list of all layer by index and easily change their properties on the fly?

I need to do something like:

Phaser.getLayer(0).opacity = 0.5;

Looks like you can get a layer by index with the getLayer method of a Tilemap - https://photonstorm.github.io/phaser3-docs/Phaser.Tilemaps.Tilemap.html#getLayer__anchor

Then once you have the layer, you can set its alpha property (rather than its opacity) - https://photonstorm.github.io/phaser3-docs/Phaser.Tilemaps.DynamicTilemapLayer.html#alpha__anchor.