Skip to content

Run AutoSSL for a web hosting account

POST /api/v2/shared-hosting/{accountId}/ssl/actions/run-autossl

Ask the server to issue or renew free SSL certificates for every domain on a web hosting account now. Without this call it tries again at its next daily run. Use it after you fixed a domain’s DNS. Use it also when a website shows a self-signed, expired or missing certificate. The check runs in the background on the hosting server. There is no job to follow. After a few minutes, read the certificates with GET /api/v2/shared-hosting/{accountId}/ssl-certificates. The run changes nothing else on the website or in email. Repeating it is safe. The account must be active and on cPanel.

Authentication: An API key with the scopes write:hosting and console:services. About keys and scopes

Request

Path parameters

accountIdstringrequired
The web hosting account ID (acct_…).

Example

POST /api/v2/shared-hosting/{accountId}/ssl/actions/run-autossl
curl -X POST "https://cloud.hostup.se/api/v2/shared-hosting/acct_01hxa3b4c5d6e7f8g9h0j1k2m3/ssl/actions/run-autossl" \
-H "Authorization: Bearer $HOSTUP_API_KEY" \
-H "Content-Type: application/json"

Responses

200 The check was started.

Response 200
{
"started": true
}
Response fields
startedboolean
True when the server accepted the check.

Errors

Errors are Problem Details with a stable code. Branch on the code, not on the text.

400Invalid request. The response body is an RFC 7807 Problem Details document.
401Unauthorized. Authentication is required.
403Forbidden. The caller lacks a required scope or does not own the resource.
404Not found. The resource does not exist or is not owned by the caller.
409The account is not on cPanel (account_not_eligible_cpanel).
429Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers.
500Internal error. Retry later or contact support if the issue persists.
502The check could not be started right now (upstream_failed).