Create a markdown library item Experimental; added in 9.6.0

POST /api/markdowns

Spaces method and path for this operation:

post /s/{space_id}/api/markdowns

Refer to Spaces for more information.

Creates a new markdown library item and returns its ID, full state, and metadata.

Headers

  • kbn-xsrf string Required

    A required header to protect against CSRF attacks

application/json

Body

  • content string Required

    The Markdown text rendered by the panel. Supports GitHub-flavored Markdown, including headings, paragraphs, lists, links, images, tables, blockquotes, and code blocks. Use \n for line breaks within JSON strings.

  • description string

    A short description of the markdown library item.

  • settings object

    Display settings for the markdown panel.

    Default value is {"open_links_in_new_tab" => true}. Additional properties are NOT allowed.

    Hide settings attribute Show settings attribute object
    • open_links_in_new_tab boolean

      Open links in a new browser tab.

      Default value is true.

  • title string Required

    The markdown library item title.

    Minimum length is 1.

Responses

  • 201 application/json

    created

    Hide response attributes Show response attributes object
    • data object Required

      Additional properties are NOT allowed.

      Hide data attributes Show data attributes object
      • content string Required

        The Markdown text rendered by the panel. Supports GitHub-flavored Markdown, including headings, paragraphs, lists, links, images, tables, blockquotes, and code blocks. Use \n for line breaks within JSON strings.

      • description string

        A short description of the markdown library item.

      • settings object

        Display settings for the markdown panel.

        Default value is {"open_links_in_new_tab" => true}. Additional properties are NOT allowed.

        Hide settings attribute Show settings attribute object
        • open_links_in_new_tab boolean

          Open links in a new browser tab.

          Default value is true.

      • title string Required

        The markdown library item title.

        Minimum length is 1.

    • id string Required

      The unique ID of the markdown library item, as returned by the create or search endpoints.

    • meta object Required

      Additional properties are NOT allowed.

      Hide meta attributes Show meta attributes object
      • created_at string

        Timestamp when the object was created (ISO 8601).

      • created_by string

        User profile ID of the user who created the object.

      • managed boolean

        When true, the object is managed by Kibana and cannot be edited by users.

      • owner string

        Identifier of the plugin or team that owns this object.

      • updated_at string

        Timestamp when the object was last updated (ISO 8601).

      • updated_by string

        User profile ID of the user who last updated the object.

      • version string

        Internal version identifier for optimistic concurrency control.

  • 400

    invalid request

  • 403

    forbidden

POST /api/markdowns
curl -X POST "${KIBANA_URL}/api/markdowns" \
  -H "Authorization: ApiKey ${API_KEY}" \
  -H "kbn-xsrf: true" \
  -H "Content-Type: application/json" \
  -d '{
  "title": "Web logs overview",
  "description": "Intro and context for the web logs dashboard.",
  "content": "## Web logs overview\n\nA quick reference for the **Kibana sample web logs** dataset (`kibana_sample_data_logs`).\n\n**Key metrics in this dashboard:**\n\n- Total request count by HTTP method\n- Average response size over time\n- Geographic distribution of client IPs\n\n> Use the time picker above to narrow the dashboard to an incident window.\n\nFor field reference, see the [sample data documentation](https://www.elastic.co/docs/manage-data/ingest/sample-data).\n",
  "settings": {
    "open_links_in_new_tab": true
  }
}'
POST kbn:/api/markdowns
{
  "title": "Web logs overview",
  "description": "Intro and context for the web logs dashboard.",
  "content": "## Web logs overview\n\nA quick reference for the **Kibana sample web logs** dataset (`kibana_sample_data_logs`).\n\n**Key metrics in this dashboard:**\n\n- Total request count by HTTP method\n- Average response size over time\n- Geographic distribution of client IPs\n\n> Use the time picker above to narrow the dashboard to an incident window.\n\nFor field reference, see the [sample data documentation](https://www.elastic.co/docs/manage-data/ingest/sample-data).\n",
  "settings": {
    "open_links_in_new_tab": true
  }
}
Request example
{
  "content": "## Web logs overview\n\nA quick reference for the **Kibana sample web logs** dataset (`kibana_sample_data_logs`).\n\n**Key metrics in this dashboard:**\n\n- Total request count by HTTP method\n- Average response size over time\n- Geographic distribution of client IPs\n\n> Use the time picker above to narrow the dashboard to an incident window.\n\nFor field reference, see the [sample data documentation](https://www.elastic.co/docs/manage-data/ingest/sample-data).\n",
  "description": "Intro and context for the web logs dashboard.",
  "settings": {
    "open_links_in_new_tab": true
  },
  "title": "Web logs overview"
}
Response examples (201)
Response to creating a markdown library item. Returns the generated ID, the full item state in `data`, and metadata.
{
  "data": {
    "content": "## Web logs overview\n\nA quick reference for the **Kibana sample web logs** dataset (`kibana_sample_data_logs`).\n\n**Key metrics in this dashboard:**\n\n- Total request count by HTTP method\n- Average response size over time\n- Geographic distribution of client IPs\n\n> Use the time picker above to narrow the dashboard to an incident window.\n\nFor field reference, see the [sample data documentation](https://www.elastic.co/docs/manage-data/ingest/sample-data).\n",
    "description": "Intro and context for the web logs dashboard.",
    "settings": {
      "open_links_in_new_tab": true
    },
    "title": "Web logs overview"
  },
  "id": "5e1f3a20-c4d6-11ef-be8b-3c7c2b9d1f4e",
  "meta": {
    "created_at": "2026-04-13T10:00:00.000Z",
    "managed": false,
    "updated_at": "2026-04-13T10:00:00.000Z",
    "version": "WzU5LDFd"
  }
}