Package org.mcpjava.server.prompts
Interface PromptResponse.Builder
- All Superinterfaces:
MetaCarrier.Builder<PromptResponse.Builder>
- Enclosing interface:
PromptResponse
Builder for creating a prompt response
-
Method Summary
Modifier and TypeMethodDescriptionaddMessage(Role role, ContentBlock content) Add a message to the resultbuild()Builds the prompt responsesetDescription(String description) Set a description for the promptMethods inherited from interface org.mcpjava.server.MetaCarrier.Builder
putMetadata, setMetadata
-
Method Details
-
setDescription
Set a description for the prompt- Parameters:
description- the description- Returns:
- this builder
-
addMessage
Add a message to the result- Parameters:
role- the sender's rolecontent- the content of the message- Returns:
- this builder
-
build
PromptResponse build()Builds the prompt response- Returns:
- the new prompt response
-