Domains & SSL
POST /api/domains/enable-ssl
Enables Let's Encrypt SSL for a domain already registered in the srvly dashboard.
Request Body
{
"domainId": "uuid-of-the-domain-record"
}
Fields
| Field | Type | Description |
|---|---|---|
domainId | string (UUID) | ID of the domain record from the srvly Domains page |
How It Works
- srvly verifies DNS points to your server
- Configures Nginx or Caddy proxy for the domain
- Provisions a Let's Encrypt TLS certificate via Certbot
- Sets up auto-renewal via cron
- The domain status changes to "active" in the dashboard
Prerequisites
- The domain must first be added in the srvly Domains page (creates a database record)
- The domain's DNS must point to your server's IP
- Ports 80 and 443 must be accessible from the internet
- The target application must already be running on the configured port
Response
{
"success": true,
"url": "https://app.example.com",
"message": "SSL activated!"
}