> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.ovalbee.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.ovalbee.com/_mcp/server.

# Export to cloud storage

> Export a dataset's images, with their annotations, to an S3-compatible bucket.

## Overview

Exports a dataset's images, and their annotations, to a folder in an S3-compatible bucket, laid out in the format you pick.

Works with AWS S3 and with S3-compatible storage such as MinIO, Ceph or RustFS. The export is the counterpart of [Import from cloud storage](/node-library/nodes/import-ops-import-from-cloud-storage): a folder written here can be read back by that node.

```mermaid
flowchart LR
  n1["Dataset"] --> n2["Export to cloud storage"]
```

## Prerequisites

| Requirement             | What you need                                                                                                              |
| ----------------------- | -------------------------------------------------------------------------------------------------------------------------- |
| **Dataset with images** | An OvalBee dataset that already holds at least one image.                                                                  |
| **S3 secret**           | A secret of type S3 with an access key ID and secret access key that can write to the bucket, plus its region or endpoint. |
| **Network access**      | A worker that can reach the bucket's endpoint.                                                                             |

## How it works

Reads the source dataset and confirms it holds at least one image.

Opens a connection to the bucket folder from **Bucket path**, using the S3 secret.

Exports the images, and their annotations unless **With annotations** is off, laid out as **Annotation format**.

Applies **If files exist** to any file already sitting at the destination.

## FAQ

#### What does each annotation format write?

**YOLO** writes `images/train`, `labels/train` and a `data.yaml` class list. **COCO** writes `images/train` and an `annotations/train.json`. **Supervisely** writes a project-level `meta.json` plus `<dataset>/img` and `<dataset>/ann` folders.

#### How do I export only the images?

Turn off **With annotations**. The node still writes the layout for the picked **Annotation format**, but skips every annotation file.

#### What happens when a file already exists at the destination?

**Skip existing**, the default, leaves an image alone once a same-sized file is already there and rewrites the annotation files, so a rerun only sends what changed. **Overwrite** replaces every file. **Fail** stops the run instead of writing into a folder that already holds anything.

#### What should the S3 secret contain?

For AWS, the region is enough and the endpoint can stay empty. For MinIO and other S3-compatible storage, set the endpoint and turn on **Force path style**. The endpoint never includes the bucket name: use `https://s3.eu-central-1.amazonaws.com`, not `https://my-bucket.s3.eu-central-1.amazonaws.com`. IAM role secrets aren't supported yet.

#### Why did the run fail?

The source dataset may have no images, the secret may not have permission to write to the bucket, the bucket path may be malformed, or **If files exist** may be set to **Fail** while the destination folder already holds files.

## Inputs

**`Dataset`** `dataset` — required

Dataset whose images are exported. Key: `DATASET`.

---

**`S3 credentials`** `secret` — required

S3 secret with an access key pair and a region or endpoint. Works with AWS S3 and S3-compatible storage such as MinIO. Allowed credential types: `s3`. Key: `S3_SECRET`.

---

**`Bucket path`** `string` — required

Bucket and folder to export to, for example `s3://my-bucket/datasets/cars/`. Placeholder: `s3://my-bucket/path/to/export/`. Key: `PATH`.

---

**`With annotations`** `boolean` — required, default: true

Export annotations next to the images. Turn off to export only the image files. Key: `WITH_ANNOTATIONS`.

---

**`Annotation format`** `select` — required, default: supervisely

Format the annotations are written in. Visible when `WITH_ANNOTATIONS` is not `False`. Key: `ANNOTATION_FORMAT`.

Options:

* Supervisely (`supervisely`)
* COCO (`coco`)
* YOLO (`yolo`)

---

**`If files exist`** `select` — required, default: skip

What to do when a file already exists at the destination. Key: `IF_EXISTS`.

Options:

* Overwrite (`overwrite`)
* Skip existing (`skip`)
* Fail (`fail`)

---

## JSON config

Machine-readable node interface for automation and advanced usage.

#### Show JSON

```json
{
  "name": "Export to cloud storage",
  "description": "Export a dataset's images, with their annotations, to an S3-compatible bucket.",
  "category": "Export",
  "namespace": "ovalbee",
  "templateKey": "export_ops/export_to_cloud_storage",
  "version": "v1",
  "inputs": [
    {
      "key": "DATASET",
      "label": "Dataset",
      "type": "dataset",
      "description": "Dataset whose images are exported.",
      "required": true,
      "default": null,
      "visibleWhen": null
    },
    {
      "key": "S3_SECRET",
      "label": "S3 credentials",
      "type": "secret",
      "description": "S3 secret with an access key pair and a region or endpoint. Works with AWS S3 and S3-compatible storage such as MinIO.",
      "required": true,
      "default": null,
      "visibleWhen": null,
      "options": {
        "types": [
          "s3"
        ]
      }
    },
    {
      "key": "PATH",
      "label": "Bucket path",
      "type": "string",
      "description": "Bucket and folder to export to, for example `s3://my-bucket/datasets/cars/`.",
      "required": true,
      "default": null,
      "visibleWhen": null,
      "options": {
        "placeholder": "s3://my-bucket/path/to/export/"
      }
    },
    {
      "key": "WITH_ANNOTATIONS",
      "label": "With annotations",
      "type": "boolean",
      "description": "Export annotations next to the images. Turn off to export only the image files.",
      "required": true,
      "default": true,
      "visibleWhen": null
    },
    {
      "key": "ANNOTATION_FORMAT",
      "label": "Annotation format",
      "type": "select",
      "description": "Format the annotations are written in.",
      "required": true,
      "default": "supervisely",
      "visibleWhen": {
        "key": "WITH_ANNOTATIONS",
        "operator": "notEquals",
        "value": false
      },
      "options": {
        "options": [
          {
            "label": "Supervisely",
            "value": "supervisely"
          },
          {
            "label": "COCO",
            "value": "coco"
          },
          {
            "label": "YOLO",
            "value": "yolo"
          }
        ]
      }
    },
    {
      "key": "IF_EXISTS",
      "label": "If files exist",
      "type": "select",
      "description": "What to do when a file already exists at the destination.",
      "required": true,
      "default": "skip",
      "visibleWhen": null,
      "options": {
        "options": [
          {
            "label": "Overwrite",
            "value": "overwrite"
          },
          {
            "label": "Skip existing",
            "value": "skip"
          },
          {
            "label": "Fail",
            "value": "fail"
          }
        ]
      }
    }
  ],
  "outputs": []
}
```