---
updatedAt: 2026-10-05T21:33:06.000Z
agentTools:
  projectIndex: https://developer.duda.co/llms.txt
---

# Upload Resources

Uploads up to 10 resources, such as images, from external URLs to Duda's CDN, so they can be used on the site. Make sure each file has the right extension.

> 🚧 Please make sure files you upload have the correct extension. For example, PNG images should have .png and JPEG should have .jpg or .jpeg

> 🚧 Only 10 resources can be uploaded in a single call

| Property            | Type             | Description                                                                                                                      |
| ------------------- | ---------------- | -------------------------------------------------------------------------------------------------------------------------------- |
| n\_failures         | int              | The number of failed resource that failed to upload.                                                                             |
| uploaded\_resources | Array of Objects | An array of objects describing each resource uploaded. This contains an original URL, new URL (in the Duda system) and a status. |
| original\_url       | URL              | The source URL of the resource that was uploaded.                                                                                |
| new\_url            | URL              | A direct URL link to the resource from the Duda CDN.                                                                             |
| status              | String           | The status of the upload. Value can be *NOT\_FOUND* or *UPLOADED*                                                                |

> 📘 Since Duda must download the image, multi-size them and finally compress images uploaded through this API, it can often take several seconds to respond, depending on the number of images. If possible, we recommend you perform this action asynchronously.

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "Duda Partner API",
    "version": "1.0.0",
    "description": "REST API for Duda partners. Manage accounts, sites, content, collections, eCommerce, bookings, memberships and webhooks on the Duda platform."
  },
  "servers": [
    {
      "url": "https://api.duda.co",
      "description": "Production (US)"
    },
    {
      "url": "https://api.eu.duda.co",
      "description": "Production (EU)"
    },
    {
      "url": "https://api-sandbox.duda.co",
      "description": "Sandbox"
    }
  ],
  "security": [
    {
      "basicAuth": []
    }
  ],
  "paths": {
    "/api/sites/multiscreen/resources/{site_name}/upload": {
      "post": {
        "tags": [
          "Sites"
        ],
        "summary": "Upload Resources",
        "description": "Uploads up to 10 resources, such as images, from external URLs to Duda's CDN, so they can be used on the site. Make sure each file has the right extension.",
        "operationId": "resourcesUpload",
        "parameters": [
          {
            "$ref": "#/components/parameters/SiteName"
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/UploadResourceRDT"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UploadResourceResultRDT"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/PaymentRequired"
          },
          "405": {
            "$ref": "#/components/responses/MethodNotAllowed"
          },
          "429": {
            "$ref": "#/components/responses/TooManyRequests"
          },
          "500": {
            "$ref": "#/components/responses/InternalServerError"
          }
        }
      }
    }
  },
  "components": {
    "responses": {
      "BadRequest": {
        "description": "Bad Request",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorRDT"
            }
          }
        }
      },
      "InternalServerError": {
        "description": "Internal Server Error"
      },
      "MethodNotAllowed": {
        "description": "Method Not Allowed"
      },
      "PaymentRequired": {
        "description": "Payment Required",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorRDT"
            }
          }
        }
      },
      "TooManyRequests": {
        "description": "Too many requests. The rate limit was exceeded.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorRDT"
            }
          }
        }
      },
      "Unauthorized": {
        "description": "Unauthorized",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/ErrorRDT"
            }
          }
        }
      }
    },
    "schemas": {
      "ErrorRDT": {
        "type": "object",
        "properties": {
          "error_code": {
            "type": "string",
            "enum": [
              "AccessForbidden",
              "ResourceNotExist",
              "ResourceAlreadyExist",
              "InvalidInput",
              "InvalidState",
              "InternalError",
              "UnAuthorized",
              "TooManyRequests",
              "EmailDomainNotValidated",
              "InsufficientCredits"
            ]
          },
          "message": {
            "type": "string"
          }
        }
      },
      "UploadResourceRDT": {
        "type": "object",
        "properties": {
          "folder": {
            "type": "string"
          },
          "resource_type": {
            "type": "string",
            "enum": [
              "IMAGE",
              "FILE",
              "ICON",
              "AUDIO",
              "VIDEO"
            ]
          },
          "src": {
            "type": "string"
          },
          "target_file_name": {
            "type": "string"
          }
        }
      },
      "UploadResourceResultRDT": {
        "type": "object",
        "properties": {
          "n_failures": {
            "type": "integer",
            "format": "int32"
          },
          "uploaded_resources": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/UploadedResourceRDT"
            }
          }
        }
      },
      "UploadedResourceRDT": {
        "type": "object",
        "properties": {
          "new_url": {
            "type": "string"
          },
          "original_url": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "UPLOADED",
              "NOT_FOUND",
              "INVALID_TARGET"
            ]
          }
        }
      }
    },
    "securitySchemes": {
      "basicAuth": {
        "type": "http",
        "description": "API username and password. Find them in the API access section of the Business tools tab in the platform.",
        "scheme": "basic"
      }
    },
    "parameters": {
      "SiteName": {
        "name": "site_name",
        "in": "path",
        "description": "The site's unique name (its ID), returned when the site is created.",
        "required": true,
        "schema": {
          "type": "string"
        }
      }
    }
  }
}
```