Skip to main content
POST
Create a computer environment

Authorizations

Authorization
string
header
required

MCPJam API key (sk_…). Create one at Settings → API keys. Guest sessions cannot use the API, and API keys cannot manage other API keys.

Path Parameters

projectId
string
required

ID of the hosted project that contains the server.

Body

application/json

Create an environment from a Dockerfile. The Dockerfile must start FROM an allowlisted official base pinned by @sha256 digest; only FROM + RUN are supported.

name
string
required

Display name for the new environment; must be non-empty after trimming.

Minimum string length: 1
dockerfile
string
required

Dockerfile text.

Minimum string length: 1

Response

The environment was created.

A project's custom Computer image: a digest-pinned Dockerfile plus its latest build.

id
string
required
projectId
string
required
name
string
required
dockerfile
string
required
contentHash
string
required
sharing
enum<string>
required

user = a personal draft; project = shared with the whole project.

Available options:
user,
project
isOwner
boolean
required
currentBuild
object | null
required

One build of an environment's image.

createdAt
number
required
updatedAt
number
required