Skip to main content
Glama

strapi_create_tutorial

Create step-by-step tutorials in markdown format for Strapi CMS, including title, content, difficulty levels, and metadata for organized learning content.

Instructions

Create a new tutorial with step-by-step content in markdown

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
titleYesTutorial title
contentYesTutorial content in MARKDOWN format
descriptionNoShort description
difficultyNoDifficulty level
durationNoEstimated duration in minutes
author_idYesAuthor ID
category_idNoCategory ID
tag_idsNoArray of tag IDs
publishedAtNoPublication date (ISO 8601) or null for draft

Implementation Reference

  • The handler function that executes the tool logic by constructing a data payload from input arguments and making a POST request to Strapi's content-manager API endpoint for tutorials.
    async createTutorial (headers, args) {
      const data = {
        title: args.title,
        content: args.content,
        description: args.description,
        difficulty: args.difficulty,
        duration: args.duration,
        author: args.author_id,
        category: args.category_id,
        tags: args.tag_ids,
        publishedAt: args.publishedAt || null
      }
    
      const response = await axios.post(
        `${this.strapiUrl}/content-manager/collection-types/api::tutorial.tutorial`,
        data,
        { headers }
      )
    
      return {
        content: [{
          type: 'text',
          text: JSON.stringify(response.data, null, 2)
        }]
      }
    }
  • Input schema definition for the strapi_create_tutorial tool, specifying parameters, types, descriptions, and required fields.
    name: 'strapi_create_tutorial',
    description: 'Create a new tutorial with step-by-step content in markdown',
    inputSchema: {
      type: 'object',
      properties: {
        title: { type: 'string', description: 'Tutorial title' },
        content: { type: 'string', description: 'Tutorial content in MARKDOWN format' },
        description: { type: 'string', description: 'Short description' },
        difficulty: { type: 'string', enum: ['beginner', 'intermediate', 'advanced'], description: 'Difficulty level' },
        duration: { type: 'number', description: 'Estimated duration in minutes' },
        author_id: { type: 'number', description: 'Author ID' },
        category_id: { type: 'number', description: 'Category ID' },
        tag_ids: { type: 'array', items: { type: 'number' }, description: 'Array of tag IDs' },
        publishedAt: { type: 'string', description: 'Publication date (ISO 8601) or null for draft' }
      },
      required: ['title', 'content', 'author_id']
    }
  • index.js:390-391 (registration)
    Switch case in the CallToolRequest handler that dispatches to the createTutorial method for this tool.
    case 'strapi_create_tutorial':
      return await this.createTutorial(headers, request.params.arguments)

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/AINative-Studio/ainative-strapi-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server