---
title: "A 15-minute download link (presigned URL) for a backup dump; the dump is copied to platform storage and reused for 24 hours. Needs databases:reveal (owner/admin, or a developer on the project). 409 with Retry-After while a large dump is still being copied"
method: POST
path: "/projects/{projectId}/wordpress/backups/download"
tags: ["WordPress"]
---

# A 15-minute download link (presigned URL) for a backup dump; the dump is copied to platform storage and reused for 24 hours. Needs databases:reveal (owner/admin, or a developer on the project). 409 with Retry-After while a large dump is still being copied

`POST /projects/{projectId}/wordpress/backups/download`

## Request

- Base URL: `https://hostingsurge.com/api/v1`
- URL: `https://hostingsurge.com/api/v1/projects/{projectId}/wordpress/backups/download`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `__Host-hs_session`

## Path parameters

- `projectId` string, uuid, required

## Request body

- object
  - `filename` string, required: A backup filename from GET /projects/{projectId}/wordpress/backups (<timestamp>.sql.gz)

## Response `200`

Download link

- object
  - `filename` string, required
  - `url` string, required: Presigned HTTPS GET URL of the gzipped SQL dump; no credentials needed, do not share it
  - `expiresAt` string, required: The URL works until then (start the download before)
  - `downloadName` string, required: File name the browser saves it as
  - `sizeBytes` integer, required
  - `contentType` 'application/gzip', required
  - `availableUntil` string, required: The prepared copy is deleted then; asking again after that prepares a new one
  - `prepared` boolean, required: true when this request copied the backup; false when an existing copy was reused

## Other responses

- `400`: Invalid request (code invalid_request)
- `401`: Missing or invalid session/token (code unauthorized)
- `402`: The backup is larger than downloads allow (code limit_reached)
- `403`: Authenticated but not permitted (code forbidden)
- `404`: Not found or not visible to the caller (code not_found)
- `409`: Conflicting state (code conflict)
- `429`: Too many requests (code rate_limited); see Retry-After
- `501`: Backup downloads are not configured on this server (code not_configured)
- `503`: Hosting engine unavailable (code provider_unavailable)

---

[API](https://skmtc.dev/hostingsurge/apis/hostingsurge-platform-api.md) · [All operations](https://skmtc.dev/hostingsurge/apis/hostingsurge-platform-api/llms.txt) · [OpenAPI document](https://skmtc.dev/hostingsurge/apis/hostingsurge-platform-api/revisions/4d08337cdff1?raw)
