Start a process, stream its captured output over Server-Sent Events, and receive a final exit event.Use this endpoint when you want a single request for non-interactive command execution. If the process needs stdin, use Start Process, Process Stdin, and Close Process Stdin instead.
env defaults to {} and is applied to the process environment.
working_dir is optional.
user is optional and accepts a username, UID string, uid:gid string, or an object such as {"uid": 1000, "gid": 1000}.
timeout is optional. When set, Tensorlake kills the process if it is still running after that many seconds.
/processes/run always starts the process with stdin closed and stdout/stderr captured, even if stdin_mode, stdout_mode, or stderr_mode are present in the request body.
The first event contains handle, pid, and started_at. Output events contain line, timestamp, and stream. The final event contains exit_code or signal; if the kernel OOM killer ended the process, it includes signal: 9 and oom_killed: true.
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"Tensorlake","colors":{"primary":"#047857","light":"#047857","dark":"#0D1117"},"logo":{"light":"https://mintcdn.com/tensorlake-35e9e726/pfTs6FweN5gDe2IY/logo/TL-Light.svg?fit=max\u0026auto=format\u0026n=pfTs6FweN5gDe2IY\u0026q=85\u0026s=de3c3b6e814425b1be6902f8af88b719","dark":"https://mintcdn.com/tensorlake-35e9e726/pfTs6FweN5gDe2IY/logo/TL-Dark.svg?fit=max\u0026auto=format\u0026n=pfTs6FweN5gDe2IY\u0026q=85\u0026s=b08c049d9fabd32c205f6e8d9f621ba3"},"favicon":"https://mintcdn.com/tensorlake-35e9e726/fVE8-oNRlpqs-U2A/logo/favicon.png?fit=max\u0026auto=format\u0026n=fVE8-oNRlpqs-U2A\u0026q=85\u0026s=15a7031809c3f949e46d8b9c926c28f4","api":{"openapi":"api-reference/openapi.yaml","playground":{"display":"interactive"},"mdx":{"auth":{"method":"bearer"},"server":"https://api.tensorlake.ai/"}},"appearance":{"default":"system"},"navbar":{"links":[{"href":"https://tensorlake.ai/blog","label":"Blog"},{"href":"https://join.slack.com/t/tensorlakecloud/shared_invite/zt-32fq4nmib-gO0OM5RIar3zLOBm~ZGqKg","label":"Slack"},{"href":"https://github.com/tensorlakeai/tensorlake","label":"GitHub"}],"primary":{"type":"button","label":"Dashboard","href":"https://cloud.tensorlake.ai/login"}},"footer":{"socials":{"website":"https://www.tensorlake.ai/","x":"https://x.com/tensorlake","github":"https://github.com/tensorlakeai","linkedin":"https://linkedin.com/company/tensorlake","bluesky":"https://bsky.app/profile/tensorlake.bsky.social"}},"seo":{"metatags":{"og:type":"website","og:site_name":"Tensorlake Documentation","og:title":"Tensorlake Documentation","og:description":"Build with Tensorlake: secure and stateful sandboxes for AI agents, durable orchestration for long-running workflows","og:url":"https://docs.tensorlake.ai","og:locale":"en_US","twitter:card":"summary_large_image","twitter:site":"@tensorlake","twitter:creator":"@tensorlake","twitter:title":"Tensorlake Documentation","twitter:description":"Sandboxes and orchestration for AI agents.","og:image":"https://docs.tensorlake.ai/images/og-preview.png","og:image:width":"2400","og:image:height":"1260","twitter:image":"https://docs.tensorlake.ai/images/og-preview.png","description":"Tensorlake Documentation— secure and stateful sandboxes for AI agents, durable workflow orchestration for long-running workflows, covers in Python and TypeScript SDKs plus CLI","keywords":"AI agents, sandboxes, stateful sandboxes, durable execution, agent orchestration, agentic workflows","author":"Tensorlake","robots":"index, follow, max-image-preview:large, max-snippet:-1","googlebot":"index, follow"},"indexing":"all"},"fonts":{"family":"Inter"},"integrations":{"ga4":{"measurementId":"G-EBFHHWKKQM"}},"contextual":{"options":["claude","chatgpt","cursor","grok","copy","view"],"display":"header"},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"tensorlake-35e9e726","hasAudioNarration":false,"actualSubdomain":"tensorlake-35e9e726","customDomains":["docs.tensorlake.ai"],"gitSource":{"type":"github","owner":"tensorlakeai","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6ad946de658b2a79ae61e3f2","collectionId":"cb2581eb-838e-4e8e-afb0-11cd88dd423c","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6ad946de658b2a79ae61e3f2"},"feedback":{"thumbs":true,"edits":true,"issues":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6ae18ee053a72d97e552f548","clientVersion":"0.0.3990","searchFilterCounts":[{"language":"default","tag":"Sandboxes","count":90},{"language":"default","tag":"API Reference","count":48},{"language":"default","tag":"Guides","count":41},{"language":"default","tag":"Overview","count":25},{"language":"default","tag":"Orchestrate","count":24},{"language":"default","tag":"Use Cases","count":23},{"language":"default","tag":"Process Management","count":15},{"language":"default","tag":"Life Cycle Management","count":13},{"language":"default","tag":"Platform Features","count":13},{"language":"default","tag":"Cloud Volumes","count":9}]},"assistantConfig":{},"basePath":"","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-v7-file-tree","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"pause-universal-search-reconcile","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"per-site-search-delta","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-private-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-nav-generations","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"byok-sep-25","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-agent-model-picker","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-updated-9-15","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"isAtlas":false,"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"api-reference/v2/processes/run","slug":"/api-reference/v2/processes/run","pageMetadata":{"title":"Run Process","openapi":"post /api/v1/processes/run","og:image":"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png","twitter:image":"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png","description":"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.","href":"/api-reference/v2/processes/run"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={a:`a`,code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Note}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Note)_missingMdxReference(`Note`,true);return _jsxs(_Fragment,{children:[_jsx(_components.p,{children:`Start a process, stream its captured output over Server-Sent Events, and receive a final exit event.`}),`\n`,_jsxs(_components.p,{children:[`Use this endpoint when you want a single request for non-interactive command execution. If the process needs stdin, use `,_jsx(_components.a,{href:`/api-reference/v2/processes/start`,children:`Start Process`}),`, `,_jsx(_components.a,{href:`/api-reference/v2/processes/stdin`,children:`Process Stdin`}),`, and `,_jsx(_components.a,{href:`/api-reference/v2/processes/close-stdin`,children:`Close Process Stdin`}),` instead.`]}),`\n`,_jsx(Heading,{level:`2`,id:`endpoint`,children:`Endpoint`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`1`,language:`http`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`http`,children:_jsxs(_components.code,{language:`http`,numberOfLines:`1`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#C586C0`},children:`POST`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:` /api/v1/processes/run`})]}),`\n`]})})}),`\n`,_jsx(_components.p,{children:`Use this endpoint on the sandbox proxy host:`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`2`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`2`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`https://\u003csandbox-id-or-name>.sandbox.tensorlake.ai/api/v1/processes/run`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsx(Heading,{level:`2`,id:`example-request`,children:`Example Request`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`10`,language:`shellscript`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`shellscript`,children:_jsxs(_components.code,{language:`shellscript`,numberOfLines:`10`,children:[_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#953800`,\"--shiki-dark\":`#DCDCAA`},children:`curl`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -N`}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -X`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` POST`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` https://`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`\u003c`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`sandbox-i`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`d`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D4D4D4`},children:`>`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`.sandbox.tensorlake.ai/api/v1/processes/run`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Authorization: Bearer `}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#9CDCFE`},children:`$TENSORLAKE_API_KEY`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -H`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"Content-Type: application/json\"`}),_jsx(_components.span,{style:{color:`#CF222E`,\"--shiki-dark\":`#D7BA7D`},children:` \\\\`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:` -d`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` '{`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"command\": \"python\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"args\": [\"-c\", \"import os; print(os.environ[\\\\\"MODE\\\\\"])\"],`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"env\": {\"MODE\": \"batch\"},`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"working_dir\": \"/workspace\",`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` \"timeout\": 30`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:` }'`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`request-body`,children:`Request Body`}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`8`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`8`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"command\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"python\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"args\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: [`}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"-c\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`, `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"print('hello')\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`],`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"env\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: {`}),_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:`\"MODE\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"batch\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`},`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"working_dir\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"/workspace\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"user\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"tl-user\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"timeout\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#B5CEA8`},children:`30`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`command`}),` is required.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`args`}),` defaults to `,_jsx(_components.code,{children:`[]`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`env`}),` defaults to `,_jsx(_components.code,{children:`{}`}),` and is applied to the process environment.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`working_dir`}),` is optional.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`user`}),` is optional and accepts a username, UID string, `,_jsx(_components.code,{children:`uid:gid`}),` string, or an object such as `,_jsx(_components.code,{children:`{\"uid\": 1000, \"gid\": 1000}`}),`.`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`timeout`}),` is optional. When set, Tensorlake kills the process if it is still running after that many seconds.`]}),`\n`]}),`\n`,_jsx(Note,{children:_jsxs(_components.p,{children:[_jsx(_components.code,{children:`/processes/run`}),` always starts the process with stdin closed and stdout/stderr captured, even if `,_jsx(_components.code,{children:`stdin_mode`}),`, `,_jsx(_components.code,{children:`stdout_mode`}),`, or `,_jsx(_components.code,{children:`stderr_mode`}),` are present in the request body.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`sse-events`,children:`SSE Events`}),`\n`,_jsxs(_components.p,{children:[`Tensorlake streams JSON payloads in SSE `,_jsx(_components.code,{children:`data:`}),` frames:`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`text`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`text`,children:_jsxs(_components.code,{language:`text`,numberOfLines:`6`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`data: {\"handle\":1,\"pid\":42,\"started_at\":1710000000000}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`data: {\"line\":\"hello\",\"timestamp\":1710000000010,\"stream\":\"stdout\"}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{children:`data: {\"exit_code\":0}`})}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{})})]})})}),`\n`,_jsxs(_components.p,{children:[`The first event contains `,_jsx(_components.code,{children:`handle`}),`, `,_jsx(_components.code,{children:`pid`}),`, and `,_jsx(_components.code,{children:`started_at`}),`. Output events contain `,_jsx(_components.code,{children:`line`}),`, `,_jsx(_components.code,{children:`timestamp`}),`, and `,_jsx(_components.code,{children:`stream`}),`. The final event contains `,_jsx(_components.code,{children:`exit_code`}),` or `,_jsx(_components.code,{children:`signal`}),`; if the kernel OOM killer ended the process, it includes `,_jsx(_components.code,{children:`signal: 9`}),` and `,_jsx(_components.code,{children:`oom_killed: true`}),`.`]})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Run Process","openapi":"post /api/v1/processes/run","og:image":"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png","twitter:image":"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png","description":"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.","href":"/api-reference/v2/processes/run"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Endpoint","slug":"endpoint","depth":2,"children":[]},{"title":"Example Request","slug":"example-request","depth":2,"children":[]},{"title":"Request Body","slug":"request-body","depth":2,"children":[]},{"title":"SSE Events","slug":"sse-events","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":["/_mintlify/custom/tensorlake-35e9e726/1373ae293ad67675/plausible.js"],"openApiReferenceData":{"operation":{"tags":["sandbox-processes"],"summary":"Run a process","description":"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.","operationId":"sandbox_process_run","requestBody":"feeaea74-fc78-4b87-b3f7-da372163bbbf","responses":{"200":"5aea63dd-3619-4546-a16e-313c7585cf2b","409":"a7c66d3c-2451-41b6-b3c4-b6054e04b9b6","500":"b0f75efd-d3f9-4061-beb3-179be6e4f08d"},"method":"post","type":"path","servers":["8d625253-b1fc-461e-a276-d7b1de09c2a3"],"security":["78658037-3db0-4fc5-b34d-44ec08e461f1"],"path":"/api/v1/processes/run","baseUrlOptions":["https://{identifier}.sandbox.tensorlake.ai"],"title":"Run a process","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["command"],"properties":{"command":{"type":"string","isRequired":true,"uniqueKey":"command","typeLabel":"string"},"args":{"type":"array","items":{"type":"string","uniqueKey":"args.items.[INDEX]","typeLabel":"string"},"uniqueKey":"args","typeLabel":"string[]"},"env":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"env.additionalProperties","typeLabel":"string"},"uniqueKey":"env","typeLabel":"object"},"working_dir":{"type":"string","uniqueKey":"working_dir","typeLabel":"string"},"user":{"oneOf":[{"type":"string","description":"Username, UID string, or uid:gid string.","uniqueKey":"user.oneOf.0","typeLabel":"string"},{"type":"object","properties":{"name":{"type":"string","uniqueKey":"user.oneOf.1.name","typeLabel":"string"},"uid":{"type":"integer","format":"int32","uniqueKey":"user.oneOf.1.uid","typeLabel":"integer\u003cint32>"},"gid":{"type":"integer","format":"int32","uniqueKey":"user.oneOf.1.gid","typeLabel":"integer\u003cint32>"}},"uniqueKey":"user.oneOf.1","typeLabel":"object"}],"uniqueKey":"user","typeLabel":"string | object"},"timeout":{"type":"number","format":"double","description":"Maximum seconds to wait before killing the process.","uniqueKey":"timeout","typeLabel":"number\u003cdouble>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"command":"\u003cstring>","args":["\u003cstring>"],"env":{},"working_dir":"\u003cstring>","user":"\u003cstring>","timeout":123}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"5aea63dd-3619-4546-a16e-313c7585cf2b":{"description":"Process event stream","content":{"text/event-stream":{"schema":{"oneOf":[{"type":"object","description":"JSON payload carried in each Server-Sent Events `data:` frame from `/api/v1/processes/run`.","required":["handle","pid","started_at"],"properties":{"handle":{"type":"integer","format":"int64","isRequired":true,"uniqueKey":"oneOf.0.handle","typeLabel":"integer\u003cint64>"},"pid":{"type":"integer","format":"int32","isRequired":true,"uniqueKey":"oneOf.0.pid","typeLabel":"integer\u003cint32>"},"started_at":{"type":"integer","format":"int64","isRequired":true,"uniqueKey":"oneOf.0.started_at","typeLabel":"integer\u003cint64>"}},"uniqueKey":"oneOf.0","typeLabel":"object"},{"type":"object","description":"JSON payload carried in each Server-Sent Events `data:` frame from `/api/v1/processes/run`.","required":["line","timestamp"],"properties":{"line":{"type":"string","isRequired":true,"uniqueKey":"oneOf.1.line","typeLabel":"string"},"timestamp":{"type":"integer","format":"int64","isRequired":true,"uniqueKey":"oneOf.1.timestamp","typeLabel":"integer\u003cint64>"},"stream":{"type":"string","enum":["stdout","stderr"],"uniqueKey":"oneOf.1.stream","typeLabel":"enum\u003cstring>"}},"uniqueKey":"oneOf.1","typeLabel":"object"},{"type":"object","description":"JSON payload carried in each Server-Sent Events `data:` frame from `/api/v1/processes/run`.","properties":{"exit_code":{"oneOf":[{"type":"integer","format":"int32","uniqueKey":"oneOf.2.exit_code.oneOf.0","typeLabel":"integer\u003cint32>"},{"type":"null","format":"int32","uniqueKey":"oneOf.2.exit_code.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.exit_code","typeLabel":"integer\u003cint32> | null"},"signal":{"oneOf":[{"type":"integer","format":"int32","uniqueKey":"oneOf.2.signal.oneOf.0","typeLabel":"integer\u003cint32>"},{"type":"null","format":"int32","uniqueKey":"oneOf.2.signal.oneOf.1","typeLabel":"null"}],"uniqueKey":"oneOf.2.signal","typeLabel":"integer\u003cint32> | null"},"oom_killed":{"type":"boolean","uniqueKey":"oneOf.2.oom_killed","typeLabel":"boolean"}},"uniqueKey":"oneOf.2","typeLabel":"object"}],"uniqueKey":"","typeLabel":"object"},"examples":{"started":{"title":"started","value":"data: {\"handle\":1,\"pid\":42,\"started_at\":1710000000000}\n\n"},"output":{"title":"output","value":"data: {\"line\":\"hello\",\"timestamp\":1710000000010,\"stream\":\"stdout\"}\n\n"},"exited":{"title":"exited","value":"data: {\"exit_code\":0}\n\n"}},"exampleType":"examples"}},"exampleType":"examples"},"a7c66d3c-2451-41b6-b3c4-b6054e04b9b6":{"description":"The sandbox is suspended and automatic resume is disabled. The proxy rejects the request without waking it. Explicitly resume before retrying, or PATCH auto_resume to true to allow subsequent traffic to wake it.","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","uniqueKey":"code","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"example":{"error":"Sandbox 'parked-agent' is suspended and automatic resume is disabled; resume it explicitly before sending traffic.","code":"SANDBOX_AUTO_RESUME_DISABLED"},"examples":{"Example":{"title":"Example","value":{"error":"Sandbox 'parked-agent' is suspended and automatic resume is disabled; resume it explicitly before sending traffic.","code":"SANDBOX_AUTO_RESUME_DISABLED"}}},"exampleType":"examples"}},"exampleType":"examples"},"b0f75efd-d3f9-4061-beb3-179be6e4f08d":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","required":["error"],"properties":{"error":{"type":"string","isRequired":true,"uniqueKey":"error","typeLabel":"string"},"code":{"type":"string","uniqueKey":"code","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"\u003cstring>","code":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"78658037-3db0-4fc5-b34d-44ec08e461f1":{"bearerAuth":{"type":"http","scheme":"bearer","scopes":[],"schemeName":"bearerAuth"}}},"servers":{"8d625253-b1fc-461e-a276-d7b1de09c2a3":{"url":"https://{identifier}.sandbox.tensorlake.ai","description":"Example sandbox proxy host for a specific running sandbox. For programmatic access, use the sandbox's `ingress_endpoint`.","variables":{"identifier":{"default":"example-sandbox","description":"The sandbox ID or sandbox name."}}}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"http","scheme":"bearer","scopes":[],"schemeName":"bearerAuth"},"schema":{"title":"Bearer Auth","type":"string","isRequired":true,"description":"Bearer authentication header of the form `Bearer \u003ctoken>`, where `\u003ctoken>` is your auth token.","format":"bearer","typeLabel":"string\u003cbearer>","deprecated":false},"schemeName":"bearerAuth","name":"Authorization"}],"title":"bearerAuth"}]},"originalFileLocation":"api-reference/openapi.yaml"},"subdomain":"tensorlake-35e9e726","siteName":"Tensorlake","title":"Tensorlake Documentation","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-06-07T07:01:44.177Z","originalFileLocation":"api-reference/v2/processes/run.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"description\" content=\"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.\">\u003cmeta data-mint-head name=\"keywords\" content=\"AI agents, sandboxes, stateful sandboxes, durable execution, agent orchestration, agentic workflows\">\u003cmeta data-mint-head name=\"application-name\" content=\"Tensorlake\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003cmeta data-mint-head name=\"robots\" content=\"index, follow, max-image-preview:large, max-snippet:-1\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Tensorlake Documentation\">\u003cmeta data-mint-head property=\"og:description\" content=\"Build with Tensorlake: secure and stateful sandboxes for AI agents, durable orchestration for long-running workflows\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"Tensorlake Documentation\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.tensorlake.ai/api-reference/v2/processes/run\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Tensorlake Documentation\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Sandboxes and orchestration for AI agents.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/mintlify-assets/_mintlify/favicons/tensorlake-35e9e726/jzD554Nmq8Zqors6/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"Tensorlake\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#047857\">\u003cmeta data-mint-head name=\"og:locale\" content=\"en_US\">\u003cmeta data-mint-head name=\"twitter:creator\" content=\"@tensorlake\">\u003cmeta data-mint-head name=\"author\" content=\"Tensorlake\">\u003cmeta data-mint-head name=\"googlebot\" content=\"index, follow\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.tensorlake.ai/api-reference/v2/processes/run\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/api-reference/v2/processes/run.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.tensorlake.ai/#organization\",\"name\":\"Tensorlake\",\"url\":\"https://docs.tensorlake.ai\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/tensorlake-35e9e726/pfTs6FweN5gDe2IY/logo/TL-Light.svg?fit=max\u0026auto=format\u0026n=pfTs6FweN5gDe2IY\u0026q=85\u0026s=de3c3b6e814425b1be6902f8af88b719\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.tensorlake.ai#website\",\"name\":\"Tensorlake\",\"url\":\"https://docs.tensorlake.ai\",\"publisher\":{\"@id\":\"https://docs.tensorlake.ai/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run#webpage\",\"url\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run\",\"name\":\"Run Process\",\"description\":\"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.\",\"dateModified\":\"2026-06-07T07:01:44.177Z\",\"isPartOf\":{\"@id\":\"https://docs.tensorlake.ai#website\"},\"breadcrumb\":{\"@id\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Sandboxes\",\"item\":\"https://docs.tensorlake.ai/api-reference/v2/sandboxes/create\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Process Management\",\"item\":\"https://docs.tensorlake.ai/api-reference/v2/processes/introduction\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Run Process\",\"item\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run#apireference\",\"headline\":\"Run Process\",\"name\":\"Run Process\",\"description\":\"Start a non-interactive process, stream captured output over Server-Sent Events, and emit a final exit event. Stdin is closed for this endpoint.\",\"url\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run\",\"mainEntityOfPage\":{\"@id\":\"https://docs.tensorlake.ai/api-reference/v2/processes/run#webpage\"},\"image\":\"https://docs.tensorlake.ai/images/og/api-reference-v2-processes-run.png\",\"dateModified\":\"2026-06-07T07:01:44.177Z\",\"publisher\":{\"@id\":\"https://docs.tensorlake.ai/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.tensorlake.ai#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"Tensorlake\",\"creator\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","siteName":"Tensorlake","nav":{"global":null,"tabs":[{"tab":"Sandboxes","pages":[{"title":"Sandboxes","href":"/sandboxes/introduction"}]},{"tab":"GitHub Actions","pages":[{"title":"GitHub Actions","href":"/github-actions/quickstart"}]},{"tab":"Cloud Volumes","pages":[{"title":"Cloud Volumes","href":"/filesystems/introduction"}]},{"tab":"Git Repositories","pages":[{"title":"Git Repositories","href":"/git/introduction"}]},{"tab":"Orchestrate","pages":[{"title":"Orchestrate","href":"/applications/introduction"}]},{"tab":"Platform Features","pages":[{"title":"Platform Features","href":"/platform/authentication"}]},{"tab":"API Reference","groups":[{"group":"API Documentation","pages":[{"title":"Introduction","href":"/api-reference/v2/introduction"}]},{"group":"Sandboxes","pages":[{"group":"Life Cycle Management","pages":[{"title":"Create Sandbox","openapi":"post /sandboxes","href":"/api-reference/v2/sandboxes/create"},{"title":"List sandboxes","sidebarTitle":"List Sandboxes","openapi":"get /sandboxes","href":"/api-reference/v2/sandboxes/list"},{"title":"Get Sandbox","openapi":"get /sandboxes/{sandbox_id}","href":"/api-reference/v2/sandboxes/get"},{"title":"Update Sandbox","openapi":"patch /sandboxes/{sandbox_id}","href":"/api-reference/v2/sandboxes/update"},{"title":"Delete Sandbox","openapi":"delete /sandboxes/{sandbox_id}","href":"/api-reference/v2/sandboxes/delete"},{"title":"Snapshot Sandbox","openapi":"post /sandboxes/{sandbox_id}/snapshot","href":"/api-reference/v2/sandboxes/snapshot"},{"title":"Copy Sandbox","openapi":"post /sandboxes/{sandbox_id}/copy","href":"/api-reference/v2/sandboxes/copy"},{"title":"Restore Sandbox","openapi":"post /sandboxes","href":"/api-reference/v2/sandboxes/restore"},{"title":"Suspend Sandbox","openapi":"post /sandboxes/{sandbox_id}/suspend","href":"/api-reference/v2/sandboxes/suspend"},{"title":"Resume Sandbox","openapi":"post /sandboxes/{sandbox_id}/resume","href":"/api-reference/v2/sandboxes/resume"},{"title":"Restart Sandbox","openapi":"post /sandboxes/{sandbox_id}/restart","href":"/api-reference/v2/sandboxes/restart"},{"title":"Attach Filesystem","openapi":"post /sandboxes/{sandbox_id}/file_systems","href":"/api-reference/v2/sandboxes/attach-filesystem"},{"title":"Detach Filesystem","openapi":"delete /sandboxes/{sandbox_id}/file_systems","href":"/api-reference/v2/sandboxes/detach-filesystem"}]},{"group":"Process Management","pages":[{"title":"Sandbox Processes API Overview","sidebarTitle":"Overview","href":"/api-reference/v2/processes/introduction"},{"title":"Start Process","openapi":"post /api/v1/processes","description":"Start a new process through the sandbox proxy, for example on `https://\u003csandbox-id-or-name>.sandbox.tensorlake.ai`.","href":"/api-reference/v2/processes/start"},{"title":"Run Process","openapi":"post /api/v1/processes/run","href":"/api-reference/v2/processes/run"},{"title":"List Processes","openapi":"get /api/v1/processes","description":"List the processes tracked inside a sandbox through the sandbox proxy.","href":"/api-reference/v2/processes/list"},{"title":"Get Process","openapi":"get /api/v1/processes/{pid}","href":"/api-reference/v2/processes/get"},{"title":"Kill Process","openapi":"delete /api/v1/processes/{pid}","href":"/api-reference/v2/processes/kill"},{"title":"Send Signal","openapi":"post /api/v1/processes/{pid}/signal","href":"/api-reference/v2/processes/signal"},{"title":"Process Stdin","openapi":"post /api/v1/processes/{pid}/stdin","href":"/api-reference/v2/processes/stdin"},{"title":"Close Process Stdin","openapi":"post /api/v1/processes/{pid}/stdin/close","href":"/api-reference/v2/processes/close-stdin"},{"title":"Get Process Stdout","openapi":"get /api/v1/processes/{pid}/stdout","href":"/api-reference/v2/processes/stdout"},{"title":"Get Process Stderr","openapi":"get /api/v1/processes/{pid}/stderr","href":"/api-reference/v2/processes/stderr"},{"title":"Get Process Output","openapi":"get /api/v1/processes/{pid}/output","href":"/api-reference/v2/processes/output"},{"title":"Follow Process Stdout","openapi":"get /api/v1/processes/{pid}/stdout/follow","href":"/api-reference/v2/processes/follow-stdout"},{"title":"Follow Process Stderr","openapi":"get /api/v1/processes/{pid}/stderr/follow","href":"/api-reference/v2/processes/follow-stderr"},{"title":"Follow Process Output","openapi":"get /api/v1/processes/{pid}/output/follow","href":"/api-reference/v2/processes/follow-output"}]},{"group":"Runtime Metadata","pages":[{"title":"Runtime Health","openapi":"get /api/v1/health","href":"/api-reference/v2/runtime/health"},{"title":"Runtime Info","openapi":"get /api/v1/info","href":"/api-reference/v2/runtime/info"},{"title":"Get resource usage","sidebarTitle":"Get Resource Usage","openapi":"get /api/v1/resource-usage","href":"/api-reference/v2/runtime/resource-usage"}]},{"group":"File Management","pages":[{"title":"Sandbox Files API Overview","sidebarTitle":"Overview","href":"/api-reference/v2/sandbox-files/introduction"},{"title":"Read File","openapi":"get /api/v1/files","href":"/api-reference/v2/sandbox-files/read"},{"title":"Write File","openapi":"put /api/v1/files","href":"/api-reference/v2/sandbox-files/write"},{"title":"Delete File","openapi":"delete /api/v1/files","href":"/api-reference/v2/sandbox-files/delete"},{"title":"List Directory","openapi":"get /api/v1/files/list","href":"/api-reference/v2/sandbox-files/list"}]},{"group":"PTY Sessions","pages":[{"title":"Sandbox PTY API Overview","sidebarTitle":"Overview","href":"/api-reference/v2/pty/introduction"},{"title":"Create PTY Session","openapi":"post /api/v1/pty","href":"/api-reference/v2/pty/create"},{"title":"List PTY Sessions","openapi":"get /api/v1/pty","href":"/api-reference/v2/pty/list"},{"title":"Get PTY Session","openapi":"get /api/v1/pty/{session_id}","href":"/api-reference/v2/pty/get"},{"title":"Resize PTY Session","openapi":"post /api/v1/pty/{session_id}/resize","href":"/api-reference/v2/pty/resize"},{"title":"Attach PTY WebSocket","openapi":"get /api/v1/pty/{session_id}/ws","href":"/api-reference/v2/pty/websocket"},{"title":"Kill PTY Session","openapi":"delete /api/v1/pty/{session_id}","href":"/api-reference/v2/pty/kill"}]},{"group":"TCP Tunnels","pages":[{"title":"TCP Tunnel WebSocket","openapi":"get /api/v1/tunnels/tcp","href":"/api-reference/v2/tunnels/tcp"}]},{"group":"SSH Lifecycle","pages":[{"title":"SSH Status","openapi":"get /api/v1/ssh/status","href":"/api-reference/v2/ssh/status"},{"title":"Enable SSH","openapi":"post /api/v1/ssh/enable","href":"/api-reference/v2/ssh/enable"},{"title":"Disable SSH","openapi":"post /api/v1/ssh/disable","href":"/api-reference/v2/ssh/disable"}]}]}]},{"tab":"FAQ","pages":[{"title":"FAQ","href":"/faqs/sandboxes-faq"}]}]},"title":"Tensorlake Documentation","buildId":"dpl_2oYXwqkEXirXBPk8wV1FtM5USFWi","deploymentId":"dpl_2oYXwqkEXirXBPk8wV1FtM5USFWi","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-WRhTSUDL.js","utils-ChMov4Kr.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-_REmC2bI.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-Bp6nVRCu.js","snippetPresets-DZadmXoU.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-CY2WdoTl.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-DwYG-Q4l.js","shallow-BXQIGwv4.js","getApiPlaygroundDisplay-CK5nK5B9.js","CodeSnippet-TH4a2aGW.js","CodeSnippets-DwsQiOFS.js","Page-R3M_BF4L.js","getPastedJson-DD7kUzi_.js","icon-holE3QoJ.js","MethodPill-DUW0T8us.js","DuplicateIcon-CI_p4be-.js","createIcon-BdbRvavb.js","DynamicMarkdown-DN96a4Ur.js","SectionHeading-SCu36A9d.js","axios-vUo_bRtp.js","Markdown-CCeGv-zI.js","clsx-BGBGWFTt.js","lib--scc4DXi.js","lib-B8HbPgcC.js","html-void-elements-mCSPHezU.js","dist-Cv_O2fky.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","AssistantPageLink-2C5OB2eV.js"]}