Runtime

When a script is saved, a new runtime environment is created which contains all routes, policies, triggers, jobs, and object exports. Runtime environments can be accessed via the environment or the environment object scripts.

"Runtime" decorators are evaluated during execution. The differentiation between static and runtime exists in Cortex because static runtime are evaluated at compile-time.

return (env.read('runtime')).routes.map(route => {

  const { configuration: { method, path } } = route

  return `${method} /routes/${path}`

})

Last updated