Timer

If a player does not make a decision in 30 seconds, how could I generate an action?

for example in a board game, if it does not move the piece, the server automatically moves the piece.

Check out http://colyseus.io/docs/api-timing-events/
You could set up a callback when it becomes the player's turn. They return a "Delayed" object which you can "cancel" if the player did perform his action in time.

@plyoung thanks