MCPcopy Index your code
hub / github.com/coder/coder / GetChatPlanModeInstructions

Method GetChatPlanModeInstructions

codersdk/chats.go:2390–2401  ·  view source on GitHub ↗

GetChatPlanModeInstructions returns the deployment-wide plan mode instructions.

(ctx context.Context)

Source from the content-addressed store, hash-verified

2388
2389// GetChatPlanModeInstructions returns the deployment-wide plan mode instructions.
2390func (c *ExperimentalClient) GetChatPlanModeInstructions(ctx context.Context) (ChatPlanModeInstructionsResponse, error) {
2391 res, err := c.Request(ctx, http.MethodGet, "/api/experimental/chats/config/plan-mode-instructions", nil)
2392 if err != nil {
2393 return ChatPlanModeInstructionsResponse{}, err
2394 }
2395 defer res.Body.Close()
2396 if res.StatusCode != http.StatusOK {
2397 return ChatPlanModeInstructionsResponse{}, ReadBodyAsError(res)
2398 }
2399 var resp ChatPlanModeInstructionsResponse
2400 return resp, json.NewDecoder(res.Body).Decode(&resp)
2401}
2402
2403// UpdateChatPlanModeInstructions updates the deployment-wide plan mode instructions.
2404func (c *ExperimentalClient) UpdateChatPlanModeInstructions(ctx context.Context, req UpdateChatPlanModeInstructionsRequest) error {

Callers 1

Calls 3

ReadBodyAsErrorFunction · 0.85
CloseMethod · 0.65
RequestMethod · 0.45

Tested by 1