iVendNextDevelopers Request a sandbox

A standalone portal with "Sign in with iVendNext" — the recipe

This recipe builds a web app of your own, on your own server, for people who already have accounts in a shop: a head-office view, a franchise portal, a manager's dashboard. The person signs in with their iVendNext account, and the portal shows only what that person's own permissions allow. Reference implementation: samples/s13_portal/ (the portal, its tests).

When to use it. When the screen cannot live inside the shop. If it can, use the shop's own screens first (guide chapter 13a, rung 1–4); a portal is rung 5.

Steps

  1. Ask the shop to register your app (recipes/sign_in.md §1): an OAuth Client with your exact redirect address (https://your.server/callback), scopes openid all. They give you the client id. To let only some roles into your app, they list them under Allowed Roles: the shop then stops anyone else at its own Allow step.

  2. Run the portal with three settings:

    PORTAL_SHOP=https://shop.example PORTAL_CLIENT_ID=… PORTAL_REDIRECT=https://your.server/callback python3 portal.py

    Put it behind HTTPS and set PORTAL_SECURE=1, so the session cookie is never sent in the clear.

  3. Give each person the permissions you want them to have — in the shop. The portal does no filtering of its own. A store user is fenced to their store by a User Permission on the store (the same way S8 and S14 do); the portal's list then holds only that store's sales. Change who sees what in the shop and the portal follows.

  4. Make your own pages with the kit. The sample's pages carry the kit's classes only, no colour or font of your own. Run the screen check on every page you ship: kit/design/tools/check_kit.sh your-page.html.

  5. Decide what to list. The sample lists the latest 20 sales (POS Invoice) with a link into the shop's Desk record. Replace it with the records your people need; ask only for the fields you show.

What is refused, and why

Your duties

Technical notes

What was proven, and where

Measured

Not proven

The shop's token ending during an 8-hour session (proven on the laptop only); the refresh token; HTTPS (the bench is plain HTTP on its own network); two portals on one client; many users at once; a person's browser was played by a script (the pages were checked by the screen check, not looked at by a person).

This page in the kit