Skip to content
 
 

Latest commit

 

History

739 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

STARLIMS VS Code

STARLIMS VS Code is an unofficial Visual Studio Code extension for working with STARLIMS Enterprise Designer assets from within VS Code. It supports browsing remote items, synchronizing them to a local workspace, reviewing changes, running supported assets, debugging forms, and combining STARLIMS workflows with Git and GitHub Copilot-aware tooling.

Key Capabilities

  • Browse, search and edit all STARLIMS code items, forms, resources, database tables, and dictionary tables directly from VS Code
  • Work with multiple STARLIMS environments through named server definitions and the built-in server selector
  • Check out items to a local workspace, compare local files with the server version, and see checked out items of other users
  • Check in, undo checkout, rename, move, add, and delete supported items
  • Export your checked out items to an SDP package
  • Transfer all checked out items to another configured STARLIMS server; the target server imports the package and automatically generates a new version of each item (items remain checked out on the source server)
  • Run server scripts and data sources, capture script output, stream STARLIMS server logs, and clear logs from VS Code
  • Open HTML forms, debug them in Chrome or Edge, launch XFD forms through STARLIMS Bridge
  • HTML Form designer for creating or editing forms in a WYSIWYG environment with live preview, drag-and-drop controls, and property editing
  • Search by item name, perform global code search across all STARLIMS code items, and quickly navigate from source code to server scripts, client scripts, data sources via hotkeys
  • Explore database and dictionary tables, inspect table definitions, and generate SELECT, INSERT, UPDATE, and DELETE statements into the active editor
  • Initialize a Git repository for the local SLVSCODE mirror, configure a remote, and optionally auto-commit and auto-push local STARLIMS changes during check-in
  • Optionally detect new Git commits in the SLVSCODE repository and check matching checked-out STARLIMS script and data source files in with the Git commit message
  • Manage STARLIMS tickets (BMBH only) from VS Code by filtering queues, selecting an active ticket, undertaking, releasing, solving, and renaming tickets, and creating ticket measures during check-in
  • Launch a selected STARLIMS ticket into an OpenCode terminal — starts a new session or reuses a running instance with the ticket context preloaded
  • SSL and SLSQL language support with syntax highlighting, code completion, hover documentation, go-to-definition, find references, document symbols, and folding ranges
  • Use a local MCP endpoint and Copilot-facing workspace files to enable agents to use the STARLIMS MCP for browse, search, code retrieval, checkout/check-in, transfer to another server, runtime execution, and table operations when working with STARLIMS assets

Requirements

  • Visual Studio Code 1.110 or later
  • Access to a STARLIMS environment
  • The SCM_API.sdp package imported into STARLIMS from the latest project release
  • The following entry in the STARLIMS web.config file:
<add key="HTTPServices" value="SCM_API.*"/>

For product development environments with system layer ID 200, enable Overwrite System Layer during package import.

If your STARLIMS platform version does not support the HTTPServices setting, configure STARLIMS.urlSuffix to lims2.

Importing the latest SCM_API.sdp release is strongly recommended because newer features such as ticket workflows, form callback publishing, MCP access, and backend auto-upgrade depend on current backend endpoints.

Installation and Setup

  1. Install the extension in VS Code.
  2. Import SCM_API.sdp into your STARLIMS environment.
  3. Configure the STARLIMS connection settings in VS Code.
  4. Set STARLIMS.rootPath to the parent folder where the extension should create the local SLVSCODE workspace mirror.
  5. Open the STARLIMS view from the activity bar and connect to a configured server.

The extension creates or opens the SLVSCODE folder under STARLIMS.rootPath and uses it as the local working copy for checked out items.

On activation, the extension also:

  • Checks the backend API version and offers to upgrade SCM_API.sdp automatically when the deployed backend is older than the extension
  • Publishes the local form callback port back to STARLIMS SCM so FormDesigner can open local code-behind files in VS Code
  • Creates .vscode/mcp.json, .github/agents/starlims.agent.md, and .github/copilot-instructions.md inside SLVSCODE when they are missing
  • Bootstraps ESLint support for STARLIMS client-side JavaScript by copying the workspace config and installing the VS Code ESLint extension when needed

Configuration

Core settings:

  • STARLIMS.url: STARLIMS installation URL
  • STARLIMS.user: STARLIMS user name
  • STARLIMS.userPassword: Password stored through the extension command instead of the settings file
  • STARLIMS.rootPath: Parent folder for the local SLVSCODE workspace mirror

Common optional settings:

  • STARLIMS.servers: Named server definitions for multi-environment setups
  • STARLIMS.selectedServer: The currently active named server
  • STARLIMS.browser: Browser used for form debugging (chrome or msedge)
  • STARLIMS.urlSuffix: Service suffix for environments that require lims2
  • STARLIMS.defaultFormLanguage: Default language used when checking out form items, GER by default

OpenCode ticket launcher settings:

  • STARLIMS.opencode.integration: How Solve ticket with OpenCode launches OpenCode. server (default) drives ticket sessions through the OpenCode server API, terminal keeps the previous terminal-based launch
  • STARLIMS.opencode.serverHostname: Loopback hostname the OpenCode server binds to when spawned by the extension (127.0.0.1 by default)
  • STARLIMS.opencode.serverPort: TCP port used by the OpenCode server (4096 by default). A server already running on this port is reused
  • STARLIMS.opencode.command: Command or absolute executable path used by Solve ticket with OpenCode. Use npx.cmd together with STARLIMS.opencode.commandArgs if you launch OpenCode through npx on Windows
  • STARLIMS.opencode.commandArgs: Optional leading arguments for the launcher command, such as opencode when using npx.cmd
  • STARLIMS.opencode.planModel: Initial model used when the ticket action opens OpenCode in plan mode
  • STARLIMS.opencode.buildModel: Preferred implementation model used after the plan is approved in server integration mode; the terminal integration shows it without switching automatically
  • STARLIMS.opencode.workingDirectory: Optional working directory override for the OpenCode terminal session

The OpenCode server password is stored through the command STARLIMS: Set OpenCode server password instead of a plain settings value. When set, the extension passes it to the spawned server via OPENCODE_SERVER_PASSWORD and authenticates against the API with HTTP basic auth.

Git automation settings:

  • STARLIMS.git.enabled: Enables Git integration for STARLIMS check-in flows
  • STARLIMS.git.autoPush: Automatically pushes Git commits after STARLIMS check-in
  • STARLIMS.git.remoteUrl: Optional remote URL used by the configure-remote command
  • STARLIMS.git.remoteName: Git remote name, defaulting to origin
  • STARLIMS.git.commitMessageGenerator: Uses a fast local message or AI-assisted message generation (fast, copilot, or ollama)
  • STARLIMS.git.copilotCommitMessageModel: Optional exact Copilot model name for message generation
  • STARLIMS.git.aiCommitMessageSystemPrompt: Custom system prompt sent to Copilot or Ollama for message generation
  • STARLIMS.git.aiCommitMessageTimeoutMs: Maximum time to wait for AI message generation before falling back to the fast local message
  • STARLIMS.git.ollamaCommitMessageBaseUrl: Base URL of the local Ollama server (http://127.0.0.1:11434 by default)
  • STARLIMS.git.ollamaCommitMessageModel: Ollama model used for message generation (gemma4 by default)

Additional Git message settings are available to control detail level, prefixes, maximum length, and whether item type or language is included.

Ticket Workflows

The Tickets view groups STARLIMS tickets by status and supports title filtering, active ticket selection, ticket undertaking and release, marking tickets as solved, and renaming tickets.

When an active ticket is selected, STARLIMS check-in commands can reuse ticket-aware reasons and automatically create ticket measures. Ticket measure text can use the same fast local generator or Copilot-assisted generation that is used for Git and check-in messages.

The ticket context menu also includes Solve ticket with OpenCode. In the default server integration, the extension reuses an OpenCode server running on STARLIMS.opencode.serverHostname:STARLIMS.opencode.serverPort or spawns opencode web there itself (which opens the OpenCode Web UI in your browser). For each ticket it creates a session titled Ticket #<id> - <title>, sends the ticket prompt with the plan agent, and shows an Approve & Implement notification once the plan is ready. Approving continues the same session with the build model. Sessions can be aborted from the ticket context menu, and the Web UI is opened from the ticket context menu or the Approve & Implement/Open Web UI notifications. The terminal integration instead opens a new terminal session in plan mode with the selected ticket details preloaded, reusing a running OpenCode terminal when one exists. The extension writes the ticket prompt to a temporary file under the extension storage folder and feeds that content into the OpenCode CLI.

MCP Integration

The extension also starts a local form callback server on the first free loopback port in the range 3003-3099 for FormDesigner code-behind navigation. The selected port is published back to STARLIMS SCM so the FormDesigner client can resolve it dynamically.

When STARLIMS.mcp.enabled is enabled, the extension exposes a local MCP endpoint on http://127.0.0.1:3002/mcp by default.

The MCP integration is intentionally limited:

  • Binds to loopback only
  • Uses the currently selected STARLIMS server
  • Supports browse, search, available-language discovery, code retrieval, checkout, check-in, undo checkout, server script execution, data source execution, table definition retrieval, item creation, table creation, and edit operations
  • Extension integration tests can be triggered through MCP, but each run requires an explicit local user confirmation prompt before npm test starts
  • High-risk actions such as delete, rename, and move are still not exposed

Related settings:

  • STARLIMS.mcp.enabled: Enables the endpoint
  • STARLIMS.mcp.port: Changes the loopback port used by MCP
  • STARLIMS.mcp.maxItems: Limits browse and search result sizes
  • STARLIMS.mcp.maxCodeCharacters: Limits code returned by read requests
  • STARLIMS.mcp.includeStructuredDataInText: Includes the full structured tool payload (items, code, output) as JSON in the visible text of every MCP tool result (default true) — required for clients that render only content[].text and ignore structuredContent

The MCP endpoint is sessionful: the server returns an Mcp-Session-Id header on initialize and expects it on all subsequent requests (non-initialize requests without it are rejected with 400, unknown sessions with 404, and DELETE /mcp terminates a session). Tool results mark cut-off responses with a TRUNCATED: note in the text, and per-request maxCharacters values below 100 are honored rather than silently raised.

When the local SLVSCODE workspace is created, the extension also seeds Copilot-facing helper files so agents can discover the STARLIMS MCP endpoint and prefer STARLIMS-native browse, search, code retrieval, checkout/check-in, runtime execution, and table management operations. Those instructions also tell agents to default STARLIMS form work to GER and to ask the user before running extension integration tests.

Default Shortcuts

  • F5: Run a server script or data source, or debug an HTML form, depending on the active file type
  • Ctrl+F5: Open HTML forms or XFD forms
  • Ctrl+F6: Open the HTML form designer
  • F11: Navigate to the STARLIMS item referenced at the cursor
  • Ctrl+Alt+F: Run STARLIMS global code search

Development

Current development dependency floor:

  • Node.js 20.19 or later, or Node.js 22.13 or later

Node 18 is no longer supported by the current toolchain. The locked versions of copy-webpack-plugin and jsdom require newer runtime features and will fail during CI or local builds on Node 18.

Recommended local workflow:

npm ci
npm run lint
npm run compile
npm run package
npm run compile-tests
npm run pretest

npm test runs the VS Code extension host tests and may fail in restricted or headless environments.

To build a VSIX package on Windows, use:

npm run build-windows

License

See LICENSE.md.

About

STARLIMS VS Code Extension

Resources

Contributing

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages