cURL
curl --request POST \ --url https://api.primeintellect.ai/api/v1/sandbox/{sandbox_id}/expose \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data ' { "port": 4511, "name": "<string>", "protocol": "HTTP" } '
{ "exposure_id": "<string>", "sandbox_id": "<string>", "port": 123, "protocol": "<string>", "url": "<string>", "tls_socket": "<string>", "name": "<string>" }
Expose a port from a sandbox
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Bearer <token>
<token>
Port number to expose (22-9000)
22 <= x <= 9000
Optional human-readable name for the exposure
50
Protocol (only HTTP supported currently)
Successful Response
Public URL for accessing the exposed port