terse-sdk 0.3.8 → 0.4.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.
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/inputRequest.d.ts.map +1 -1
- package/dist/inputRequest.js +1 -1
- package/dist/inputRequest.js.map +1 -1
- package/dist/runIdentity/workflowSource.js +2 -2
- package/dist/runIdentity/workflowSource.js.map +1 -1
- package/package.json +4 -4
- package/dist/__state_typetest.d.ts +0 -2
- package/dist/__state_typetest.d.ts.map +0 -1
- package/dist/__state_typetest.js +0 -32
- package/dist/__state_typetest.js.map +0 -1
- package/dist/memoryfs/file.d.ts +0 -16
- package/dist/memoryfs/file.d.ts.map +0 -1
- package/dist/memoryfs/file.js +0 -40
- package/dist/memoryfs/file.js.map +0 -1
- package/dist/memoryfs/index.d.ts +0 -25
- package/dist/memoryfs/index.d.ts.map +0 -1
- package/dist/memoryfs/index.js +0 -60
- package/dist/memoryfs/index.js.map +0 -1
- package/dist/memoryfs/memory.d.ts +0 -21
- package/dist/memoryfs/memory.d.ts.map +0 -1
- package/dist/memoryfs/memory.js +0 -196
- package/dist/memoryfs/memory.js.map +0 -1
- package/dist/memoryfs/paths.d.ts +0 -7
- package/dist/memoryfs/paths.d.ts.map +0 -1
- package/dist/memoryfs/paths.js +0 -39
- package/dist/memoryfs/paths.js.map +0 -1
- package/dist/memoryfs/store.d.ts +0 -18
- package/dist/memoryfs/store.d.ts.map +0 -1
- package/dist/memoryfs/store.js +0 -89
- package/dist/memoryfs/store.js.map +0 -1
- package/dist/perf.d.ts +0 -9
- package/dist/perf.d.ts.map +0 -1
- package/dist/perf.js +0 -57
- package/dist/perf.js.map +0 -1
- package/dist/shared/ApiRoutes.d.ts +0 -348
- package/dist/shared/ApiRoutes.d.ts.map +0 -1
- package/dist/shared/ApiRoutes.js +0 -325
- package/dist/shared/ApiRoutes.js.map +0 -1
- package/dist/shared/Configs.d.ts +0 -488
- package/dist/shared/Configs.d.ts.map +0 -1
- package/dist/shared/Configs.js +0 -785
- package/dist/shared/Configs.js.map +0 -1
- package/dist/shared/Entities.d.ts +0 -8
- package/dist/shared/Entities.d.ts.map +0 -1
- package/dist/shared/Entities.js +0 -9
- package/dist/shared/Entities.js.map +0 -1
- package/dist/shared/Integrations.d.ts +0 -235
- package/dist/shared/Integrations.d.ts.map +0 -1
- package/dist/shared/Integrations.js +0 -143
- package/dist/shared/Integrations.js.map +0 -1
- package/dist/shared/ModelEvents.d.ts +0 -176
- package/dist/shared/ModelEvents.d.ts.map +0 -1
- package/dist/shared/ModelEvents.js +0 -29
- package/dist/shared/ModelEvents.js.map +0 -1
- package/dist/shared/RunHistoryTypes.d.ts +0 -95
- package/dist/shared/RunHistoryTypes.d.ts.map +0 -1
- package/dist/shared/RunHistoryTypes.js +0 -11
- package/dist/shared/RunHistoryTypes.js.map +0 -1
- package/dist/shared/Survey.d.ts +0 -10
- package/dist/shared/Survey.d.ts.map +0 -1
- package/dist/shared/Survey.js +0 -2
- package/dist/shared/Survey.js.map +0 -1
- package/dist/shared/TicketSystem.d.ts +0 -154
- package/dist/shared/TicketSystem.d.ts.map +0 -1
- package/dist/shared/TicketSystem.js +0 -21
- package/dist/shared/TicketSystem.js.map +0 -1
- package/dist/shared/types.d.ts +0 -1732
- package/dist/shared/types.d.ts.map +0 -1
- package/dist/shared/types.js +0 -17
- package/dist/shared/types.js.map +0 -1
|
@@ -1,348 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* API route path constants
|
|
3
|
-
*
|
|
4
|
-
* These constants standardize API route paths across frontend and backend,
|
|
5
|
-
* preventing magic strings and making refactoring easier.
|
|
6
|
-
*
|
|
7
|
-
* Dynamic routes use route objects with both Express patterns and URL builders
|
|
8
|
-
* to ensure frontend and backend stay in sync.
|
|
9
|
-
*/
|
|
10
|
-
export declare const ApiRoutes: {
|
|
11
|
-
readonly AUTH: {
|
|
12
|
-
readonly ME: "/me";
|
|
13
|
-
readonly LOGIN: "/login";
|
|
14
|
-
readonly LOGIN_URL: "/login/url";
|
|
15
|
-
readonly LOGOUT: "/logout";
|
|
16
|
-
readonly LOGOUT_URL: "/logout/url";
|
|
17
|
-
readonly GITHUB_APP_CALLBACK: "/auth/github-app/callback";
|
|
18
|
-
readonly WORKOS_CALLBACK: "/auth/workos/callback";
|
|
19
|
-
};
|
|
20
|
-
readonly WORKOS: {
|
|
21
|
-
readonly WIDGET_TOKEN: "/auth/workos/widget-token";
|
|
22
|
-
};
|
|
23
|
-
readonly ORGANIZATIONS: {
|
|
24
|
-
readonly CREATE: "/organizations";
|
|
25
|
-
readonly GET_CURRENT: "/organizations/current";
|
|
26
|
-
readonly LIST: "/organizations";
|
|
27
|
-
readonly SWITCH: "/organizations/switch";
|
|
28
|
-
readonly UPDATE: "/organizations";
|
|
29
|
-
readonly LOGO_UPLOAD_URL: "/organizations/logo/upload-url";
|
|
30
|
-
readonly LOGO: {
|
|
31
|
-
readonly pattern: "/organizations/:organizationId/logo";
|
|
32
|
-
readonly build: (organizationId: string) => string;
|
|
33
|
-
readonly params: {
|
|
34
|
-
readonly organizationId: "string";
|
|
35
|
-
};
|
|
36
|
-
};
|
|
37
|
-
};
|
|
38
|
-
readonly STATS: "/stats";
|
|
39
|
-
readonly RUN_HISTORY: {
|
|
40
|
-
readonly ALL: "/run-history";
|
|
41
|
-
readonly ACTIONS: "/run-history/actions";
|
|
42
|
-
readonly BY_AGENT_ID: {
|
|
43
|
-
readonly pattern: "/run-history/:agentId";
|
|
44
|
-
readonly build: (agentId: string) => string;
|
|
45
|
-
readonly params: {
|
|
46
|
-
readonly agentId: "string";
|
|
47
|
-
};
|
|
48
|
-
};
|
|
49
|
-
readonly CHAT_BY_RUN_ID: {
|
|
50
|
-
readonly pattern: "/run-history/:runId/chat";
|
|
51
|
-
readonly build: (runId: string) => string;
|
|
52
|
-
readonly params: {
|
|
53
|
-
readonly runId: "string";
|
|
54
|
-
};
|
|
55
|
-
};
|
|
56
|
-
};
|
|
57
|
-
readonly SESSION: {
|
|
58
|
-
readonly TOKEN: "/session/token";
|
|
59
|
-
};
|
|
60
|
-
readonly GITHUB: {
|
|
61
|
-
readonly INTEGRATIONS: "/github/integrations";
|
|
62
|
-
readonly INSTALLATION_URL: "/github/installation-url";
|
|
63
|
-
readonly GET_REPOSITORIES_FOR_INTEGRATION: "/github/get-repositories-for-integration";
|
|
64
|
-
readonly INSTALLATION_CALLBACK: "/github/installation-callback";
|
|
65
|
-
readonly INSTALLATION_DELETED: "/github/installation-deleted";
|
|
66
|
-
readonly UNIFIED_EVENT: "/github/unified-event";
|
|
67
|
-
};
|
|
68
|
-
readonly ATLASSIAN: {
|
|
69
|
-
readonly INTEGRATIONS: "/atlassian/integrations";
|
|
70
|
-
readonly OAUTH_CALLBACK: "/atlassian/oauth/callback";
|
|
71
|
-
};
|
|
72
|
-
readonly JIRA: {
|
|
73
|
-
readonly RESOURCES: "/jira/resources";
|
|
74
|
-
readonly GET_API_KEY: "/jira/get-api-key";
|
|
75
|
-
readonly SET_API_KEY: "/jira/set-api-key";
|
|
76
|
-
readonly VALIDATE_AND_FETCH_PROJECTS: "/jira/validate-and-fetch-projects";
|
|
77
|
-
readonly DELETE_CREDENTIALS: "/jira/delete-credentials";
|
|
78
|
-
};
|
|
79
|
-
readonly CONFLUENCE: {
|
|
80
|
-
readonly INTEGRATIONS: "/confluence/integrations";
|
|
81
|
-
readonly RESOURCES: "/confluence/resources";
|
|
82
|
-
};
|
|
83
|
-
readonly GMAIL: {
|
|
84
|
-
readonly INTEGRATIONS: "/gmail/integrations";
|
|
85
|
-
readonly CALLBACK: "/gmail/callback";
|
|
86
|
-
readonly DELETE_INTEGRATION: "/gmail/delete-integration";
|
|
87
|
-
};
|
|
88
|
-
readonly NOTION: {
|
|
89
|
-
readonly INTEGRATIONS: "/notion/integrations";
|
|
90
|
-
readonly OAUTH_CALLBACK: "/notion/oauth/callback";
|
|
91
|
-
readonly RESOURCES: "/notion/resources";
|
|
92
|
-
readonly DELETE_INTEGRATION: "/notion/delete-integration";
|
|
93
|
-
};
|
|
94
|
-
readonly FIGMA: {
|
|
95
|
-
readonly INTEGRATIONS: "/figma/integrations";
|
|
96
|
-
readonly OAUTH_CALLBACK: "/figma/oauth/callback";
|
|
97
|
-
};
|
|
98
|
-
readonly LINEAR: {
|
|
99
|
-
readonly OAUTH_CALLBACK: "/linear/oauth/callback";
|
|
100
|
-
readonly WEBHOOK: "/linear/webhook";
|
|
101
|
-
readonly INTEGRATIONS: "/linear/integrations";
|
|
102
|
-
readonly TEAMS: "/linear/teams";
|
|
103
|
-
};
|
|
104
|
-
readonly SLACK: {
|
|
105
|
-
readonly INTEGRATIONS: "/slack/integrations";
|
|
106
|
-
readonly GET_CURRENT_INTEGRATION: "/slack/get-current-integration";
|
|
107
|
-
readonly OAUTH_CALLBACK: "/slack/oauth-callback";
|
|
108
|
-
readonly CHANNELS: "/slack/channels";
|
|
109
|
-
readonly USERS: "/slack/users";
|
|
110
|
-
readonly EVENTS: "/slack/events";
|
|
111
|
-
};
|
|
112
|
-
readonly POSTHOG: {
|
|
113
|
-
readonly INTEGRATIONS: "/posthog/integrations";
|
|
114
|
-
readonly PROJECTS: "/posthog/projects";
|
|
115
|
-
};
|
|
116
|
-
readonly LAUNCHDARKLY: {
|
|
117
|
-
readonly INTEGRATIONS: "/launchdarkly/integrations";
|
|
118
|
-
readonly PROJECTS_BY_INTEGRATION_ID: {
|
|
119
|
-
readonly pattern: "/launchdarkly/integrations/:integrationId/projects";
|
|
120
|
-
readonly build: (integrationId: string) => string;
|
|
121
|
-
readonly params: {
|
|
122
|
-
readonly integrationId: "string";
|
|
123
|
-
};
|
|
124
|
-
};
|
|
125
|
-
readonly ENVIRONMENTS_BY_INTEGRATION_AND_PROJECT: {
|
|
126
|
-
readonly pattern: "/launchdarkly/integrations/:integrationId/projects/:projectKey/environments";
|
|
127
|
-
readonly build: (integrationId: string, projectKey: string) => string;
|
|
128
|
-
readonly params: {
|
|
129
|
-
readonly integrationId: "string";
|
|
130
|
-
readonly projectKey: "string";
|
|
131
|
-
};
|
|
132
|
-
};
|
|
133
|
-
};
|
|
134
|
-
readonly DATADOG: {
|
|
135
|
-
readonly INTEGRATIONS: "/datadog/integrations";
|
|
136
|
-
readonly INDEXES: "/datadog/indexes";
|
|
137
|
-
};
|
|
138
|
-
readonly WORKOS_INTEGRATION: {
|
|
139
|
-
readonly INTEGRATIONS: "/workos-integration/integrations";
|
|
140
|
-
readonly WEBHOOK_SECRET: "/workos-integration/webhook-secret";
|
|
141
|
-
};
|
|
142
|
-
readonly SNOWFLAKE: {
|
|
143
|
-
readonly INTEGRATIONS: "/snowflake/integrations";
|
|
144
|
-
};
|
|
145
|
-
readonly ATTIO: {
|
|
146
|
-
readonly INTEGRATIONS: "/attio/integrations";
|
|
147
|
-
readonly OAUTH_CALLBACK: "/attio/oauth/callback";
|
|
148
|
-
readonly OBJECTS: {
|
|
149
|
-
readonly pattern: "/attio/integrations/:integrationId/objects";
|
|
150
|
-
readonly build: (integrationId: string) => string;
|
|
151
|
-
readonly params: {
|
|
152
|
-
readonly integrationId: "string";
|
|
153
|
-
};
|
|
154
|
-
};
|
|
155
|
-
};
|
|
156
|
-
readonly AGENTS: {
|
|
157
|
-
readonly LIST: "/agents";
|
|
158
|
-
readonly RECENT: "/agents/recent";
|
|
159
|
-
readonly BY_ID: {
|
|
160
|
-
readonly pattern: "/agents/:id";
|
|
161
|
-
readonly build: (id: string) => string;
|
|
162
|
-
readonly params: {
|
|
163
|
-
readonly id: "string";
|
|
164
|
-
};
|
|
165
|
-
};
|
|
166
|
-
};
|
|
167
|
-
readonly IMPROVEMENTS: {
|
|
168
|
-
readonly BY_AGENT_ID: {
|
|
169
|
-
readonly pattern: "/agents/:agentId/improvements";
|
|
170
|
-
readonly build: (agentId: string) => string;
|
|
171
|
-
readonly params: {
|
|
172
|
-
readonly agentId: "string";
|
|
173
|
-
};
|
|
174
|
-
};
|
|
175
|
-
readonly APPLY: {
|
|
176
|
-
readonly pattern: "/agents/:agentId/improvements/:id/apply";
|
|
177
|
-
readonly build: (agentId: string, id: string) => string;
|
|
178
|
-
readonly params: {
|
|
179
|
-
readonly agentId: "string";
|
|
180
|
-
readonly id: "string";
|
|
181
|
-
};
|
|
182
|
-
};
|
|
183
|
-
readonly DISMISS: {
|
|
184
|
-
readonly pattern: "/agents/:agentId/improvements/:id/dismiss";
|
|
185
|
-
readonly build: (agentId: string, id: string) => string;
|
|
186
|
-
readonly params: {
|
|
187
|
-
readonly agentId: "string";
|
|
188
|
-
readonly id: "string";
|
|
189
|
-
};
|
|
190
|
-
};
|
|
191
|
-
readonly UNDO_DISMISS: {
|
|
192
|
-
readonly pattern: "/agents/:agentId/improvements/:id/undo-dismiss";
|
|
193
|
-
readonly build: (agentId: string, id: string) => string;
|
|
194
|
-
readonly params: {
|
|
195
|
-
readonly agentId: "string";
|
|
196
|
-
readonly id: "string";
|
|
197
|
-
};
|
|
198
|
-
};
|
|
199
|
-
readonly TOGGLE_ENABLED: {
|
|
200
|
-
readonly pattern: "/agents/:agentId/improvements-enabled";
|
|
201
|
-
readonly build: (agentId: string) => string;
|
|
202
|
-
readonly params: {
|
|
203
|
-
readonly agentId: "string";
|
|
204
|
-
};
|
|
205
|
-
};
|
|
206
|
-
};
|
|
207
|
-
readonly TEMPLATES: "/templates";
|
|
208
|
-
readonly PUBLIC: {
|
|
209
|
-
readonly TEMPLATES: "/public/templates";
|
|
210
|
-
};
|
|
211
|
-
readonly TOOLS: {
|
|
212
|
-
readonly THAT_REQUIRE_APPROVALS: "/tools/that-require-approvals";
|
|
213
|
-
};
|
|
214
|
-
readonly INTEGRATIONS: {
|
|
215
|
-
readonly INSTALLATION_DETAILS_BY_TYPE: {
|
|
216
|
-
readonly pattern: "/integrations/:integrationType/installation-details";
|
|
217
|
-
readonly build: (integrationType: string) => string;
|
|
218
|
-
readonly params: {
|
|
219
|
-
readonly integrationType: "string";
|
|
220
|
-
};
|
|
221
|
-
};
|
|
222
|
-
readonly LIST: "/integrations";
|
|
223
|
-
readonly ACTIVE: "/integrations/active";
|
|
224
|
-
};
|
|
225
|
-
readonly NOTIFICATION_DESTINATIONS: {
|
|
226
|
-
readonly LIST: "/notification-destinations";
|
|
227
|
-
readonly BY_ID: {
|
|
228
|
-
readonly pattern: "/notification-destinations/:id";
|
|
229
|
-
readonly build: (id: string) => string;
|
|
230
|
-
readonly params: {
|
|
231
|
-
readonly id: "string";
|
|
232
|
-
};
|
|
233
|
-
};
|
|
234
|
-
};
|
|
235
|
-
readonly API_TOKENS: {
|
|
236
|
-
readonly LIST: "/api-tokens";
|
|
237
|
-
readonly BY_ID: {
|
|
238
|
-
readonly pattern: "/api-tokens/:id";
|
|
239
|
-
readonly build: (id: string) => string;
|
|
240
|
-
readonly params: {
|
|
241
|
-
readonly id: "string";
|
|
242
|
-
};
|
|
243
|
-
};
|
|
244
|
-
};
|
|
245
|
-
readonly SDK: {
|
|
246
|
-
readonly ME: "/sdk/me";
|
|
247
|
-
readonly SAMPLE_EVENTS: "/sdk/sample-events";
|
|
248
|
-
readonly TOOL_EXECUTE: "/sdk/tool-execute";
|
|
249
|
-
readonly TOOL_DEFINITIONS: "/sdk/tool-definitions";
|
|
250
|
-
readonly AGENT_RUN: "/sdk/agent-run";
|
|
251
|
-
readonly APPROVAL_DECISION: "/sdk/approval-decision";
|
|
252
|
-
readonly SESSION_EVENTS: "/sdk/session-events";
|
|
253
|
-
readonly DEPLOY: "/sdk/deploy";
|
|
254
|
-
readonly DEVICE_TOKEN_EXCHANGE: "/sdk/auth/device-token-exchange";
|
|
255
|
-
readonly INTEGRATION_FIELDS: {
|
|
256
|
-
readonly pattern: "/sdk/integrations/:integrationType/fields";
|
|
257
|
-
readonly build: (integrationType: string) => string;
|
|
258
|
-
readonly params: {
|
|
259
|
-
readonly integrationType: "string";
|
|
260
|
-
};
|
|
261
|
-
};
|
|
262
|
-
readonly INTEGRATION_FORM_SUBMIT: {
|
|
263
|
-
readonly pattern: "/sdk/integrations/:integrationType/form-submit";
|
|
264
|
-
readonly build: (integrationType: string) => string;
|
|
265
|
-
readonly params: {
|
|
266
|
-
readonly integrationType: "string";
|
|
267
|
-
};
|
|
268
|
-
};
|
|
269
|
-
};
|
|
270
|
-
readonly NOTIFICATION_SETTINGS: "/notification-settings";
|
|
271
|
-
readonly SENT_NOTIFICATIONS: {
|
|
272
|
-
readonly LIST: "/sent-notifications";
|
|
273
|
-
};
|
|
274
|
-
readonly PENDING_APPROVALS: {
|
|
275
|
-
readonly LIST: "/pending-approvals";
|
|
276
|
-
};
|
|
277
|
-
readonly WEBHOOKS: {
|
|
278
|
-
readonly GMAIL: "/webhooks/gmail";
|
|
279
|
-
readonly FIGMA: "/webhooks/figma";
|
|
280
|
-
readonly WORKOS: "/webhooks/workos";
|
|
281
|
-
readonly JIRA_BY_ACCOUNT_ID: {
|
|
282
|
-
readonly pattern: "/webhooks/jira/:accountId";
|
|
283
|
-
readonly build: (accountId: string) => string;
|
|
284
|
-
readonly params: {
|
|
285
|
-
readonly accountId: "string";
|
|
286
|
-
};
|
|
287
|
-
};
|
|
288
|
-
readonly LINEAR_BY_USER_ID: {
|
|
289
|
-
readonly pattern: "/webhooks/linear/:userId";
|
|
290
|
-
readonly build: (userId: string) => string;
|
|
291
|
-
readonly params: {
|
|
292
|
-
readonly userId: "string";
|
|
293
|
-
};
|
|
294
|
-
};
|
|
295
|
-
readonly SCHEDULE_BY_INPUT_ID: {
|
|
296
|
-
readonly pattern: "/webhooks/schedule/:inputId";
|
|
297
|
-
readonly build: (inputId: string) => string;
|
|
298
|
-
readonly params: {
|
|
299
|
-
readonly inputId: "string";
|
|
300
|
-
};
|
|
301
|
-
};
|
|
302
|
-
readonly WORKOS_TRIGGER_BY_INTEGRATION_ID: {
|
|
303
|
-
readonly pattern: "/webhooks/workos-trigger/:integrationId";
|
|
304
|
-
readonly build: (integrationId: string) => string;
|
|
305
|
-
readonly params: {
|
|
306
|
-
readonly integrationId: "string";
|
|
307
|
-
};
|
|
308
|
-
};
|
|
309
|
-
};
|
|
310
|
-
readonly SCHEDULE: {
|
|
311
|
-
readonly TRIGGER_BY_INPUT_ID: {
|
|
312
|
-
readonly pattern: "/schedule/trigger/:inputId";
|
|
313
|
-
readonly build: (inputId: string) => string;
|
|
314
|
-
readonly params: {
|
|
315
|
-
readonly inputId: "string";
|
|
316
|
-
};
|
|
317
|
-
};
|
|
318
|
-
readonly TRIGGER_WITH_EVENT: {
|
|
319
|
-
readonly pattern: "/schedule/trigger-with-event/:automationId";
|
|
320
|
-
readonly build: (automationId: string) => string;
|
|
321
|
-
readonly params: {
|
|
322
|
-
readonly automationId: "string";
|
|
323
|
-
};
|
|
324
|
-
};
|
|
325
|
-
};
|
|
326
|
-
readonly REFRESH_TOKENS: "/refresh-tokens";
|
|
327
|
-
readonly REVIEW_AGENTS: "/review-agents";
|
|
328
|
-
readonly USERS: {
|
|
329
|
-
readonly CREATE: "/users";
|
|
330
|
-
readonly BY_ID: {
|
|
331
|
-
readonly pattern: "/users/:id";
|
|
332
|
-
readonly build: (id: string) => string;
|
|
333
|
-
readonly params: {
|
|
334
|
-
readonly id: "string";
|
|
335
|
-
};
|
|
336
|
-
};
|
|
337
|
-
};
|
|
338
|
-
readonly BUILDER_CHAT: {
|
|
339
|
-
readonly HISTORY_BY_SESSION_ID: {
|
|
340
|
-
readonly pattern: "/builder-chat/:sessionId/history";
|
|
341
|
-
readonly build: (sessionId: string) => string;
|
|
342
|
-
readonly params: {
|
|
343
|
-
readonly sessionId: "string";
|
|
344
|
-
};
|
|
345
|
-
};
|
|
346
|
-
};
|
|
347
|
-
};
|
|
348
|
-
//# sourceMappingURL=ApiRoutes.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ApiRoutes.d.ts","sourceRoot":"","sources":["../../src/shared/ApiRoutes.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;6CAyBc,MAAM;;;;;;;;;;;;sCAcb,MAAM;;;;;;;oCAKR,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4CA0FE,MAAM;;;;;;;4CAKN,MAAM,cAAc,MAAM;;;;;;;;;;;;;;;;;;;;;;;4CA4B1B,MAAM;;;;;;;;;;;iCAWjB,MAAM;;;;;;;;;sCAQD,MAAM;;;;;;;sCAKN,MAAM,MAAM,MAAM;;;;;;;;sCAKlB,MAAM,MAAM,MAAM;;;;;;;;sCAKlB,MAAM,MAAM,MAAM;;;;;;;;sCAKlB,MAAM;;;;;;;;;;;;;;;;8CAoBE,MAAM;;;;;;;;;;;;iCAYnB,MAAM;;;;;;;;;;iCAUN,MAAM;;;;;;;;;;;;;;;;;;8CAkBO,MAAM;;;;;;;8CAKN,MAAM;;;;;;;;;;;;;;;;;;;wCAsBZ,MAAM;;;;;;;qCAKT,MAAM;;;;;;;sCAKL,MAAM;;;;;;;4CAKA,MAAM;;;;;;;;;sCASZ,MAAM;;;;;;;2CAKD,MAAM;;;;;;;;;;;;iCAchB,MAAM;;;;;;;;;wCASC,MAAM;;;;;;CAI3B,CAAA"}
|
package/dist/shared/ApiRoutes.js
DELETED
|
@@ -1,325 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* API route path constants
|
|
3
|
-
*
|
|
4
|
-
* These constants standardize API route paths across frontend and backend,
|
|
5
|
-
* preventing magic strings and making refactoring easier.
|
|
6
|
-
*
|
|
7
|
-
* Dynamic routes use route objects with both Express patterns and URL builders
|
|
8
|
-
* to ensure frontend and backend stay in sync.
|
|
9
|
-
*/
|
|
10
|
-
// Type definitions for route objects
|
|
11
|
-
export const ApiRoutes = {
|
|
12
|
-
// Authentication routes
|
|
13
|
-
AUTH: {
|
|
14
|
-
ME: "/me",
|
|
15
|
-
LOGIN: "/login",
|
|
16
|
-
LOGIN_URL: "/login/url",
|
|
17
|
-
LOGOUT: "/logout",
|
|
18
|
-
LOGOUT_URL: "/logout/url",
|
|
19
|
-
GITHUB_APP_CALLBACK: "/auth/github-app/callback",
|
|
20
|
-
WORKOS_CALLBACK: "/auth/workos/callback"
|
|
21
|
-
},
|
|
22
|
-
WORKOS: {
|
|
23
|
-
WIDGET_TOKEN: "/auth/workos/widget-token"
|
|
24
|
-
},
|
|
25
|
-
ORGANIZATIONS: {
|
|
26
|
-
CREATE: "/organizations",
|
|
27
|
-
GET_CURRENT: "/organizations/current",
|
|
28
|
-
LIST: "/organizations",
|
|
29
|
-
SWITCH: "/organizations/switch",
|
|
30
|
-
UPDATE: "/organizations",
|
|
31
|
-
LOGO_UPLOAD_URL: "/organizations/logo/upload-url",
|
|
32
|
-
LOGO: {
|
|
33
|
-
pattern: "/organizations/:organizationId/logo",
|
|
34
|
-
build: (organizationId) => `/organizations/${encodeURIComponent(organizationId)}/logo`,
|
|
35
|
-
params: { organizationId: "string" }
|
|
36
|
-
}
|
|
37
|
-
},
|
|
38
|
-
// Stats routes
|
|
39
|
-
STATS: "/stats",
|
|
40
|
-
// Run history routes
|
|
41
|
-
RUN_HISTORY: {
|
|
42
|
-
ALL: "/run-history",
|
|
43
|
-
ACTIONS: "/run-history/actions",
|
|
44
|
-
BY_AGENT_ID: {
|
|
45
|
-
pattern: "/run-history/:agentId",
|
|
46
|
-
build: (agentId) => `/run-history/${encodeURIComponent(agentId)}`,
|
|
47
|
-
params: { agentId: "string" }
|
|
48
|
-
},
|
|
49
|
-
CHAT_BY_RUN_ID: {
|
|
50
|
-
pattern: "/run-history/:runId/chat",
|
|
51
|
-
build: (runId) => `/run-history/${encodeURIComponent(runId)}/chat`,
|
|
52
|
-
params: { runId: "string" }
|
|
53
|
-
}
|
|
54
|
-
},
|
|
55
|
-
// Session routes
|
|
56
|
-
SESSION: {
|
|
57
|
-
TOKEN: "/session/token"
|
|
58
|
-
},
|
|
59
|
-
// GitHub routes
|
|
60
|
-
GITHUB: {
|
|
61
|
-
INTEGRATIONS: "/github/integrations",
|
|
62
|
-
INSTALLATION_URL: "/github/installation-url",
|
|
63
|
-
GET_REPOSITORIES_FOR_INTEGRATION: "/github/get-repositories-for-integration",
|
|
64
|
-
INSTALLATION_CALLBACK: "/github/installation-callback",
|
|
65
|
-
INSTALLATION_DELETED: "/github/installation-deleted",
|
|
66
|
-
UNIFIED_EVENT: "/github/unified-event"
|
|
67
|
-
},
|
|
68
|
-
// Atlassian/Jira routes
|
|
69
|
-
ATLASSIAN: {
|
|
70
|
-
INTEGRATIONS: "/atlassian/integrations",
|
|
71
|
-
OAUTH_CALLBACK: "/atlassian/oauth/callback"
|
|
72
|
-
},
|
|
73
|
-
JIRA: {
|
|
74
|
-
RESOURCES: "/jira/resources",
|
|
75
|
-
GET_API_KEY: "/jira/get-api-key",
|
|
76
|
-
SET_API_KEY: "/jira/set-api-key",
|
|
77
|
-
VALIDATE_AND_FETCH_PROJECTS: "/jira/validate-and-fetch-projects",
|
|
78
|
-
DELETE_CREDENTIALS: "/jira/delete-credentials"
|
|
79
|
-
},
|
|
80
|
-
// Confluence routes
|
|
81
|
-
CONFLUENCE: {
|
|
82
|
-
INTEGRATIONS: "/confluence/integrations",
|
|
83
|
-
RESOURCES: "/confluence/resources"
|
|
84
|
-
},
|
|
85
|
-
// Gmail routes
|
|
86
|
-
GMAIL: {
|
|
87
|
-
INTEGRATIONS: "/gmail/integrations",
|
|
88
|
-
CALLBACK: "/gmail/callback",
|
|
89
|
-
DELETE_INTEGRATION: "/gmail/delete-integration"
|
|
90
|
-
},
|
|
91
|
-
// Notion routes
|
|
92
|
-
NOTION: {
|
|
93
|
-
INTEGRATIONS: "/notion/integrations",
|
|
94
|
-
OAUTH_CALLBACK: "/notion/oauth/callback",
|
|
95
|
-
RESOURCES: "/notion/resources",
|
|
96
|
-
DELETE_INTEGRATION: "/notion/delete-integration"
|
|
97
|
-
},
|
|
98
|
-
// Figma routes
|
|
99
|
-
FIGMA: {
|
|
100
|
-
INTEGRATIONS: "/figma/integrations",
|
|
101
|
-
OAUTH_CALLBACK: "/figma/oauth/callback"
|
|
102
|
-
},
|
|
103
|
-
// Linear routes
|
|
104
|
-
LINEAR: {
|
|
105
|
-
OAUTH_CALLBACK: "/linear/oauth/callback",
|
|
106
|
-
WEBHOOK: "/linear/webhook",
|
|
107
|
-
INTEGRATIONS: "/linear/integrations",
|
|
108
|
-
TEAMS: "/linear/teams"
|
|
109
|
-
},
|
|
110
|
-
// Slack routes
|
|
111
|
-
SLACK: {
|
|
112
|
-
INTEGRATIONS: "/slack/integrations",
|
|
113
|
-
GET_CURRENT_INTEGRATION: "/slack/get-current-integration",
|
|
114
|
-
OAUTH_CALLBACK: "/slack/oauth-callback",
|
|
115
|
-
CHANNELS: "/slack/channels",
|
|
116
|
-
USERS: "/slack/users",
|
|
117
|
-
EVENTS: "/slack/events"
|
|
118
|
-
},
|
|
119
|
-
// Posthog routes
|
|
120
|
-
POSTHOG: {
|
|
121
|
-
INTEGRATIONS: "/posthog/integrations",
|
|
122
|
-
PROJECTS: "/posthog/projects"
|
|
123
|
-
},
|
|
124
|
-
// LaunchDarkly routes
|
|
125
|
-
LAUNCHDARKLY: {
|
|
126
|
-
INTEGRATIONS: "/launchdarkly/integrations",
|
|
127
|
-
PROJECTS_BY_INTEGRATION_ID: {
|
|
128
|
-
pattern: "/launchdarkly/integrations/:integrationId/projects",
|
|
129
|
-
build: (integrationId) => `/launchdarkly/integrations/${encodeURIComponent(integrationId)}/projects`,
|
|
130
|
-
params: { integrationId: "string" }
|
|
131
|
-
},
|
|
132
|
-
ENVIRONMENTS_BY_INTEGRATION_AND_PROJECT: {
|
|
133
|
-
pattern: "/launchdarkly/integrations/:integrationId/projects/:projectKey/environments",
|
|
134
|
-
build: (integrationId, projectKey) => `/launchdarkly/integrations/${encodeURIComponent(integrationId)}/projects/${encodeURIComponent(projectKey)}/environments`,
|
|
135
|
-
params: { integrationId: "string", projectKey: "string" }
|
|
136
|
-
}
|
|
137
|
-
},
|
|
138
|
-
// Datadog routes
|
|
139
|
-
DATADOG: {
|
|
140
|
-
INTEGRATIONS: "/datadog/integrations",
|
|
141
|
-
INDEXES: "/datadog/indexes"
|
|
142
|
-
},
|
|
143
|
-
// WorkOS Integration routes (customer's own WorkOS account)
|
|
144
|
-
WORKOS_INTEGRATION: {
|
|
145
|
-
INTEGRATIONS: "/workos-integration/integrations",
|
|
146
|
-
WEBHOOK_SECRET: "/workos-integration/webhook-secret"
|
|
147
|
-
},
|
|
148
|
-
// Snowflake routes
|
|
149
|
-
SNOWFLAKE: {
|
|
150
|
-
INTEGRATIONS: "/snowflake/integrations"
|
|
151
|
-
},
|
|
152
|
-
// Attio routes
|
|
153
|
-
ATTIO: {
|
|
154
|
-
INTEGRATIONS: "/attio/integrations",
|
|
155
|
-
OAUTH_CALLBACK: "/attio/oauth/callback",
|
|
156
|
-
OBJECTS: {
|
|
157
|
-
pattern: "/attio/integrations/:integrationId/objects",
|
|
158
|
-
build: (integrationId) => `/attio/integrations/${encodeURIComponent(integrationId)}/objects`,
|
|
159
|
-
params: { integrationId: "string" }
|
|
160
|
-
}
|
|
161
|
-
},
|
|
162
|
-
// Agents routes
|
|
163
|
-
AGENTS: {
|
|
164
|
-
LIST: "/agents",
|
|
165
|
-
RECENT: "/agents/recent",
|
|
166
|
-
BY_ID: {
|
|
167
|
-
pattern: "/agents/:id",
|
|
168
|
-
build: (id) => `/agents/${encodeURIComponent(id)}`,
|
|
169
|
-
params: { id: "string" }
|
|
170
|
-
}
|
|
171
|
-
},
|
|
172
|
-
IMPROVEMENTS: {
|
|
173
|
-
BY_AGENT_ID: {
|
|
174
|
-
pattern: "/agents/:agentId/improvements",
|
|
175
|
-
build: (agentId) => `/agents/${encodeURIComponent(agentId)}/improvements`,
|
|
176
|
-
params: { agentId: "string" }
|
|
177
|
-
},
|
|
178
|
-
APPLY: {
|
|
179
|
-
pattern: "/agents/:agentId/improvements/:id/apply",
|
|
180
|
-
build: (agentId, id) => `/agents/${encodeURIComponent(agentId)}/improvements/${encodeURIComponent(id)}/apply`,
|
|
181
|
-
params: { agentId: "string", id: "string" }
|
|
182
|
-
},
|
|
183
|
-
DISMISS: {
|
|
184
|
-
pattern: "/agents/:agentId/improvements/:id/dismiss",
|
|
185
|
-
build: (agentId, id) => `/agents/${encodeURIComponent(agentId)}/improvements/${encodeURIComponent(id)}/dismiss`,
|
|
186
|
-
params: { agentId: "string", id: "string" }
|
|
187
|
-
},
|
|
188
|
-
UNDO_DISMISS: {
|
|
189
|
-
pattern: "/agents/:agentId/improvements/:id/undo-dismiss",
|
|
190
|
-
build: (agentId, id) => `/agents/${encodeURIComponent(agentId)}/improvements/${encodeURIComponent(id)}/undo-dismiss`,
|
|
191
|
-
params: { agentId: "string", id: "string" }
|
|
192
|
-
},
|
|
193
|
-
TOGGLE_ENABLED: {
|
|
194
|
-
pattern: "/agents/:agentId/improvements-enabled",
|
|
195
|
-
build: (agentId) => `/agents/${encodeURIComponent(agentId)}/improvements-enabled`,
|
|
196
|
-
params: { agentId: "string" }
|
|
197
|
-
}
|
|
198
|
-
},
|
|
199
|
-
// Templates routes
|
|
200
|
-
TEMPLATES: "/templates",
|
|
201
|
-
PUBLIC: {
|
|
202
|
-
TEMPLATES: "/public/templates"
|
|
203
|
-
},
|
|
204
|
-
// Tools routes
|
|
205
|
-
TOOLS: {
|
|
206
|
-
THAT_REQUIRE_APPROVALS: "/tools/that-require-approvals"
|
|
207
|
-
},
|
|
208
|
-
// Integrations routes
|
|
209
|
-
INTEGRATIONS: {
|
|
210
|
-
INSTALLATION_DETAILS_BY_TYPE: {
|
|
211
|
-
pattern: "/integrations/:integrationType/installation-details",
|
|
212
|
-
build: (integrationType) => `/integrations/${encodeURIComponent(integrationType)}/installation-details`,
|
|
213
|
-
params: { integrationType: "string" }
|
|
214
|
-
},
|
|
215
|
-
LIST: "/integrations",
|
|
216
|
-
ACTIVE: "/integrations/active"
|
|
217
|
-
},
|
|
218
|
-
// Notification destinations routes
|
|
219
|
-
NOTIFICATION_DESTINATIONS: {
|
|
220
|
-
LIST: "/notification-destinations",
|
|
221
|
-
BY_ID: {
|
|
222
|
-
pattern: "/notification-destinations/:id",
|
|
223
|
-
build: (id) => `/notification-destinations/${encodeURIComponent(id)}`,
|
|
224
|
-
params: { id: "string" }
|
|
225
|
-
}
|
|
226
|
-
},
|
|
227
|
-
// API Tokens routes
|
|
228
|
-
API_TOKENS: {
|
|
229
|
-
LIST: "/api-tokens",
|
|
230
|
-
BY_ID: {
|
|
231
|
-
pattern: "/api-tokens/:id",
|
|
232
|
-
build: (id) => `/api-tokens/${encodeURIComponent(id)}`,
|
|
233
|
-
params: { id: "string" }
|
|
234
|
-
}
|
|
235
|
-
},
|
|
236
|
-
// SDK routes (authenticated via API tokens)
|
|
237
|
-
SDK: {
|
|
238
|
-
ME: "/sdk/me",
|
|
239
|
-
SAMPLE_EVENTS: "/sdk/sample-events",
|
|
240
|
-
TOOL_EXECUTE: "/sdk/tool-execute",
|
|
241
|
-
TOOL_DEFINITIONS: "/sdk/tool-definitions",
|
|
242
|
-
AGENT_RUN: "/sdk/agent-run",
|
|
243
|
-
APPROVAL_DECISION: "/sdk/approval-decision",
|
|
244
|
-
SESSION_EVENTS: "/sdk/session-events",
|
|
245
|
-
DEPLOY: "/sdk/deploy",
|
|
246
|
-
DEVICE_TOKEN_EXCHANGE: "/sdk/auth/device-token-exchange",
|
|
247
|
-
INTEGRATION_FIELDS: {
|
|
248
|
-
pattern: "/sdk/integrations/:integrationType/fields",
|
|
249
|
-
build: (integrationType) => `/sdk/integrations/${encodeURIComponent(integrationType)}/fields`,
|
|
250
|
-
params: { integrationType: "string" }
|
|
251
|
-
},
|
|
252
|
-
INTEGRATION_FORM_SUBMIT: {
|
|
253
|
-
pattern: "/sdk/integrations/:integrationType/form-submit",
|
|
254
|
-
build: (integrationType) => `/sdk/integrations/${encodeURIComponent(integrationType)}/form-submit`,
|
|
255
|
-
params: { integrationType: "string" }
|
|
256
|
-
}
|
|
257
|
-
},
|
|
258
|
-
NOTIFICATION_SETTINGS: "/notification-settings",
|
|
259
|
-
SENT_NOTIFICATIONS: {
|
|
260
|
-
LIST: "/sent-notifications"
|
|
261
|
-
},
|
|
262
|
-
PENDING_APPROVALS: {
|
|
263
|
-
LIST: "/pending-approvals"
|
|
264
|
-
},
|
|
265
|
-
// Webhooks routes
|
|
266
|
-
WEBHOOKS: {
|
|
267
|
-
GMAIL: "/webhooks/gmail",
|
|
268
|
-
FIGMA: "/webhooks/figma",
|
|
269
|
-
WORKOS: "/webhooks/workos",
|
|
270
|
-
JIRA_BY_ACCOUNT_ID: {
|
|
271
|
-
pattern: "/webhooks/jira/:accountId",
|
|
272
|
-
build: (accountId) => `/webhooks/jira/${encodeURIComponent(accountId)}`,
|
|
273
|
-
params: { accountId: "string" }
|
|
274
|
-
},
|
|
275
|
-
LINEAR_BY_USER_ID: {
|
|
276
|
-
pattern: "/webhooks/linear/:userId",
|
|
277
|
-
build: (userId) => `/webhooks/linear/${encodeURIComponent(userId)}`,
|
|
278
|
-
params: { userId: "string" }
|
|
279
|
-
},
|
|
280
|
-
SCHEDULE_BY_INPUT_ID: {
|
|
281
|
-
pattern: "/webhooks/schedule/:inputId",
|
|
282
|
-
build: (inputId) => `/webhooks/schedule/${encodeURIComponent(inputId)}`,
|
|
283
|
-
params: { inputId: "string" }
|
|
284
|
-
},
|
|
285
|
-
WORKOS_TRIGGER_BY_INTEGRATION_ID: {
|
|
286
|
-
pattern: "/webhooks/workos-trigger/:integrationId",
|
|
287
|
-
build: (integrationId) => `/webhooks/workos-trigger/${encodeURIComponent(integrationId)}`,
|
|
288
|
-
params: { integrationId: "string" }
|
|
289
|
-
}
|
|
290
|
-
},
|
|
291
|
-
// Schedule routes
|
|
292
|
-
SCHEDULE: {
|
|
293
|
-
TRIGGER_BY_INPUT_ID: {
|
|
294
|
-
pattern: "/schedule/trigger/:inputId",
|
|
295
|
-
build: (inputId) => `/schedule/trigger/${encodeURIComponent(inputId)}`,
|
|
296
|
-
params: { inputId: "string" }
|
|
297
|
-
},
|
|
298
|
-
TRIGGER_WITH_EVENT: {
|
|
299
|
-
pattern: "/schedule/trigger-with-event/:automationId",
|
|
300
|
-
build: (automationId) => `/schedule/trigger-with-event/${encodeURIComponent(automationId)}`,
|
|
301
|
-
params: { automationId: "string" }
|
|
302
|
-
}
|
|
303
|
-
},
|
|
304
|
-
// Refresh tokens route
|
|
305
|
-
REFRESH_TOKENS: "/refresh-tokens",
|
|
306
|
-
REVIEW_AGENTS: "/review-agents",
|
|
307
|
-
// Users routes
|
|
308
|
-
USERS: {
|
|
309
|
-
CREATE: "/users",
|
|
310
|
-
BY_ID: {
|
|
311
|
-
pattern: "/users/:id",
|
|
312
|
-
build: (id) => `/users/${encodeURIComponent(id)}`,
|
|
313
|
-
params: { id: "string" }
|
|
314
|
-
}
|
|
315
|
-
},
|
|
316
|
-
// Builder chat routes
|
|
317
|
-
BUILDER_CHAT: {
|
|
318
|
-
HISTORY_BY_SESSION_ID: {
|
|
319
|
-
pattern: "/builder-chat/:sessionId/history",
|
|
320
|
-
build: (sessionId) => `/builder-chat/${encodeURIComponent(sessionId)}/history`,
|
|
321
|
-
params: { sessionId: "string" }
|
|
322
|
-
}
|
|
323
|
-
}
|
|
324
|
-
};
|
|
325
|
-
//# sourceMappingURL=ApiRoutes.js.map
|