pages / example / key_login

example · key_login

canister coord://offchain/genie/program/key_login@v1/459e0b2f41bbe164 · v1 · artifact root 0x459e0b2f41bbe1646b20ffaf53e0efaf1a294d5c57c2837f183588b6654b4203 · previous none (first version) · superroot at publish not sealed yet

sealed cases that reached it: 0 — sealed cases that reached this word (the store counts, never reads)

the words it says

its helpdesk graph

key login (a .genie program) in the studio: 7 symptoms, 7 fixes

the source

// _GENIE_FLOW_v1_ — the key flow of the layer in the flow form: a visitor registers a tenant, accepts the documents its party
// signs, mints a key and makes the first billed call. Nothing bills before the acceptance: the layer answers 403 agreement_required
// at its doors, and the compiler refuses the program first. The door takes typed inputs; the runtime refuses a case without them.
genie key_login v1
about "The key flow: register, accept the documents, mint the key, the first billed call — the flow form, typed inputs, the acceptance native"

use product taifoon.api
use document TSUL-1.1 TAT
use party user

agent login is "one visitor, from the first visit to the first billed call under a key"
  flow visiting -> registered -> accepted -> keyed -> billed
  failed refused
  on case
  move visiting -> registered op POST /v1/register hop offer_in
  move registered -> accepted accepts TSUL-1.1 TAT as user signed clickwrap
  move accepted -> keyed op POST /v1/tenant/keys
  move keyed -> billed op POST /v1/chat/completions meter taifoon.api hop delivered
  move * -> refused when agreement.accepted == false
  refuse agreement_required "a product door refuses a key with no acceptance of the documents its party signs"
  say registered "Your tenant exists; the layer answered with the documents to accept"
  say billed "The first call is on the meter: one line under your key, the ecosystem cut among its legs"
  next visiting registered "Register: POST /v1/register answers the tenant and the documents"
  next registered accepted "Accept the Access Terms and the license by clicking through"
  next accepted keyed "Mint the key: POST /v1/tenant/keys"
  next keyed billed "Make the first call; every billed unit carries the key"

door "get a key" as login takes email: string plan?: string tenant?: HdTenant
  product taifoon.api
  step visiting "Register with your email; the layer answers the documents your party signs" next registered opens registered
  step registered "Read and accept the Access Terms and the license" next accepted
  step accepted "Mint your first key: a sandbox one and a live one" next keyed
  step keyed "Make the first call with the key; the meter line is yours to read" next billed
  step billed "You are on the meter; the cockpit shows every line"
  ask "Which plan do you want to start on?"
  handoff "a key that answers 403 after the acceptance is a person's case" booking https://cal.com/taifoon meet https://meet.jit.si room genie-key-login

knowledge
  symptom "the first call answers 403 agreement_required" caused_by "the key accepted no document, or a child key whose reseller accepted none" fixed_by "accept the documents under the key (POST /v1/access/agreements) and call again"
  policy "every billed unit carries a key under an accepted agreement; the meter line carries the ecosystem cut"