Skip to main content
Glama

generate_carousel

Create LinkedIn and Instagram carousel slides for educational, storytelling, or data-driven content. Specify topic, slide count, and style to generate structured visual posts.

Instructions

Generate LinkedIn/Instagram carousel slides with title + body per slide. Supports educational, storytelling, and data-driven styles.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
topicYesCarousel topic
slides_countNoNumber of slides (3-10)
styleNoCarousel style: educational (step-by-step), storytelling (narrative), data (stats & numbers)educational

Implementation Reference

  • The `generateCarousel` function implements the logic for creating carousel content based on a topic, slide count, and style (educational, storytelling, or data).
    function generateCarousel(
      topic: string,
      slidesCount: number,
      style: "educational" | "storytelling" | "data",
    ): CarouselSlide[] {
      const slides: CarouselSlide[] = [];
    
      if (style === "educational") {
        slides.push({ slide_number: 1, title: topic, body: "Ce que tu dois savoir\n(Swipe pour decouvrir)" });
        const educationalContent = [
          { title: "Le probleme", body: `La plupart des entrepreneurs subissent ${topic} en silence.\nIls pensent que c'est le prix du succes.` },
          { title: "Pourquoi c'est grave", body: "Sans action, les consequences s'aggravent :\n- Sante physique\n- Relations\n- Performance business" },
          { title: "La solution existe", body: "En 3 etapes simples :\n1. Conscience\n2. Routine protectrice\n3. Accompagnement" },
          { title: "Etape 1 : Conscience", body: "Identifie tes signaux d'alerte.\nFatigue ? Irritabilite ? Insomnie ?\nNote-les pendant 7 jours." },
          { title: "Etape 2 : Routine", body: "10 minutes par jour suffisent.\nRespiration, gratitude, deconnexion.\nLe plus dur c'est de commencer." },
          { title: "Etape 3 : Accompagnement", body: "Tu n'as pas a tout porter seul.\nUn coach, un pair, un groupe.\nDemander de l'aide = force." },
          { title: "Les resultats", body: "Apres 30 jours :\n- Sommeil retrouve\n- Energie stable\n- Clarte mentale\n- Business qui tourne mieux" },
          { title: "A toi de jouer", body: "Fais le premier pas :\nTest burnout gratuit (2 min)\nstresszeroentrepreneur.fr/test-burnout" },
        ];
        const count = Math.min(slidesCount - 2, educationalContent.length);
        for (let i = 0; i < count; i++) {
          slides.push({ slide_number: i + 2, ...educationalContent[i] });
        }
        slides.push({
          slide_number: slides.length + 1,
          title: "Passe a l'action",
          body: `Teste ton niveau de burnout\nstresszeroentrepreneur.fr/test-burnout\n\n${BRAND.identity}`,
        });
      } else if (style === "storytelling") {
        slides.push({ slide_number: 1, title: topic, body: "L'histoire d'un entrepreneur\nqui a failli tout perdre" });
        const storyContent = [
          { title: "Le debut", body: "Il avait tout pour reussir.\nUn business qui cartonne.\nDes clients.\nDe l'ambition." },
          { title: "Les premiers signes", body: "Mais petit a petit...\nLes nuits raccourcissent.\nL'irritabilite monte.\nLe plaisir disparait." },
          { title: "Le deni", body: "\"C'est normal, c'est le prix a payer.\"\nIl se repetait ca chaque jour.\nPendant 18 mois." },
          { title: "La chute", body: "Un matin, il n'a pas pu se lever.\nLe corps a dit STOP.\nCe que l'esprit refusait d'entendre." },
          { title: "Le tournant", body: "Il a demande de l'aide.\nPas une faiblesse.\nLa decision la plus courageuse de sa vie." },
          { title: "La reconstruction", body: "Nouvelles routines. Nouvel equilibre.\nEn 90 jours, tout a change.\nSon business aussi." },
          { title: "Aujourd'hui", body: "Il performe MIEUX qu'avant.\nMais sans se detruire.\nLa preuve qu'un autre modele existe." },
        ];
        const count = Math.min(slidesCount - 2, storyContent.length);
        for (let i = 0; i < count; i++) {
          slides.push({ slide_number: i + 2, ...storyContent[i] });
        }
        slides.push({
          slide_number: slides.length + 1,
          title: "Et toi ?",
          body: `N'attends pas la chute.\nFais le point maintenant.\n\nstresszeroentrepreneur.fr/test-burnout`,
        });
      } else {
        // data
        slides.push({ slide_number: 1, title: topic, body: "Les chiffres qui devraient t'alerter\n(Swipe pour voir)" });
        const dataContent = [
          { title: "1 sur 3", body: "1 entrepreneur sur 3 est en situation de burnout.\nSource : Etude INSERM 2024" },
          { title: "x2.5", body: "Les entrepreneurs ont 2.5x plus de risque de burnout que les salaries." },
          { title: "63%", body: "63% des entrepreneurs ont deja eu des symptomes de burnout.\nSans le savoir." },
          { title: "18 mois", body: "Duree moyenne avant diagnostic.\n18 mois de souffrance evitable." },
          { title: "-40%", body: "Impact sur la productivite.\nLe burnout ne fait pas que te detruire.\nIl detruit ton business." },
          { title: "90 jours", body: "C'est le temps moyen pour retrouver l'equilibre.\nAvec un accompagnement adapte." },
          { title: "92%", body: "Des entrepreneurs accompagnes retrouvent un niveau d'energie satisfaisant en 3 mois." },
        ];
        const count = Math.min(slidesCount - 2, dataContent.length);
        for (let i = 0; i < count; i++) {
          slides.push({ slide_number: i + 2, ...dataContent[i] });
        }
        slides.push({
          slide_number: slides.length + 1,
          title: "Agis maintenant",
          body: `Test burnout gratuit (2 min)\nstresszeroentrepreneur.fr/test-burnout\n\n${BRAND.identity}`,
        });
      }
    
      // Ensure we have exactly the right number of slides
      return slides.slice(0, slidesCount);
    }
  • src/index.ts:845-880 (registration)
    The `generate_carousel` tool is registered using `server.registerTool`. It invokes the `generateCarousel` function and formats the output for the MCP client.
    server.registerTool(
      "generate_carousel",
      {
        title: "Generate Carousel Slides",
        description:
          "Generate LinkedIn/Instagram carousel slides with title + body per slide. " +
          "Supports educational, storytelling, and data-driven styles.",
        inputSchema: {
          topic: z.string().describe("Carousel topic"),
          slides_count: z.number().min(3).max(10).default(6).describe("Number of slides (3-10)"),
          style: z.enum(["educational", "storytelling", "data"]).default("educational").describe(
            "Carousel style: educational (step-by-step), storytelling (narrative), data (stats & numbers)",
          ),
        },
        annotations: { readOnlyHint: true, openWorldHint: false, destructiveHint: false },
      },
      async ({ topic, slides_count, style }) => {
        const slides = generateCarousel(topic, slides_count, style);
    
        const output = [
          `--- CAROUSEL ${style.toUpperCase()} (${slides.length} slides) ---`,
          `Sujet: ${topic}`,
          "",
        ];
    
        slides.forEach((slide) => {
          output.push(`=== Slide ${slide.slide_number} ===`);
          output.push(`TITRE: ${slide.title}`);
          output.push(`CONTENU:\n${slide.body}`);
          output.push("");
        });
    
        output.push(`--- ${slides.length} slides generees | Style: ${style} ---`);
        output.push(`Identite: ${BRAND.identity}`);
    
        return {

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/gomessoaresemmanuel-cpu/content-distribution-mcp'

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