DocumentationAPI Reference

Resize

Get available resize options and scale your server.

GET/servers/:id/resize

Get available resize options with costs, current usage, and quotas.

curl "https://www.mado-hosting.com/api/v1/servers/srv_abc123/resize" \
  -H "Authorization: Bearer rsk_your_key"

Execute Resize

POST/servers/:id/resize

Scale server to new RAM size. Server is automatically restarted.

Body Parameters

NameTypeRequiredDescription
newRamGbnumberYesNew RAM size in GB (even numbers: 2, 4, 6, ..., 32)
curl -X POST "https://www.mado-hosting.com/api/v1/servers/srv_abc123/resize" \
  -H "Authorization: Bearer rsk_your_key" \
  -H "Content-Type: application/json" \
  -d '{ "newRamGb": 8 }'
For downgrades, current disk usage is checked against the new limit. If it exceeds, DISK_USAGE_EXCEEDED is returned.

Error Codes

HTTPCodeDescription
400INVALID_RAMRAM not in valid increments
400NO_CHANGESame size as current
400BELOW_MIN_RAMBelow pricing minimum
400ABOVE_MAX_RAMAbove pricing maximum
400RAM_LIMIT_EXCEEDEDTotal RAM quota exceeded
400DISK_USAGE_EXCEEDEDDisk usage exceeds new limit