---
title: "GET /api/v1.0/labels/"
method: GET
path: "/api/v1.0/labels/"
tags: ["labels"]
---

# GET /api/v1.0/labels/

`GET /api/v1.0/labels/`

List all labels accessible to the user in a hierarchical structure.

        The response returns labels in a tree structure where:
        - Labels are ordered alphabetically by name
        - Each label includes its children (sub-labels)
        - The hierarchy is determined by the label's name (e.g., "Inbox/Important" is a child of "Inbox")

        You can filter labels by mailbox using the mailbox_id query parameter.

## Query parameters

- `mailbox_id` string, uuid

## Response `200`

List of labels in hierarchical structure

- TreeLabel[]
  - `id` string, uuid, required
  - `name` string, required
  - `slug` string, required
  - `color` string, required
  - `display_name` string, required
  - `children` TreeLabel[], required
  - `description` string, required
  - `is_auto` boolean, required

---

[API](https://skmtc.dev/betagouv/apis/messages-api.md) · [All operations](https://skmtc.dev/betagouv/apis/messages-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/betagouv/messages-api/revisions/ba0c140b76dd/schema)
