ToolSets API
The ToolSets API provides endpoints for creating, managing, and deploying ToolSets — bundles of AI tools that can be exported as MCP servers, Copilot connectors, SDK bundles, or HTTP catalogs. ToolSets are the primary unit of organization and deployment in the Nexla MCP-as-a-Service platform.
ToolSet Endpoints
| Method | Path | Description |
|---|---|---|
| POST | /v1/toolsets | Create a ToolSet |
| POST | /v1/toolsets:from_nexsets | Create ToolSet from Nexsets (auto-gen tools + export) |
| GET | /v1/toolsets | List ToolSets |
| GET | /v1/toolsets/{id} | Get ToolSet details |
| PATCH | /v1/toolsets/{id} | Update ToolSet metadata |
| DELETE | /v1/toolsets/{id} | Delete ToolSet (soft delete) |
| POST | /v1/toolsets/{id}/tools | Add tools to ToolSet |
| DELETE | /v1/toolsets/{id}/tools | Remove tools from ToolSet |
| GET | /v1/toolsets/{id}/tools | List tools in ToolSet |
| POST | /v1/toolsets/{id}:activate | Activate ToolSet |
| POST | /v1/toolsets/{id}:pause | Pause ToolSet |
| POST | /v1/toolsets/{id}:clone | Clone a ToolSet |
Export Endpoints
| Method | Path | Description |
|---|---|---|
| POST | /v1/toolsets/{id}/exports | Create an export (MCP server) |
| GET | /v1/toolsets/{id}/exports | List exports |
| GET | /v1/toolsets/{id}/exports/{export_id} | Get export details |
| PATCH | /v1/toolsets/{id}/exports/{export_id} | Update export |
| DELETE | /v1/toolsets/{id}/exports/{export_id} | Delete export |
Create a ToolSet
POST /v1/toolsets
Creates a new ToolSet with the specified tools and metadata. The ToolSet starts in an active status by default.
curl -X POST https://api-genai.nexla.io/v1/toolsets \
-H "Authorization: Bearer $NEXLA_SERVICE_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Customer Data Tools",
"description": "Tools for accessing customer data",
"tags": ["customer", "analytics"],
"tool_ids": [1, 2, 3],
"mcp_gateway_enabled": false
}'
{
"id": 42,
"name": "Customer Data Tools",
"description": "Tools for accessing customer data",
"status": "active",
"tags": ["customer", "analytics"],
"mcp_server_key": "sk_ts42_a1b2c3d4e5f6...",
"mcp_gateway_enabled": false,
"tools": [
{ "id": 1, "name": "get_customer_profile", "status": "active" },
{ "id": 2, "name": "search_customers", "status": "active" },
{ "id": 3, "name": "get_customer_orders", "status": "active" }
],
"created_at": "2025-06-15T10:30:00Z",
"updated_at": "2025-06-15T10:30:00Z"
}
Create ToolSet from Nexsets
POST /v1/toolsets:from_nexsets
This is the recommended approach for going from data to a working MCP server in a single API call. It auto-generates tools from the specified Nexsets, bundles them into a ToolSet, and optionally creates an MCP server export.
curl -X POST https://api-genai.nexla.io/v1/toolsets:from_nexsets \
-H "Authorization: Bearer $NEXLA_SERVICE_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Sales Analytics",
"nexset_ids": [123, 456, 789],
"create_export": true
}'
{
"id": 43,
"name": "Sales Analytics",
"status": "active",
"mcp_server_key": "sk_ts43_x7y8z9...",
"tool_ids": [10, 11, 12],
"tools": [
{ "id": 10, "name": "query_sales_pipeline", "nexset_id": 123, "status": "active" },
{ "id": 11, "name": "get_deal_details", "nexset_id": 456, "status": "active" },
{ "id": 12, "name": "search_revenue_data", "nexset_id": 789, "status": "active" }
],
"export": {
"id": 1,
"export_type": "mcp_server",
"status": "active",
"mcp_url": "https://api-genai.nexla.io/mcp/service_key/sk_ts43_x7y8z9..."
},
"created_at": "2025-06-15T11:00:00Z",
"updated_at": "2025-06-15T11:00:00Z"
}
This is the fastest way to go from data to a working MCP server. One API call creates tools, bundles them, and deploys an MCP server.
Add Tools to ToolSet
POST /v1/toolsets/{id}/tools
Adds one or more existing tools to a ToolSet.
curl -X POST https://api-genai.nexla.io/v1/toolsets/42/tools \
-H "Authorization: Bearer $NEXLA_SERVICE_KEY" \
-H "Content-Type: application/json" \
-d '{
"tool_ids": [4, 5]
}'
{
"id": 42,
"name": "Customer Data Tools",
"tool_ids": [1, 2, 3, 4, 5],
"updated_at": "2025-06-15T12:00:00Z"
}
Remove Tools from ToolSet
DELETE /v1/toolsets/{id}/tools
Removes one or more tools from a ToolSet. The tools themselves are not deleted — they are only unlinked from the ToolSet.
curl -X DELETE https://api-genai.nexla.io/v1/toolsets/42/tools \
-H "Authorization: Bearer $NEXLA_SERVICE_KEY" \
-H "Content-Type: application/json" \
-d '{
"tool_ids": [3]
}'
{
"id": 42,
"name": "Customer Data Tools",
"tool_ids": [1, 2, 4, 5],
"updated_at": "2025-06-15T12:15:00Z"
}
Clone a ToolSet
POST /v1/toolsets/{id}:clone
Creates a complete copy of a ToolSet, including a new server key, a new ID, and a new export. Cloning is useful for creating environment-specific variants (e.g., dev vs. prod) or for duplicating a working configuration as a starting point.
curl -X POST https://api-genai.nexla.io/v1/toolsets/42:clone \
-H "Authorization: Bearer $NEXLA_SERVICE_KEY" \
-H "Content-Type: application/json"
{
"id": 55,
"name": "Customer Data Tools (clone)",
"status": "active",
"mcp_server_key": "sk_ts55_new_key...",
"tool_ids": [1, 2, 4, 5],
"export": {
"id": 5,
"export_type": "mcp_server",
"status": "active",
"mcp_url": "https://api-genai.nexla.io/mcp/service_key/sk_ts55_new_key..."
},
"created_at": "2025-06-15T13:00:00Z",
"updated_at": "2025-06-15T13:00:00Z"
}
Create an Export
POST /v1/toolsets/{id}/exports
Creates a new export for a ToolSet. An export defines how the ToolSet is served to external consumers — as an MCP server, a Copilot connector, an SDK bundle, or an HTTP catalog.
curl -X POST https://api-genai.nexla.io/v1/toolsets/42/exports \
-H "Authorization: Bearer $NEXLA_SERVICE_KEY" \
-H "Content-Type: application/json" \
-d '{
"export_type": "mcp_server",
"environment": "prod",
"public_name": "Production Customer Tools"
}'
{
"id": 7,
"toolset_id": 42,
"export_type": "mcp_server",
"environment": "prod",
"public_name": "Production Customer Tools",
"server_key": "sk_exp7_prod_abc123...",
"endpoint_url": "https://api-genai.nexla.io/mcp/service_key/sk_exp7_prod_abc123...",
"status": "active",
"created_at": "2025-06-15T14:00:00Z",
"updated_at": "2025-06-15T14:00:00Z"
}
Export Types
| Type | Description |
|---|---|
mcp_server | Deploys an MCP Streamable HTTP server |
copilot_connector | Creates a connector for Microsoft Copilot |
sdk_bundle | Generates an SDK-compatible tool bundle |
http_catalog | Exposes tools via a standard HTTP catalog |
Environments
| Environment | Description |
|---|---|
dev | Development — for testing and iteration |
stage | Staging — for pre-production validation |
prod | Production — for live consumer traffic |
Related Resources
- Tools API — Create and manage individual tools
- MCP Protocol — MCP Streamable HTTP and session management
- Gateway API — Register external MCP servers
- MCP Tools & Servers User Guide — UI workflows for ToolSets and exports