AppWrenv0.10.1
GitHub

API

Everything the web app does, it does through a JSON API under /api/v1. This guide covers how to sign in, how answers and errors are shaped, how lists page, and what routes there are. The exact shape of every request and answer is in the OpenAPI document: openapi.json in this directory, or /api/openapi.json on a running server.

A program reaches the API in one of four ways:

Until 1.0, routes may change between releases. Changes are listed in the changelog.

Sign in#

curl -s -c cookies.txt -H 'Content-Type: application/json' \
  -d '{"email": "you@example.org", "password": "…"}' \
  http://127.0.0.1:8000/api/v1/session

The answer describes who you are, and sets a session cookie, appwren_session:

{
  "data": {
    "account": {"id": 12, "name": "Your Name", "email": "you@example.org"},
    "roles": ["manager", "member"],
    "permissions": {"…": true},
    "units": {"manager": null},
    "member_units": [4],
    "has_password": true,
    "csrf_token": "…"
  },
  "meta": {}
}

Everyone holds member. In units, each scoped role lists the units it covers, or null for the whole organization. permissions says what the account may do somewhere, such as manage or architect; whether it may do it to a given record is decided by that record.

GET /api/v1/session returns the same for the session you hold, or 401 if you hold none. DELETE /api/v1/session signs out.

Changing things#

Every request that changes anything (POST, PUT, PATCH, DELETE) must carry the session's CSRF token in a header:

curl -s -b cookies.txt -H 'Content-Type: application/json' \
  -H 'X-CSRF-Token: …' \
  -d '{"name": "Freezer Watch", "sourcing": "built_here", "lifecycle": "active", "tier": "2", "org_unit_id": 4}' \
  http://127.0.0.1:8000/api/v1/applications

Without it the answer is 403. A change is also refused with 403, whether or not anyone is signed in, when the request comes from another site: when it carries Sec-Fetch-Site: cross-site, or an Origin header that does not match the host.

Sign in as another system#

A script or another system signs in with an API token instead of a session. An administrator issues one under Admin → API tokens, or with POST /admin/tokens: for one role (any but administrator), for one unit and those beneath it if the role has a unit, for reading only unless they say otherwise, and until a day at most a year away, 90 days from now if no day is given. At most 50 issued tokens are live at once. The answer, 201 Created, holds the token itself, token, shown this once, and its prefix, the first ten characters, by which lists and the history name it; only its SHA-256 is kept. Send it with each request:

curl -s -H 'Authorization: Bearer awt_…' http://127.0.0.1:8000/api/v1/applications

A token sees and may do what its role may, and nothing more. A reading token is refused any change with 403. A change made with a token is recorded in the history against the token's name and prefix, such as Nightly sync (token awt_x7Kp2q). A token stands for a role, not a person, so mine means nothing to it: a list given mine=true is not narrowed. A token needs no CSRF token, since no browser is involved, and never signs in to the web app. One that is revoked or has expired is refused with 401 at once.

A token of your own#

Anyone may make a token of their own under Your account → Your API tokens, or with POST /tokens while signed in: at most ten live at once, each for 90 days unless they give another day up to a year away, its token and prefix in the answer this once. It acts as them, so it sees exactly what they see; it reads, and it proposes changes, and it changes nothing itself. A proposal is a suggestion on an application: a value for one field, with a note saying why. It waits on the application's page until someone who keeps the application accepts it, which is their own edit, checked by the usual rules and kept in the history under their name, or dismisses it.

curl -s -H 'Authorization: Bearer awt_…' -H 'Content-Type: application/json' \
  -d '{"field": "users", "value": 95, "note": "The sign-in log says so"}' \
  http://127.0.0.1:8000/api/v1/applications/APP-0024/suggestions

A personal token is revoked when its owner's password changes or their account is disabled. Whatever its owner's roles, it never administers. What it proposes is recorded under its owner's name and its prefix, such as Your Name (token awt_x7Kp2q).

Let an AI assistant read AppWren#

An assistant that speaks the Model Context Protocol can read AppWren, and propose changes, through a small tool server that comes with it. The assistant's host program starts it; give it the address of your AppWren and a token of the person's own:

{"mcpServers": {"appwren": {
  "command": "uv", "args": ["run", "--directory", "/opt/appwren", "appwren", "tools", "serve"],
  "env": {"APPWREN_URL": "https://apps.example.org", "APPWREN_TOKEN": "awt_…"}}}}

Its tools: search, get_record, list_applications, check_application (the checkpoint), my_work (what is waiting on the person), and suggest_change. It cannot change a record, decide, or accept its own proposal; every call goes through the API as the person, so it sees nothing they may not.

Ask whether an application is approved#

A purchasing form, a data access request, or a project intake can cite an application's reference and ask AppWren whether it is approved, with any token or session:

curl -s -H 'Authorization: Bearer awt_…' \
  'http://127.0.0.1:8000/api/v1/checkpoint/APP-0024?data_class=identifiable_research'
{"data": {"ref": "APP-0024", "name": "Specimen Tracker", "checked_on": "2026-11-27",
          "stage": "active", "decision": "modernize", "approved": true,
          "asked_data_class": "identifiable_research", "allowed": true,
          "data_classes": ["identifiable_research", "personal"], "flags": [],
          "reasons": [
            {"check": "stage", "ok": true, "text": "Its lifecycle stage is Active"},
            {"check": "decision", "ok": true, "text": "The decision on record is to modernize it"},
            {"check": "support", "ok": true, "text": "Nothing it is known to run on is past its end of support"},
            {"check": "data_class", "ok": true, "text": "Its record says it handles identifiable research data"}]}}

approved is true when the application is in service and open to new use (phase in or active), its decision on record does not take it away (retire, replace, or consolidate), and nothing it is known to run on is past its end of support. With data_class, allowed is true only when the application is approved and its record says it handles that class; it is null when what data the application handles is not shown to the asker. Every reason is given, so the process asking can weigh them itself. A restricted application the asker may not see is answered 404, as if there were none.

Be told when something happens#

An administrator registers webhooks under Admin → Webhooks: an https:// address on the public internet, and what it is to be told of.

TopicSent when
decision.recordedA decision is recorded for an application
application.stage_changedAn application moves to another lifecycle stage
confirmation.lapsedAn application's record goes past the date it was to be confirmed by
assessment.lapsedAn application's assessment goes past the date it was due again

Each message is a small JSON document that says what changed, never what a record holds; ask the API for more. A restricted application's name is sent as null.

{"topic": "decision.recorded", "event": 4127, "at": "2026-11-27T10:15:02Z",
 "data": {"ref": "APP-0024", "name": "Specimen Tracker", "tier": "2", "decision": "DEC-0031",
          "disposition": "modernize", "recommendation": "modernize",
          "decided_on": "2026-11-27", "review_on": "2027-11-27"}}

The message about a lapse comes from a reminder, not from the history, so its event is null, and its data holds the application's ref, name, and tier and the due_on date that passed. Send test sends a made-up message with the topic test, once and not tried again.

Each request carries these headers:

HeaderHolds
X-AppWren-TopicThe topic, as in the body
X-AppWren-DeliveryThe delivery's id. A delivery that is tried again keeps its id
X-AppWren-TimestampWhen this attempt was signed, in seconds since 1970 (Unix time)
X-AppWren-Signaturesha256= and the signature, in hex

A message may arrive more than once. Delivery is at least once: a receiver that took a message but whose answer was lost is sent it again. Keep the delivery ids you have handled, and do nothing for one you have seen.

Every message is signed with the webhook's secret, shown once when it is added. To check one, compute HMAC-SHA256 over the X-AppWren-Timestamp header, a dot, and the body exactly as received, and compare it with X-AppWren-Signature:

import hashlib, hmac


def genuine(secret: str, headers: dict, body: bytes) -> bool:
    mac = hmac.new(
        secret.encode(), headers["X-AppWren-Timestamp"].encode() + b"." + body, hashlib.sha256
    ).hexdigest()
    return hmac.compare_digest(f"sha256={mac}", headers["X-AppWren-Signature"])

Reject a message whose timestamp is more than a few minutes old. Answer with any 2xx status; anything else, or no answer within ten seconds, is tried again after 2, 4, 8, 16, and 32 minutes. A webhook that fails twenty times in a row is paused until an administrator switches it on again. Redirects are never followed. Before each delivery, the receiver's name is looked up on the machine AppWren runs on, and the message goes only if every address it resolves to is on the public internet; that holds when HTTPS_PROXY sends it through a proxy as well.

Editing a record someone else is editing#

Records carry a version. Send the version you read with every PATCH of a record, and with PUT /applications/{ref}/use, and if someone else has changed the record since, the answer is 409 and nothing is saved. Read it again and decide what to do. The OpenAPI document marks version as optional, but a change sent without it is always answered 409: no version matches none.

Answers#

Every successful answer has the same envelope:

{"data": …, "meta": {…}}

data is one object or a list. meta carries what is about the answer and not in it: paging for a list, or a count of what else changed.

Times are UTC in ISO 8601. Dates with no time, such as a review date, are YYYY-MM-DD.

Errors#

Errors are problem documents (application/problem+json):

{
  "type": "about:blank",
  "title": "Unprocessable Content",
  "status": 422,
  "detail": "The decision was not recorded.",
  "errors": [
    {"location": ["rationale"], "message": "Say why. The next person to look at it will want to know."}
  ],
  "instance": "/api/v1/applications/APP-0042/decisions"
}

Read status, and errors where there are any. title is the standard phrase for the status, taken from the Python AppWren runs on, and differs between versions (422 is "Unprocessable Entity" before Python 3.13 and "Unprocessable Content" from it), so do not compare it. detail is written for a person and may change.

A 422 comes in two shapes. The one above is AppWren's own: a value was read and refused, detail says what was not done, and each location is the field's name alone. When the request itself does not fit the route, such as a value of the wrong type or a number out of range, detail is "The request is not valid." and each location starts with where the value was, body, query, or path:

{"type": "about:blank", "title": "Unprocessable Content", "status": 422,
 "detail": "The request is not valid.",
 "errors": [{"location": ["query", "limit"], "message": "Input should be greater than or equal to 1"}],
 "instance": "/api/v1/applications"}
StatusMeaning
400The request could not be carried out as asked
401Nobody is signed in, the email address and password do not match, or the token is not valid, has expired, or was revoked
403You may not do this: your role does not allow it, the CSRF token is missing, the request came from another site (Sec-Fetch-Site: cross-site, or an Origin that is not this host), the token may only read, or password sign-in is kept for administrators ([sso] local_sign_in = false). detail says which
404No such thing, or none that you may see. The two are not told apart
409A conflict: the record changed since you read it, or the thing is already so
413The request is larger than 32 MB
422A value is missing or not allowed. errors names each field
429Too many failed sign-ins, or too many wrong current passwords at POST /session/password: wait a few minutes. From the assistant: the day's limit of questions is used up, or your last question is still being answered
500Something went wrong in AppWren itself. detail says only that; the server's log has the rest
503The database is busy, with Retry-After: 5, so try again in a few seconds; or it is unavailable

Lists#

The lists of records (GET /{records}, and the reviews, initiatives, and requests of planning change) take these parameters. Not every list takes every one:

ParameterTaken byMeaning
qEvery listWords to look for in the name, reference, or summary, or in what the record is called in another system
sortEvery listA field name. Start with - for descending. The default is -updated_at
limitEvery listHow many to return: 50 by default, 200 at most
cursorEvery listWhere to continue from: next_cursor or prev_cursor from the last answer
unitApplications, components, reviews, initiatives, requestsA unit's id. Includes every unit beneath it
ownerApplicationsAn account's id: only the records that person is named on
mineApplicationstrue for only the records you are named on
technology, release, versionApplications, componentsThose built on a technology's reference; with release, one of its releases by cycle (none for those that name none); with version, an exact version or its start. An application counts when any of its components does

A parameter a route does not take is ignored, not refused. GET /vendors?unit=4 lists every vendor, and so does a misspelled parameter on any route, so check a filter against the OpenAPI document, which lists each route's parameters.

Each kind of record adds its own filters, such as lifecycle, sourcing, tier, domain, data_class, and capability for applications; application and data_class for interfaces; platform_id and environment for deployments; and ending_within (days) for contracts. The OpenAPI document lists them.

A list's meta says where the page sits:

{"total": 109, "offset": 0, "next_cursor": "eyJvZmZzZXQiOjUwfQ", "prev_cursor": null}

A list returns only what you may see, and total counts only that.

Routes#

Every route requires a signed-in account except those marked public. What a route allows beyond that depends on the record: its unit, the people named on it, and whether it is restricted. See Running the program.

System and session#

RouteWhat it does
GET /health/live · GET /health/readyWhether the server is up, and whether it can serve (public)
GET /metaProduct name, version, branding, palettes, and, on a demo, its sample people (public)
GET · POST · DELETE /sessionWho is signed in; sign in; sign out
POST /session/demoSign in as one of a demo's sample people (public; 404 unless this is a demo)
POST /session/passwordChange your own password
GET /sso/start · GET /sso/callbackThe single sign-on round trip, for a browser (public; 404 unless it is set up)
GET /sso · POST /sso/check · PUT /sso/mappingsHow single sign-on is set up; check the connection; set which provider roles give which roles here (admin)

People and units#

RouteWhat it does
GET /accounts · POST /accountsFind people; add an account (admin)
GET · PATCH /accounts/{id}One account; change it
PUT /accounts/{id}/roles · PUT /accounts/{id}/unitsSet its roles and units (admin)
POST /accounts/{id}/passwordSet a password for someone (admin)
GET /rolesThe roles and what each allows
GET /units · POST /units · GET · PATCH /units/{id}The organization's units
POST /imports/units · POST /imports/peopleImport from CSV, with dry_run (admin)
GET · PUT /admin/branding · POST /admin/branding/checkNames, palette, accent, and score colors; check them without saving (admin)
POST · DELETE /admin/branding/images/{kind}Upload or remove a logo or the tab icon (admin)

Records#

{records} is one of applications, components, interfaces, deployments, contracts, funding-sources, vendors, technologies, hosting-platforms, or capabilities. A record is addressed by its reference, such as APP-0042.

RouteWhat it does
GET /{records} · POST /{records}List; add one. Applications: a steward, architect, or manager in scope. Components, deployments, and interfaces: whoever keeps the application (for an interface, either of the two). Contracts: a steward, architect, or manager. Vendors, technologies, capabilities, hosting platforms, and funding sources: an architect or manager
GET · PATCH /{records}/{ref}One record with everything about it; change it. Send the version you read. external_refs sets what it is called in other systems
GET /{records}/{ref}/historyIts history
POST /{records}/{ref}/links · DELETE /{records}/{ref}/links/{id}Link two records (depends on, is part of, replaces); unlink them
PUT /applications/{ref}/peopleName the people in each role. Exactly one is accountable
PUT /applications/{ref}/capabilitiesThe capabilities it serves, and whether it is the primary provider of each
PUT /applications/{ref}/useWho uses it, in one change: org_wide, or the units where everyone uses it and the audiences (kinds of people) who use it wherever they work; users, about how many; external_users. Naming everyone clears the units and kinds. Send the version you read
PUT /applications/{ref}/unitsThe units that use it, alone
PUT /components/{ref}/technologiesThe technologies a component is built on, and which release of each
PUT /technologies/{ref}/releasesA technology's releases and their support dates (an architect or manager)
GET /vocabularies · GET /catalogEvery vocabulary; the fields of each kind of record, the definition, and what each stage requires
GET /capability-mapThe capabilities in their areas, with how many applications serve each
PUT /contracts/{ref}/applicationsThe applications a contract covers, and the licenses each uses

Assessment, scores, and decisions#

RouteWhat it does
GET /questionnaire · GET /scoring-modelThe current questions and scoring model
GET /applications/{ref}/scoresIts scores, coverage, confidence, recommendation, flags, and the working of each
POST /applications/{ref}/score-previewThe scores some answers would give, from the same engine. Nothing is saved
GET · POST /applications/{ref}/assessmentsIts assessments; record a new one
GET · POST /applications/{ref}/decisionsIts decisions; record a new one (a manager, or a leader of its unit, who is not its accountable owner, unless the program lets owners decide: see PUT /program/decision-rules)
GET /score-snapshots/{id}The scores a decision was made against, as they were
GET · POST /portfolio-snapshots · GET /portfolio-snapshots/{ref}Portfolio snapshots; take one (manager); one with every application as it was

An assessment's answers maps each question's key to a level from 1 to 5, to null for don't know, or to {"level": 4, "note": "…"}. The default keys are strategic_fit, functional_fit, future_need, reliability, maintainability, vendor_viability, support_effort, change_effort, and compliance.

curl -s -b cookies.txt -H 'Content-Type: application/json' -H 'X-CSRF-Token: …' \
  -d '{"disposition": "modernize", "rationale": "Move it off the old runtime before the grant ends.", "review_on": "2027-06-30"}' \
  http://127.0.0.1:8000/api/v1/applications/APP-0042/decisions

The landscape, and cost#

RouteWhat it does
GET /data-flowsHow many interfaces carry each class of data; with data_class, every interface that carries it and every application that holds it. undeclared on an interface lists the classes its receiver's record does not list
GET /graph/{ref}Any record and what it is joined to, in groups; hidden counts what the reader may not see
GET /applications/{ref}/impactWhat depends on it, directly and beyond; the interfaces that would stop; the capabilities left with nothing; the people and units affected
GET /overlapCapabilities served by more than one application in service, with those applications side by side. Takes unit and domain
GET /capability-heatThe capability tree, each capability with how many serve it, their average scores and confidence, and the health of the weakest
GET /lifecycle · GET /radarTechnology releases to their end of support, with what runs on each; technologies in use by ring
POST /imports/end-of-lifeReleases and support dates from a JSON body of end-of-life data. dry_run is true unless you say otherwise (an architect or manager)
GET /applications/{ref}/costs · PUT /applications/{ref}/cost-linesIts cost lines, totals by category, cost per user, and the contracts that cover it, or withheld; replace the lines
GET /data-handlingHow many applications handle each class of data; with data_class, each of them with its owner, hosting, sign-in, technology support, interfaces, and data agreement
GET /historyEvery change, newest first: actor, about (a reference), kind, since, until, and before for the next page (managers for the whole organization, auditors, administrators)

Reports, import, and export#

RouteWhat it does
GET /portfolioEvery application you may see, with its scores, recommendation, decision, flags, and what its record lacks. Takes the dashboard's filters, such as recommendation, decision, flag, quality, mismatch, and review_due
GET /homeWhat is waiting on the signed-in person
GET /dashboard · GET /data-qualityThe figures, each with the filters that give its list from /portfolio. Take unit, and the dashboard domain
GET /exports/{kind}Any {records} above, portfolio, or data-handling (with data_class), as format=csv or format=json, with the same filters as the list
GET /imports/applications/fieldsThe fields a file of applications may hold, and the headings each is known by
POST /imports/applicationsA CSV file as the body (text/csv). dry_run is true unless you say otherwise; mapping says which column holds each field where the headings differ

Keeping current#

RouteWhat it does
GET /notices · GET /notices/count · POST /notices/readYour notices, newest first; how many are unread; mark some read (ids), or all
GET · PUT /session/preferencesHow notices reach you by email: immediate, digest, or none
GET · POST /applications/{ref}/confirmationsWhen its record was last confirmed and is next due, and every confirmation; confirm it, with an optional note (whoever is named on it, its unit's stewards, managers)
GET /campaigns · POST /campaigns · POST /campaigns/previewCampaigns with their progress; start one; what one would ask, and of whom, saving nothing (stewards and managers, for their units)
GET /campaigns/{ref}A campaign, its coverage by unit, and its items. Takes unit, status, and mine
POST /campaigns/{ref}/remind · /close · /cancel · /items/{id}/excuseRemind those still to do it; close it; cancel it; excuse one application with a reason
GET /tasks · GET /tasks/{id} · POST /tasks/{id}/closeOpen tasks you may see (mine, status, kind, unassigned); one task; mark it done or dismissed with a note
GET /accounts/{id}/holdings · POST /accounts/{id}/hand-overWhat a person holds; pass all of it to another (administrators and managers)
GET /searchOne search across every kind of record: q, and type for one kind
GET · POST /views · PATCH · DELETE /views/{id}Your saved views of a list (path), and the shared ones; save, change, or delete one
GET /similar-applicationsApplications a new one may be already: name, aliases, vendor, product, and except for its own reference
GET · POST /applications/{ref}/contests · GET /contests · POST /contests/{id}/answerContests of its scores; contest a factor; those waiting for your answer; accept or answer one (a manager or architect)

Facts from other systems#

See Facts from other systems.

RouteWhat it does
GET /connectors · POST /connectorsThe kinds of source and the connectors set up; add one, switched off, with its kind, key, name, settings, and the credential_env that holds its credential (admin)
GET · PATCH /connectors/{key}A connector and its recent runs; change it, or switch it on or off with enabled (admin)
POST /connectors/{key}/check · POST /connectors/{key}/runWhether it reaches its source, writing nothing; run it now (admin)
GET /sourced/{ref}What sources supply for a record you may see, each value with its source, when it was read, and any override; for a technology, its releases' too; for an application, its components'
POST · DELETE /sourced/{ref}/{field}/overrideOverride a value with a value and a reason, and a technology's release where it is one of a release's; remove the override (whoever keeps the record)
GET /discovered · POST /discovered/{id}/add · /dismiss · /restoreApplications registered with the identity provider that are not on record (show: new, dismissed, added, all); add one in an org_unit_id; dismiss one with a reason; list it again (stewards, architects, managers)
GET · POST /push-keys · DELETE /push-keys/{id}Push keys; issue one, shown in the answer this once; revoke one (admin)
POST /factsFacts from a push source, with its key as Authorization: Bearer <key> and no session: facts, each with record, field, value, and optionally observed_at and release. Checked whole: one bad fact writes nothing
GET · POST /applications/{ref}/catalogThe application and its components as a catalog file (YAML); bring one in, sent as the body, with dry_run (the default) saying what would change
GET /maturity · GET /maturity/{ref}How many applications are at each engineering maturity level under each unit below unit; an application's or a component's level, checks, and what it needs for the next

Planning change#

See Planning change.

RouteWhat it does
GET · POST /reviews · GET · PATCH /reviews/{ref}Portfolio reviews, as records with a unit, held_on, a chair_id, and tiers; one review, with its agenda. Planned and changed by managers and the unit's leaders
POST /reviews/{ref}/drawAdd to the agenda what needs deciding in its scope now: a decision that differs from the recommendation, one due for review by its date, or none. meta.added says how many
POST /reviews/{ref}/items · DELETE /reviews/{ref}/items/{id}Put an application on the agenda with a note; take one off
POST /reviews/{ref}/open · POST /reviews/{ref}/closeOpen it, from when a decision recorded for an item is shown on it; close it, keeping each item's decision. A closed review changes no more
GET · POST /initiatives · GET · PATCH /initiatives/{ref}Initiatives, as records with a kind, a stage, an owner_id, starts_on, ends_on, and a budget; filtered by application too
PUT /initiatives/{ref}/applicationsThe applications it changes, each with its application, its action (changes, retires, or receives), and a note
GET /roadmapInitiatives with their dates, for a timeline: by unit, kind, or stage, and closed for those done or cancelled
GET · POST /requests · GET · PATCH /requests/{ref}Requests for something new, as records with a capability_id, requested_by_id, users_expected, and needed_by; one request, with what already serves its capability and what is named like it. Anyone may ask
PUT /requests/{ref}/optionsThe ways to meet it: each with an approach (build, buy, partner, or reuse), a name, a vendor or an application, an annual_cost, a fit of 1 to 5, and notes
POST /requests/{ref}/approve · /meet · /declineEnd it once, with a reason: approved, adding a proposed application (name if not the request's); met by an application on record; or declined
GET · POST · DELETE /applications/{ref}/retirementIts retirement plan and checklist; start one with planned_on and a note; cancel an open one
PUT /applications/{ref}/retirement/steps/{step} · POST /applications/{ref}/retirement/completeMark a step done, or not, with a note; complete the plan, every step done, retiring the application and keeping its savings
GET /retirementsRetirements under way and done, with the savings by year

Insight#

See Insight.

RouteWhat it does
GET /trendsHow the portfolio moved from the snapshot before to the snapshot after, or to today without one: the figures each held, what moved, and the decisions recorded between them
GET /applications/{ref}/score-historyIts scores at each portfolio snapshot and each decision, oldest first
GET /sharesThe costliest tenth, the dearest tenth per user, the least used fifth, and the oldest fifth of the applications in service
GET · POST /reports · GET /reports/{ref}Leadership reports, the latest period first; make one with a title, period_from, and period_to (a manager); one report as it was made, with its digest and whether it is intact. Read by those who may see every record
GET /as-of · GET /applications/{ref}/as-ofThe portfolio on a day: the applications in service at its end, each with its stage, unit, tier, and decision then and now; one application on a day, each value then beside now, with its decision and scores then. Read from the history
GET · POST /scenarios · GET · PATCH /scenarios/{ref}Scenarios, as records with a name and summary, kept by architects and managers; one scenario, with its changes and their effect: cost_saved, people, interfaces, capabilities, and risk
PUT /scenarios/{ref}/changesThe changes it would make: each an application, an action (retire, consolidate, or replace), the application it moves into or is replaced by, and a note. Changes no application
POST /scenarios/{ref}/initiativeMake a proposed initiative of it, with a name and org_unit_id if not its own; the scenario then changes no more

The program and the installation#

RouteWhat it does
GET /programThe program as it stands, and which lists may only be renamed (managers for the whole organization, administrators)
PUT /program/vocabularies/{name} · PUT /program/fields · PUT /program/questionnaireSave a list, the organization's own fields, or new wording of the questions
PUT /program/decision-rulesowners_may_decide: whether an application's accountable owner, if also a manager or leader over it, may record its decision; stage_gates: whether an application may move to a later stage only with what that stage requires. Send either or both
POST /program/scoring/preview · PUT /program/scoringEvery application a changed scoring model would change; publish it as a new version
GET /jobs · POST /jobs/{key}/run · PUT /jobs/{key}Scheduled work and its recent runs; run a job now; pause or resume one (admin)
GET /mail · POST /mail/testHow email is set up and doing; send yourself a test message (admin)
GET · POST /tokens · DELETE /tokens/{id}Your own tokens; make one with a name and expires_on, its token in the answer this once; revoke one
GET · POST /applications/{ref}/suggestionsThe changes proposed to an application, pending and recently decided; propose a value for one field, with a note
POST /suggestions/{id}/accept · POST /suggestions/{id}/dismissAccept a proposal, making the change as yours, or dismiss it. Someone who keeps the application, signed in
POST /assistant/ask · POST /assistant/draft · GET /assistant/exchangesWhere an assistant is set up: an answer to a question with the records it cites; values drafted from a document's text, and what was dropped; every exchange (for those who see everything). 404 when there is no assistant
GET /checkpoint/{ref}Whether an application is approved for new use, and for a data_class if given, with every reason. See Ask whether an application is approved
GET · POST /admin/tokens · DELETE /admin/tokens/{id}API tokens and when each was last used; issue one with a name, role, org_unit_id, read_only, and expires_on, its token in the answer this once; revoke one (admin)
GET · POST /admin/webhooks · PATCH · DELETE /admin/webhooks/{id} · POST /admin/webhooks/{id}/testWebhooks and their recent deliveries; add one with a name, url, and topics, its secret in the answer this once; change, switch off, or remove one; send a test now (admin)

What the API will not do#

Describes AppWren 0.10.1. Apache License 2.0. Screenshots show an invented organization; every person and record in them is fictional.