modl.gg

Create Punishment

Issue a new punishment to a player.

POST /v1/minecraft/punishments/create

Issue a new punishment to a player. The punishment will be applied immediately and synced to any connected servers.

Authentication

Requires the X-API-Key header with your server's API key.

Request

Headers

HeaderTypeRequiredDescription
X-API-KeystringYesYour server's API key.
Content-TypestringYesMust be application/json.

Body

FieldTypeRequiredDescription
targetUuidstringYesThe UUID of the player to punish.
issuerNamestringYesThe name of the staff member issuing the punishment.
typeOrdinalintegerYesThe punishment type ordinal (0-14).
reasonstringNoThe reason for the punishment.
durationlongNoDuration in milliseconds. Use -1 for permanent.
dataobjectNoAdditional data to attach to the punishment.
notesstring[]NoInternal notes visible only to staff.
attachedTicketIdsstring[]NoIDs of tickets to link to this punishment.
severitystringNoSeverity level: "lenient", "regular", or "aggravated".
statusstringNoInitial status of the punishment.
Example Request Body
{
  "targetUuid": "069a79f4-44e9-4726-a5be-fca90e38aaf5",
  "issuerName": "StaffMember",
  "typeOrdinal": 7,
  "reason": "Use of unauthorized client modifications",
  "duration": 604800000,
  "severity": "regular",
  "notes": ["Caught by anticheat, confirmed manually"]
}

Response

200 OK

An empty response body indicates the punishment was created successfully.

Error Responses

Status CodeDescription
400Invalid request body or missing required fields.
401Missing or invalid API key.
404Target player not found.

On this page