AS AgentScopeAPI 手册 / API Reference

AguiRequestBodyParser

public class AguiRequestBodyParser
源码Source io/agentscope/core/agui/runtime/AguiRequestBodyParser.java:33–45

AGUI 请求正文解析器,在智能体、模型与前端之间传递结构化消息和事件。位于 io.agentscope.core.agui.runtime 包。核心成员包括 parse。

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.

方法摘要Method Summary

方法Method说明Description
public RunAgentInput parse(String body)
设置解析。
Parses a JSON request body into `RunAgentInput`.

方法详情Method Detail

parse

public RunAgentInput parse(String body)

设置解析。

Parses a JSON request body into RunAgentInput.

参数Parameters
名称Name类型Type说明Description
bodyString原始 JSON 请求正文。the raw JSON request body
返回Returns RunAgentInput
已解析 AG-UI 输入。the parsed AG-UI input
源码Source io/agentscope/core/agui/runtime/AguiRequestBodyParser.java:41–44
基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.