Execute TypeScript code. fetch() is available. Code runs in async IIFE wrapper automatically after TypeScript transpiles to JavaScript. CRITICAL: Write plain statements with await/return, NOT wrapped in functions. For available indicators, use indicator.<ID>(marketSeries) or indicator["<ID>"](marketSeries) with full Historical Data output and an optional object of input-title overrides. Do not define indicator(...) or import pinets/PineTS in this block.
Raw TypeScript statements (NOT a function). Code is transpiled to JavaScript and auto-wrapped in async context. MUST use fetch() for HTTP (NOT xhr/axios/request libs). Write like: await fetch(url) then return result. Imports require E2B runtime support. For available indicators, pass the full Historical Data MarketSeries object, not a scalar series like <historical_data.close>. The optional second argument must be an object, for example indicator.RSI(<historical_data>, { Length: 7 }) or indicator["custom-indicator-id"](<historical_data>, { inputs: { Length: 7 } }). Use indicator.list() if the available ID is unknown. Do not import pinets or define indicator(...) directly.
Write TypeScript or JavaScript statements directly, using await and return without a function wrapper. Python is not supported. Code transpiles to JavaScript and runs in a local VM or an E2B sandbox, according to the deployment's E2B system-service configuration; there is no per-block runtime toggle. The default code timeout is 180 seconds, and workflow limits may end a run sooner. fetch() is available subject to URL restrictions; external imports require E2B runtime support. console.log() is captured in stdout. There is no automatically populated input object: use exact upstream tags such as <api.data>, workflow variables such as <variable.riskLimit>, and environment references such as {{API_KEY}}. For indicators, call await indicator.RSI(<historical_data>, { Length: 7 }) with the full Historical Data output and saved input titles; use indicator.list() to discover available IDs. Do not import PineTS or define an indicator in Function code. Execution errors fail the block and can be handled with an error-path connection.