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

# Sync assets

> Make a folder of assets match a local folder in one call: give every file's path, SHA-256 and size. Files the workspace has are recorded at once; you get an upload to make for each of the others, then call again to record them. A file over 100 MiB gets a multipart upload: PUT each part, keep each part's ETag, and in the next call give that file `multipart` (its upload_id and every part's part_number and etag).

MCP tool: [`sync_assets`](/mcp/tools/assets#sync_assets).



## OpenAPI

````yaml /api/openapi.json post /v1/assets/sync
openapi: 3.1.0
info:
  title: Rendermate API
  version: v1
servers:
  - url: https://api.rendermate.com
security:
  - api_key: []
tags:
  - name: Account
  - name: Workspaces
  - name: Projects
  - name: Documents
  - name: Links
  - name: Exports
  - name: Assets
  - name: Generations
  - name: Persons
  - name: Help
paths:
  /v1/assets/sync:
    post:
      tags:
        - Assets
      summary: Sync assets
      description: >-
        Make a folder of assets match a local folder in one call: give every
        file's path, SHA-256 and size. Files the workspace has are recorded at
        once; you get an upload to make for each of the others, then call again
        to record them. A file over 100 MiB gets a multipart upload: PUT each
        part, keep each part's ETag, and in the next call give that file
        `multipart` (its upload_id and every part's part_number and etag).


        MCP tool: [`sync_assets`](/mcp/tools/assets#sync_assets).
      operationId: sync_assets
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              properties:
                delete_missing:
                  default: false
                  description: Also delete the folder's assets that aren't in `files`.
                  type: boolean
                files:
                  description: Every file of the local folder, up to 1000.
                  items:
                    $ref: '#/components/schemas/SyncFile'
                  type: array
                prefix:
                  default: ''
                  description: >-
                    The workspace folder, ending in `/`, or empty for the whole
                    workspace.
                  type: string
                project_id:
                  default: null
                  description: >-
                    The project new assets go in; the workspace's default
                    project when absent.
                  type:
                    - string
                    - 'null'
              required:
                - files
              type: object
        required: true
      responses:
        '200':
          content:
            application/json:
              example:
                deleted:
                  - launch/old-intro.mp4
                recorded:
                  - launch/intro.mp4
                uploads:
                  - name: launch/outro.mp4
                    upload:
                      expires_at: '2026-12-03T11:15:00Z'
                      headers:
                        content-type: video/mp4
                        x-amz-checksum-sha256: nyxOGns9X44MKitN8eHFWnudDy4MaLHn5+nJoLLU9m4=
                      method: PUT
                      url: >-
                        https://media.rendermate.com/ws_use_0193f2a1b7c84e6d9a2f5b8c1d4e7f30/blobs/9f2c4e1a7b3d5f8e0c6a2b4d8f1e3c5a7b9d0f2e4c6a8b1d3f5e7c9a0b2d4f6e??X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Date=20261203T101500Z&X-Amz-Expires=86400&X-Amz-Signature=5d1f…
              schema:
                properties:
                  deleted:
                    description: Names deleted because they weren't in `files`.
                    items:
                      type: string
                    type: array
                  recorded:
                    description: Names recorded or already up to date.
                    items:
                      type: string
                    type: array
                  uploads:
                    description: Files to upload before the next request.
                    items:
                      $ref: '#/components/schemas/PendingUpload'
                    type: array
                required:
                  - recorded
                  - uploads
                  - deleted
                type: object
          description: OK
        '400':
          content:
            application/json:
              examples:
                invalid_request:
                  summary: invalid_request
                  value:
                    error:
                      code: invalid_request
                      doc_url: https://rendermate.com/docs/errors#invalid_request
                      message: >-
                        prefix is a folder ending in /, or empty for the whole
                        workspace
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            - `invalid_request`: prefix is a folder ending in /, or empty for
            the whole workspace
        '401':
          content:
            application/json:
              examples:
                unauthorized:
                  summary: unauthorized
                  value:
                    error:
                      code: unauthorized
                      doc_url: https://rendermate.com/docs/errors#unauthorized
                      message: 'provide a valid API key: Authorization: Bearer sk_…'
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            - `unauthorized`: provide a valid API key: Authorization: Bearer
            sk_…
        '403':
          content:
            application/json:
              examples:
                key_without_workspace:
                  summary: key_without_workspace
                  value:
                    error:
                      code: key_without_workspace
                      doc_url: https://rendermate.com/docs/errors#key_without_workspace
                      message: >-
                        this API key has no workspace: create a key in the
                        dashboard, under api keys in the workspace it should act
                        in
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            - `key_without_workspace`: this API key has no workspace: create a
            key in the dashboard, under api keys in the workspace it should act
            in
        '404':
          content:
            application/json:
              examples:
                project.not_found:
                  summary: project.not_found
                  value:
                    error:
                      code: project.not_found
                      doc_url: https://rendermate.com/docs/errors#project.not_found
                      message: no such project in this workspace
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: '- `project.not_found`: no such project in this workspace'
        '409':
          content:
            application/json:
              examples:
                asset.content_being_deleted:
                  summary: asset.content_being_deleted
                  value:
                    error:
                      code: asset.content_being_deleted
                      doc_url: >-
                        https://rendermate.com/docs/errors#asset.content_being_deleted
                      message: >-
                        the workspace is deleting a file with this content; try
                        again in a few seconds
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
                asset.content_changing:
                  summary: asset.content_changing
                  value:
                    error:
                      code: asset.content_changing
                      doc_url: >-
                        https://rendermate.com/docs/errors#asset.content_changing
                      message: >-
                        this content kept changing while the asset was recorded;
                        try again
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
                asset.name_taken:
                  summary: asset.name_taken
                  value:
                    error:
                      code: asset.name_taken
                      doc_url: https://rendermate.com/docs/errors#asset.name_taken
                      message: an asset named "launch/intro.mp4" already exists
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            - `asset.content_being_deleted`: the workspace is deleting a file
            with this content; try again in a few seconds

            - `asset.name_taken`: an asset named "launch/intro.mp4" already
            exists

            - `asset.content_changing`: this content kept changing while the
            asset was recorded; try again
        '500':
          content:
            application/json:
              examples:
                internal:
                  summary: internal
                  value:
                    error:
                      code: internal
                      doc_url: https://rendermate.com/docs/errors#internal
                      message: internal error
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: '- `internal`: internal error'
        '503':
          content:
            application/json:
              examples:
                uploads_unavailable:
                  summary: uploads_unavailable
                  value:
                    error:
                      code: uploads_unavailable
                      doc_url: https://rendermate.com/docs/errors#unavailable
                      message: >-
                        uploading new files isn't available yet; assets whose
                        content the workspace already has can still be recorded
                      request_id: req_0193f2a4c1d87b2e9f3a6c5d4e8b7a10
              schema:
                $ref: '#/components/schemas/Error'
          description: >-
            - `uploads_unavailable`: uploading new files isn't available yet;
            assets whose content the workspace already has can still be recorded
components:
  schemas:
    SyncFile:
      description: One local file of a synced folder.
      properties:
        content_type:
          default: null
          type:
            - string
            - 'null'
        multipart:
          anyOf:
            - $ref: '#/components/schemas/FinishMultipart'
            - type: 'null'
          description: Finishes this file's multipart upload from the previous sync.
        path:
          description: Its path relative to the synced folder, with `/` between folders.
          type: string
        sha256:
          type: string
        size:
          format: uint64
          minimum: 0
          type: integer
      required:
        - path
        - sha256
        - size
      type: object
    PendingUpload:
      properties:
        multipart:
          anyOf:
            - $ref: '#/components/schemas/Multipart'
            - type: 'null'
          description: >-
            Parts to PUT, for larger files; send the parts' ETags back in the
            file's `multipart`.
        name:
          description: The asset's name, as `files` gave it.
          type: string
        upload:
          anyOf:
            - $ref: '#/components/schemas/Upload'
            - type: 'null'
          description: One presigned PUT, for files up to 100 MiB.
      required:
        - name
      type: object
    Error:
      properties:
        error:
          properties:
            code:
              description: Stable, such as `asset.name_taken` or `not_available`.
              type: string
            doc_url:
              description: The code's entry on the Errors page.
              type: string
            message:
              description: What went wrong and what to do next.
              type: string
            request_id:
              description: >-
                The request's ID, also in its `x-request-id` header. Quote it
                when you contact support.
              type: string
          required:
            - code
            - message
            - doc_url
            - request_id
          type: object
      required:
        - error
      type: object
    FinishMultipart:
      description: >-
        A multipart upload: the parts uploaded so far, or every part to finish
        it.
      properties:
        count:
          default: null
          description: >-
            For an upload of unknown size: how many part URLs, 1 to 100; 8 when
            absent.
          format: uint32
          minimum: 0
          type:
            - integer
            - 'null'
        from:
          default: null
          description: >-
            For an upload of unknown size: the first part to get a URL for; the
            one after `parts`

            when absent.
          format: uint32
          minimum: 0
          type:
            - integer
            - 'null'
        parts:
          description: >-
            The parts uploaded, from 1, each with the ETag its PUT answered
            with. Finishing lists them

            all.
          items:
            $ref: '#/components/schemas/UploadedPart'
          type: array
        upload_id:
          type: string
      required:
        - upload_id
      type: object
    Multipart:
      description: >-
        Uploads a file in parts: PUT each part's bytes (`part_size` bytes each,
        the last one the

        rest) to its URL, keep the `ETag` each answers with, then repeat the
        asset's upload request

        with `upload_id` and the parts' ETags to finish it.
      properties:
        credentials:
          anyOf:
            - $ref: '#/components/schemas/PartCredentials'
            - type: 'null'
          description: >-
            For an upload of unknown size to R2: credentials to sign every
            part's upload with

            instead of `parts`, which is then empty.
        first_part:
          description: >-
            The number of `parts`' first URL: 1, unless more URLs were asked for
            an upload of unknown

            size.
          format: uint32
          minimum: 0
          type: integer
        part_size:
          description: Bytes per part; the last part is the rest.
          format: uint64
          minimum: 0
          type: integer
        parts:
          description: In order, from part `first_part`.
          items:
            $ref: '#/components/schemas/Upload'
          type: array
        upload_id:
          description: The multipart upload's ID, to send back with the parts' ETags.
          type: string
      required:
        - upload_id
        - part_size
        - first_part
        - parts
      type: object
    Upload:
      description: >-
        A presigned request that uploads one blob: send the file as its body
        with exactly these

        headers, which include the content's `x-amz-checksum-sha256`, so the
        bucket refuses any other

        bytes.
      properties:
        expires_at:
          description: RFC 3339; ask again after it.
          type: string
        headers:
          additionalProperties:
            type: string
          description: The headers to send, exactly as given.
          type: object
        method:
          description: The HTTP method, `PUT`.
          type: string
        url:
          description: Where to send the file, signed.
          type: string
      required:
        - method
        - url
        - headers
        - expires_at
      type: object
    UploadedPart:
      description: A finished part of a multipart upload.
      properties:
        etag:
          description: The `ETag` header the part's PUT answered with.
          type: string
        part_number:
          description: From 1.
          format: int32
          type: integer
      required:
        - part_number
        - etag
      type: object
    PartCredentials:
      description: >-
        Temporary S3 credentials that may only upload parts of one multipart
        upload, for a client to

        sign its own part uploads with, instead of asking for a URL per part.
      properties:
        access_key_id:
          description: The access key ID to sign with.
          type: string
        bucket:
          description: The bucket to upload to.
          type: string
        endpoint:
          description: >-
            The S3 endpoint, for path-style requests: `PUT
            {endpoint}/{bucket}/{key}?partNumber=…&uploadId=…`.
          type: string
        expires_at:
          description: RFC 3339; ask for new ones before then.
          type: string
        key:
          description: The object key of the upload.
          type: string
        region:
          description: The region to sign for.
          type: string
        secret_access_key:
          description: The secret access key to sign with.
          type: string
        session_token:
          description: Send it as `x-amz-security-token`.
          type: string
        upload_id:
          description: The bucket's ID for the multipart upload.
          type: string
      required:
        - access_key_id
        - secret_access_key
        - session_token
        - expires_at
        - endpoint
        - region
        - bucket
        - key
        - upload_id
      type: object
  securitySchemes:
    api_key:
      description: >-
        An API key from the dashboard, such as `sk_live_…`. It acts in its
        workspace.
      scheme: bearer
      type: http

````

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