Skip to main content

PKU370: Missing Title Property

Error Message

[PKU370] MCP resource '[uri]' is missing the required 'title' property.

What Went Wrong

Your MCP resource is missing the required title property. Unlike tools and prompts which use name, resources require both a uri for identification and a title for display.

How to Fix

Add a title property to your MCP resource:

import { addMCPResource } from '@pikku/core/mcp'
import { pikkuFunc } from '#pikku'

addMCPResource({
uri: 'file:///config/database',
title: 'Database Configuration', // ✅ Add this
description: 'Current database connection settings',
func: pikkuFunc(async () => {
return {
content: JSON.stringify({ host: 'localhost', port: 5432 }),
}
}),
})

Title vs Name vs URI

MCP endpoints use different identification properties:

TypeIdentifierDisplay Name
Toolnamename
Promptnamename
Resourceurititle

Resources are unique because they:

  • Use uri for technical identification
  • Use title for human-readable display
  • Require both properties

Best Practices

  • Use clear, descriptive titles
  • Keep titles concise but informative
  • Use title case (e.g., "User Profile Settings")
  • Avoid redundancy between title and description
  • PKU111 - Missing Name (for tools/prompts)
  • PKU123 - Missing Description
  • PKU220 - Missing URI