How to port the poker player to a new language

The players are simple REST services. Please check out the Player API documentation to understand the interface that needs to be implemented.

You should have the following files:

  • A file, usually called player_service, that will take care of routing the requests to an object called player. The current game state is sent as a POST variable named game_state in JSON format. The game_state needs to be decoded into a dynamic structure. The action POST variable specifies which function of the player is to be called.
  • The other file is usually called player, and contains a Player class (or equivalent structure in languages where there are no classes) with a single bet_request function, that returns 0.

The service should run out of the box when it is pushed to Heroku. If Heroku does not support your choice of language, and it is not possible to create a custom build pack, then it is possible to use a custom deployer service. It should implement the same interface as the Hermes service