This is a basic Next.js project that embeds a Rill dashboard. It embeds the demo/rill-openrtb-prog-ads/bids dashboard and is deployed using Netlify to rill-embedding-example.netlify.app.
See the Embed Dashboards docs page for more details.
First, create a Rill service token:
rill service create rill-embedding-tokenSecond, write it to a .env file (which is gitignored):
cat "RILL_SERVICE_TOKEN=<INSERT TOKEN>" > .envThird, update the rillOrg, rillProject, and rillDashboard variables in pages/api/iframe.js to reflect the dashboard you want to embed:
const rillOrg = "demo";
const rillProject = "rill-openrtb-prog-ads";
const rillDashboard = "bids";Lastly, run the development server:
npm install
npm run devOpen http://localhost:3000 with your browser to see the result.