第四部分:字段级调用详解Fields

每个方法列出请求体字段与响应体字段(名称/类型/含义)。类型基于 JVM 签名 + 启发式映射。

moment.v1.ChatService

CreateChatV2 unary

请求 CreateChatV2Request

字段类型含义
momentIdstring动态ID
chatTypemessage(ChatType?)chatType
chatTypeSubKeystringchatTypeSubKey
askKimiQuestionstringaskKimiQuestion

响应 CreateChatV2Response

字段类型含义
chatIdint32会话ID
_chatChatchat
chatTypemessage(ChatType?)chatType
chatTypeSubKeymessage(ChatTypeSubKey?)chatTypeSubKey

GetLastChatV2 unary

请求 GetLastChatV2Request

字段类型含义
momentIdstring动态ID
chatTypemessage(ChatType?)chatType
chatTypeSubKeyint32chatTypeSubKey

响应 GetLastChatV2Response

字段类型含义
chatIdint32会话ID
chatTypestringchatType
chatTypeSubKeymessage(ChatTypeSubKey?)chatTypeSubKey

ReChat stream

流式方法:响应为按行分隔的 JSON 事件流(含 heartbeat/done/chunk 等事件,用 eventOffset 续传),不能按普通 unary 调用。

请求 ReChatRequest momentId int32

响应 ReChatResponse chatId int32, _chat Chat, chatType, chatTypeSubKey

moment.v1.CommentService

CreateComment unary

请求 momentId int32, mentions string, links string

响应 _comment Comment

DeleteComment unary

请求 commentId string   响应无字段

ListComments unary

请求 momentId int32, _rootCommentId string, _pinnedCommentId string

响应 nextPageToken string, _pageStat PageStat, isLastPage bool, _pinnedCommentId string, comments repeated

moment.v1.MomentService

CreateMoment unary

请求 text string, visibility string, _artifactShareId string, images repeated, mentions repeated, links repeated, hashtagIds int32

响应 _moment Moment

DeleteMoment unary

请求 momentId string   响应无字段

GetChatShareCard unary

请求 chatShareId string   响应 _chatShareCard ChatShareCard

kimi.gateway.chat.v1.ChatService

BatchDeleteChats unary

请求 chatIds repeated   响应 chatIds int32

Chat stream

流式方法:响应为按行分隔的 JSON 事件流(含 heartbeat/done/chunk 等事件,用 eventOffset 续传)

请求 ChatRequest chatId int32, _message ChatMessage, _options string, _projectId string, tools string

响应 ChatResponse op, _mask, eventOffset int32, _chat Chat, _message ChatMessage, _block Block, _ref ChatFileRef, _usage Usage, _notification Notification, _done Done, _heartbeat Heartbeat, _tts, _interaction, _interactionAck

ListChats unary

请求 _projectId int32, _withMessageContent string, _includePinned string, pageSize string, pageToken bool

响应 nextPageToken string, chats repeated, pinnedChats repeated

ListMessages unary

请求 chatId int32, _direction string, _startMessageId int32, _includeStartMessage string, _endMessageId message(EndMessageId?), _includeEndMessage string, _noMarkAsRead bool

响应 nextPageToken string

RegenerateMessage unary

请求 chatId int32, _message Message, _scenario string, _options string, tools string