@okostream/mcp 0.17.0 → 0.18.1

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.
Files changed (3) hide show
  1. package/README.md +53 -7
  2. package/dist/server.js +1189 -457
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -6,9 +6,8 @@ analytics, and integrations around a video player supplied by the organizer.
6
6
 
7
7
  ## Before You Connect
8
8
 
9
- Webinar data and actions require an active OKO organizer account. Organizer
10
- an active organizer account is required before an API key can be created
11
- signup.
9
+ Webinar data and actions require an active OKO organizer account. An active
10
+ organizer account is required before an API key can be created.
12
11
 
13
12
  - Already invited: [sign in or register](https://okostream.app/auth?redirect=/app/mcp).
14
13
  - Already an organizer: create a scoped key in the
@@ -86,6 +85,28 @@ is behind, with the exact update step. Global installs update with
86
85
  now (the extension bundle is discontinued; the Desktop path returns when the
87
86
  package ships through a directory).
88
87
 
88
+ ## Publishing and lumens
89
+
90
+ A new page is a draft: viewers of its public URL see "not published".
91
+ `oko_publish_event` publishes it and, like a few other operations, spends
92
+ **lumens**, the unit of the OKO wallet. Money is handled in one direction:
93
+
94
+ - **Spending is previewed.** `oko_publish_event`, `oko_unpublish_event`,
95
+ `oko_start_session`, `oko_extend_session` and `oko_publish_telegram_post`
96
+ state the charge (or the refund) when called without `confirm`, name the
97
+ wallet that pays, and take nothing until the organizer confirms. The amount in
98
+ the preview is the amount charged; the public price list is at
99
+ [okostream.app/pricing](https://okostream.app/pricing) and is not copied here.
100
+ - **`oko_wallet` reads the wallet.** It returns the lumen balance, the grants and
101
+ the ledger of the organizer behind the key (scope `wallet:read`, included in
102
+ the `operator` and `full` presets, not in `readOnly`). Keys created before that scope existed get `SCOPE_REQUIRED` and
103
+ need a new key. A page in a shared workspace is paid from the workspace
104
+ owner's wallet: its balance is told, in the previews and refusals, to whoever
105
+ may spend from it; its grants and ledger are the owner's to read.
106
+ - **Payment and terms are web-only.** Plans and lumens are bought, and terms
107
+ accepted, only in the OKO web cabinet, and no MCP tool collects a password,
108
+ card or bank details, or agreement to terms on anyone's behalf.
109
+
89
110
  ## When a tool refuses
90
111
 
91
112
  Refusals are explicit and never require guessing:
@@ -96,10 +117,28 @@ Refusals are explicit and never require guessing:
96
117
  or rephrasing does not help; the result carries a ready-made report for the
97
118
  OKO team.
98
119
  - `PLATFORM_REJECTED_READ` — no access to that resource, or it does not exist.
99
- - `CHAT_PAUSED` — the event's chat is paused and accepts no messages from anyone,
100
- the owner included; it is the chat's state, not a missing permission.
120
+ - `ENTITLEMENT_REQUIRED` / `INSUFFICIENT_TOKENS` — the plan that pays lacks the
121
+ feature, or the wallet that pays is short of lumens. `oko_publish_telegram_post`
122
+ costs 5 lumens per post, charged when Telegram confirms delivery; the plan and the
123
+ balance are checked before the send, and the refusal names the `postId` left
124
+ behind as `failed` (create a new post after fixing the cause, then delete the
125
+ failed one with `oko_cancel_telegram_post`).
126
+ - `CHAT_PAUSED` — the event's chat is paused, which closes it for viewers (the
127
+ event owner and moderators still write into a paused chat); it is the chat's
128
+ state, not a missing permission.
101
129
  `CHAT_MESSAGE_REFUSED` — the chat refused a message and the cause could not be
102
130
  established; the result lists what was ruled out and what remains possible.
131
+ - `EVENT_DATE_LOCKED` — the date of a published page moves only inside the show
132
+ window it bought (the result carries `windowStart`, `windowEnd` and the next
133
+ steps); a date outside the window, a cleared date, or any date on a page whose
134
+ show is over is refused. `oko_update_event` may also return `warnings` (advice,
135
+ never a refusal).
136
+ - `WORKSPACE_LIMIT`, `SEATS_FULL`, `ENTITLEMENT_REQUIRED` — the plan of the
137
+ workspace owner does not hold another shared workspace, another member, or
138
+ the capability at all. A refused invitation stays valid. Plans are bought only
139
+ in the OKO cabinet, never through MCP.
140
+ - `WORKSPACE_INACTIVE` — `oko_publish_event` in a shared workspace the plan no
141
+ longer publishes into (Pro: only the workspace its owner chose as active).
103
142
 
104
143
  **One install path.** Every supported client — Claude Code, Codex, and any
105
144
  MCP client that takes a command with arguments and env — runs the package
@@ -122,10 +161,17 @@ always works. The result's `sourceVia` says who fetched the image.
122
161
  ## Capabilities
123
162
 
124
163
  - Create, duplicate, move, restore, and delete webinars.
125
- - Configure video, forms, calls to action, cards, banners, and images.
164
+ - Configure video, forms, calls to action, cards, banners, and images. On an
165
+ already published page, turning on a banner, CTA, cards or forms costs 10
166
+ lumens each for that show: the tool answers with the quote first and writes
167
+ only after `confirm=true`; unpublishing later does not return these top-ups.
168
+ The live control room is a paid option of a published page (50 lumens, Pro
169
+ and above) bought in the analytics screen, not through MCP.
126
170
  - Operate live audience controls, chat, moderation, and analytics sessions.
127
171
  - Read analytics, session reports, geography, engagement, and form submissions.
128
- - Manage workspaces, invitations, notifications, and Telegram publishing.
172
+ - Manage workspaces, invitations, notifications, and Telegram publishing
173
+ (5 lumens per post, shown in the confirmation preview).
174
+ - Read the lumen balance and ledger of your own wallet (`oko_wallet`).
129
175
 
130
176
  OKO MCP acts as the organizer represented by the selected access key. It does
131
177
  not inherit platform-owner privileges. Keys are scoped and revocable, and