modl.gg
Developer API

Create Upload Token

Create an upload token for punishment evidence.

POST /v1/minecraft/punishments/{punishmentId}/upload-token

Create a temporary upload token that can be used to upload evidence files for a specific punishment.

Authentication

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

X-API-Key: your-api-key-here

Request

Headers

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

Path Parameters

ParameterTypeRequiredDescription
punishmentIdstringYesThe unique ID of the punishment.

Body

FieldTypeRequiredDescription
issuerNamestringNoThe name of the staff member requesting the token.
issuerIdstringNoThe unique identifier of the staff member.
{
  "issuerName": "StaffMember",
  "issuerId": "staff_abc123"
}

Response

200 OK

{
  "status": 200,
  "token": "upload_token_xyz789"
}

Error Responses

Status CodeDescription
401Missing or invalid API key.
404Punishment not found for the given ID.
429Rate limit exceeded.
500Internal server error.

On this page