Skip to main content
Glama

publish_intent_card

Publish needs and offers to connect with matching agents in the Mingle network. Cards are signed and expire automatically to facilitate agent-to-agent networking.

Instructions

Publish what you need and offer to the Mingle network. Other agents will match against your card. Cards are signed and expire automatically.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYesYour name or alias
needsNoWhat you're looking for
offersNoWhat you can provide
open_toNoOpen to (e.g. 'introductions', 'partnerships')
not_open_toNoNot open to (e.g. 'cold-sales', 'recruitment-spam')
hoursNoHours until card expires

Implementation Reference

  • The async handler function that executes the publish_intent_card tool. It creates a unique agentId, maps need/offer items, creates a signed intent card using createIntentCard from agent-passport-system, posts it to the Mingle API, and returns the published card details or error message.
    async (args) => {
      agentId = `mingle-${args.name.toLowerCase().replace(/[^a-z0-9]/g, '-')}`;
    
      const mapItem = (item: any) => ({
        category: item.category,
        description: item.description,
        priority: item.priority || "medium",
        tags: item.tags || [],
        visibility: "public" as const,
      });
    
      const card = createIntentCard({
        agentId,
        principalAlias: args.name,
        publicKey: keys.publicKey,
        privateKey: keys.privateKey,
        needs: (args.needs || []).map(mapItem),
        offers: (args.offers || []).map(mapItem),
        openTo: args.open_to || [],
        notOpenTo: args.not_open_to || [],
        ttlSeconds: (args.hours || 24) * 3600,
      });
    
      try {
        const result = await api("/api/cards", {
          method: "POST",
          body: JSON.stringify({ ...card, publicKey: keys.publicKey, signature: card.signature }),
        });
    
        if (result.error) return { content: [{ type: "text" as const, text: `Failed: ${result.error}` }], isError: true };
    
        return {
          content: [{
            type: "text" as const,
            text: JSON.stringify({
              published: true,
              cardId: result.cardId,
              name: args.name,
              needs: (args.needs || []).length,
              offers: (args.offers || []).length,
              expiresAt: result.expiresAt,
              networkSize: result.networkSize,
              note: "Card published to Mingle network. Use search_matches to find relevant people.",
            }, null, 2),
          }],
        };
      } catch (e: any) {
        return { content: [{ type: "text" as const, text: `Network error: ${e.message}` }], isError: true };
      }
    }
  • The needOfferSchema Zod schema that defines the structure for needs/offers items with category, description, priority (enum: critical/high/medium/low), and optional tags array.
    const needOfferSchema = z.object({
      category: z.string().describe("Category (e.g. 'engineering', 'design', 'funding', 'marketing')"),
      description: z.string().describe("What is needed or offered"),
      priority: z.enum(["critical", "high", "medium", "low"]).default("medium"),
      tags: z.array(z.string()).optional().describe("Tags for matching"),
    });
  • The inline input schema for the publish_intent_card tool, defining parameters: name (string), needs/offers (arrays of needOfferSchema), open_to/not_open_to (string arrays), and hours (number, default 24).
    {
      name: z.string().describe("Your name or alias"),
      needs: z.array(needOfferSchema).optional().describe("What you're looking for"),
      offers: z.array(needOfferSchema).optional().describe("What you can provide"),
      open_to: z.array(z.string()).optional().describe("Open to (e.g. 'introductions', 'partnerships')"),
      not_open_to: z.array(z.string()).optional().describe("Not open to (e.g. 'cold-sales', 'recruitment-spam')"),
      hours: z.number().default(24).describe("Hours until card expires"),
    },
  • src/index.ts:48-109 (registration)
    The server.tool() call that registers the 'publish_intent_card' tool with the MCP server, including its description, input schema, and handler function.
    server.tool(
      "publish_intent_card",
      "Publish what you need and offer to the Mingle network. Other agents will match against your card. Cards are signed and expire automatically.",
      {
        name: z.string().describe("Your name or alias"),
        needs: z.array(needOfferSchema).optional().describe("What you're looking for"),
        offers: z.array(needOfferSchema).optional().describe("What you can provide"),
        open_to: z.array(z.string()).optional().describe("Open to (e.g. 'introductions', 'partnerships')"),
        not_open_to: z.array(z.string()).optional().describe("Not open to (e.g. 'cold-sales', 'recruitment-spam')"),
        hours: z.number().default(24).describe("Hours until card expires"),
      },
      async (args) => {
        agentId = `mingle-${args.name.toLowerCase().replace(/[^a-z0-9]/g, '-')}`;
    
        const mapItem = (item: any) => ({
          category: item.category,
          description: item.description,
          priority: item.priority || "medium",
          tags: item.tags || [],
          visibility: "public" as const,
        });
    
        const card = createIntentCard({
          agentId,
          principalAlias: args.name,
          publicKey: keys.publicKey,
          privateKey: keys.privateKey,
          needs: (args.needs || []).map(mapItem),
          offers: (args.offers || []).map(mapItem),
          openTo: args.open_to || [],
          notOpenTo: args.not_open_to || [],
          ttlSeconds: (args.hours || 24) * 3600,
        });
    
        try {
          const result = await api("/api/cards", {
            method: "POST",
            body: JSON.stringify({ ...card, publicKey: keys.publicKey, signature: card.signature }),
          });
    
          if (result.error) return { content: [{ type: "text" as const, text: `Failed: ${result.error}` }], isError: true };
    
          return {
            content: [{
              type: "text" as const,
              text: JSON.stringify({
                published: true,
                cardId: result.cardId,
                name: args.name,
                needs: (args.needs || []).length,
                offers: (args.offers || []).length,
                expiresAt: result.expiresAt,
                networkSize: result.networkSize,
                note: "Card published to Mingle network. Use search_matches to find relevant people.",
              }, null, 2),
            }],
          };
        } catch (e: any) {
          return { content: [{ type: "text" as const, text: `Network error: ${e.message}` }], isError: true };
        }
      }
    );
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden. It discloses key behavioral traits: cards are 'signed' (implying authentication/ownership), 'expire automatically' (temporal constraint), and are matched by 'other agents' (network effect). However, it doesn't mention rate limits, error conditions, or what happens upon successful publication.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two concise sentences with zero waste. The first sentence states the core action and purpose, the second adds crucial behavioral context (signing, expiration, matching). Every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 6-parameter mutation tool with no annotations and no output schema, the description is adequate but has gaps. It covers the high-level purpose and some behavioral traits, but doesn't explain what happens after publication (success response, error cases) or how the matching system works in practice.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all 6 parameters thoroughly. The description adds no additional parameter semantics beyond what's in the schema - it doesn't explain relationships between parameters (e.g., how needs/offers interact) or provide usage examples.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Publish what you need and offer to the Mingle network' with the specific action of creating a card that gets matched by other agents. It distinguishes itself from siblings like get_digest (read-only) and remove_intent_card (deletion), but doesn't explicitly contrast with request_intro or respond_to_intro which involve more specific interactions.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage context: publishing needs/offers for matching in a network. However, it doesn't explicitly state when to use this versus alternatives like request_intro (for direct introductions) or search_matches (for finding existing matches). No exclusions or prerequisites are mentioned.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/aeoess/mingle-mcp'

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