Class AguiRequestBodyParser

java.lang.Object
io.agentscope.core.agui.runtime.AguiRequestBodyParser

public class AguiRequestBodyParser extends Object
Parses AG-UI request bodies with AgentScope's JSON codec.

The default AgentScope codec is Jackson 2. Keeping this conversion at the AG-UI boundary avoids selecting Spring Boot 4's Jackson 3 codec for AG-UI's Jackson 2-annotated models, while leaving the application's other HTTP converters unchanged.

The Spring Boot starter exposes this type as a bean and provides a default instance via @ConditionalOnMissingBean. Applications can register their own AguiRequestBodyParser bean to customize request body conversion.

  • Constructor Details

    • AguiRequestBodyParser

      public AguiRequestBodyParser()
  • Method Details

    • parse

      public RunAgentInput parse(String body)
      Parses a JSON request body into RunAgentInput.
      Parameters:
      body - the raw JSON request body
      Returns:
      the parsed AG-UI input