Skip to content

[BUG] Endpoints with Form Params not handled correctly #119

Open
@davidschwab98

Description

@davidschwab98

Describe the bug

Currently fastapi_mcp doesn't correctly handles endpoints with form paramers. The reason for this is that in the _request method of the FastApiMCP class, all parameters are passed as the json argument, wich leads to a 422 return (should be the body param instead).

To Reproduce
Create an enpoint with form parameters.

System Info
Python 3.13, latest versions of FastAPI and fastapi_mcp

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions