Skip to content

identity

Identity: who people are and what proves it.

On this page 6
TypeScript
import { identity } from "copilotz/plugins/access";

What it keeps

It keeps 2 collections, each on the record: every change to one is an event.

CollectionKept asFields
credentialdocumentskind, person, hint, expires, staff, at
persondocumentsname, email, picture, accounts, at

Its named queries read for callers, as the rules let them:

QueryWho outside runs it
credential.actorthe app's code
person.profilethe app's code

What it lets callers do

Of its 5 Actions, people may call 1; agents, contacts and someone signed out may call none.

ActionPersonAgentContactAnyoneKeyRoutineWhat it does
session.endyesnononononoEnds the session whose secret is shown.

An agent works for a person, and calls what both may. A key calls only what its scope names. A routine is work done for a person, which they set going.

Only the app's own code calls credential.revoke, person.email, person.set and session.start: its plugins, its schedules and the system.

It answers 2 routes over HTTP:

MethodPath
GET/me
POST/signout

It also says who a request is (who) and adds rules every read and write keeps to (guard).

Where it shows

It has no Views: it shows nowhere on its own.

What it needs

Nothing to set: it works as it comes.

What it requires

It builds on no other plugin.

It ships with copilotz@1.0.0-rc.34.

Listing

It breaks 2 listing rules as it is:

  • Route "/me" isn't under /identity.
  • Route "/signout" isn't under /identity.