> ## Documentation Index
> Fetch the complete documentation index at: https://docs.rdp.sh/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Download Backup

> Prepares the backup's disk as a VMDK file. That can take a while for large
disks; the link then appears as `url` in `downloads` of
`GET /servers/{server}/backups` and works for 24 hours. One download is
prepared at a time per server, free of charge.




## OpenAPI

````yaml post /servers/{server}/backups/{backup}/download
openapi: 3.1.0
info:
  title: APIFiddle Sample Definition
  version: 0.0.0
  description: Example workspace
servers:
  - url: https://rdp.sh/api/v1
    description: Default production endpoint.
security: []
paths:
  /servers/{server}/backups/{backup}/download:
    post:
      summary: Download a backup
      description: >
        Prepares the backup's disk as a VMDK file. That can take a while for
        large

        disks; the link then appears as `url` in `downloads` of

        `GET /servers/{server}/backups` and works for 24 hours. One download is

        prepared at a time per server, free of charge.
      operationId: downloadServerBackup
      parameters:
        - $ref: '#/components/parameters/server'
        - $ref: '#/components/parameters/backup'
      responses:
        '201':
          content:
            application/json:
              schema:
                type: object
                title: DownloadServerBackupOk
                properties:
                  status:
                    type: boolean
                    examples:
                      - true
                  message:
                    type: string
                    examples:
                      - >-
                        Your download is being prepared. This can take a while
                        for large disks.
                  download:
                    $ref: '#/components/schemas/backupDownload'
          description: The download is being prepared.
        '403':
          description: User does not own the server.
        '404':
          description: Server not found, or no backup with this ID on the server.
        '409':
          content:
            application/json:
              schema:
                type: object
                title: DownloadServerBackupConflict
                properties:
                  status:
                    type: boolean
                    examples:
                      - false
                  error:
                    type: string
                    examples:
                      - >-
                        A download is already being prepared for this server.
                        Please wait for it to finish.
          description: >
            The backup has not completed, a download is already being prepared,
            backups

            are not enabled, or the server is suspended or busy.
      security:
        - Authorization: []
components:
  parameters:
    server:
      in: path
      name: server
      schema:
        type: string
      required: true
    backup:
      in: path
      name: backup
      schema:
        type: integer
      required: true
      description: Backup ID
  schemas:
    backupDownload:
      type: object
      required:
        - id
        - backup_id
        - status
      properties:
        id:
          type: integer
          examples:
            - 31
        backup_id:
          type: integer
          examples:
            - 812
        status:
          type: string
          enum:
            - pending
            - running
            - completed
            - failed
            - expired
          examples:
            - completed
        progress:
          type: integer
          minimum: 0
          maximum: 100
          examples:
            - 100
        url:
          type:
            - string
            - 'null'
          description: The VMDK file, once it is ready and until the link expires.
        size_bytes:
          type:
            - integer
            - 'null'
        expires_at:
          type:
            - string
            - 'null'
          description: When the link stops working.
        error:
          type:
            - string
            - 'null'
          description: Why preparing the download failed, once it has.
        created_at:
          type: string
      description: A backup prepared as a file to download.
  securitySchemes:
    Authorization:
      in: header
      name: Authorization
      type: apiKey
      description: |
        Your API key as it is, without `Bearer`. API access is off for new
        accounts: until it is turned on under Settings > API, every request
        answers `403` with `API access is turned off for this account. Turn it
        on under Settings > API.` If the account lists allowed IPs, a request
        from any other address answers `403` with `This API key is not allowed
        from <address>`.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.