Ready-to-use App examples for common API workflows.
The examples below are self-contained. Paste any of them into the App tab’s code editor, save, and activate App Mode to try them out.
bru.ctx data arrives asynchronously after page load. Always do the first render inside bru.ctx.onInit, then react to later changes via on*Change callbacks. Reading state at the top level or on DOMContentLoaded returns null or empty values.
Request Apps
Send a request and display the response
A minimal form that sends the parent request with a custom variable and renders the JSON response.
Add {{search}} somewhere in your request — URL, body, params, or headers. Bruno will interpolate it at runtime.
Renders the latest response instantly whenever one arrives — from the Send button, the runner, or another App call. No polling or manual refresh needed.
<pre id="out">Waiting for a response…</pre><script> function render(response) { document.getElementById('out').textContent = response ? JSON.stringify(response.data, null, 2) : 'Waiting for a response…'; } bru.ctx.onInit = () => render(bru.ctx.http.response); bru.ctx.http.onResponseChange = render;</script>
Login form with token display
Useful for any POST /login or POST /auth/token endpoint. Displays the status code and extracted token after a successful login.
Your request body should reference {{email}} and {{password}}.
JSX is transpiled in-browser via @babel/standalone. Pin to @7 (the newer automatic JSX runtime emits import statements that inline text/babel scripts cannot handle).