@pstdio/sdk 0.7.0 → 0.9.0
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 +27 -188
- package/dist/api/extensions.d.ts +1 -1
- package/dist/api/index.d.ts +2 -2
- package/dist/api/settings.d.ts +1 -0
- package/dist/api/statuses.d.ts +1 -0
- package/dist/api/tags.d.ts +1 -0
- package/dist/api/tickets.d.ts +3 -0
- package/dist/api/workspaces.d.ts +10 -1
- package/dist/client/client.d.ts +7 -2
- package/dist/client/index.d.ts +5 -3
- package/dist/client/index.js +285 -31
- package/dist/client/projects.d.ts +0 -11
- package/dist/client/request.d.ts +9 -0
- package/dist/client/sessions.d.ts +25 -3
- package/dist/client/settings.d.ts +7 -0
- package/dist/client/sse.d.ts +15 -0
- package/dist/client/statuses.d.ts +2 -0
- package/dist/client/sync.d.ts +35 -0
- package/dist/client/tags.d.ts +2 -0
- package/dist/client/tickets.d.ts +6 -1
- package/dist/client/workspaces.d.ts +2 -0
- package/dist/extensions/define-command.d.ts +1 -1
- package/dist/extensions/define-extension.d.ts +50 -7
- package/dist/extensions/index.d.ts +3 -2
- package/dist/extensions/index.js +151 -11
- package/dist/extensions/kernel-slots.d.ts +131 -10
- package/dist/extensions/params.d.ts +19 -12
- package/dist/extensions/refs.d.ts +3 -3
- package/dist/extensions/slots.d.ts +1 -9
- package/dist/extensions/types/commands.d.ts +8 -0
- package/dist/extensions/types/context.d.ts +225 -18
- package/dist/extensions/types/contributions.d.ts +183 -10
- package/dist/extensions/types/extension.d.ts +16 -10
- package/dist/extensions/types/params.d.ts +43 -29
- package/dist/extensions/types/slots.d.ts +1 -1
- package/dist/extensions/types/webview-capabilities.d.ts +12 -2
- package/dist/extensions/workbench-targets.d.ts +134 -0
- package/dist/hooks/attempt.d.ts +2 -0
- package/dist/hooks/entities.d.ts +2 -0
- package/dist/hooks/ticket.d.ts +3 -0
- package/dist/resources/index.d.ts +3 -0
- package/dist/resources/index.js +26 -0
- package/dist/resources/known-agents.d.ts +12 -0
- package/dist/resources/settings.d.ts +1 -0
- package/dist/resources/status.d.ts +1 -0
- package/dist/resources/tag.d.ts +1 -0
- package/dist/resources/ticket.d.ts +1 -0
- package/dist/resources/workspace.d.ts +4 -1
- package/package.json +2 -6
- package/dist/api/actions.d.ts +0 -13
- package/dist/client/actions.d.ts +0 -8
- package/dist/plugins/define-plugin.d.ts +0 -2
- package/dist/plugins/helpers/context.d.ts +0 -24
- package/dist/plugins/helpers/create-attempt.d.ts +0 -5
- package/dist/plugins/helpers/create-session.d.ts +0 -21
- package/dist/plugins/helpers/create-workspace.d.ts +0 -5
- package/dist/plugins/helpers/find-ticket-by-ref.d.ts +0 -6
- package/dist/plugins/helpers/find-workspace-by-ref.d.ts +0 -5
- package/dist/plugins/helpers/followup-session.d.ts +0 -29
- package/dist/plugins/helpers/get-attempts-for-ticket.d.ts +0 -17
- package/dist/plugins/helpers/index.d.ts +0 -16
- package/dist/plugins/helpers/remove-all-worktrees-for-ticket.d.ts +0 -2
- package/dist/plugins/helpers/run-command.d.ts +0 -10
- package/dist/plugins/helpers/save-ticket.d.ts +0 -14
- package/dist/plugins/helpers/set-ticket-status.d.ts +0 -7
- package/dist/plugins/helpers/set-workspace-attempt-status.d.ts +0 -7
- package/dist/plugins/helpers/ticket-pull.d.ts +0 -18
- package/dist/plugins/helpers/update-ticket-when-all-attempts-match.d.ts +0 -7
- package/dist/plugins/helpers/workspaces-for-ticket.d.ts +0 -17
- package/dist/plugins/helpers/worktree-bootstrap.d.ts +0 -8
- package/dist/plugins/hooks.d.ts +0 -42
- package/dist/plugins/index.d.ts +0 -5
- package/dist/plugins/index.js +0 -739
- package/dist/plugins/types.d.ts +0 -112
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@ This package is the public integration surface for:
|
|
|
7
7
|
- calling the Prompt Studio HTTP API
|
|
8
8
|
- importing shared request and resource types
|
|
9
9
|
- rendering prompt templates
|
|
10
|
-
- authoring Prompt Studio
|
|
10
|
+
- authoring Prompt Studio extensions
|
|
11
11
|
|
|
12
12
|
The package is ESM-only and is published through subpath exports. Import from the entrypoint you need, not from `@pstdio/sdk` directly.
|
|
13
13
|
|
|
@@ -19,14 +19,13 @@ bun add @pstdio/sdk
|
|
|
19
19
|
|
|
20
20
|
## Entry Points
|
|
21
21
|
|
|
22
|
-
| Import path
|
|
23
|
-
|
|
|
24
|
-
| `@pstdio/sdk/client`
|
|
25
|
-
| `@pstdio/sdk/api`
|
|
26
|
-
| `@pstdio/sdk/resources`
|
|
27
|
-
| `@pstdio/sdk/
|
|
28
|
-
| `@pstdio/sdk/
|
|
29
|
-
| `@pstdio/sdk/hooks` | Hook context and hook client types |
|
|
22
|
+
| Import path | Purpose |
|
|
23
|
+
| ------------------------ | ------------------------------------- |
|
|
24
|
+
| `@pstdio/sdk/client` | Runtime HTTP client for Prompt Studio |
|
|
25
|
+
| `@pstdio/sdk/api` | Request and response payload types |
|
|
26
|
+
| `@pstdio/sdk/resources` | Shared resource/entity types |
|
|
27
|
+
| `@pstdio/sdk/prompts` | Prompt rendering helpers |
|
|
28
|
+
| `@pstdio/sdk/extensions` | Extension authoring types |
|
|
30
29
|
|
|
31
30
|
Example:
|
|
32
31
|
|
|
@@ -34,9 +33,8 @@ Example:
|
|
|
34
33
|
import { createClient, PstdioApiError } from "@pstdio/sdk/client";
|
|
35
34
|
import type { CreateTicketInput } from "@pstdio/sdk/api";
|
|
36
35
|
import type { TicketDetail } from "@pstdio/sdk/resources";
|
|
37
|
-
import { createSession, definePlugin } from "@pstdio/sdk/plugins";
|
|
38
36
|
import { renderPrompt } from "@pstdio/sdk/prompts";
|
|
39
|
-
import type {
|
|
37
|
+
import type { ExtensionDefinition } from "@pstdio/sdk/extensions";
|
|
40
38
|
```
|
|
41
39
|
|
|
42
40
|
## HTTP Client
|
|
@@ -71,7 +69,6 @@ The request layer throws `PstdioApiError` for non-2xx responses.
|
|
|
71
69
|
|
|
72
70
|
- `error.message`: API error message
|
|
73
71
|
- `error.status`: HTTP status code
|
|
74
|
-
- when the API returns `hook_output`, it is appended to `message`
|
|
75
72
|
|
|
76
73
|
```ts
|
|
77
74
|
import { PstdioApiError, createClient } from "@pstdio/sdk/client";
|
|
@@ -105,7 +102,6 @@ try {
|
|
|
105
102
|
| `templates` | `list`, `get`, `create`, `update`, `delete` |
|
|
106
103
|
| `skills` | `list`, `get`, `update` |
|
|
107
104
|
| `agents` | `list`, `info`, `models`, `setup`, `setupAvailable`, `update`, `delete` |
|
|
108
|
-
| `actions` | `list`, `execute` |
|
|
109
105
|
|
|
110
106
|
Notes:
|
|
111
107
|
|
|
@@ -125,18 +121,11 @@ import type {
|
|
|
125
121
|
} from "@pstdio/sdk/api";
|
|
126
122
|
```
|
|
127
123
|
|
|
128
|
-
Most of these types come from `pstdio-api-contracts`.
|
|
129
|
-
|
|
130
|
-
- `ListTicketsInput`
|
|
131
|
-
- `TicketAttemptResponse`
|
|
132
|
-
- `ActionResult`
|
|
133
|
-
- `ExecuteActionInput`
|
|
134
|
-
|
|
135
|
-
Use `import type` for this entrypoint. It does not expose runtime helpers.
|
|
124
|
+
Most of these types come from `pstdio-api-contracts`. Use `import type` for this entrypoint. It does not expose runtime helpers.
|
|
136
125
|
|
|
137
126
|
## Resource Types
|
|
138
127
|
|
|
139
|
-
`@pstdio/sdk/resources` re-exports the shared Prompt Studio entities used across the API and
|
|
128
|
+
`@pstdio/sdk/resources` re-exports the shared Prompt Studio entities used across the API and extension system.
|
|
140
129
|
|
|
141
130
|
Common exports include `Project`, `Repo`, `Ticket`, `TicketDetail`, `TicketListItem`, `TicketFile`, `Workspace`,
|
|
142
131
|
`WorkspaceListItem`, `Session`, `SessionStatus`, `Status`, `AttemptStatus`, `Tag`, `TagOption`, `Template`,
|
|
@@ -163,179 +152,29 @@ const prompt = renderPrompt("Implement ticket {{ticket}}", {
|
|
|
163
152
|
});
|
|
164
153
|
```
|
|
165
154
|
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
## Plugins
|
|
169
|
-
|
|
170
|
-
Prompt Studio plugins export a default `definePlugin(...)` result from a TypeScript or JavaScript module.
|
|
171
|
-
|
|
172
|
-
Plugins can provide:
|
|
155
|
+
## Extensions
|
|
173
156
|
|
|
174
|
-
|
|
175
|
-
- `hooks`: lifecycle handlers that run before or after Prompt Studio events
|
|
176
|
-
|
|
177
|
-
### Action example
|
|
157
|
+
Prompt Studio extensions are packaged integrations that can contribute commands, middleware, lifecycle event handlers, menu entries, and webviews. Use `@pstdio/sdk/extensions` for the extension authoring types.
|
|
178
158
|
|
|
179
159
|
```ts
|
|
180
|
-
import {
|
|
181
|
-
|
|
182
|
-
export default definePlugin({
|
|
183
|
-
actions: [
|
|
184
|
-
{
|
|
185
|
-
key: "refine-ticket",
|
|
186
|
-
label: "Refine ticket",
|
|
187
|
-
targetType: "ticket",
|
|
188
|
-
placement: "overflow",
|
|
189
|
-
params: [
|
|
190
|
-
{
|
|
191
|
-
key: "context",
|
|
192
|
-
label: "Additional context",
|
|
193
|
-
type: "longtext",
|
|
194
|
-
required: false,
|
|
195
|
-
},
|
|
196
|
-
],
|
|
197
|
-
async trigger(ctx) {
|
|
198
|
-
const context = ctx.params.context as string | undefined;
|
|
199
|
-
|
|
200
|
-
const parts = [`Refine ticket: ${ctx.target.shorthand}`];
|
|
201
|
-
if (context) parts.push(`Additional context:\n${context}`);
|
|
202
|
-
|
|
203
|
-
await createSession(ctx, {
|
|
204
|
-
title: `Refine ticket: ${ctx.target.shorthand}`,
|
|
205
|
-
prompt: parts.join("\n\n"),
|
|
206
|
-
});
|
|
207
|
-
},
|
|
208
|
-
},
|
|
209
|
-
],
|
|
210
|
-
});
|
|
211
|
-
```
|
|
160
|
+
import type { ExtensionDefinition } from "@pstdio/sdk/extensions";
|
|
212
161
|
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
"bun",
|
|
226
|
-
"run",
|
|
227
|
-
"validate",
|
|
228
|
-
]);
|
|
229
|
-
if (validation.exitCode === 0) return;
|
|
230
|
-
|
|
231
|
-
const output = [validation.stdout, validation.stderr]
|
|
232
|
-
.filter(Boolean)
|
|
233
|
-
.join("\n\n");
|
|
234
|
-
|
|
235
|
-
return {
|
|
236
|
-
reject: true,
|
|
237
|
-
reason: output || "bun run validate failed",
|
|
238
|
-
};
|
|
239
|
-
},
|
|
162
|
+
const extension: ExtensionDefinition = {
|
|
163
|
+
manifest: {
|
|
164
|
+
id: "example-extension",
|
|
165
|
+
name: "Example extension",
|
|
166
|
+
version: "0.0.0",
|
|
167
|
+
},
|
|
168
|
+
activate(ctx) {
|
|
169
|
+
ctx.commands.register({
|
|
170
|
+
id: "example-extension.say-hello",
|
|
171
|
+
title: "Say hello",
|
|
172
|
+
handler: () => ({ ok: true }),
|
|
173
|
+
});
|
|
240
174
|
},
|
|
241
|
-
});
|
|
242
|
-
```
|
|
243
|
-
|
|
244
|
-
### Plugin types
|
|
245
|
-
|
|
246
|
-
The plugin entrypoint exports the core types used by plugin authors, including `PluginDefinition`, `PluginHooks`,
|
|
247
|
-
`PrePluginHooks`, `PostPluginHooks`, `HookResponse`, `PreHookReturn`, `PostHookReturn`, `ActionDefinition`,
|
|
248
|
-
`ActionDescriptor`, `ActionInput`, `ActionTriggerContext`, `ActionParamDef`, `TargetType`, and `ActionPlacement`.
|
|
249
|
-
|
|
250
|
-
Action parameter definitions support `text`, `longtext`, `select`, `template-select`, `agent`, and `repo`.
|
|
251
|
-
Action targets support `ticket`, `workspace`, and `session`. Action placement supports `primary`, `secondary`,
|
|
252
|
-
and `overflow`.
|
|
253
|
-
|
|
254
|
-
`definePlugin()` is intentionally small. Today it mainly validates that every declared action has a `trigger(ctx)` function and then returns the plugin definition unchanged.
|
|
255
|
-
|
|
256
|
-
### Lifecycle hooks
|
|
257
|
-
|
|
258
|
-
Pre hooks may return `{ reject, reason, data }` to stop an operation. Post hooks return `void`.
|
|
259
|
-
|
|
260
|
-
Available pre hooks:
|
|
261
|
-
|
|
262
|
-
- `preTicketCreation`
|
|
263
|
-
- `preTicketStatusChange`
|
|
264
|
-
- `preTicketArchive`
|
|
265
|
-
- `preTicketDeletion`
|
|
266
|
-
- `preWorktreeCreate`
|
|
267
|
-
- `preWorktreeRemove`
|
|
268
|
-
- `preCommit`
|
|
269
|
-
- `preRebase`
|
|
270
|
-
- `preMerge`
|
|
271
|
-
- `preAttemptStatusChange`
|
|
272
|
-
|
|
273
|
-
Available post hooks:
|
|
274
|
-
|
|
275
|
-
- `postTicketCreation`
|
|
276
|
-
- `postTicketStatusChange`
|
|
277
|
-
- `postTicketArchive`
|
|
278
|
-
- `postTicketDeletion`
|
|
279
|
-
- `postSessionStart`
|
|
280
|
-
- `postSessionSuccess`
|
|
281
|
-
- `postSessionFail`
|
|
282
|
-
- `postSessionResume`
|
|
283
|
-
- `postSessionAwaitInput`
|
|
284
|
-
- `postWorktreeCreate`
|
|
285
|
-
- `postWorktreeRemove`
|
|
286
|
-
- `postCommit`
|
|
287
|
-
- `postRebase`
|
|
288
|
-
- `postMerge`
|
|
289
|
-
- `onConflict`
|
|
290
|
-
- `postAttemptStatusChange`
|
|
291
|
-
|
|
292
|
-
### Plugin helpers
|
|
293
|
-
|
|
294
|
-
`@pstdio/sdk/plugins` also exports helper functions for common workflow automation:
|
|
295
|
-
|
|
296
|
-
| Helper | Purpose |
|
|
297
|
-
| ---------------------------------- | -------------------------------------------------------------------------------------------- |
|
|
298
|
-
| `createAttempt` | Create a ticket attempt and start a session |
|
|
299
|
-
| `createWorkspace` | Create a ticket attempt without starting a session |
|
|
300
|
-
| `createSession` | Create a session using `ctx.projectId` automatically |
|
|
301
|
-
| `followupSession` | Send a follow-up message using an explicit or contextual session id |
|
|
302
|
-
| `findTicketByRef` | Resolve a ticket by id or shorthand |
|
|
303
|
-
| `findWorkspaceByRef` | Resolve a workspace by id or shorthand |
|
|
304
|
-
| `getAttemptsForTicket` | List workspaces for a ticket |
|
|
305
|
-
| `workspacesForTicket` | List workspaces for a ticket |
|
|
306
|
-
| `setTicketStatus` | Resolve a status by name and update the ticket |
|
|
307
|
-
| `setWorkspaceAttemptStatus` | Update a workspace attempt status by name |
|
|
308
|
-
| `updateTicketWhenAllAttemptsMatch` | Update a ticket when all attempts share a target attempt status |
|
|
309
|
-
| `removeAllWorktreesForTicket` | Remove every worktree currently attached to a ticket |
|
|
310
|
-
| `bootstrapWorktree` | Copy Prompt Studio and agent metadata into a worktree and optionally pull the ticket locally |
|
|
311
|
-
| `pullTickets` | Write ticket markdown and attachments into `.pstdio/tickets/...` |
|
|
312
|
-
| `runCommand` | Run a command array in a working directory and capture `stdout`, `stderr`, and `exitCode` |
|
|
313
|
-
|
|
314
|
-
These helpers accept action or hook context and resolve project-scoped ids for you where possible.
|
|
315
|
-
|
|
316
|
-
## Hook Context Types
|
|
317
|
-
|
|
318
|
-
`@pstdio/sdk/hooks` exposes the shared context types used by hooks and hook runtimes:
|
|
319
|
-
|
|
320
|
-
`BaseHookContext`, `HookClient`, `HookPayload`, `SessionFollowupInput`, `AttemptStatusChangeContext`,
|
|
321
|
-
`SessionHookContext`, `TicketContext`, `TicketCreationContext`, `TicketStatusChangeContext`, `WorktreeContext`,
|
|
322
|
-
and `WorktreeCreateContext`.
|
|
323
|
-
|
|
324
|
-
Import from this entrypoint when you want to annotate hook code explicitly:
|
|
325
|
-
|
|
326
|
-
```ts
|
|
327
|
-
import type {
|
|
328
|
-
SessionHookContext,
|
|
329
|
-
TicketStatusChangeContext,
|
|
330
|
-
} from "@pstdio/sdk/hooks";
|
|
331
|
-
|
|
332
|
-
const logStatusChange = (ctx: TicketStatusChangeContext) => {
|
|
333
|
-
console.log(ctx.shorthand, ctx.fromStatus, ctx.toStatus);
|
|
334
175
|
};
|
|
335
176
|
|
|
336
|
-
|
|
337
|
-
console.log(ctx.sessionId, ctx.sessionStatus);
|
|
338
|
-
};
|
|
177
|
+
export default extension;
|
|
339
178
|
```
|
|
340
179
|
|
|
341
180
|
## Package Development
|
package/dist/api/extensions.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export type { UpdateInstalledExtensionTemplateInput, UpdateInstalledExtensionTemplateResponse, } from "pstdio-api-contracts";
|
|
1
|
+
export type { CommandExecuteRequest, CommandExecuteResponse, ExtensionCommandRecord, ExtensionDataRendererRecord, ExtensionDiagnostic, ExtensionMenuContribution, ExtensionModeRecord, ExtensionNavigationRecord, ExtensionRecord, ExtensionRouteRecord, ExtensionSettingDefinitionRecord, ExtensionSettingsPanelRecord, ExtensionSettingValueRecord, ExtensionTreeItemContribution, ExtensionViewRecord, ListExtensionAppearanceResponse, ListExtensionCommandsResponse, ListExtensionSettingsResponse, ListProjectExtensionsResponse, ModeLayoutContributionRecord, ProjectExtensionInstance, UpdateExtensionSettingRequest, UpdateInstalledExtensionTemplateInput, UpdateInstalledExtensionTemplateResponse, WorkbenchExtensionDataRendererRecord, WorkbenchExtensionMetadata, } from "pstdio-api-contracts";
|
package/dist/api/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export type { ActionResult, ExecuteActionInput } from "./actions";
|
|
2
1
|
export type { SetupAgentInput, SetupAvailableAgentsInput, UpdateAgentInput } from "./agents";
|
|
3
|
-
export type { UpdateInstalledExtensionTemplateInput, UpdateInstalledExtensionTemplateResponse } from "./extensions";
|
|
2
|
+
export type { CommandExecuteRequest, CommandExecuteResponse, ExtensionCommandRecord, ExtensionDataRendererRecord, ExtensionDiagnostic, ExtensionMenuContribution, ExtensionModeRecord, ExtensionNavigationRecord, ExtensionRecord, ExtensionRouteRecord, ExtensionSettingDefinitionRecord, ExtensionSettingsPanelRecord, ExtensionSettingValueRecord, ExtensionTreeItemContribution, ExtensionViewRecord, ListExtensionAppearanceResponse, ListExtensionCommandsResponse, ListExtensionSettingsResponse, ListProjectExtensionsResponse, ProjectExtensionInstance, UpdateExtensionSettingRequest, UpdateInstalledExtensionTemplateInput, UpdateInstalledExtensionTemplateResponse, WorkbenchExtensionDataRendererRecord, WorkbenchExtensionMetadata, } from "./extensions";
|
|
4
3
|
export type { CreateProjectInput, RegisterRepoInput } from "./projects";
|
|
5
4
|
export type { ApprovalInput, CreateSessionInput, FollowUpInput, ResolveSessionIdInput, ResolveSessionIdResponse, SessionConversationResponse, } from "./sessions";
|
|
5
|
+
export type { Settings, UpdateSettingsInput } from "./settings";
|
|
6
6
|
export type { UpdateSkillInput } from "./skills";
|
|
7
7
|
export type { CreateAttemptStatusInput, CreateStatusInput } from "./statuses";
|
|
8
8
|
export type { CreateTagInput, CreateTagOptionInput, UpdateTagInput, UpdateTagOptionInput } from "./tags";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type { Settings, UpdateSettingsInput } from "pstdio-api-contracts";
|
package/dist/api/statuses.d.ts
CHANGED
package/dist/api/tags.d.ts
CHANGED
package/dist/api/tickets.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
/** @deprecated Legacy core ticket API. Ticket data is owned by the pstdio tickets extension. */
|
|
1
2
|
export type { CreateTicketAttemptInput, CreateTicketInput, ListProjectActivityForTicketsInput, ListTicketActivityInput, ListTicketActivityResponse, TicketAttemptMode, UpdateTicketInput, UpdateWhenAttemptStatusInput, UpdateWhenAttemptStatusResponse, UploadTicketFileInput, } from "pstdio-api-contracts";
|
|
2
3
|
import type { Ticket, Workspace } from "../resources";
|
|
4
|
+
/** @deprecated Legacy core ticket API. Ticket data is owned by the pstdio tickets extension. */
|
|
3
5
|
export type ListTicketsInput = {
|
|
4
6
|
status?: string;
|
|
5
7
|
tag?: string | string[];
|
|
@@ -9,6 +11,7 @@ export type ListTicketsInput = {
|
|
|
9
11
|
shorthand?: string;
|
|
10
12
|
search?: string;
|
|
11
13
|
};
|
|
14
|
+
/** @deprecated Legacy core ticket attempts. Ticket attempts are owned by the pstdio tickets extension. */
|
|
12
15
|
export type TicketAttemptResponse = {
|
|
13
16
|
mode: "worktree" | "current_branch";
|
|
14
17
|
ticket: Ticket;
|
package/dist/api/workspaces.d.ts
CHANGED
|
@@ -1 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
import type { CreateWorkspaceInput as ContractCreateWorkspaceInput, ListWorkspaceActivityInput as ContractListWorkspaceActivityInput, ListWorkspaceActivityResponse as ContractListWorkspaceActivityResponse, RemoveWorktreeResponse as ContractRemoveWorktreeResponse, UpdateAttemptStatusInput as ContractUpdateAttemptStatusInput, UpdateAttemptStatusResponse as ContractUpdateAttemptStatusResponse } from "pstdio-api-contracts";
|
|
2
|
+
/** @deprecated Requires legacy ticket-workspace linkage. Ticket ownership is moving to the pstdio tickets extension. */
|
|
3
|
+
export type CreateWorkspaceInput = ContractCreateWorkspaceInput;
|
|
4
|
+
export type ListWorkspaceActivityInput = ContractListWorkspaceActivityInput;
|
|
5
|
+
export type ListWorkspaceActivityResponse = ContractListWorkspaceActivityResponse;
|
|
6
|
+
export type RemoveWorktreeResponse = ContractRemoveWorktreeResponse;
|
|
7
|
+
/** @deprecated Legacy ticket attempt status mutation. Workspace status automation is extension-owned. */
|
|
8
|
+
export type UpdateAttemptStatusInput = ContractUpdateAttemptStatusInput;
|
|
9
|
+
/** @deprecated Legacy ticket attempt status mutation. Workspace status automation is extension-owned. */
|
|
10
|
+
export type UpdateAttemptStatusResponse = ContractUpdateAttemptStatusResponse;
|
package/dist/client/client.d.ts
CHANGED
|
@@ -1,26 +1,31 @@
|
|
|
1
|
-
import { type ActionClient } from "./actions";
|
|
2
1
|
import { type AgentClient } from "./agents";
|
|
3
2
|
import { type ExtensionClient } from "./extensions";
|
|
4
3
|
import { type ProjectClient } from "./projects";
|
|
5
4
|
import type { ClientOptions } from "./request";
|
|
6
5
|
import { type SessionClient } from "./sessions";
|
|
6
|
+
import { type SettingsClient } from "./settings";
|
|
7
7
|
import { type SkillClient } from "./skills";
|
|
8
8
|
import { type StatusClient } from "./statuses";
|
|
9
|
+
import { type SyncClient } from "./sync";
|
|
9
10
|
import { type TagClient } from "./tags";
|
|
10
11
|
import { type TemplateClient } from "./templates";
|
|
11
12
|
import { type TicketClient } from "./tickets";
|
|
12
13
|
import { type WorkspaceClient } from "./workspaces";
|
|
13
14
|
export type PstdioClient = {
|
|
14
15
|
projects: ProjectClient;
|
|
16
|
+
/** @deprecated Legacy core ticket client. Ticket data is owned by the pstdio tickets extension. */
|
|
15
17
|
tickets: TicketClient;
|
|
16
18
|
workspaces: WorkspaceClient;
|
|
17
19
|
sessions: SessionClient;
|
|
20
|
+
/** @deprecated Legacy core ticket status client. Ticket statuses are owned by the pstdio tickets extension. */
|
|
18
21
|
statuses: StatusClient;
|
|
22
|
+
/** @deprecated Legacy core ticket tag client. Ticket tags are owned by the pstdio tickets extension. */
|
|
19
23
|
tags: TagClient;
|
|
20
24
|
templates: TemplateClient;
|
|
21
25
|
skills: SkillClient;
|
|
22
26
|
agents: AgentClient;
|
|
23
|
-
actions: ActionClient;
|
|
24
27
|
extensions: ExtensionClient;
|
|
28
|
+
settings: SettingsClient;
|
|
29
|
+
sync: SyncClient;
|
|
25
30
|
};
|
|
26
31
|
export declare const createClient: (options?: ClientOptions) => PstdioClient;
|
package/dist/client/index.d.ts
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
export type { ActionClient } from "./actions";
|
|
2
1
|
export type { AgentClient } from "./agents";
|
|
3
2
|
export { createClient, type PstdioClient } from "./client";
|
|
4
3
|
export type { ExtensionClient } from "./extensions";
|
|
5
4
|
export type { ProjectClient } from "./projects";
|
|
6
|
-
export { type ClientOptions, createRequest, PstdioApiError, type RequestFn } from "./request";
|
|
7
|
-
export type { SessionClient } from "./sessions";
|
|
5
|
+
export { type ClientOptions, createRequest, PstdioApiError, type RequestFn, type RequestOptions, } from "./request";
|
|
6
|
+
export type { ListSessionsInput, SessionClient, SessionStreamConnection, SessionStreamHandlers } from "./sessions";
|
|
7
|
+
export type { SettingsClient } from "./settings";
|
|
8
8
|
export type { SkillClient } from "./skills";
|
|
9
|
+
export type { SseEvent } from "./sse";
|
|
9
10
|
export type { StatusClient } from "./statuses";
|
|
11
|
+
export { applySyncEvent, parseSyncDeleteEvent, type StartSyncInput, type SyncClient, type SyncConnection, type SyncRow, type SyncWriter, type SyncWriterProvider, } from "./sync";
|
|
10
12
|
export type { TagClient } from "./tags";
|
|
11
13
|
export type { TemplateClient } from "./templates";
|
|
12
14
|
export type { TicketClient } from "./tickets";
|