Skip to main content
POST
Attack

Body

application/json

Details for a ship to perform an attack, including the game ID, the direction of attack, the attacking ship, and the target ship.

Data transfer object for a ship to perform an attack action against another ship.

gameID
string
required

The unique identifier of the game.

direction
enum<string>
required

The direction of the attack relative to the attacking ship. 'CURRENT' means attacking at the same vertex.

Available options:
CURRENT,
UP,
DOWN,
LEFT,
RIGHT,
FORWARD,
BACK
attackingShip
object
required

The ship initiating the attack.

target
object
required

The ship being targeted by the attack.

Response

201

Attack successfully executed.