Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions apps/vscode-e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
"@vscode/test-electron": "^2.4.0",
"glob": "^11.1.0",
"mocha": "^11.1.0",
"rimraf": "^6.0.1",
"typescript": "5.8.3"
"rimraf": "^6.0.1"
}
}
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"rimraf": "^6.0.1",
"tsx": "^4.19.3",
"turbo": "^2.5.6",
"typescript": "^5.4.5"
"typescript": "5.8.3"
},
"lint-staged": {
"*.{js,jsx,ts,tsx,json,css,md}": [
Expand All @@ -63,7 +63,9 @@
"brace-expansion": "^2.0.2",
"form-data": ">=4.0.4",
"bluebird": ">=3.7.2",
"glob": ">=11.1.0"
"glob": ">=11.1.0",
"@types/react": "^18.3.23",
"@types/react-dom": "^18.3.5"
}
}
}
2 changes: 1 addition & 1 deletion packages/types/npm/package.metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@roo-code/types",
"version": "1.99.0",
"version": "1.100.0",
"description": "TypeScript type definitions for Roo Code.",
"publishConfig": {
"access": "public",
Expand Down
2 changes: 1 addition & 1 deletion packages/types/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"@roo-code/config-typescript": "workspace:^",
"@types/node": "^24.1.0",
"globals": "^16.3.0",
"tsup": "^8.3.5",
"tsup": "^8.4.0",
"vitest": "^3.2.3"
}
}
13 changes: 13 additions & 0 deletions packages/types/src/git.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
export interface GitRepositoryInfo {
repositoryUrl?: string
repositoryName?: string
defaultBranch?: string
}

export interface GitCommit {
hash: string
shortHash: string
subject: string
author: string
date: string
}
2 changes: 2 additions & 0 deletions packages/types/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ export * from "./custom-tool.js"
export * from "./events.js"
export * from "./experiment.js"
export * from "./followup.js"
export * from "./git.js"
export * from "./global-settings.js"
export * from "./history.js"
export * from "./image-generation.js"
Expand All @@ -24,6 +25,7 @@ export * from "./terminal.js"
export * from "./tool.js"
export * from "./tool-params.js"
export * from "./type-fu.js"
export * from "./vscode-extension-host.js"
export * from "./vscode.js"

export * from "./providers/index.js"
5 changes: 5 additions & 0 deletions packages/types/src/marketplace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,3 +86,8 @@ export const installMarketplaceItemOptionsSchema = z.object({
})

export type InstallMarketplaceItemOptions = z.infer<typeof installMarketplaceItemOptionsSchema>

export interface MarketplaceInstalledMetadata {
project: Record<string, { type: string }>
global: Record<string, { type: string }>
}
91 changes: 90 additions & 1 deletion packages/types/src/mcp.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import { z } from "zod"

/**
* MCP Server Use Types
* McpServerUse
*/

export interface McpServerUse {
type: string
serverName: string
Expand Down Expand Up @@ -39,3 +40,91 @@ export const mcpExecutionStatusSchema = z.discriminatedUnion("status", [
])

export type McpExecutionStatus = z.infer<typeof mcpExecutionStatusSchema>

/**
* McpServer
*/

export type McpServer = {
name: string
config: string
status: "connected" | "connecting" | "disconnected"
error?: string
errorHistory?: McpErrorEntry[]
tools?: McpTool[]
resources?: McpResource[]
resourceTemplates?: McpResourceTemplate[]
disabled?: boolean
timeout?: number
source?: "global" | "project"
projectPath?: string
instructions?: string
}

export type McpTool = {
name: string
description?: string
inputSchema?: object
alwaysAllow?: boolean
enabledForPrompt?: boolean
}

export type McpResource = {
uri: string
name: string
mimeType?: string
description?: string
}

export type McpResourceTemplate = {
uriTemplate: string
name: string
description?: string
mimeType?: string
}

export type McpResourceResponse = {
_meta?: Record<string, any> // eslint-disable-line @typescript-eslint/no-explicit-any
contents: Array<{
uri: string
mimeType?: string
text?: string
blob?: string
}>
}

export type McpToolCallResponse = {
_meta?: Record<string, any> // eslint-disable-line @typescript-eslint/no-explicit-any
content: Array<
| {
type: "text"
text: string
}
| {
type: "image"
data: string
mimeType: string
}
| {
type: "audio"
data: string
mimeType: string
}
| {
type: "resource"
resource: {
uri: string
mimeType?: string
text?: string
blob?: string
}
}
>
isError?: boolean
}

export type McpErrorEntry = {
message: string
timestamp: number
level: "error" | "warn" | "info"
}
5 changes: 5 additions & 0 deletions packages/types/src/model.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { z } from "zod"
import { DynamicProvider, LocalProvider } from "./provider-settings.js"

/**
* ReasoningEffort
Expand Down Expand Up @@ -140,3 +141,7 @@ export const modelInfoSchema = z.object({
})

export type ModelInfo = z.infer<typeof modelInfoSchema>

export type ModelRecord = Record<string, ModelInfo>

export type RouterModels = Record<DynamicProvider | LocalProvider, ModelRecord>
3 changes: 2 additions & 1 deletion packages/types/src/provider-settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,8 @@ const qwenCodeSchema = apiModelIdProviderModelSchema.extend({
})

const rooSchema = apiModelIdProviderModelSchema.extend({
// No additional fields needed - uses cloud authentication.
// Can use cloud authentication or provide an API key (cli).
rooApiKey: z.string().optional(),
})

const vercelAiGatewaySchema = baseProviderSettingsSchema.extend({
Expand Down
Loading
Loading