---
title: "object exists · RUAL Documentation"
description: "Checks whether an object exists and reads its size, type and metadata : without downloading it."
canonical: https://docs.rual.nl/block-types/object%20storage/s3connection_head_object
language: en
---

[Cluster](https://docs.rual.nl/cluster)

[Blocks](https://docs.rual.nl/block-types)

[Interfaces](https://docs.rual.nl/interfaces)

[Blueprints](https://docs.rual.nl/blueprints)

[Tutorials](https://docs.rual.nl/tutorials)

[Home automation](https://docs.rual.nl/home-automation)

[Examples](https://docs.rual.nl/examples)

[Reference](https://docs.rual.nl/reference)

[Architecture](https://docs.rual.nl/architecture)

[Troubleshooting](https://docs.rual.nl/troubleshooting)

Other

# object exists

This block is part of the [`object storage`](https://docs.rual.nl/block-types/object%20storage) group and was last modified in core [`v15.0.1`](https://docs.rual.nl/core-versions/150001).

Checks whether an object exists and reads its size, type and metadata : without downloading it.

- flow `flow`

- connection required `s3connection` The object storage connection to use, from an **open connection** block.

- bucket `value` Bucket name. Leave empty to use the bucket set on the connection.

- key required `value` The object key to check.

- flow `flow`

- connection `s3connection` The same connection, so it can be passed to the next block.

- success `condition` Whether the check could be performed. A missing object is still a success : read **exists** for the answer.

- error `value`

- exists `condition` Whether the object is there. Only meaningful when **success** is true.

- size `number`

- content type `value`

- etag `value`

- last modified `date`

- metadata `object`

HEADs `bucket`/`key`: reports existence and metadata without transferring the object. `exists` and `success` answer DIFFERENT questions and both are written. A missing object is a SUCCESSFUL answer (success=true, exists=false) : the question was asked and answered. success=false means the question could not be asked at all: no connection, no credentials, or a refused request. That distinction is load-bearing: a 403 reported as exists=false would read as "absent" to the branch downstream, and a flow that writes when an object is absent would then overwrite an object it merely lacks permission to see. Branch on `exists`, but only after checking `success`. When exists=false every metadata pin is written at its zero. `last_modified` is an RFC-3339 string or null.

| `s3 head` |
| --- |
| `exists` |
| `object info` |
| `stat object` |
| `head` |

## Version history

Introduced in [`v15.0.1`](https://docs.rual.nl/core-versions/150001).

- [Back to `object storage`](https://docs.rual.nl/block-types/object%20storage): Return to the main group to view all sub-groups

- [Back to `object storage`](https://docs.rual.nl/block-types/object%20storage?group=object%20storage): Return to the group to view all blocks within this group

Was this page helpful? [Tell us what to improve](https://docs.rual.nl/support) · RUAL Docs is an integral component of the [RUAL ecosystem](https://rual.nl)
