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

# Storage

> Use `/storage/add` and `/storage/read` to move data between ROS 2 and the peaq storage pallet.

Write and read compact JSON data (or file references) via lifecycle ROS 2 services. For high-throughput telemetry with IPFS, see [Verifiable Storage](/peaqchain/sdk-reference/robotics-sdk/ros2/messaging/verifiable-storage).

## Write data (`/storage/add`)

```bash theme={"theme":{"light":"github-light-default","dark":"github-dark"}}
ros2 service call /peaq_core_node/storage/add \
  peaq_ros2_interfaces/srv/StoreAddData \
  '{key: "DEMO", value_json: "{\"ok\": true}", confirmation_mode: "FAST"}'
```

Expected output (abridged):

```text theme={"theme":{"light":"github-light-default","dark":"github-dark"}}
status: submitted
message: "Storage transaction initiated"
tx_hash: 0xabc123...
```

## Read data (`/storage/read`)

```bash theme={"theme":{"light":"github-light-default","dark":"github-dark"}}
ros2 service call /peaq_core_node/storage/read \
  peaq_ros2_interfaces/srv/StoreReadData \
  '{key: "DEMO"}'
```

Example response:

```text theme={"theme":{"light":"github-light-default","dark":"github-dark"}}
exists: true
value_json: '{"ok": true}'
cid: Qm...
```

Subsections

* Add: submit JSON data with `/storage/add`
* Read: retrieve JSON data with `/storage/read`
* Telemetry & Configuration: see [Verifiable Storage](/peaqchain/sdk-reference/robotics-sdk/ros2/messaging/verifiable-storage) for IPFS setup and retry policies

Tips

* Pair service calls with `ros2 topic echo /peaq/tx_status` to monitor confirmation phases (`PENDING`, `IN_BLOCK`, `FINALIZED`).
* Use `confirmation_mode: FINAL` in production for stronger guarantees.
* For files, publish via the `peaq/storage/ingest` topic handled by the storage bridge.
