Endpoint
Configuration Requirement
This endpoint must be explicitly enabled in the Wings configuration. It is disabled by default for security reasons. Inconfig.yml:
Authentication
Requires Bearer token authentication via theAuthorization header.
Path Parameters
The UUID of the server
Request Body
The remote URL to download from (must be HTTP/HTTPS)
The destination directory where the file will be saved (relative to server root)
Optional custom filename. If not provided, filename is extracted from the URL or Content-Disposition header.
Whether to use the filename from the Content-Disposition header if available
Whether to download in the foreground (blocks until complete) or background
Response
Returns204 No Content on success (background download) or after completion (foreground download).
Example Request
Behavior
- Downloads are performed asynchronously by default (
foreground: false) - Foreground downloads block until complete, background downloads return immediately
- Download progress is published via WebSocket events
- File is written directly to disk (no memory buffering of entire file)
- Supports redirects (follows 3xx responses)
- User-Agent is set to
Pterodactyl Wings - Timeout: 15 minutes for the entire download
- Maximum file size: Limited by available disk space
- Existing files with the same name are overwritten
- Path traversal is prevented
Monitor download progress through the server’s WebSocket connection. Progress events include download speed and bytes downloaded.
Error Responses
400 Bad Request
400 Bad Request
Invalid URL format or missing required fields
401 Unauthorized
401 Unauthorized
403 Forbidden
403 Forbidden
Remote downloads are disabled in Wings configuration
404 Not Found
404 Not Found
Server does not exist or remote file not found
500 Internal Server Error
500 Internal Server Error
Failed to download file (network error, disk full, etc.)
Security Considerations
- SSRF Prevention: Wings does not validate remote URLs. Malicious users could potentially download from internal network resources.
- Disk Usage: Large downloads can fill up disk space
- Malware: Downloaded files are not scanned for malware
- Rate Limiting: No built-in rate limiting for remote downloads
Use Cases
- Download plugins from remote repositories
- Import world maps from CDN
- Fetch configuration files from GitHub
- Download mod packs
- Import database dumps
Source Reference
Implementation:router/router_server_files.go (postServerPullRemoteFile function)