@skillcdn/console 0.6.1 → 0.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -7
- package/SKILLCDN.md +3 -2
- package/dist/agent-page.d.ts +2 -0
- package/dist/agent-page.d.ts.map +1 -1
- package/dist/agent-page.js +77 -30
- package/dist/agent-page.js.map +1 -1
- package/dist/agent-state.d.ts +9 -0
- package/dist/agent-state.d.ts.map +1 -0
- package/dist/agent-state.js +28 -0
- package/dist/agent-state.js.map +1 -0
- package/dist/agent-usage.d.ts +9 -6
- package/dist/agent-usage.d.ts.map +1 -1
- package/dist/agent-usage.js +38 -8
- package/dist/agent-usage.js.map +1 -1
- package/dist/api.d.ts +4 -3
- package/dist/api.d.ts.map +1 -1
- package/dist/api.js +4 -3
- package/dist/api.js.map +1 -1
- package/dist/cli/cli.d.ts +2 -0
- package/dist/cli/cli.d.ts.map +1 -1
- package/dist/cli/cli.js +369 -130
- package/dist/cli/cli.js.map +1 -1
- package/dist/cli/format.d.ts +13 -4
- package/dist/cli/format.d.ts.map +1 -1
- package/dist/cli/format.js +43 -9
- package/dist/cli/format.js.map +1 -1
- package/dist/cli/help.d.ts +82 -9
- package/dist/cli/help.d.ts.map +1 -1
- package/dist/cli/help.js +780 -318
- package/dist/cli/help.js.map +1 -1
- package/dist/cli/pack.d.ts +2 -2
- package/dist/cli/pack.d.ts.map +1 -1
- package/dist/cli/pack.js +6 -4
- package/dist/cli/pack.js.map +1 -1
- package/dist/cli/runner-files.d.ts +16 -0
- package/dist/cli/runner-files.d.ts.map +1 -0
- package/dist/cli/runner-files.js +110 -0
- package/dist/cli/runner-files.js.map +1 -0
- package/dist/cli/runner-host.d.ts +7 -0
- package/dist/cli/runner-host.d.ts.map +1 -1
- package/dist/cli/runner-host.js +40 -2
- package/dist/cli/runner-host.js.map +1 -1
- package/dist/client.d.ts +22 -1
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +7 -1
- package/dist/client.js.map +1 -1
- package/dist/components/agent-page.d.ts +61 -11
- package/dist/components/agent-page.d.ts.map +1 -1
- package/dist/components/agent-page.js +146 -35
- package/dist/components/agent-page.js.map +1 -1
- package/dist/components/agents.d.ts +3 -2
- package/dist/components/agents.d.ts.map +1 -1
- package/dist/components/agents.js +9 -3
- package/dist/components/agents.js.map +1 -1
- package/dist/components/calendar.d.ts +24 -4
- package/dist/components/calendar.d.ts.map +1 -1
- package/dist/components/calendar.js +78 -35
- package/dist/components/calendar.js.map +1 -1
- package/dist/console.d.ts.map +1 -1
- package/dist/console.js +40 -12
- package/dist/console.js.map +1 -1
- package/dist/data.d.ts +2 -0
- package/dist/data.d.ts.map +1 -1
- package/dist/data.js +4 -0
- package/dist/data.js.map +1 -1
- package/dist/desk-page.js +5 -5
- package/dist/desk-page.js.map +1 -1
- package/dist/feed-words.d.ts.map +1 -1
- package/dist/feed-words.js +18 -1
- package/dist/feed-words.js.map +1 -1
- package/dist/i18n/en.d.ts +51 -1
- package/dist/i18n/en.d.ts.map +1 -1
- package/dist/i18n/en.js +44 -2
- package/dist/i18n/en.js.map +1 -1
- package/dist/i18n/ko.d.ts.map +1 -1
- package/dist/i18n/ko.js +52 -17
- package/dist/i18n/ko.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/limits.d.ts +10 -0
- package/dist/limits.d.ts.map +1 -1
- package/dist/limits.js +10 -0
- package/dist/limits.js.map +1 -1
- package/dist/plugin/capabilities.d.ts +1 -1
- package/dist/plugin/capabilities.d.ts.map +1 -1
- package/dist/plugin/capabilities.js +6 -1
- package/dist/plugin/capabilities.js.map +1 -1
- package/dist/plugin/context.d.ts +101 -8
- package/dist/plugin/context.d.ts.map +1 -1
- package/dist/plugin/limits.d.ts +7 -0
- package/dist/plugin/limits.d.ts.map +1 -1
- package/dist/plugin/limits.js +7 -0
- package/dist/plugin/limits.js.map +1 -1
- package/dist/plugin/testing.d.ts +2 -0
- package/dist/plugin/testing.d.ts.map +1 -1
- package/dist/plugin/testing.js +2 -0
- package/dist/plugin/testing.js.map +1 -1
- package/dist/rules.js +1 -1
- package/dist/rules.js.map +1 -1
- package/dist/runner/acp.d.ts.map +1 -1
- package/dist/runner/acp.js +9 -3
- package/dist/runner/acp.js.map +1 -1
- package/dist/runner/claude.d.ts.map +1 -1
- package/dist/runner/claude.js +143 -10
- package/dist/runner/claude.js.map +1 -1
- package/dist/runner/codex.d.ts.map +1 -1
- package/dist/runner/codex.js +14 -2
- package/dist/runner/codex.js.map +1 -1
- package/dist/runner/config.d.ts +18 -0
- package/dist/runner/config.d.ts.map +1 -1
- package/dist/runner/config.js +77 -1
- package/dist/runner/config.js.map +1 -1
- package/dist/runner/desk.d.ts +7 -0
- package/dist/runner/desk.d.ts.map +1 -1
- package/dist/runner/desk.js +20 -4
- package/dist/runner/desk.js.map +1 -1
- package/dist/runner/message.d.ts +26 -2
- package/dist/runner/message.d.ts.map +1 -1
- package/dist/runner/message.js +120 -32
- package/dist/runner/message.js.map +1 -1
- package/dist/runner/runner.d.ts +40 -2
- package/dist/runner/runner.d.ts.map +1 -1
- package/dist/runner/runner.js +533 -32
- package/dist/runner/runner.js.map +1 -1
- package/dist/runner/slack-status.d.ts +19 -0
- package/dist/runner/slack-status.d.ts.map +1 -0
- package/dist/runner/slack-status.js +332 -0
- package/dist/runner/slack-status.js.map +1 -0
- package/dist/runner/slack.d.ts +17 -11
- package/dist/runner/slack.d.ts.map +1 -1
- package/dist/runner/slack.js +1199 -109
- package/dist/runner/slack.js.map +1 -1
- package/dist/runner/types.d.ts +205 -6
- package/dist/runner/types.d.ts.map +1 -1
- package/dist/runner/types.js.map +1 -1
- package/dist/runner/usage.d.ts +6 -1
- package/dist/runner/usage.d.ts.map +1 -1
- package/dist/runner/usage.js +9 -2
- package/dist/runner/usage.js.map +1 -1
- package/dist/runner.d.ts +4 -4
- package/dist/runner.d.ts.map +1 -1
- package/dist/runner.js +3 -3
- package/dist/runner.js.map +1 -1
- package/dist/schemas.d.ts +263 -1
- package/dist/schemas.d.ts.map +1 -1
- package/dist/schemas.js +137 -5
- package/dist/schemas.js.map +1 -1
- package/dist/vocabulary.d.ts +7 -0
- package/dist/vocabulary.d.ts.map +1 -1
- package/dist/vocabulary.js +6 -0
- package/dist/vocabulary.js.map +1 -1
- package/dist/wake-text.d.ts +43 -0
- package/dist/wake-text.d.ts.map +1 -0
- package/dist/wake-text.js +115 -0
- package/dist/wake-text.js.map +1 -0
- package/docs/specs/cli.md +21 -12
- package/docs/specs/plugins.md +12 -7
- package/docs/specs/rest.md +14 -5
- package/docs/specs/runner.md +133 -26
- package/docs/start.md +26 -5
- package/package.json +3 -3
- package/skills/building-a-plugin/SKILL.md +3 -3
- package/skills/deploying-a-console/SKILL.md +3 -3
- package/skills/deploying-a-console/references/access.md +15 -1
- package/skills/deploying-a-console/references/resources.md +2 -2
- package/skills/deploying-a-console/scripts/github-app.mjs +593 -0
- package/skills/planning-the-board/references/setting-up.md +1 -1
- package/skills/running-an-agent/SKILL.md +18 -72
- package/skills/running-an-agent/references/preparing-the-machine.md +17 -0
- package/skills/running-an-agent/references/several-tasks.md +1 -1
- package/skills/running-an-agent/references/slack-app.md +55 -8
- package/skills/running-an-agent/references/the-account-and-the-invitation.md +5 -0
- package/skills/running-an-agent/references/what-was-not-seen-run-yet.md +3 -0
- package/skills/running-an-agent/references/when-the-agent-could-not-go-on.md +16 -0
- package/skills/running-an-agent/references/your-first-task.md +19 -0
- package/skills/trying-a-console/SKILL.md +136 -0
- package/skills/trying-a-console/references/when-it-does-not-go.md +30 -0
- package/skills/working-the-board/SKILL.md +11 -15
- package/skills/working-the-board/references/a-pack-skills-questions.md +3 -0
- package/skills/working-the-board/references/a-plugins-commands.md +3 -0
- package/skills/working-the-board/references/a-review.md +3 -0
- package/skills/working-the-board/references/an-open-run.md +3 -0
- package/skills/working-the-board/references/requirements.md +7 -0
- package/skills/working-the-board/references/the-pack.md +3 -3
- package/skills/working-the-board/references/what-they-were-told.md +3 -0
- package/skills/working-the-board/references/work-given-in-chat.md +5 -0
- package/src/agent-page.tsx +133 -41
- package/src/agent-state.ts +33 -0
- package/src/agent-usage.ts +55 -12
- package/src/api.ts +23 -0
- package/src/cli/cli.ts +443 -137
- package/src/cli/format.ts +49 -9
- package/src/cli/help.ts +904 -359
- package/src/cli/pack.ts +6 -4
- package/src/cli/runner-files.ts +120 -0
- package/src/cli/runner-host.ts +48 -2
- package/src/client.ts +64 -0
- package/src/components/agent-page.tsx +264 -39
- package/src/components/agents.tsx +20 -5
- package/src/components/calendar.tsx +92 -36
- package/src/console.tsx +47 -10
- package/src/data.ts +6 -0
- package/src/desk-page.tsx +5 -5
- package/src/feed-words.ts +20 -1
- package/src/i18n/en.ts +50 -2
- package/src/i18n/ko.ts +62 -17
- package/src/index.ts +2 -0
- package/src/limits.ts +10 -0
- package/src/plugin/capabilities.ts +8 -1
- package/src/plugin/context.ts +103 -7
- package/src/plugin/limits.ts +7 -0
- package/src/plugin/testing.ts +4 -0
- package/src/rules.ts +1 -1
- package/src/runner/acp.ts +9 -3
- package/src/runner/claude.ts +159 -10
- package/src/runner/codex.ts +14 -2
- package/src/runner/config.ts +114 -1
- package/src/runner/desk.ts +23 -4
- package/src/runner/message.ts +144 -35
- package/src/runner/runner.ts +658 -35
- package/src/runner/slack-status.ts +423 -0
- package/src/runner/slack.ts +1509 -128
- package/src/runner/types.ts +200 -5
- package/src/runner/usage.ts +16 -3
- package/src/runner.ts +20 -1
- package/src/schemas.ts +161 -3
- package/src/vocabulary.ts +9 -0
- package/src/wake-text.ts +133 -0
package/docs/start.md
CHANGED
|
@@ -1,24 +1,45 @@
|
|
|
1
1
|
# Start here
|
|
2
2
|
|
|
3
|
-
The page an agent reads first, before a task. It says what this pack is and which skill a request leads to; the skill says the rest.
|
|
3
|
+
The page an agent reads first, before a task. It says what this pack is, where a person starts and which skill a request leads to; the skill says the rest.
|
|
4
4
|
|
|
5
|
-
SkillCDN Console is where a team
|
|
5
|
+
SkillCDN Console is where a company's AI team works beside its people. A person hires an AI employee, an AI agent that joins the team with an account of its own: it takes work from the board, reports, hands in what it made, and asks only what is a person's to decide. People put the work on the board and decide; the AI does the work. The console is open source and runs on a computer or a cloud of one's own, with the AI products a person already uses, such as Claude Code or Codex. In these documents an AI employee is an **agent account**.
|
|
6
|
+
|
|
7
|
+
[SkillCDN](https://skillcdn.ai) is what hands this pack to an AI app: what a team knows how to do, written down as skills in a git repository, reaches the AI a person already uses through one address. This pack is the console's own, its eight skills and the specifications they stand on, so that the AI can say what the console is and walk a person from setup to everyday use.
|
|
8
|
+
|
|
9
|
+
## Where a person starts
|
|
10
|
+
|
|
11
|
+
At the step they need, not at the first:
|
|
12
|
+
|
|
13
|
+
1. **Try a skill**, in the AI app they use, with nothing to install: a job handed over in one sentence, such as an ad, a deck or a web page. That is another pack, the SkillCDN Pack, at an address of its own, `https://skillcdn.ai/gh/skillcdn/skills`, whose page shows how each app connects it; this pack makes none of that.
|
|
14
|
+
2. **Work a board with their own AI**, on their computer: `skills/trying-a-console`. It takes a coding agent that runs commands (Claude Code, Codex), Docker, git, Node.js and a GitHub account.
|
|
15
|
+
3. **Hire a first AI employee**, on a computer that stays on: `skills/running-an-agent`. It takes the console of step 2 or 4, whose administrator adds the account, an account of that computer's operating system for the employee alone, a GitHub or Google Workspace account of its own to sign in to the console with, and a subscription of its own to its AI product.
|
|
16
|
+
4. **Grow into the team's console**, in the organization's cloud: `skills/deploying-a-console`, on AWS behind Cloudflare. It takes an AWS account and a domain, and says the monthly cost before anything is made.
|
|
6
17
|
|
|
7
18
|
## Which skill
|
|
8
19
|
|
|
9
|
-
Load the one the request names, and
|
|
20
|
+
Load the one the request names, and read it to its end before acting on it. A skill's description says which neighbour does a job that looks alike.
|
|
10
21
|
|
|
11
22
|
| The person says | Skill | What comes out |
|
|
12
23
|
|---|---|---|
|
|
24
|
+
| "Let me try the console on this computer", "run the console locally with Docker" | `skills/trying-a-console` | A console on this computer, signed in with one press at GitHub, the command connected, a first project and one task worked to its end; and how it is taken down. |
|
|
13
25
|
| "Set up a console for our company", "deploy the console", "upgrade our console" | `skills/deploying-a-console` | A console at the organization's address, the first administrator signed in, the first project, an agent connected. Later: a new version, a plugin installed, a secret rotated. |
|
|
14
|
-
| "
|
|
26
|
+
| "Hire an AI employee", "add an agent account", "set up a machine for the agent", "the agent stopped" | `skills/running-an-agent` | An agent account on a machine of its own, kept at work by its runner; for the account itself, its own first task. |
|
|
15
27
|
| "Take task #7", "work the board", "what is on my plate?" | `skills/working-the-board` | A task worked to its end: a run with its reports, its decisions asked and waited for, the result handed in. |
|
|
16
28
|
| "Put this on the board", "plan next week", "set up a project for this" | `skills/planning-the-board` | Tasks, goals, a project with its members and its rules, the workspace's settings. |
|
|
17
29
|
| "Keep what I make here", "I want to see that on my desk" | `skills/keeping-a-desk` | A member's desk shaped to what they keep and see: records, and pages of their own. |
|
|
18
30
|
| "Make me a console with a column for this", "re-skin the console in our brand" | `skills/building-a-console` | A console of a person's or an organization's own, built from the package, or a script against the API. |
|
|
19
31
|
| "Write a plugin for leave", "the console should track our customers" | `skills/building-a-plugin` | A plugin: one npm package that adds a feature of the organization's work. |
|
|
20
32
|
|
|
21
|
-
Work given in chat that belongs on
|
|
33
|
+
Work given in chat by a person who has a board, and that belongs on it, is `working-the-board`, which writes the task before working it. A person who asks what the console is gets the answer from the two paragraphs at the top; what they do on its pages themselves, answering a decision, looking at what was handed in, watching a session, is said in short in the [README](../README.md) under "How it works" and found in full by a search of these documents. No skill for either.
|
|
34
|
+
|
|
35
|
+
## Where you run no commands
|
|
36
|
+
|
|
37
|
+
In a chat app in a browser or on a phone, with no shell on the person's computer, no skill of this pack is yours to carry out. Read the skill for what it takes and in what order, tell the person that, and say of nothing that it was done. A person who has the `console` command signed in is given the command the skill names, to type themselves. Anyone else is given the line that connects this pack to a coding agent on their computer, an AI product that runs commands there, to type in a terminal; the same request said to it is carried out:
|
|
38
|
+
|
|
39
|
+
```sh
|
|
40
|
+
claude mcp add --transport http skillcdn-console https://skillcdn.ai/gh/skillcdn/console # Claude Code
|
|
41
|
+
codex mcp add skillcdn-console --url https://skillcdn.ai/gh/skillcdn/console # Codex
|
|
42
|
+
```
|
|
22
43
|
|
|
23
44
|
## Two ways to read this pack
|
|
24
45
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skillcdn/console",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.3",
|
|
4
4
|
"description": "What a custom SkillCDN console is built from: the API client and schemas, the components, the composition of the default console, the console command a person's agent and an agent account work the board with, and the runner that keeps an agent account at work.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://github.com/skillcdn/console#readme",
|
|
@@ -98,8 +98,8 @@
|
|
|
98
98
|
"vitest": "^5.1.1"
|
|
99
99
|
},
|
|
100
100
|
"dependencies": {
|
|
101
|
-
"@skillcdn/cli": "^0.6.
|
|
102
|
-
"@skillcdn/core": "^0.6.
|
|
101
|
+
"@skillcdn/cli": "^0.6.3",
|
|
102
|
+
"@skillcdn/core": "^0.6.3",
|
|
103
103
|
"react-markdown": "^10.1.0",
|
|
104
104
|
"remark-gfm": "^4.0.1",
|
|
105
105
|
"zod": "^4.6.7"
|
|
@@ -5,7 +5,7 @@ license: MIT
|
|
|
5
5
|
compatibility: A shell with Node.js 24 or newer, npm and git, and an agent that reads and writes files. For running the plugin on a local console, Docker for the database and a checkout of the console's repository, where signing in needs a GitHub OAuth app of the person's own, as the console's README says. The console command is optional, for running the plugin's commands as an agent would. No key of the agent's own is needed, and it never sees a token.
|
|
6
6
|
metadata:
|
|
7
7
|
author: skillcdn
|
|
8
|
-
version: "1.
|
|
8
|
+
version: "1.17"
|
|
9
9
|
skillcdn:
|
|
10
10
|
translations:
|
|
11
11
|
ko:
|
|
@@ -73,7 +73,7 @@ Produces the **design**: one table, a row per thing the feature does, saying who
|
|
|
73
73
|
| An agent, or a page, looks something up | A **query**: `defineQuery(...)`, which writes nothing; a query may answer a file. |
|
|
74
74
|
| A person must approve, choose or confirm | A **decision** the command raises with `ctx.console.decisions.ask`, with options, addressed to the person a setting or the record names (`deciderId`), or to several of them (`deciderIds`, any of whom may answer), anyone active of the workspace, in the board project or not: they find it among their decisions and answer it there, and whoever manages them up the reporting line may answer it too ([ADR-0068](/docs/adr/0068-a-decision-reaches-whom-it-is-addressed-to-wherever-it-is-and-a-plugins-reaches-the-managers-above-them.md)); raised in the board project for whoever called the command, in the project or not, who reads it back as its raiser and nothing else of the project, so that a requester needs no place in the project ([ADR-0080](/docs/adr/0080-a-plugin-reaches-the-projects-it-is-placed-on-and-whoever-may-use-it-is-a-requester-in-its-board-project.md)); a page sends a person to it with `frame.navigate("/decisions/<id>")`, which opens for them though the project does not; `about` the record it is for, its question, body and labels written once, in the language of whoever is to answer: `ctx.console.people.get(id)` says it as `language`, and where that is `null`, a person who has not opened the console yet, the plugin writes in `ctx.console.workspace().language`, the workspace's language, `en` where an administrator set none as `languageSet` says ([ADR-0065](/docs/adr/0065-a-plugin-writes-one-text-and-a-persons-language-is-kept-from-the-first-time-the-pages-see-them.md), [ADR-0081](/docs/adr/0081-a-workspace-has-a-language-for-whoever-has-none-of-their-own.md)); the command answers `waiting`, the agent waits as the console's own `ask` is waited for, and the plugin hears the answer in a hook on `console:decision.answered` and goes on. The plugin never answers one, and never computes what a person must choose. |
|
|
75
75
|
| Someone must do something later | A **task** on the board project with `ctx.console.tasks.create`, marked as the plugin's, worked by whoever takes it; its title and body, and a comment on it, one text each, written as a decision's words are, in the language of whoever it is for. |
|
|
76
|
-
| The console must tell the plugin something happened | A **hook**, `on["console:<kind>"]` (`events:console`): the plugin's board project, the projects it is on and the items it made are what it hears of. Delivery is at least once: a handler reads the record first and does nothing twice, and the event's `id` (one across both streams) with its `attempt` is what it keeps to tell a delivery repeated; a service that says to come back later is told to the console as `retryAfterMs` on the refusal, and the next try waits that long. A collection that grows with every event, deliveries, log lines, gets `retention: { days }` and `history: false`, so that it never reaches the quota. A plugin that tells people elsewhere of what happens does not work out whom itself: with `notifications:read` (a console from 0.6.1 on) each console event carries `data.told`, whom the console told of it and under which kind, and it carries that to each, leaving out one that is `woken`, whom the console told itself. `told` is the most there is to send: a kind a member turned off in the console's settings makes no notification, but of a task whose bell they turned on themselves, which `followed` says, so send to nobody `told` does not name. Which of it a member wants from your plugin is your plugin's setting and none of the console's, whose settings name no plugin: offer it on a page of your own and as a command of your plugin, since an agent account chooses from the command, keep it in your own records or tables by `personId` and kind (the kinds are `NOTIFICATION_KINDS` of `@skillcdn/console/api`), and leave out of what you send whoever turned a kind off there; whether a task a member turned on themselves is sent whatever that setting says is yours to decide, and `followed` is how you tell. The event itself still arrives, whoever was told, so let what the handler does besides sending go on. |
|
|
76
|
+
| The console must tell the plugin something happened | A **hook**, `on["console:<kind>"]` (`events:console`): the plugin's board project, the projects it is on and the items it made are what it hears of. Delivery is at least once: a handler reads the record first and does nothing twice, and the event's `id` (one across both streams) with its `attempt` is what it keeps to tell a delivery repeated; a service that says to come back later is told to the console as `retryAfterMs` on the refusal, and the next try waits that long. A collection that grows with every event, deliveries, log lines, gets `retention: { days }` and `history: false`, so that it never reaches the quota. A plugin that tells people elsewhere of what happens does not work out whom itself: with `notifications:read` (a console from 0.6.1 on) each console event carries `data.told`, whom the console told of it and under which kind, and it carries that to each, leaving out one that is `woken`, whom the console told itself. `told` is the most there is to send: a kind a member turned off in the console's settings makes no notification, but of a task whose bell they turned on themselves, which `followed` says, so send to nobody `told` does not name. Which of it a member wants from your plugin is your plugin's setting and none of the console's, whose settings name no plugin: offer it on a page of your own and as a command of your plugin, since an agent account chooses from the command, keep it in your own records or tables by `personId` and kind (the kinds are `NOTIFICATION_KINDS` of `@skillcdn/console/api`), and leave out of what you send whoever turned a kind off there; show as off what is off in the console, which a member's own call reads of theirs (`ctx.console.notifications.settings()`, a console from 0.6.2 on), since nothing of it comes to send; whether a task a member turned on themselves is sent whatever that setting says is yours to decide, and `followed` is how you tell. The event itself still arrives, whoever was told, so let what the handler does besides sending go on. |
|
|
77
77
|
| Another plugin must tell it | A **hook** on `plugin:<key>:<kind>` (`events:plugins`), or a call on the other's `api` (`plugins:<key>`). |
|
|
78
78
|
| Time passes | A **job** (`jobs`), `every` or `at` in the workspace's time zone, never two at once; what it did goes into records and, where people should know, a task or a decision. |
|
|
79
79
|
| An outside service calls in | An **endpoint** (`endpoints`): a `person` endpoint for whoever holds a role, a `webhook` for nobody, verified with `ctx.secrets.verify` against a secret setting. |
|
|
@@ -84,7 +84,7 @@ Produces the **design**: one table, a row per thing the feature does, saying who
|
|
|
84
84
|
|
|
85
85
|
Then the data. Records, unless the feature needs what records do not give: joins across many collections, more rows than a plugin's records may hold, or figures beyond counting, summing, the least and the most; then `storage:sql`, a schema and a role of the plugin's own with migrations under `migrations/`, which needs the deployment's database user to hold `CREATEROLE` and to own the database, closes the console's schemas to every other role not granted them by name, and is said in the hand-over. The role reaches its own schema alone: a statement that names a table of the console's is refused. Records are the default: the console keeps them with versions, files, links, search and aggregates, exports and purges them, and shows them to people by role; a schema is the plugin's to keep.
|
|
86
86
|
|
|
87
|
-
Then the capabilities: the list the split needs, each read as the sentence the administrator will consent to (the specification's catalogue says what each opens and what a malicious plugin could do with it). A capability no row needs is dropped; `people:read:all`, `people:read:email` (the work email, to match a person to an account elsewhere), `projects:read:all`, `storage:sql` and every `outbound:<host>` are asked for only where the design shows the row that needs them. Write the design: the table, the collections with their fields, the roles, the settings, the board (`needs`, the defaults), the menu group, the pages and the widgets, and the capabilities with their sentences; stop for the checkpoint.
|
|
87
|
+
Then the capabilities: the list the split needs, each read as the sentence the administrator will consent to (the specification's catalogue says what each opens and what a malicious plugin could do with it). A capability no row needs is dropped; `people:read:all`, `people:read:email` (the work email, to match a person to an account elsewhere), `people:accounts` (telling the console which account at a messenger is whose, by which an agent account takes a supervisor's word there), `projects:read:all`, `storage:sql` and every `outbound:<host>` are asked for only where the design shows the row that needs them. A plugin that holds `people:read:all`, for a hook or a job, reads everyone in a person's call too, which is more than that person sees on a console that keeps its people apart: whatever a page or a command shows its caller of the people, a calendar of who is away, a list, a picker, is read with `seenByCaller: true` (`ctx.console.people.list({ seenByCaller: true })`, and the same option on `get`, `granted` and the teams; a console from 0.6.3 on), the people the console's own page shows that member ([ADR-0168](/docs/adr/0168-a-plugin-that-holds-the-whole-directory-reads-the-people-its-caller-may-see-where-it-asks.md)), and the whole directory is kept for what the plugin itself decides, as whom a request goes to; where "everyone" is the plugin's own to reach, a notice say, `ctx.console.workspace().peopleVisibility` says whether that is more than any one member sees, to tell the administrator. Write the design: the table, the collections with their fields, the roles, the settings, the board (`needs`, the defaults), the menu group, the pages and the widgets, and the capabilities with their sentences; stop for the checkpoint.
|
|
88
88
|
|
|
89
89
|
### Phase 2: Start from the template, then fill it
|
|
90
90
|
|
|
@@ -5,7 +5,7 @@ license: MIT
|
|
|
5
5
|
compatibility: Needs a shell with Node.js 24 or newer, git, curl, jq and the AWS CLI v2, the gh command signed in or an empty repository the person made, network access to AWS, Cloudflare, GitHub and npm, an AWS account and a domain on Cloudflare the person can create a key and a token for, and a browser on any device for the few steps only a signed-in person can take. Works in any agent that can run a shell and write files; on Windows, in Git Bash with path conversion off.
|
|
6
6
|
metadata:
|
|
7
7
|
author: skillcdn
|
|
8
|
-
version: "1.
|
|
8
|
+
version: "1.9"
|
|
9
9
|
skillcdn:
|
|
10
10
|
translations:
|
|
11
11
|
ko:
|
|
@@ -14,7 +14,7 @@ skillcdn:
|
|
|
14
14
|
---
|
|
15
15
|
# Deploying a console for an organization
|
|
16
16
|
|
|
17
|
-
What goes in: an AWS account, a domain on Cloudflare or one to buy, and the answers to a few plain questions. What comes out: the console at `https://<hostname>`, signed in by its first administrator, with a first project and an agent connected; running as containers on AWS next to a managed PostgreSQL and a bucket, reached only through Cloudflare, every secret in a parameter store; a private deployment repository whose every push rebuilds and redeploys; a budget alert; and a record, `DEPLOY.md`, of what exists and how it is run. The person never needs to know the cloud: every choice is derived from their answers, shown with its cost, and changed when they ask. The shape and why it was chosen are [ADR-0017](/docs/adr/0017-the-reference-deployment-is-the-image-on-aws-behind-cloudflare-written-as-a-skill.md); what the console asks of any platform is [deploy/README.md](/deploy/README.md). For one machine, a trial, or a closed network that reaches no cloud, the smallest install of [deploy/README.md](/deploy/README.md#the-smallest-install-and-a-closed-network) is the shape, not this skill: the image next to PostgreSQL with the packs in a directory, carried in where nothing is reachable.
|
|
17
|
+
What goes in: an AWS account, a domain on Cloudflare or one to buy, and the answers to a few plain questions. What comes out: the console at `https://<hostname>`, signed in by its first administrator, with a first project and an agent connected; running as containers on AWS next to a managed PostgreSQL and a bucket, reached only through Cloudflare, every secret in a parameter store; a private deployment repository whose every push rebuilds and redeploys; a budget alert; and a record, `DEPLOY.md`, of what exists and how it is run. The person never needs to know the cloud: every choice is derived from their answers, shown with its cost, and changed when they ask. The shape and why it was chosen are [ADR-0017](/docs/adr/0017-the-reference-deployment-is-the-image-on-aws-behind-cloudflare-written-as-a-skill.md); what the console asks of any platform is [deploy/README.md](/deploy/README.md). For one machine, a trial, or a closed network that reaches no cloud, the smallest install of [deploy/README.md](/deploy/README.md#the-smallest-install-and-a-closed-network) is the shape, not this skill: the image next to PostgreSQL with the packs in a directory, carried in where nothing is reachable. A trial on one's own computer, from nothing to a first task worked on the board, is the skill [trying-a-console](/skills/trying-a-console/SKILL.md).
|
|
18
18
|
|
|
19
19
|
## How the person is involved
|
|
20
20
|
|
|
@@ -32,7 +32,7 @@ What goes in: an AWS account, a domain on Cloudflare or one to buy, and the answ
|
|
|
32
32
|
| A shell with Node.js 24 or newer, git, curl, jq and the AWS CLI v2 (`aws --version`); on Windows, Git Bash with `export MSYS_NO_PATHCONV=1`, since Git Bash otherwise rewrites an argument that starts with `/` (a log group, a parameter) into a Windows path before a program sees it | Every command of the run; the deployment repository |
|
|
33
33
|
| The deployer's access key and the Cloudflare token, as [access.md](references/access.md) says they are made and reach the agent | Everything on AWS and at Cloudflare |
|
|
34
34
|
| The `gh` command signed in (`gh auth status`), or an empty private repository the person made | The deployment repository, its first push, watching its runs |
|
|
35
|
-
| The `console` command, `npm install -g @skillcdn/console` in phase 1 | The proof at the end: an agent connected, a file handed in; and this skill's
|
|
35
|
+
| The `console` command, `npm install -g @skillcdn/console` in phase 1 | The proof at the end: an agent connected, a file handed in; and this skill's scripts, which the package carries at `$(npm root -g)/@skillcdn/console/skills/deploying-a-console/scripts/`, copied into the run's `scratch/` folder, or read through the connection and written there; and the skill building-a-console, beside this one at `$(npm root -g)/@skillcdn/console/skills/building-a-console/SKILL.md` or through the connection, for the look and `console-ui/` |
|
|
36
36
|
| The person, with a browser on any device | The GitHub App or the Google client, the first sign-in, approving the agent's code, a registrar's nameservers |
|
|
37
37
|
| Network access to AWS, Cloudflare, GitHub and npm | |
|
|
38
38
|
|
|
@@ -65,7 +65,21 @@ curl -s https://api.cloudflare.com/client/v4/accounts -H @scratch/auth.txt
|
|
|
65
65
|
|
|
66
66
|
### The GitHub App, for signing in with GitHub, and for the organization to say who is in
|
|
67
67
|
|
|
68
|
-
One app does both ([ADR-0022](/docs/adr/0022-who-is-in-is-the-consoles-own-record-and-an-administrator-keeps-it.md)): its client signs people in, and, installed on the organization, it lets the console read who is a member, at sign-in and every ten minutes after.
|
|
68
|
+
One app does both ([ADR-0022](/docs/adr/0022-who-is-in-is-the-consoles-own-record-and-an-administrator-keeps-it.md)): its client signs people in, and, installed on the organization, it lets the console read who is a member, at sign-in and every ten minutes after. It is made once the console's address is known, by the script first and by hand where that does not go.
|
|
69
|
+
|
|
70
|
+
**With one press, by the script** ([github-app.mjs](../scripts/github-app.mjs), [ADR-0171](/docs/adr/0171-the-smallest-install-registers-its-github-app-from-a-manifest-with-one-press.md)), on the machine whose browser the person is signed in to GitHub with:
|
|
71
|
+
|
|
72
|
+
```sh
|
|
73
|
+
node scratch/github-app.mjs --url https://<hostname> --org <the organization's login> --secrets "$SECRETS" --wait 100
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
- Tell the person first, in a message of its own, since the command prints its words when it ends: "Open `http://127.0.0.1:11196/` in the browser where you are signed in to GitHub as an owner of `<organization>`, and press **Create GitHub App** once. The app reads who is a member of the organization, and nothing of your repositories." Then run the command. It waits for the press as long as `--wait` says, which is kept under what the host gives a command; where it ends with nothing registered, say so and run it again.
|
|
77
|
+
- It writes `GITHUB_CLIENT_SECRET` and `GITHUB_APP_PRIVATE_KEY` into the secrets file itself, and prints what is no secret: `GITHUB_CLIENT_ID` and `GITHUB_APP_ID` for the plan, the app's owner and its page. No secret passes through the chat or a command line, and none is left for the person to rotate.
|
|
78
|
+
- Then the person installs the app on the organization, from the address the command's last line names: Install, and confirm. No repository access is asked for. Everyone of the organization is in from then on; the plan's `GITHUB_ORG` is the organization's login.
|
|
79
|
+
- Without an organization, leave `--org` out: the app signs people in, the key is not kept, and an administrator lets each person in on the People page.
|
|
80
|
+
- Where GitHub refuses the settings, its page says why: go on by hand, below; and so where the person's browser is on another device than this machine, since the page is this machine's own. The script was run against a stand-in for GitHub and not yet against GitHub itself ([ADR-0171](/docs/adr/0171-the-smallest-install-registers-its-github-app-from-a-manifest-with-one-press.md)): say in the record which way the app was made.
|
|
81
|
+
|
|
82
|
+
**By hand**, the person, signed in to GitHub as an owner of the organization (checked 2026-10): Your organizations, Settings next to the organization, Developer settings, GitHub Apps, New GitHub App.
|
|
69
83
|
|
|
70
84
|
- GitHub App name: the board's name (34 characters at most, unique across GitHub).
|
|
71
85
|
- Homepage URL: the console's address, `https://<hostname>`.
|
|
@@ -17,7 +17,7 @@ SECRETS=../console-secrets.json # outside the repository; made by the f
|
|
|
17
17
|
|
|
18
18
|
Every id the run makes or finds (`CF_ACCOUNT`, `ZONE`, `VPC`, `SUBNETS`, `TASKS_SG`, `DB_SG`, `ENDPOINT`, `BUCKET`, `TUNNEL`, the rules' ids) goes into `scratch/notes.md` as it is made, as a line `NAME=value`, and a new shell sets them again from there (`set -a; . scratch/notes.md; set +a` when the file holds nothing but such lines): phases 5 to 7 come after a ten-minute watch, or after a pause of hours, almost always in a new shell. Where every command runs in a new shell, as some agents' tools do, the lines above go in `scratch/env.sh`, sourced at the start of every command; a wait longer than one command may take (the database, the workflow's run, a sign-in) runs in the background or is polled.
|
|
19
19
|
|
|
20
|
-
A value that must not be seen goes through a file or a pipe, never a command line: `aws ... --cli-input-json file://scratch/<file>` for a request that carries one, and the
|
|
20
|
+
A value that must not be seen goes through a file or a pipe, never a command line: `aws ... --cli-input-json file://scratch/<file>` for a request that carries one, and the scripts of this skill ([import-aws-key.mjs](../scripts/import-aws-key.mjs), [store-secrets.mjs](../scripts/store-secrets.mjs), [github-app.mjs](../scripts/github-app.mjs)), copied to `scratch/`, for the key, the parameters and the GitHub App. A response that carries one is piped straight into the secrets file:
|
|
21
21
|
|
|
22
22
|
```sh
|
|
23
23
|
set_secret() { node scratch/store-secrets.mjs set "$SECRETS" "$1"; } # reads the value from standard input
|
|
@@ -207,7 +207,7 @@ The generated one first, if the Conventions' example was not run as a step: `nod
|
|
|
207
207
|
|
|
208
208
|
### The secrets the person holds
|
|
209
209
|
|
|
210
|
-
The hostname being known, one message per provider chosen with the steps of access.md "The GitHub App" and "The OAuth client", the exact URLs filled in, the lines to add to the secrets file (`"GITHUB_CLIENT_SECRET": "<the secret>"`, and, with an organization, `"GITHUB_APP_PRIVATE_KEY": "<the key, as PEM>"`, the file's lines joined with `\n`), and `later` as the other answer. On an answer, store it (`store` again adds what is new) and note the client id, and the app's id and the organization, for the task definition. A provider answered `later` is left out of the task definition entirely, since the console wants both halves or neither, and so is the organization without its key, since it wants all three or none; a provider not chosen has no line in the secrets file and nothing in the record.
|
|
210
|
+
The hostname being known, the GitHub App is made by the script, with the person's one press (access.md "The GitHub App": it writes its two secrets into the secrets file and prints the client id and the app's id); where that does not go, and for Google, one message per provider chosen with the steps of access.md "The GitHub App", by hand, and "The OAuth client", the exact URLs filled in, the lines to add to the secrets file (`"GITHUB_CLIENT_SECRET": "<the secret>"`, and, with an organization, `"GITHUB_APP_PRIVATE_KEY": "<the key, as PEM>"`, the file's lines joined with `\n`), and `later` as the other answer. On an answer, store it (`store` again adds what is new) and note the client id, and the app's id and the organization, for the task definition. A provider answered `later` is left out of the task definition entirely, since the console wants both halves or neither, and so is the organization without its key, since it wants all three or none; a provider not chosen has no line in the secrets file and nothing in the record.
|
|
211
211
|
|
|
212
212
|
## Phase 4: The deployment repository
|
|
213
213
|
|