Skip to content

Apps API

The Apps API manages the lifecycle of installed bundles (apps). You can list, install, uninstall, start, stop, and fetch UI resources for any app.

List all installed apps with their status, tool count, trust score, and UI metadata.

Response:

{
"apps": [
{
"name": "weather",
"bundleName": "@nimblebraininc/weather",
"version": "0.3.1",
"status": "running",
"type": "plain",
"toolCount": 3,
"trustScore": 85,
"ui": null
},
{
"name": "tasks",
"bundleName": "@nimblebraininc/tasks",
"version": "1.0.0",
"status": "running",
"type": "upjack",
"toolCount": 5,
"trustScore": 92,
"ui": {
"name": "Tasks",
"icon": "check-square",
"primaryView": { "resourceUri": "ui://tasks/board" }
}
}
]
}

App fields:

FieldTypeDescription
namestringShort server name used in API paths
bundleNamestringScoped manifest name (e.g., @nimblebraininc/weather)
versionstringVersion from the bundle manifest
statusstringLifecycle state: starting, running, crashed, dead, stopped
typestring"upjack" for Upjack apps, "plain" for standard MCP servers
toolCountnumberNumber of tools exposed by this app
trustScorenumberMTF trust score (0-100)
uiobject | nullUI metadata, or null if the app has no UI

Example:

Terminal window
curl http://localhost:27247/v1/apps \
-H "Authorization: Bearer your-secret-key"

Install a bundle from the mpak registry (by name), from a local directory (by path), or from a remote URL.

Request body:

Provide exactly one of name, path, or url:

FieldTypeRequiredDescription
namestringOne of threeBundle name from mpak (e.g., @nimblebraininc/weather)
pathstringOne of threeLocal filesystem path to a bundle directory
urlstringOne of threeURL of a remote MCP server
serverNamestringNoCustom server name (used with url installs)
transportobjectNoTransport config for remote servers (see below)
envobjectNoEnvironment variables to pass to the bundle process

The transport object (for url installs):

FieldTypeDescription
typestring"streamable-http" or "sse"
authobjectAuth config: {type: "bearer", token}, {type: "header", name, value}, or {type: "none"}
headersobjectExtra HTTP headers

Response:

{
"name": "weather",
"bundleName": "@nimblebraininc/weather",
"version": "0.3.1",
"status": "running",
"type": "plain",
"toolCount": 3,
"trustScore": 85,
"ui": null
}

Error responses:

StatuserrorCondition
400bad_requestNone or more than one of name, path, url provided
400credentials_requiredBundle requires API keys in the env field
409already_installedA bundle with this name is already installed
500install_failedInstallation failed (details in message)

Examples:

Terminal window
curl -X POST http://localhost:27247/v1/apps/install \
-H "Content-Type: application/json" \
-H "Authorization: Bearer your-secret-key" \
-d '{"name": "@nimblebraininc/weather"}'

Install response:

{
"name": "weather",
"bundleName": "@nimblebraininc/weather",
"version": "0.3.1",
"status": "running",
"type": "plain",
"toolCount": 3,
"trustScore": 85,
"ui": null
}

Uninstall an app. This stops the MCP server process and removes the app from the configuration. App data is preserved on disk at ~/.nimblebrain/apps/<name>/.

Path parameters:

ParameterDescription
:nameThe app’s short server name

Response:

{
"name": "weather",
"uninstalled": true,
"dataPreserved": true,
"dataPath": "~/.nimblebrain/apps/weather/"
}

Error responses:

StatuserrorCondition
403protectedBundle is protected from uninstall
404not_foundApp not found
500uninstall_failedUninstall failed

Example:

Terminal window
curl -X DELETE http://localhost:27247/v1/apps/weather \
-H "Authorization: Bearer your-secret-key"

Start a stopped app. If the app is already running, this is a no-op that returns the current status.

Path parameters:

ParameterDescription
:nameThe app’s short server name

Response:

{
"name": "weather",
"status": "running"
}

Error responses:

StatuserrorCondition
404not_foundApp not found
500start_failedStart failed

Example:

Terminal window
curl -X POST http://localhost:27247/v1/apps/weather/start \
-H "Authorization: Bearer your-secret-key"

Stop a running app. The MCP server process is terminated but the app remains in the configuration.

Path parameters:

ParameterDescription
:nameThe app’s short server name

Response:

{
"name": "weather",
"status": "stopped"
}

Error responses:

StatuserrorCondition
404not_foundApp not found
500stop_failedStop failed

Example:

Terminal window
curl -X POST http://localhost:27247/v1/apps/weather/stop \
-H "Authorization: Bearer your-secret-key"

Fetch a UI resource (HTML) served by an app’s MCP server. Apps that declare a primaryView in their manifest expose UI content through this endpoint.

Path parameters:

ParameterDescription
:nameThe app’s short server name
:pathResource path. Use primary to resolve the app’s primary view.

The special path primary resolves to the app’s primaryView.resourceUri from its manifest metadata. You do not need to know the specific resource URI.

Response:

Returns text/html content on success.

Error responses:

StatuserrorCondition
404not_foundApp not found
404resource_not_foundThe requested resource does not exist

Example:

Terminal window
curl http://localhost:27247/v1/apps/tasks/resources/primary \
-H "Authorization: Bearer your-secret-key"