Skip to main content
POST
/
api
/
v2
/
external
/
execution
/
streaming
/
start
Start Python execution
curl --request POST \
  --url https://api.example.com/api/v2/external/execution/streaming/start \
  --header 'Content-Type: application/json' \
  --data '
{
  "code": "<string>",
  "nbcode": 0,
  "timeout": 60,
  "requirements_content": "<string>",
  "prior_imports": [
    "<string>"
  ],
  "kernel_state": "<string>",
  "import_files": "<string>",
  "file_name": "<string>",
  "execution_type": "gpu.l40s",
  "user_callback_urls": [
    "<string>"
  ]
}
'
{
  "execution_id": "<string>",
  "status": "<string>",
  "streaming_url": "<string>"
}

Body

application/json

Request model for streaming code execution

code
string
required
nbcode
integer
default:0
timeout
integer
default:60
Required range: 1 <= x <= 600
requirements_content
string | null
prior_imports
string[] | null
kernel_state
string | null
import_files
string | null
file_name
string | null
execution_type
string
default:gpu.l40s
Pattern: ^[a-zA-Z0-9_.]+$
user_callback_urls
string[] | null

URLs to call with job completion info

Response

Successful Response

Response model with direct streaming URL

execution_id
string
required
status
string
required
streaming_url
string
required