@commonlyai/mcp 0.3.19 → 0.3.20

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 (2) hide show
  1. package/package.json +1 -1
  2. package/src/tools.js +16 -0
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@commonlyai/mcp",
3
3
  "mcpName": "io.github.Team-Commonly/commonly",
4
- "version": "0.3.19",
4
+ "version": "0.3.20",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
7
7
  "type": "git",
package/src/tools.js CHANGED
@@ -215,6 +215,22 @@ export const buildTools = (config) => {
215
215
  body: outcome === undefined ? undefined : { outcome },
216
216
  })),
217
217
  },
218
+ {
219
+ name: 'commonly_checkpoint_event',
220
+ description: 'Checkpoint ONE inbox event only after tool-side work is committed (including a reply posted through a tool), or a deliberate NO_REPLY. Never checkpoint an answer held for final CLI output: the wrapper must post that reply before acknowledging the item. This durably acknowledges that event now, so a later turn timeout does not replay it. Use only the eventId and deliveryId supplied together in the current inbox item. Never checkpoint unseen or unfinished work. Release any message claim with its correct completed/declined outcome first. A failed call is not a checkpoint; leave the item pending. This posts no chat message and does not complete a task.',
221
+ inputSchema: reqWith({ eventId: { type: 'string', minLength: 1 }, deliveryId: { type: 'string', minLength: 1 } }, ['eventId', 'deliveryId']),
222
+ call: wrap(async ({ eventId, deliveryId }) => {
223
+ if (typeof eventId !== 'string' || !eventId.trim()
224
+ || typeof deliveryId !== 'string' || !deliveryId.trim()) {
225
+ throw new Error('eventId and deliveryId from the current inbox item are required');
226
+ }
227
+ return request(config, {
228
+ method: 'POST',
229
+ path: `/api/agents/runtime/events/${encodeURIComponent(eventId)}/ack`,
230
+ body: { deliveryId, result: { outcome: 'acknowledged', reason: 'handled-checkpoint' } },
231
+ });
232
+ }),
233
+ },
218
234
  {
219
235
  name: 'commonly_get_messages',
220
236
  description: 'Read chat messages from a pod. `limit` is clamped server-side to [1, 50] (default 20). To page into older history, pass the `createdAt` timestamp of the oldest message as `before`; the response `hasMore` flag distinguishes another page from the end of history. Pass `threadRootId` (a message id) to read one thread — returns the root message plus every reply in that thread, oldest first.',