modelcontextprotocol / modelcontextprotocol/php-sdk

[Schema] No support for additonalProperties in tool input schema

Open Beginner friendly
#370 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
PHP
Stars
1.6k
Forks
173
Avg merge
2d 49m
Merged PRs (30d)
23

Description

Is your feature request related to a problem? Please describe.
There is no proper support for "strict" json schema mode in tool input schema due to not having 'additionalProperties' field.

Describe the solution you'd like
Support 'additionalProperties' in tool input schema same like in tool output schema.

Describe alternatives you've considered
Ignoring phpstan sealed array rule - makes code less reliable.

Additional context
This is sometimes needed when integrating mcp server with software that requires tool input/output schema to follow strict json schema (no additional properties allowed for example, all fields required etc). These sometimes refuse to work with tools whose schema isn't 'strict' enough.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the tool input schema definition and compare it with the existing tool output schema support for additionalProperties. Verify the resulting input schema against strict JSON Schema requirements and confirm that integrations accepting strict tool schemas now work as expected.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
api
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.