diff --git a/api/openapi.json b/api/openapi.json index c5a1a365..64b9d791 100644 --- a/api/openapi.json +++ b/api/openapi.json @@ -408,6 +408,128 @@ } } } + }, + "/api/v1/workspaces/{workspace_name}/system-prompt": { + "get": { + "tags": [ + "CodeGate API", + "Workspaces" + ], + "summary": "Get Workspace System Prompt", + "description": "Get the system prompt for a workspace.", + "operationId": "v1_get_workspace_system_prompt", + "parameters": [ + { + "name": "workspace_name", + "in": "path", + "required": true, + "schema": { + "type": "string", + "title": "Workspace Name" + } + } + ], + "responses": { + "200": { + "description": "Successful Response", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SystemPrompt" + } + } + } + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + } + }, + "put": { + "tags": [ + "CodeGate API", + "Workspaces" + ], + "summary": "Set Workspace System Prompt", + "operationId": "v1_set_workspace_system_prompt", + "parameters": [ + { + "name": "workspace_name", + "in": "path", + "required": true, + "schema": { + "type": "string", + "title": "Workspace Name" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/SystemPrompt" + } + } + } + }, + "responses": { + "204": { + "description": "Successful Response" + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + } + }, + "delete": { + "tags": [ + "CodeGate API", + "Workspaces" + ], + "summary": "Delete Workspace System Prompt", + "operationId": "v1_delete_workspace_system_prompt", + "parameters": [ + { + "name": "workspace_name", + "in": "path", + "required": true, + "schema": { + "type": "string", + "title": "Workspace Name" + } + } + ], + "responses": { + "204": { + "description": "Successful Response" + }, + "422": { + "description": "Validation Error", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/HTTPValidationError" + } + } + } + } + } + } } }, "components": { @@ -710,6 +832,19 @@ "title": "QuestionAnswer", "description": "Represents a question and answer pair." }, + "SystemPrompt": { + "properties": { + "prompt": { + "type": "string", + "title": "Prompt" + } + }, + "type": "object", + "required": [ + "prompt" + ], + "title": "SystemPrompt" + }, "ValidationError": { "properties": { "loc": {