Send Commands
Servers
Send Commands
POST
Send Commands
Sends one or more commands to a running server instance.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/pterodactyl/wings/llms.txt
Use this file to discover all available pages before exploring further.
Authentication
Requires the Wings authentication token in theAuthorization header:
Path Parameters
The UUID of the server
Request Body
Array of command strings to send to the server. Each command is sent sequentially.
Response
Returns204 No Content when commands have been sent successfully.
Error Responses
404 Not Found
The requested server does not exist on this Wings instance.
502 Bad Gateway
Cannot send commands to a stopped server instance.
500 Internal Server Error
An error occurred while checking if the server is running.
Behavior
- Checks if the server is running before sending commands
- If the server is not running, returns a 502 error
- Commands are sent sequentially in the order provided
- If a command fails to send, an error is logged but subsequent commands are still attempted
- Command failures do not cause the API request to fail
Example Request
Example Response
Notes
- Commands are executed in the server’s console/stdin
- The server must be in a running state (not offline, starting, or stopping)
- Individual command failures are logged but don’t fail the entire request
- There is no response body indicating which commands succeeded or failed
- Commands are sent to the environment (Docker container) via stdin
Source Reference
Implemented inrouter/router_server.go:108