Skip to content
AquadactylAquadactyl
API referenceClient API

Server settings

3 source-verified client API operations in Aquadactyl.

Generated from Aquadactyl 2bfd6ae2a30c. Read authentication and conventions first.

POST /api/client/servers/{server}/settings/rename

Renames a server.

Access: Client API key or authenticated panel session; settings.rename.

Source: Route · Controller · Request validation

Model constraints: Server.php (including runtime rules and uniqueness checks for updates).

Path parameters: server. See identifiers.

Input fields

Rules use Laravel validation syntax. Dotted keys describe nested objects; * describes each array member. Model-derived rules are shown as their source expressions; model methods can add runtime constraints.

FieldValidation
nameServer::getRules()['name']
description'string|nullable'

Response

Success: 204 (empty body).

Response construction and endpoint behavior

This source excerpt includes conditional responses, metadata, pagination, and service calls for this operation.

$name = $request->input('name');
$description = $request->has('description') ? (string) $request->input('description') : $server->description;
$this->repository->update($server->id, [
    'name' => $name,
    'description' => $description,
]);

if ($server->name !== $name) {
    Activity::event('server:settings.rename')
        ->property(['old' => $server->name, 'new' => $name])
        ->log();
}

if ($server->description !== $description) {
    Activity::event('server:settings.description')
        ->property(['old' => $server->description, 'new' => $description])
        ->log();
}

return new JsonResponse([], Response::HTTP_NO_CONTENT);

POST /api/client/servers/{server}/settings/reinstall

Reinstalls the server on the daemon.

Access: Client API key or authenticated panel session; settings.reinstall.

Source: Route · Controller · Request validation

Validation is inherited from ApplicationApiRequest.php.

Path parameters: server. See identifiers.

Response

Success: 202.

Response construction and endpoint behavior

This source excerpt includes conditional responses, metadata, pagination, and service calls for this operation.

$this->reinstallServerService->handle($server);

Activity::event('server:reinstall')->log();

return new JsonResponse([], Response::HTTP_ACCEPTED);

PUT /api/client/servers/{server}/settings/docker-image

Changes the Docker image in use by the server.

Access: Client API key or authenticated panel session; startup.docker-image.

Source: Route · Controller · Request validation

Path parameters: server. See identifiers.

Input fields

Rules use Laravel validation syntax. Dotted keys describe nested objects; * describes each array member. Model-derived rules are shown as their source expressions; model methods can add runtime constraints.

| Field | Validation | | -------------- | ------------------------------------------------------------ | ---------------------------------------------------------------------------- | | docker_image | ['required', 'string', 'max:191', 'regex:/^[\w#\.\/\- ]\*\\ | ?~?[\w\.\/\-:@ ]\*$/', Rule::in(array_values($server->egg->docker_images))] |

Response

Success: 204 (empty body).

Response construction and endpoint behavior

This source excerpt includes conditional responses, metadata, pagination, and service calls for this operation.

if (!in_array($server->image, array_values($server->egg->docker_images))) {
    throw new BadRequestHttpException('This server\'s Docker image has been manually set by an administrator and cannot be updated.');
}

$original = $server->image;
$server->forceFill(['image' => $request->input('docker_image')])->saveOrFail();

if ($original !== $server->image) {
    Activity::event('server:startup.image')
        ->property(['old' => $original, 'new' => $request->input('docker_image')])
        ->log();
}

return new JsonResponse([], Response::HTTP_NO_CONTENT);