**Version: 202701**

# List menus

**GET** `/openapi/2027-01/menus`

List the store's menus (navigation). Supports filtering by ids and hiding disabled items.

## Request

**Query Parameters**

- `ids` string[]

  Optional menu ids to filter, e.g. `?ids=header&ids=1790649397502042737`
- `hide_disabled` boolean

  When true, hide disabled menu items
- `page` int32

  Page number
- `page_size` int32

  Page size, defaults to 100

## Responses

**200**

OK

**application/json**

**Schema | Example**

**Schema**

- `code` string

  error code
- `message` string

  error message
- `data` object

  - `menus` object[]

    Menu list

    *   Array \[

    - `id` string

      Menu ID; built-in menus are `header` and `footer`
    - `title` string

      Menu title
    - `category` int32

      Menu category:

      *   `1`: Header menu
      *   `2`: Footer menu
      *   `3`: Custom menu
    - `children` object[]

      All menu items as a flat list in display order; rebuild the tree via `pid`

      *   Array \[

      - `id` int64

        Menu item ID
      - `title` string

        Menu item title
      - `origin_type` int32

        Numeric code of the link type, paired with `type` (e.g. `-1` web, `0` no link, `1` product, `2` collection, `3` page, `15` home)
      - `type` string

        Link type, e.g. `home`, `product`, `collection`, `page`, `article`, `blog`, `web`; `0` means no link
      - `source_id` string

        ID of the linked resource (product, collection, page, etc.)
      - `url` string

        Link URL
      - `pid` int64

        Parent menu item ID; `0` for a top-level item
      - `status` int32

        Menu item status
      - `disabled` int32

        Whether the item is disabled: `1` disabled, `0` enabled
      - `target` string

        Link target, e.g. `_blank` opens in a new window
      - `url_obj` object

        Link object

        - `type` string

          Link type, same values as the menu item's `type`
        - `source_id` string

          ID of the linked resource
        - `url` string

          Link URL
        - `title` string

          Title of the linked resource; not populated in the menu list
      - `expanded` boolean

        Whether the item is expanded in the editor; always `false` in the menu list
      *   \]
    *   \]
  - `total` int32

    Total number of menus
  - `page` int32

    Current page number
  - `limit` int32

    Page size
  - `has_more` boolean

    Whether more pages exist

```json
{
  "code": "string",
  "message": "string",
  "data": {
    "menus": [
      {
        "id": "string",
        "title": "string",
        "category": 0,
        "children": [
          {
            "id": 0,
            "title": "string",
            "origin_type": 0,
            "type": "string",
            "source_id": "string",
            "url": "string",
            "pid": 0,
            "status": 0,
            "disabled": 0,
            "target": "string",
            "url_obj": {
              "type": "string",
              "source_id": "string",
              "url": "string",
              "title": "string"
            },
            "expanded": true
          }
        ]
      }
    ],
    "total": 0,
    "page": 0,
    "limit": 0,
    "has_more": true
  }
}
```
