Nimbu Developer Docs
ReferenceMenus

Create a menu

POST
/menus

Authorization

AuthorizationBearer <token>

Personal access token tied to a user account. Requires the X-Nimbu-Site header to scope requests.

In: header

X-Nimbu-Site<token>

Identifier of the site context when authenticating with a personal access token.

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/menus" \  -H "Content-Type: application/json" \  -d '{    "name": "string",    "slug": "string"  }'
{
  "id": "string",
  "url": "http://example.com",
  "created_at": "2019-08-24T14:15:22Z",
  "updated_at": "2019-08-24T14:15:22Z",
  "slug": "string",
  "name": "string",
  "items": [
    {
      "created_at": "2019-08-24T14:15:22Z",
      "updated_at": "2019-08-24T14:15:22Z",
      "kind": "string",
      "slug": "string",
      "fullpath": "string",
      "position": 0,
      "depth": 0,
      "name": "string",
      "target_url": "string",
      "target_page": "string",
      "target_fullpath": "string",
      "children": [
        {
          "created_at": "2019-08-24T14:15:22Z",
          "updated_at": "2019-08-24T14:15:22Z",
          "kind": "string",
          "slug": "string",
          "fullpath": "string",
          "position": 0,
          "depth": 0,
          "name": "string",
          "target_url": "string",
          "target_page": "string",
          "target_fullpath": "string",
          "children": []
        }
      ]
    }
  ]
}
Empty