RSpace MCP Server
OfficialThe RSpace MCP Server enables LLM agents to interact with the RSpace Electronic Lab Notebook (ELN) and inventory management system via the Model Context Protocol.
System
Check RSpace server connectivity and status
Document & Notebook Management
Retrieve, read, update, tag, and rename documents or notebook entries
Create new notebooks and add entries to them
Upload/attach files to documents and download file attachments
Document Search
Flexible search by text, tags, dates, content, or advanced multi-criteria queries
Search by tags, recent modifications, or content inclusion/exclusion filtering
Form Management
List, inspect, create, publish/unpublish, share/unshare, and delete custom form templates
Create structured documents from existing form templates
Inventory — Samples
Create, retrieve, list, duplicate, and bulk-create samples
Split subsamples into aliquots and add notes to subsamples
Search inventory with full-text queries
Inventory — Containers
Create list-based (folder/box) and grid-based (e.g., 96-well plate) containers
Retrieve container details, list top-level containers, and get workbenches
Move items into containers by row, column, or specific grid coordinates
Sample Templates
Create, inspect, and list reusable sample templates for standardized creation
Inventory Utilities
Rename any inventory item, add custom metadata fields
Generate linear or QR code barcodes for physical sample tracking
Audit & Compliance
Retrieve chronological audit trails of all system events, filterable by user, document, or date range
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@RSpace MCP Server list my recent documents in RSpace"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
RSpace MCP server
This is a proof-of-concept MCP server for RSpace that runs locally on your machine. It uses the RSpace Python client and exposes some RSpace API endpoints to LLM agents using the Model Context Protocol. The repository also contains example agent skills that package up conventions and reference files for working with RSpace in a specific way.
Installation and configuration
Clone or download this repository to your local machine
Run
uv syncto install dependenciesCreate a
.envfile in the same folder and addRSPACE_URL=RSpace URL # e.g. https://community.researchspace.com RSPACE_API_KEY=your API keyConnect your LLM app with the RSpace MCP server
For VS Code Copilot, add an mcp.json with the following content
{ "inputs": [ { "type": "promptString", "id": "rspace-apikey", "description": "RSpace API Key", "password": true }, { "type": "promptString", "id": "rspace-url", "description": "RSpace base URL", "password": false } ], "servers": { "rspace": { "command": "uv", "args": [ "--directory", "<full path to this directory>", "run", "main.py" ], "env": { "RSPACE_API_KEY": "${input:rspace-apikey}", "RSPACE_URL": "${input:rspace-url}" } } } }For Claude Desktop, add a claude_desktop_config.json with the following content:
{ "mcpServers": { "rspace": { "command": "<path to uv command>", "args": [ "--directory", "<full path to this directory>", "run", "main.py" ], "env": {} } } }
Keeping the context small (tool dispatcher)
The server has a lot of tools, and every tool definition is sent to the model on every request, which costs context tokens. To keep that cost low, only the read-only core group is listed directly: status plus the search and get/list tools across documents, forms, inventory, instruments, and the audit trail. Reads are safe and common, so they need no extra step.
Everything that changes state (create, update, and the deletes) is registered but hidden, and the model reaches it through three always-present dispatcher tools:
list_rspace_tools(toolset)— discover hidden tools and which group they are in.describe_rspace_tool(names)— get the input schema for one or more tools.rspace_invoke(tool_name, arguments)— run any tool by name; arguments are validated against the tool's real schema. Destructive tools additionally requireconfirm=true.
This means a mutation is always a deliberate discover-then-invoke, and the highest-consequence operations (deletes) never sit in the always-visible tool list. Because the listed set never changes, it also works on every MCP client (it does not rely on tools/list_changed, which Claude Desktop and the claude.ai connectors do not act on mid-session). Tool names are unchanged, so a skill can still refer to a capability by name; the model discovers and invokes it on demand.
To expose more groups directly (skipping the dispatcher for them), set RSPACE_DIRECT_TOOLSETS in the client env block to a comma-separated list of groups, or all to list everything:
RSPACE_DIRECT_TOOLSETS=inventory-write,inventory-containersGroups: core (always direct, read-only), plus the mutation groups eln-docs, eln-forms, inventory-write, inventory-containers, inventory-templates, instruments, files-lom, and destructive.
Related MCP server: Anytype MCP Server
Using the RSpace through the MCP server
Please bear in mind that this is a proof of concept and your production use case might require a more specific MCP server configured with specifically fine-tuned tools. The tools provided here in this prototype ...
do not exhaustively feature the functionality currently available through the RSpace Python client
might be more than you need for your use case
might not be optimally configured for how you would like to interact with RSpace
We're curious to learn about how you (want to) use this solution, so let us know about your experiences and learnings or contribute them directly to this repository.
Use cases and applications
You can find descriptions of some usecases and examples in the examples folder and we're looking forward to hearing about new examples and learnings. If you have an experience to share, feel free to contribute.
Using an agent skill
The skills/rspace-franklin folder contains a ready-to-customise skill for working with RSpace through this MCP server — a task loop, FAIR and naming conventions, and placeholder reference files for your lab's standards, SOPs, and more. Copy the folder, give it your own name, and edit the [EDIT ME] sections to match your lab before using it.
Contributing new Tools
If you develop new tools or toolsets, feel free to share code snippets or entire tool sets in the tools folder with appropriate annotations.
Contributing new Skills
If you build a skill for a different working style, research domain, or workflow, feel free to share it in the skills folder alongside its own reference files.
Acknowledgements
This project is based on code originally created by richarda23.
Available Tools
50 toolsadd_extra_fields_to_itemA
Adds custom metadata fields to inventory items
Usage: Extend items with experiment-specific or project-specific data Field format: [{"name": "Field Name", "type": "text|number", "content": "value"}] Types: 'text' for strings, 'number' for numeric values
Returns: Updated item with new custom fields
Inputs: item_id (required), field_data (required). Returns: object
add_note_to_subsampleB
Adds annotations or observations to a specific subsample
Usage: Record experimental notes, observations, or handling instructions Returns: Updated subsample information with new note
Inputs: subsample_id (required), note (required). Returns: object
bulk_create_samplesA
Creates multiple samples efficiently in a single operation
Usage: High-performance sample creation for large datasets Performance: Much faster than individual create_sample calls Format: List of sample definition dictionaries
Note: Implementation should use batch API endpoints when available Returns: Results for all created samples with error handling
Inputs: sample_definitions (required). Returns: object
create_document_from_formB
Creates a structured document using a form template
Usage: Generate documents with predefined structure and validation Fields: Pre-populate form fields with initial data Returns: Created document information
Inputs: form_id (required), name, parent_folder_id, tags, +1 more. Returns: object
create_formA
Creates a new custom form template for structured data entry
Usage: Define reusable templates for experiments, protocols, reports Fields structure: [ { "name": "Field Name", "type": "String|Text|Number|Radio|Date|Choice", "mandatory": True/False, "defaultValue": "optional default" } ] Returns: Created form information (form will be in NEW state)
Inputs: name (required), tags, fields. Returns: object
create_grid_containerA
Creates a grid-based container with specific positioning
Usage: Create microplates, freezer boxes, or other position-specific storage Dimensions: Define exact grid size (e.g., 8x12 for 96-well plate) Positioning: Items placed at specific coordinates (row, column)
Returns: Created container information with grid specifications
Inputs: name (required), rows (required), columns (required), description, +4 more. Returns: object
create_list_containerB
Creates a simple list-based container for organizing inventory
Usage: Create folders, boxes, or other containers without specific positioning Storage permissions: Configure what types of items can be stored Hierarchy: Optionally nest within another container
Returns: Created container information with storage settings
Inputs: name (required), description, tags, can_store_containers, +2 more. Returns: object
createNewNotebookB
Creates a new electronic lab notebook
Usage: Organize related experiments/entries under a single notebook Returns: Created notebook information including ID for adding entries
Inputs: name (required).
createNotebookEntryB
Adds a new entry to an existing notebook
Usage: Add experimental procedures, results, or observations to a notebook Content: Supports both HTML and plain text formatting Returns: Created entry information
Inputs: name (required), text_content (required), notebook_id (required).
create_sampleA
Creates a new sample in the inventory system
Usage: Register new samples with metadata and quantity tracking Subsamples: Automatically creates specified number of subsample aliquots Quantity: Tracks total amount with specified units (ml, mg, μl, etc.)
Returns: Created sample information including generated subsample IDs
Inputs: name (required), tags, description, subsample_count, +2 more. Returns: object
create_sample_templateB
Creates a reusable template for sample creation
Usage: Standardize sample creation with predefined fields and validation Template data: Define field structure, default values, and constraints Returns: Created template information for future sample generation
Inputs: template_data (required). Returns: object
delete_formA
Permanently deletes a form template
Usage: Remove unused forms (only works for forms in NEW state) Warning: This operation cannot be undone Returns: Deletion confirmation
Inputs: form_id (required). Returns: object
downloadFileB
Downloads file attachments from RSpace documents
Usage: Retrieve images, data files, or other attachments Parameters:
file_id: Numeric ID of the file attachment
file_path: Local filesystem path where file should be saved
Returns: Download status and file information
Inputs: file_id (required), file_path (required).
duplicate_sampleA
Creates an exact copy of an existing sample
Usage: Replicate samples for parallel experiments or backup Returns: New sample information with fresh ID and subsamples
Inputs: sample_id (required), new_name. Returns: object
find_documents_by_contentB
Advanced content-based document search
Usage: Find documents containing specific content terms
Parameters:
content_terms: List of terms that should appear in document content
operator: "and" (all terms must appear) or "or" (any term can appear)
exclude_terms: Optional list of terms to exclude from results
order_by: Sort results by field
page_size: Number of results to return
Returns: Dictionary with search results
Example: find_documents_by_content(["DNA", "extraction"], operator="and")
Inputs: content_terms (required), operator, exclude_terms, order_by, +1 more. Returns: object
generate_barcodeB
Generates scannable barcodes for inventory items
Usage: Create physical labels for sample tracking and identification Types: 'BARCODE' for standard linear barcodes, 'QR' for QR codes Returns: Binary barcode image data for printing or display
Inputs: global_id (required), barcode_type. Returns: result
getAuditEventsB
Retrieves audit trail of all actions performed in RSpace
Usage: Monitor document access, modifications, and user activity Filtering options:
username: Filter by specific user actions
global_id: Filter by specific document
date_from/date_to: ISO8601 format date range
Returns: Chronological list of system events
Inputs: username, global_id, date_from, date_to.
get_containerA
Retrieves container information with optional content listing
Usage: Examine container properties and optionally see what's inside Performance: Set include_content=False for faster queries on large containers Returns: Container details and optionally contained items
Inputs: container_id (required), include_content. Returns: object
get_container_contents_onlyA
Retrieves only the items stored in a container
Usage: Get container contents without metadata overhead Performance: Focused query for container content analysis Returns: List of contained items with minimal metadata
Inputs: container_id (required). Returns: result
get_container_summaryA
Retrieves container metadata without content for fast queries
Usage: Quick container information lookup without performance impact Performance: Avoids loading large content lists for better response times Returns: Container metadata only (name, type, capacity, etc.)
Inputs: container_id (required). Returns: object
get_documentsA
Retrieves recent RSpace documents with pagination
Usage: Get overview of recent documents for browsing/selection Limit: Maximum 200 documents per call for performance Returns: List of document metadata (not full content)
Inputs: page_size. Returns: result
get_formA
Retrieves detailed information about a specific form template
Usage: Examine form structure before creating documents or new forms Returns: Complete form definition including field specifications
Inputs: form_id (required). Returns: object
get_formsA
Lists available custom forms for structured document creation
Usage: Browse available templates before creating structured documents Filtering: Use query parameter to search form names/descriptions Returns: Paginated list of form metadata
Inputs: query, order_by, page_number, page_size. Returns: object
get_recent_samples_summaryA
Retrieves recent samples with minimal data for dashboard views
Usage: Quick overview of recent activity without full sample details Performance: Optimized for dashboard and summary displays Filtering: Configurable time window and result count
Returns: Lightweight sample list with essential information only
Inputs: days_back, page_size. Returns: result
get_sampleA
Retrieves complete information about a specific sample
Usage: Get detailed sample metadata, location, and subsample information Parameters: sample_id can be numeric ID or global ID (e.g., "SA12345") Returns: Full sample details including all subsamples
Inputs: sample_id (required). Returns: object
get_sample_templateA
Retrieves detailed information about a sample template
Usage: Examine template structure before using for sample creation Returns: Complete template definition including field specifications
Inputs: template_id (required). Returns: object
get_single_Rspace_documentB
Retrieves complete content of a single document
Usage: Get full document text for reading/analysis Parameters: doc_id can be numeric ID or string globalId (e.g., "SD12345") Returns: Full document with concatenated field content
Inputs: doc_id (required). Returns: Complete ELN document with all content concatenated
get_workbenchesA
Retrieves all available workbenches (virtual workspaces)
Usage: Find available workspaces for organizing current work Workbenches: Special containers representing physical or logical workspaces Returns: List of all workbench containers
Inputs: no named parameters. Returns: result
list_containersA
Lists top-level containers (not nested within other containers)
Usage: Browse main container organization structure Returns: Paginated list of root-level containers
Inputs: page_size. Returns: object
list_samplesA
Lists samples in the inventory with pagination and sorting
Usage: Browse sample collection, find recent additions Sorting: Options include "lastModified", "name", "created" Returns: Paginated list of sample metadata
Inputs: page_size, order_by, sort_order. Returns: object
list_sample_templatesA
Lists available sample templates for reuse
Usage: Browse existing templates before creating new samples Returns: Paginated list of template metadata
Inputs: page_size. Returns: object
move_items_to_grid_container_by_columnB
Moves items to grid container, filling positions column by column
Usage: Alternative filling pattern for specific experimental layouts Auto-positioning: Fills down columns before moving to next column Returns: Success status and final positions of moved items
Inputs: target_container_id (required), item_ids (required), start_column, start_row, +2 more. Returns: object
move_items_to_grid_container_by_rowA
Moves items to grid container, filling positions row by row
Usage: Systematic filling of plates, boxes, or other gridded containers Auto-positioning: Automatically calculates next available positions Dimensions: Auto-detected from container if not provided
Returns: Success status and final positions of moved items
Inputs: target_container_id (required), item_ids (required), start_column, start_row, +2 more. Returns: object
move_items_to_list_containerB
Moves multiple items to a list-based container
Usage: Organize items in simple containers without specific positioning Items: Can move both samples/subsamples and other containers Returns: Success status and results for each moved item
Inputs: target_container_id (required), item_ids (required). Returns: object
move_items_to_specific_grid_locationsA
Places items at specific coordinates within a grid container
Usage: Precise positioning for experimental layouts or protocols Coordinates: Each item gets an exact (row, column) position Validation: Ensures equal number of items and positions
Returns: Success status and confirmation of final positions
Inputs: target_container_id (required), item_ids (required), grid_locations (required). Returns: object
publish_formB
Makes a form available for creating documents
Usage: Activate form after creation/modification Note: Forms must be published before they can be used for document creation Returns: Updated form status
Inputs: form_id (required). Returns: object
renameDocumentOrNotebookEntryC
Changes the name/title of a document or notebook entry
Usage: Update document titles for better organization Returns: Updated document information
Inputs: doc_id (required), name (required).
rename_inventory_itemA
Changes the name of any inventory item
Usage: Rename samples, subsamples, containers, or templates Universal: Works with any inventory item type Returns: Updated item information with new name
Inputs: item_id (required), new_name (required). Returns: object
search_by_tagsA
Search documents by specific tags
Usage: Find documents tagged with specific keywords
Parameters:
tags: List of tags to search for
operator: "and" (document must have all tags) or "or" (document can have any tag)
order_by: Sort results by field
page_number: Page number for pagination
page_size: Number of results per page
Returns: Dictionary with search results
Example: search_by_tags(["PCR", "protocol"], operator="and")
Inputs: tags (required), operator, order_by, page_number, +1 more. Returns: object
search_documentsA
Generic search tool for RSpace documents with flexible search options
Usage: Search across all your RSpace documents using various criteria
Parameters:
query: The search term(s) to look for
search_type: "simple" for basic search, "advanced" for multi-criteria search
query_types: List of search types to use (for advanced search):
"global": Search across all document content and metadata
"fullText": Search within document text content
"tag": Search by document tags
"name": Search by document names/titles
"created": Search by creation date (use ISO format like "2024-01-01")
"lastModified": Search by modification date
"form": Search by form type
"attachment": Search by attachments
operator: "and" (all criteria must match) or "or" (any criteria can match)
order_by: Sort results by field (e.g., "lastModified desc", "name asc")
page_number: Page number for pagination (0-based)
page_size: Number of results per page (max 200)
include_content: Whether to fetch full document content (slower but more complete)
Returns: Dictionary with search results and metadata
Examples:
Simple text search: search_documents("PCR protocol")
Search by tags: search_documents("experiment", search_type="advanced", query_types=["tag"])
Multi-criteria search: search_documents("DNA", search_type="advanced", query_types=["fullText", "tag"], operator="or")
Inputs: query (required), search_type, query_types, operator, +4 more. Returns: object
search_inventoryA
Searches across all inventory items using text query
Usage: Find samples, containers, or templates by name, tags, or description Result types: 'SAMPLE', 'SUBSAMPLE', 'CONTAINER', 'TEMPLATE' (or None for all) Returns: Matching items with relevance scoring
Inputs: query (required), result_type. Returns: object
search_recent_documentsB
Search for recently modified documents
Usage: Find documents modified within a specific timeframe
Parameters:
days_back: Number of days to look back
query: Optional text search within recent documents
page_size: Number of results to return
Returns: Dictionary with recent documents
Example: search_recent_documents(7, "experiment")
Inputs: days_back, query, page_size. Returns: object
split_subsampleB
Divides a subsample into multiple new subsamples
Usage: Create aliquots for distribution or different experiments Quantity: If specified, each new subsample gets this amount Returns: Information about newly created subsamples
Inputs: subsample_id (required), num_new_subsamples (required), quantity_per_subsample. Returns: object
statusA
System health check - determines if RSpace server is accessible and running
Usage: Call this first to verify connectivity before other operations Returns: Status message from RSpace server
Inputs: no named parameters. Returns: result
tagDocumentOrNotebookEntryB
Adds tags to documents for organization and searchability
Usage: Categorize documents by project, experiment type, etc. Tags: Use consistent naming for better organization Returns: Updated document with new tags
Inputs: doc_id (required), tags (required).
unpublish_formA
Hides a form from document creation interface
Usage: Temporarily disable forms without deletion Returns: Updated form status
Inputs: form_id (required). Returns: object
update_documentB
Updates existing RSpace document content and metadata
Usage: Modify document name, tags, or field content Fields format: [{"id": field_id, "content": "new HTML content"}] Returns: Updated document information
Inputs: document_id (required), name, tags, form_id, +1 more. Returns: object
uploadAndAttachFileA
Uploads a file to RSpace and attaches it to a document as a proper file attachment
Usage: One-step process to upload any file and attach it to an RSpace document File types: Supports all file types (images, PDFs, data files, protocols, etc.) Attachment: Creates proper RSpace file attachment, not just a link
Parameters:
document_id: RSpace document ID (numeric or global ID like "SD12345")
file_path: Path to the file to upload (e.g., "data/results.pdf")
caption: Optional caption that appears with the attachment
description: Optional description for the uploaded file
Returns: Upload confirmation and document update information
Inputs: document_id (required), file_path (required), caption, description. Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 50 tools
Most tools have distinct purposes, but some overlap exists, such as multiple search tools (search_documents, find_documents_by_content, search_by_tags, search_recent_documents) that could confuse agents about which to use. Similarly, container retrieval tools (get_container, get_container_contents_only, get_container_summary) have subtle differences that might lead to misselection.
The majority of tools follow a consistent snake_case verb_noun pattern (e.g., create_sample, get_container, list_samples), but there are notable exceptions like createNewNotebook, createNotebookEntry, and renameDocumentOrNotebookEntry that use camelCase or mixed styles, breaking the overall consistency.
With 50 tools, the set is excessively large for an MCP server, making it overwhelming and difficult for agents to navigate. While the domain (lab inventory and document management) is broad, many tools could be consolidated or omitted without losing functionality, indicating poor scoping.
The tool set comprehensively covers the domain of lab inventory and document management, including full CRUD operations for samples, containers, forms, and documents, along with advanced features like barcoding, auditing, and file handling. No obvious gaps exist; agents can perform all expected workflows without dead ends.
Maintenance
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
The Mercado Pago MCP Server implements the Model Context Protocol to provide AI agents and LLMs with access to Mercado Pago's APIs and tools within compatible development environments. It acts as an intermediary that translates Mercado Pago resources into executable functions (tools) that AI applications can invoke to perform actions and automate flows. The server simplifies integration, enables using documentation to implement or improve code, and optimizes operations through natural language interactions without manual implementations.
An MCP server that provides an API to LLMs to manage their JumpCloud resources.
Related MCP Servers
- AlicenseNot gradedqualityAmaintenanceA server that enables Large Language Models to discover and interact with REST APIs defined by OpenAPI specifications through the Model Context Protocol.12,706 npm302MIT
- AlicenseNot gradedqualityBmaintenanceA Model Context Protocol (MCP) server implementation that enables AI assistants to interact with Anytype's API through natural language, allowing users to manage their knowledge base through conversation.77,112 npm545MIT
- AlicenseBqualityDmaintenanceExposes RSpace API endpoints to LLM agents using the Model Context Protocol.91Apache 2.0
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol (MCP) server that provides seamless integration with the Documize API. This server enables AI assistants like Claude to interact with your Documize knowledge base - search documents, manage spaces, handle attachments, and more.11 npmMIT