> ## Documentation Index
> Fetch the complete documentation index at: https://transcension.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Capture

> Allows a ship to attempt to capture an objective or another game element at its current location or in an adjacent direction.



## OpenAPI

````yaml api-reference/cubic-api.json post /api/v1/cubic/capture
openapi: 3.0.0
info:
  title: Cubic Game API
  description: >-
    API documentation for the Cubic game, providing endpoints for game
    management, ship actions, and retrieving game state information.
  version: '1.0'
  contact:
    name: Cubic Game Support
servers:
  - url: http://50.187.81.221:4000
    description: Rendezvous Cubic Server.
  - url: https://cubic.ngrok.app
    description: Ender's Cubic Server.
security: []
tags:
  - name: Cubic
    description: Operations related to the Cubic game mechanics.
paths:
  /api/v1/cubic/capture:
    post:
      tags:
        - Cubic
      summary: Capture
      description: >-
        Allows a ship to attempt to capture an objective or another game element
        at its current location or in an adjacent direction.
      operationId: CubicController_capture
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CaptureDTO'
            examples:
              captureExample:
                summary: Example of a ship capturing an objective
                value:
                  gameID: uniqueGame123
                  direction: CURRENT
                  capturingShip:
                    teamName: RedTeam
                    shipName: RedCruiser1
        description: >-
          Details for a ship to attempt a capture action, including the game ID,
          the direction, and the capturing ship.
      responses:
        '201':
          description: Capture attempt successfully executed.
components:
  schemas:
    CaptureDTO:
      type: object
      properties:
        gameID:
          type: string
          description: The unique identifier of the game.
        direction:
          type: string
          enum:
            - CURRENT
            - UP
            - DOWN
            - LEFT
            - RIGHT
            - FORWARD
            - BACK
          description: >-
            The direction of the capture attempt relative to the capturing ship.
            'CURRENT' means attempting capture at the same vertex.
        capturingShip:
          $ref: '#/components/schemas/ShipIdentifierDTO'
          description: The ship attempting to capture an objective.
      required:
        - gameID
        - direction
        - capturingShip
      description: Data transfer object for a ship to attempt a capture action.
    ShipIdentifierDTO:
      type: object
      properties:
        teamName:
          type: string
          description: The name of the team to which the ship belongs.
        shipName:
          type: string
          description: The unique name of the ship.
      required:
        - teamName
        - shipName
      description: >-
        Data transfer object for uniquely identifying a ship by its team and
        name.

````