Title: Laboratory WordPress Menus Rest API
Author: cardofearing
Published: <strong>30. November 2018</strong>
Last modified: 30. November 2018

---

Search plugins

This plugin **hasn’t been tested with the latest 3 major releases of WordPress**.
It may no longer be maintained or supported and may have compatibility issues when
used with more recent versions of WordPress.

![](https://s.w.org/plugins/geopattern-icon/laboratory-menu-rest-endpoints.svg)

# Laboratory WordPress Menus Rest API

 By [cardofearing](https://profiles.wordpress.org/ricardolabs/)

[Download](https://downloads.wordpress.org/plugin/laboratory-menu-rest-endpoints.zip)

 * [Details](https://de-ch.wordpress.org/plugins/laboratory-menu-rest-endpoints/#description)
 * [Reviews](https://de-ch.wordpress.org/plugins/laboratory-menu-rest-endpoints/#reviews)
 *  [Installation](https://de-ch.wordpress.org/plugins/laboratory-menu-rest-endpoints/#installation)
 * [Development](https://de-ch.wordpress.org/plugins/laboratory-menu-rest-endpoints/#developers)

 [Support](https://wordpress.org/support/plugin/laboratory-menu-rest-endpoints/)

## Description

Laboratory WordPress Menus Rest API

Generate API Endpoints for WordPress menus.

### Available Endpoints

#### Get Menu Items Endpoint: `/wp-json/lab-menus/v1/menu/{menu(string | int)}`

**Params:**

 * menu – Either the slug (string) or ID (int) of a menu **e.g.**
    - `http://example.com/wp-json/lab-menus/v1/menu/main-menu`
    - `http://example.com/wp-json/lab-menus/v1/menu/2`

**Return: Array of menu item objects, otherwise false.**

    ```
    [{
      "ID": 48,
      "menu_item_parent": "0",
      "object_id": "46",
      "object": "page",
      "type": "post_type",
      "type_label": "Page",
      "url": "http:\/\/localhost:8888\/example\/test\/",
      "title": "Academics",
      "target": "",
      "attr_title": "",
      "description": "",
      "classes": [""],
      // Rest of the details...,
    }]
    ```

#### Get Available Menus Endpoint: `/wp-json/lab-menus/v1/menu-options`

**e.g.** `http://example.com/wp-json/lab-menus/v1/menu-options`

**Return: Array of available menus objects.**

    ```
    [{
     "term_id": 3,
      "name": "Example Navigation",
      "slug": "example-navigation",
      "term_group": 0,
      "term_taxonomy_id": 3,
      "taxonomy": "nav_menu",
      "description": "",
      "parent": 0,
      "count": 6,
      "filter": "raw"
    }]
    ```

#### Get Registered Menu Locations Endpoint: `/wp-json/lab-menus/v1/menu-locations`

**e.g.** `http://example.com/wp-json/lab-menus/v1/menu-locations`

**Return: (Associative Array) Array of menus registered by the theme.**

    ```
    [
      "example-nav": 3,
      "main-navigation": 2,
      "footer-nav": 4
    ]
    ```

## Installation

This plugin can be installed directly from your site.

 * Log in and navigate to Plugins  Add New.
 * Type “Laboratory WordPress Menus Rest API” into the Search and hit Enter.
 * Locate the Laboratory WordPress Menus Rest API plugin in the list of search results
   and click Install Now.
 * Once installed, click the Activate link.
 * Your endpoints will automatically be available.

It can also be installed manually.

 * Download the Laboratory WordPress Menus Rest API plugin from WordPress.org.
 * Unzip the package and move to your plugins directory.
 * Log into WordPress and navigate to the Plugins screen.
 * Locate Laboratory WordPress Menus Rest API in the list and click the Activate
   link.

## Reviews

There are no reviews for this plugin.

## Contributors & Developers

“Laboratory WordPress Menus Rest API” is open source software. The following people
have contributed to this plugin.

Contributors

 *   [ cardofearing ](https://profiles.wordpress.org/ricardolabs/)

[Translate “Laboratory WordPress Menus Rest API” into your language.](https://translate.wordpress.org/projects/wp-plugins/laboratory-menu-rest-endpoints)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/laboratory-menu-rest-endpoints/),
check out the [SVN repository](https://plugins.svn.wordpress.org/laboratory-menu-rest-endpoints/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/laboratory-menu-rest-endpoints/)
by [RSS](https://plugins.trac.wordpress.org/log/laboratory-menu-rest-endpoints/?limit=100&mode=stop_on_copy&format=rss).

## Meta

 *  Version **1.0.0**
 *  Last updated **8 Jahren ago**
 *  Active installations **Fewer than 10**
 *  WordPress version ** 4.7.1 or higher **
 *  Tested up to **4.9.33**
 *  PHP version ** 7.2 or higher **
 *  Language
 * [English (US)](https://wordpress.org/plugins/laboratory-menu-rest-endpoints/)
 * Tags
 * [api](https://de-ch.wordpress.org/plugins/tags/api/)[menus](https://de-ch.wordpress.org/plugins/tags/menus/)
 *  [Advanced View](https://de-ch.wordpress.org/plugins/laboratory-menu-rest-endpoints/advanced/)

## Ratings

Es wurden noch keine Rezensionen eingereicht.

[Your review](https://wordpress.org/support/plugin/laboratory-menu-rest-endpoints/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/laboratory-menu-rest-endpoints/reviews/)

## Contributors

 *   [ cardofearing ](https://profiles.wordpress.org/ricardolabs/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/laboratory-menu-rest-endpoints/)

## Donate

Would you like to support the advancement of this plugin?

 [ Donate to this plugin ](https://chiedolabs.com)