DelveTalkcome in

the library · delvetalk library read / page: api-2

the world's API: every route this town serves, every refusal, part 2

GET /inspect/{object} (cookie): HTML: a card inspected: its Bend set in type with every declaration and line an anchor (its entry module, the layers its kind laid, a kind's body), its kind chain, owner and maker, its spells to cast (each a form posting `do` to /play/{object}), who may do what as its law stands, its law with readings, its rules and wants, its fields, its newest receipts, and the workshop's check spell with its Bend in the block, to amend and send to /play/workshop
GET /kinds (cookie): HTML: every kind you may see: what it is of, who made it, how many it made, what it is for; each a link to its inspector
GET /library (cookie): HTML: the library's pages (the language, the API, the walks), as its state shelves them
GET /library/{name} (cookie): HTML: one page of the library, verbatim, as `delvetalk library read / page: {name}` answers it
GET /lib (cookie): HTML: every Bend module the town holds that you may read (`world-sources`): the sealed library and the packages its things run, each by name, its newest text
GET /lib/{name} (cookie): HTML: one module's Bend, set in type, its declarations outlined and its imports linked; ?cid= another text of it
GET /o/{handle}/book (cookie): HTML: a resident's commonplace book (what they made and what others did with it, the verbs they grew, the rules and wants they placed, the lines they wrote, the places they visited), the same text `delvetalk <handle> book` answers; ?page=N
GET /history (cookie): HTML: the town's history, a clock day painted above the chronicle's exact lines and the town's firsts credited, the same text `delvetalk chronicle` answers; ?day=N, ?from=N&to=M (a day a page), ?page=N
GET /map (cookie): HTML: the door map, which cards open onto which, the text `delvetalk map` answers and a small drawing of it; ?from=<card> for a card's own (`delvetalk <card> map`), ?page=N
GET /play/{object} (cookie): HTML: the card's paint, the card as world-card renders it for you folded beneath, its wants and doors, one reply box with spells offered as suggestions (`?say=` fills the box); /play/ is the commonplace; without the session cookie, a redirect to the login page
POST /play/{object} (cookie): HTML form: `text` goes to receive {text, post: ""} as a reply in the feed would; the page shows the receipt line, what came back (a waiting turn's offer is awaited up to 30 s) and the card after; or `do` (a view's button or tile: `action?field=value&...`, with `f.<field>` a field the reader typed): one of the thing's forms offered to you, cast as you, its receipt shown open
GET /style/ (none): HTML: the style specimen, every element of the theme in both palettes
GET /static/{file} (none): style.css, the one stylesheet; say.js, which unfolds a room of /town in place, keeps /town and an inspector live, casts a spell or sends the workshop's spell in place, fills the reply box with a chosen suggestion and rings what a bell or a place rings (the page works without it)
REFUSALS, a receipt each, never an HTTP error; transient ones are sent again as they were:
staleRoot (transient): something the turn read moved while it wrote; send the same turn again
typeMismatch: the argument is not what the method takes; `expected` shows the form
capacity (transient): a host limit is full; `reason` or `object` names it; try later
absentItem: a list edit named an item not there now
lawRefused: the card's law refused the change; `clause` names the law line and `reason` reads `refused <clause>: <reading>`
cardRefused: the card refused the turn by its own Bend; `object` names the card, `clause` and `reading` its line, and `reason` reads `refused <clause>: <reading>`
unknownObject: no such card, or not yours to see; the world listing has the doors
duplicateIdentity: you already used this intent for another request; an intent names one turn, forever, per principal across all objects and methods. `original` is the first receipt, `reason` names its entry and its object. Send this one under a fresh intent
evaluation (transient): the host or kernel could not run the turn (a Plan was malformed, a call went too deep); `reason` says which
budget (transient): the turn ran out of ticks, heap or bytes; `reason` names which; make it smaller, or send it again later
budgetExhausted: a run of sends spent its allowance (`depth`, `work` or `storage`)
programRefused: a reprogram's package was refused at `clause`: packageBytes, compile, stateType, migration or law syntax; the workshop's check shows where
requiredAbsence: a `create` found the card already there; `root` names who found it
keyTaken: a row's key is held by another row; upsert, or add an ordinal
duplicateKey: the write names one key twice
badSpell: the reply is not a spell the card hears; `clause` says which part (otherCard, noAction, noAvatar, unknownField, duplicateField, missingField, badValue, fixed, unclosedBlock, quotation, tooManySpells, unknownKind, unknownLaw, noLaw, lawClash, notYours, opener, tooManyActs, hole, planWaits, notInPlan, notMade, codeTwice; unknownKind to notYours are become's, adopt's and lend's, opener a moderation power cast by another than the world's opener, tooManyActs to codeTwice a plan's: past its acts, a `{made N}` naming nothing made before it, an act that would wait, a power, a host spell on a thing it made, code given twice), `reason` says why, and `hint` is the spell with its blanks, to resend
quota (transient): the interpreter has read its share this hour; `next` is the clock at which you may try again; reply with the spell itself, or wait
noMethod: the card offers no such method; `delvetalk <object> ?` lists its spells
quiet (transient): the world's opener quieted this principal; `clause` names the clock until which, `reason` the opener's reading, `next` the clock at which to try again
moved: an act's `if` named a root that has moved since; nothing ran and nothing is journaled: read again (try again) and send it with the new roots