cline 1.0.0-nightly.6 → 1.0.0-nightly.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,189 @@
1
+ syntax = "proto3";
2
+
3
+ package cline;
4
+ import "cline/common.proto";
5
+ option go_package = "github.com/cline/grpc-go/cline";
6
+ option java_package = "bot.cline.proto";
7
+ option java_multiple_files = true;
8
+
9
+ // Service for file-related operations
10
+ service FileService {
11
+ // Copies text to clipboard
12
+ rpc copyToClipboard(StringRequest) returns (Empty);
13
+
14
+ // Opens a file in the editor
15
+ rpc openFile(StringRequest) returns (Empty);
16
+
17
+ // Opens an image in the system viewer
18
+ rpc openImage(StringRequest) returns (Empty);
19
+
20
+ // Opens a mention (file, path, git commit, problem, terminal, or URL)
21
+ rpc openMention(StringRequest) returns (Empty);
22
+
23
+ // Deletes a rule file from either global or workspace rules directory
24
+ rpc deleteRuleFile(RuleFileRequest) returns (RuleFile);
25
+
26
+ // Creates a rule file from either global or workspace rules directory
27
+ rpc createRuleFile(RuleFileRequest) returns (RuleFile);
28
+
29
+ // Search git commits in the workspace
30
+ rpc searchCommits(StringRequest) returns (GitCommits);
31
+
32
+ // Select images and other files from the file system and returns as data URLs & paths respectively
33
+ rpc selectFiles(BooleanRequest) returns (StringArrays);
34
+
35
+ // Convert URIs to workspace-relative paths
36
+ rpc getRelativePaths(RelativePathsRequest) returns (RelativePaths);
37
+
38
+ // Search for files in the workspace with fuzzy matching
39
+ rpc searchFiles(FileSearchRequest) returns (FileSearchResults);
40
+
41
+ // Toggle a Cline rule (enable or disable)
42
+ rpc toggleClineRule(ToggleClineRuleRequest) returns (ToggleClineRules);
43
+
44
+ // Toggle a Cursor rule (enable or disable)
45
+ rpc toggleCursorRule(ToggleCursorRuleRequest) returns (ClineRulesToggles);
46
+
47
+ // Toggle a Windsurf rule (enable or disable)
48
+ rpc toggleWindsurfRule(ToggleWindsurfRuleRequest) returns (ClineRulesToggles);
49
+
50
+ // Refreshes all rule toggles (Cline, External, and Workflows)
51
+ rpc refreshRules(EmptyRequest) returns (RefreshedRules);
52
+
53
+ // Opens a task's conversation history file on disk
54
+ rpc openDiskConversationHistory(StringRequest) returns (Empty);
55
+
56
+ // Toggles a workflow on or off
57
+ rpc toggleWorkflow(ToggleWorkflowRequest) returns (ClineRulesToggles);
58
+
59
+ // Check if file exists in the project
60
+ rpc ifFileExistsRelativePath(StringRequest) returns (BooleanResponse);
61
+
62
+ // Open a file in editor by a relative path
63
+ rpc openFileRelativePath(StringRequest) returns (Empty);
64
+
65
+ // Opens or creates a focus chain checklist markdown file for editing
66
+ rpc openFocusChainFile(StringRequest) returns (Empty);
67
+ }
68
+
69
+ // Response for refreshRules operation
70
+ message RefreshedRules {
71
+ ClineRulesToggles global_cline_rules_toggles = 1;
72
+ ClineRulesToggles local_cline_rules_toggles = 2;
73
+ ClineRulesToggles local_cursor_rules_toggles = 3;
74
+ ClineRulesToggles local_windsurf_rules_toggles = 4;
75
+ ClineRulesToggles local_workflow_toggles = 5;
76
+ ClineRulesToggles global_workflow_toggles = 6;
77
+ }
78
+
79
+ // Request to toggle a Windsurf rule
80
+ message ToggleWindsurfRuleRequest {
81
+ Metadata metadata = 1;
82
+ string rule_path = 2; // Path to the rule file
83
+ bool enabled = 3; // Whether to enable or disable the rule
84
+ }
85
+
86
+ // Request to convert a list of URIs to relative paths
87
+ message RelativePathsRequest {
88
+ Metadata metadata = 1;
89
+ repeated string uris = 2;
90
+ }
91
+
92
+ // Response containing the converted relative paths
93
+ message RelativePaths {
94
+ repeated string paths = 1;
95
+ }
96
+
97
+ // Enum for file search type filtering
98
+ enum FileSearchType {
99
+ FILE = 0;
100
+ FOLDER = 1;
101
+ }
102
+
103
+ // Request for file search operations
104
+ message FileSearchRequest {
105
+ Metadata metadata = 1;
106
+ string query = 2; // Search query string
107
+ optional string mentions_request_id = 3; // Optional request ID for tracking requests
108
+ optional int32 limit = 4; // Optional limit for results (default: 20)
109
+ optional FileSearchType selected_type = 5; // Optional selected type filter
110
+ optional string workspace_hint = 6; // Optional workspace name to search in
111
+ }
112
+
113
+ // Result for file search operations
114
+ message FileSearchResults {
115
+ repeated FileInfo results = 1; // Array of file/folder results
116
+ optional string mentions_request_id = 2; // Echo of the request ID for tracking
117
+ }
118
+
119
+ // File information structure for search results
120
+ message FileInfo {
121
+ string path = 1; // Relative path from workspace root
122
+ string type = 2; // "file" or "folder"
123
+ optional string label = 3; // Display name (usually basename)
124
+ optional string workspace_name = 4; // Workspace this result came from
125
+ }
126
+
127
+ // Response for searchCommits
128
+ message GitCommits {
129
+ repeated GitCommit commits = 1;
130
+ }
131
+
132
+ // Represents a Git commit
133
+ message GitCommit {
134
+ string hash = 1;
135
+ string short_hash = 2;
136
+ string subject = 3;
137
+ string author = 4;
138
+ string date = 5;
139
+ }
140
+
141
+ // Unified request for all rule file operations
142
+ message RuleFileRequest {
143
+ Metadata metadata = 1;
144
+ bool is_global = 2; // Common field for all operations
145
+ optional string rule_path = 3; // Path field for deleteRuleFile (optional)
146
+ optional string filename = 4; // Filename field for createRuleFile (optional)
147
+ optional string type = 5; // Type of the file to create (optional)
148
+ }
149
+
150
+ // Result for rule file operations with meaningful data only
151
+ message RuleFile {
152
+ string file_path = 1; // Path to the rule file
153
+ string display_name = 2; // Filename for display purposes
154
+ bool already_exists = 3; // For createRuleFile, indicates if file already existed
155
+ }
156
+
157
+ // Request to toggle a Cline rule
158
+ message ToggleClineRuleRequest {
159
+ Metadata metadata = 1;
160
+ bool is_global = 2; // Whether this is a global rule or workspace rule
161
+ string rule_path = 3; // Path to the rule file
162
+ bool enabled = 4; // Whether to enable or disable the rule
163
+ }
164
+
165
+ // Maps from filepath to enabled/disabled status, matching app's ClineRulesToggles type
166
+ message ClineRulesToggles {
167
+ map<string, bool> toggles = 1;
168
+ }
169
+
170
+ // Response for toggleClineRule operation
171
+ message ToggleClineRules {
172
+ ClineRulesToggles global_cline_rules_toggles = 1;
173
+ ClineRulesToggles local_cline_rules_toggles = 2;
174
+ }
175
+
176
+ // Request to toggle a Cursor rule
177
+ message ToggleCursorRuleRequest {
178
+ Metadata metadata = 1;
179
+ string rule_path = 2; // Path to the rule file
180
+ bool enabled = 3; // Whether to enable or disable the rule
181
+ }
182
+
183
+ // Request to toggle a workflow on or off
184
+ message ToggleWorkflowRequest {
185
+ Metadata metadata = 1;
186
+ string workflow_path = 2;
187
+ bool enabled = 3;
188
+ bool is_global = 4;
189
+ }
@@ -0,0 +1,49 @@
1
+ syntax = "proto3";
2
+
3
+ package cline;
4
+ option go_package = "github.com/cline/grpc-go/cline";
5
+ option java_package = "bot.cline.proto";
6
+ option java_multiple_files = true;
7
+
8
+ // Input message for all hooks
9
+ message HookInput {
10
+ string cline_version = 1;
11
+ string hook_name = 2;
12
+ string timestamp = 3;
13
+ string task_id = 4;
14
+ repeated string workspace_roots = 5;
15
+ string user_id = 6;
16
+ oneof data {
17
+ PreToolUseData pre_tool_use = 10;
18
+ PostToolUseData post_tool_use = 11;
19
+ // Future hooks will be added here
20
+ // UserPromptSubmitData user_prompt_submit = 12;
21
+ // TaskStartData task_start = 13;
22
+ // TaskResumeData task_resume = 14;
23
+ // TaskCancelData task_cancel = 15;
24
+ // TaskCompleteData task_complete = 16;
25
+ // PreCompactData pre_compact = 17;
26
+ }
27
+ }
28
+
29
+ // Output message for all hooks
30
+ message HookOutput {
31
+ string context_modification = 1;
32
+ bool should_continue = 2;
33
+ string error_message = 3;
34
+ }
35
+
36
+ // Data for PreToolUse hook
37
+ message PreToolUseData {
38
+ string tool_name = 1;
39
+ map<string, string> parameters = 2;
40
+ }
41
+
42
+ // Data for PostToolUse hook
43
+ message PostToolUseData {
44
+ string tool_name = 1;
45
+ map<string, string> parameters = 2;
46
+ string result = 3;
47
+ bool success = 4;
48
+ int64 execution_time_ms = 5;
49
+ }
@@ -0,0 +1,133 @@
1
+ syntax = "proto3";
2
+
3
+ package cline;
4
+ import "cline/common.proto";
5
+ option go_package = "github.com/cline/grpc-go/cline";
6
+ option java_package = "bot.cline.proto";
7
+ option java_multiple_files = true;
8
+
9
+ service McpService {
10
+ rpc toggleMcpServer(ToggleMcpServerRequest) returns (McpServers);
11
+ rpc updateMcpTimeout(UpdateMcpTimeoutRequest) returns (McpServers);
12
+ rpc addRemoteMcpServer(AddRemoteMcpServerRequest) returns (McpServers);
13
+ rpc downloadMcp(StringRequest) returns (McpDownloadResponse);
14
+ rpc restartMcpServer(StringRequest) returns (McpServers);
15
+ rpc deleteMcpServer(StringRequest) returns (McpServers);
16
+ rpc toggleToolAutoApprove(ToggleToolAutoApproveRequest) returns (McpServers);
17
+ rpc refreshMcpMarketplace(EmptyRequest) returns (McpMarketplaceCatalog);
18
+ rpc openMcpSettings(EmptyRequest) returns (Empty);
19
+
20
+ // Subscribe to MCP marketplace catalog updates
21
+ rpc subscribeToMcpMarketplaceCatalog(EmptyRequest) returns (stream McpMarketplaceCatalog);
22
+ rpc getLatestMcpServers(Empty) returns (McpServers);
23
+
24
+ // Subscribe to MCP server updates
25
+ rpc subscribeToMcpServers(EmptyRequest) returns (stream McpServers);
26
+ }
27
+
28
+ message ToggleMcpServerRequest {
29
+ Metadata metadata = 1;
30
+ string server_name = 2;
31
+ bool disabled = 3;
32
+ }
33
+
34
+ message UpdateMcpTimeoutRequest {
35
+ Metadata metadata = 1;
36
+ string server_name = 2;
37
+ int32 timeout = 3;
38
+ }
39
+
40
+ message AddRemoteMcpServerRequest {
41
+ Metadata metadata = 1;
42
+ string server_name = 2;
43
+ string server_url = 3;
44
+ }
45
+
46
+ message ToggleToolAutoApproveRequest {
47
+ Metadata metadata = 1;
48
+ string server_name = 2;
49
+ repeated string tool_names = 3;
50
+ bool auto_approve = 4;
51
+ }
52
+
53
+ message McpTool {
54
+ string name = 1;
55
+ optional string description = 2;
56
+ optional string input_schema = 3;
57
+ optional bool auto_approve = 4;
58
+ }
59
+
60
+ message McpResource {
61
+ string uri = 1;
62
+ string name = 2;
63
+ optional string mime_type = 3;
64
+ optional string description = 4;
65
+ }
66
+
67
+ message McpResourceTemplate {
68
+ string uri_template = 1;
69
+ string name = 2;
70
+ optional string mime_type = 3;
71
+ optional string description = 4;
72
+ }
73
+
74
+ enum McpServerStatus {
75
+ // Protobuf enums (in proto3) must have a zero value defined, which serves as the default if the field isn't explicitly set.
76
+ // To align with the required nature of the TypeScript type and avoid an unnecessary UNSPECIFIED state, we map one of the existing statuses to this zero value.
77
+ MCP_SERVER_STATUS_DISCONNECTED = 0; // default
78
+ MCP_SERVER_STATUS_CONNECTED = 1;
79
+ MCP_SERVER_STATUS_CONNECTING = 2;
80
+ }
81
+
82
+ message McpServer {
83
+ string name = 1;
84
+ string config = 2;
85
+ McpServerStatus status = 3;
86
+ optional string error = 4;
87
+ repeated McpTool tools = 5;
88
+ repeated McpResource resources = 6;
89
+ repeated McpResourceTemplate resource_templates = 7;
90
+ optional bool disabled = 8;
91
+ optional int32 timeout = 9;
92
+ }
93
+
94
+ message McpServers {
95
+ repeated McpServer mcp_servers = 1;
96
+ }
97
+
98
+ message McpMarketplaceItem {
99
+ string mcp_id = 1;
100
+ string github_url = 2;
101
+ string name = 3;
102
+ string author = 4;
103
+ string description = 5;
104
+ string codicon_icon = 6;
105
+ string logo_url = 7;
106
+ string category = 8;
107
+ repeated string tags = 9;
108
+ bool requires_api_key = 10;
109
+ optional string readme_content = 11;
110
+ optional string llms_installation_content = 12;
111
+ bool is_recommended = 13;
112
+ int32 github_stars = 14;
113
+ int32 download_count = 15;
114
+ string created_at = 16;
115
+ string updated_at = 17;
116
+ string last_github_sync = 18;
117
+ }
118
+
119
+ message McpMarketplaceCatalog {
120
+ repeated McpMarketplaceItem items = 1;
121
+ }
122
+
123
+ message McpDownloadResponse {
124
+ string mcp_id = 1;
125
+ string github_url = 2;
126
+ string name = 3;
127
+ string author = 4;
128
+ string description = 5;
129
+ string readme_content = 6;
130
+ string llms_installation_content = 7;
131
+ bool requires_api_key = 8;
132
+ optional string error = 9;
133
+ }