Version 0.0.1 Created by Evan Coury
This is a simple ZF2 module that exposes a REST server. The REST server enables playing virtual games of Cards Against Humanity.
This project is meant for a conference demonstration and should probably not be used in production.
Real (Swagger) documentation coming soon.
Method | Endpoint | Description |
---|---|---|
GET | /decks | An array of cards (id, count, description) |
GET | /players | List all players in active games |
GET | /players/{id} | Get a specific player |
POST | /players | Create a new player (display_name, email) |
GET | /games | List all active games |
POST | /games | Create a new game (name, decks[], player_id) |
GET | /games/{id} | Get a specific game (and players) |
GET | /games/{id}/rounds/latest | Get the latest round in game |
GET | /games/{id}/rounds/{id} | Get the info for a given round |
PUT | /games/{id}/rounds/{id} | Post answer for a given round |
GET | /games/{id}/players | Get all players in a game |
POST | /games/{id}/players | Add/join a player into a game (display_name, email OR player_id) |
GET | /games/{id}/players/{id} | Get a player with their cards for a particular game |