Package com.github.copilot.sdk.json
Class UserPromptSubmittedHookOutput
java.lang.Object
com.github.copilot.sdk.json.UserPromptSubmittedHookOutput
Output for a user-prompt-submitted hook.
Allows modifying the user's prompt before processing.
- Since:
- 1.0.7
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the additional context to add.Gets the modified prompt.Gets whether output should be suppressed.setAdditionalContext(String additionalContext) Sets additional context to be added to the prompt.setModifiedPrompt(String modifiedPrompt) Sets a modified version of the user's prompt.setSuppressOutput(Boolean suppressOutput) Sets whether to suppress the output.
-
Constructor Details
-
UserPromptSubmittedHookOutput
public UserPromptSubmittedHookOutput()
-
-
Method Details
-
getModifiedPrompt
Gets the modified prompt.- Returns:
- the modified prompt, or
nullto use the original
-
setModifiedPrompt
Sets a modified version of the user's prompt.- Parameters:
modifiedPrompt- the modified prompt to use instead of the original- Returns:
- this instance for method chaining
-
getAdditionalContext
Gets the additional context to add.- Returns:
- the additional context, or
null
-
setAdditionalContext
Sets additional context to be added to the prompt.- Parameters:
additionalContext- the additional context- Returns:
- this instance for method chaining
-
getSuppressOutput
Gets whether output should be suppressed.- Returns:
trueto suppress output, ornull
-
setSuppressOutput
Sets whether to suppress the output.- Parameters:
suppressOutput-trueto suppress output- Returns:
- this instance for method chaining
-