---
title: "Add a device to a fleet as a mirror"
method: POST
path: "/api/apps/fleet/{installation_id}/devices"
tags: ["Apps - Fleet"]
---

# Add a device to a fleet as a mirror

`POST /api/apps/fleet/{installation_id}/devices`

## Request

- Base URL: `https://trmnl.com`
- URL: `https://trmnl.com/api/apps/fleet/{installation_id}/devices`
- Auth: HTTP bearer

The device joins as a mirror; setFleetMaster promotes one. A device can be in one fleet only.

## Request body

- object
  - `device_id` integer, required

## Response `200`

Added

- object
  - `data` FleetMember
    - `device_id` integer
    - `name` string, nullable
    - `role` 'master' | 'mirror'
    - `check_in_state` 'overdue' | 'on_time' | 'asleep' | 'never_seen', nullable: Whether the device checked in when it said it would; null for a device that was reset
    - `expected_check_in_at` string, date_time, nullable
    - `last_pushed_at` string, date_time, nullable
    - `in_sync` boolean: Pushed since the master playlist last changed

## Other responses

- `401`: Unauthorized
- `404`: Device belongs to another user
- `422`: The device is already in a fleet

---

[API](https://skmtc.dev/trmnl/apis/trmnl-api.md) · [All operations](https://skmtc.dev/trmnl/apis/trmnl-api/llms.txt) · [OpenAPI document](https://skmtc.dev/trmnl/apis/trmnl-api/revisions/66179e6d663b?raw)
