@lunnoa/client 1.5.0 → 2.0.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/dist/react.d.ts CHANGED
@@ -245,64 +245,6 @@ interface components {
245
245
  /** @description Availability of authentication methods for this deployment. */
246
246
  AUTH_METHODS: components["schemas"]["AuthMethodFlagsDto"];
247
247
  };
248
- CreateProjectDto: {
249
- /** @description Name of the project. */
250
- name: string;
251
- /** @description Description of the project. */
252
- description?: string;
253
- };
254
- ProjectCountDto: {
255
- /** @description Number of agents in the project. */
256
- agents?: number;
257
- /** @description Number of variables in the project. */
258
- variables?: number;
259
- /** @description Number of workflows in the project. */
260
- workflows?: number;
261
- };
262
- ProjectCreatedByUserDto: {
263
- /** @description User ID. */
264
- id: string;
265
- /** @description User email address. */
266
- email: string;
267
- /** @description User display name. */
268
- name: string;
269
- };
270
- ProjectCreatedByWorkspaceUserDto: {
271
- /** @description Workspace user ID. */
272
- id: string;
273
- /** @description The underlying user. */
274
- user: components["schemas"]["ProjectCreatedByUserDto"];
275
- };
276
- ProjectWorkflowSummaryDto: {
277
- /** @description Workflow ID. */
278
- id: string;
279
- /** @description Workflow name. */
280
- name: string;
281
- };
282
- ProjectResponseDto: {
283
- /** @description Project ID. */
284
- id: string;
285
- /** @description Project name. */
286
- name: string;
287
- /** @description Project description. Included when `expansion=description` is requested. */
288
- description?: string;
289
- /**
290
- * Format: date-time
291
- * @description Creation timestamp. Included when `expansion=createdAt` is requested.
292
- */
293
- createdAt?: string;
294
- /**
295
- * Format: date-time
296
- * @description Last update timestamp. Included when `expansion=updatedAt` is requested.
297
- */
298
- updatedAt?: string;
299
- /** @description Aggregate counts. Included when `expansion=countAgents` is requested; countVariables and countWorkflows add their respective counts. */
300
- _count?: components["schemas"]["ProjectCountDto"];
301
- /** @description Workspace user who created the project. Included when `expansion=createdByWorkspaceUser` is requested. */
302
- createdByWorkspaceUser?: components["schemas"]["ProjectCreatedByWorkspaceUserDto"];
303
- /** @description Workflows in the project. Included when `expansion=workflows` is requested. */
304
- workflows?: components["schemas"]["ProjectWorkflowSummaryDto"][];
305
- };
306
248
  CreateQueueDto: {
307
249
  /** @description Human-readable name for the queue. */
308
250
  name: string;
@@ -319,12 +261,6 @@ interface components {
319
261
  /** @description Default priority for items in this queue. Higher values are processed first. Defaults to 0. */
320
262
  priority?: number;
321
263
  };
322
- QueueProjectSummaryDto: {
323
- /** @description Project ID. */
324
- id: string;
325
- /** @description Project name. */
326
- name: string;
327
- };
328
264
  QueueWorkspaceSummaryDto: {
329
265
  /** @description Workspace ID. */
330
266
  id: string;
@@ -394,8 +330,6 @@ interface components {
394
330
  successItems?: number;
395
331
  /** @description Number of failed items. Included when `expansion=statistics` is requested. */
396
332
  failedItems?: number;
397
- /** @description Owning project. Included when `expansion=project` is requested. */
398
- project?: components["schemas"]["QueueProjectSummaryDto"];
399
333
  /** @description Owning workspace. Included when `expansion=workspace` is requested. */
400
334
  workspace?: components["schemas"]["QueueWorkspaceSummaryDto"];
401
335
  /** @description Workspace user who created the queue. Included when `expansion=createdByWorkspaceUser` is requested. */
@@ -872,18 +806,44 @@ interface components {
872
806
  /** @description Number of item IDs submitted for deletion. */
873
807
  requestedCount: number;
874
808
  };
875
- WorkflowProjectSummaryDto: {
876
- /** @description Project ID */
877
- id: string;
878
- /** @description Project name */
879
- name: string;
809
+ UpsertWorkflowStepDto: {
810
+ /** @description Workflow app id (catalogue slug). */
811
+ appId: string;
812
+ /** @description Catalogue action id. */
813
+ actionId: string;
814
+ /** @description Connection instance UUID for this step. */
815
+ connectionId?: string;
816
+ /** @description Action input / config fields. */
817
+ input?: {
818
+ [key: string]: unknown;
819
+ };
820
+ /** @description Display name for the step node. */
821
+ name?: string;
822
+ /** @description Step description. */
823
+ description?: string;
824
+ };
825
+ UpsertWorkflowBySlugDto: {
826
+ /**
827
+ * @description Stable workspace-scoped slug (lowercase, digits, hyphens). Used as the upsert key.
828
+ * @example sync-orders
829
+ */
830
+ slug: string;
831
+ /** @description Display name. Defaults to the slug when omitted. */
832
+ name?: string;
833
+ description?: string;
834
+ /** @description Whether the workflow is active. */
835
+ isActive?: boolean;
836
+ /** @description Linear catalogue-action steps (v1; no branches). */
837
+ steps: components["schemas"]["UpsertWorkflowStepDto"][];
838
+ /** @description Marks the row as managed by code (CLI / SDK). Defaults to true on this endpoint. */
839
+ managedByCode?: boolean;
880
840
  };
881
841
  WorkflowResponseDto: {
882
842
  /** @description Workflow ID */
883
843
  id: string;
884
844
  /** @description Workflow name */
885
845
  name: string;
886
- /** @description Stable project-scoped slug for CLI / code deploy upserts. Included when `expansion=slug` is requested. */
846
+ /** @description Stable workspace-scoped slug for CLI / code deploy upserts. Included when `expansion=slug` is requested. */
887
847
  slug?: string | null;
888
848
  /** @description True when last written by code (CLI / SDK). Included when `expansion=managedByCode` is requested. */
889
849
  managedByCode?: boolean;
@@ -945,42 +905,48 @@ interface components {
945
905
  * @enum {string}
946
906
  */
947
907
  workflowOrientation?: "HORIZONTAL" | "VERTICAL";
948
- /** @description The project the workflow belongs to. Included when `expansion=project` is requested. */
949
- project?: components["schemas"]["WorkflowProjectSummaryDto"];
950
908
  /** @description AI provider connection used by the workflow builder chat. Always returned on GET /workflows/{workflowId}. */
951
909
  aiConnectionId?: string | null;
952
910
  /** @description Selected model ID within the AI provider connection for workflow builder chat. Always returned on GET /workflows/{workflowId}. */
953
911
  selectedModelId?: string | null;
954
912
  };
955
- UpsertWorkflowStepDto: {
913
+ UpsertAgentToolDto: {
956
914
  /** @description Workflow app id (catalogue slug). */
957
915
  appId: string;
958
916
  /** @description Catalogue action id. */
959
917
  actionId: string;
960
- /** @description Connection instance UUID for this step. */
918
+ /** @description Connection instance UUID pre-bound on the tool. */
961
919
  connectionId?: string;
962
- /** @description Action input / config fields. */
920
+ /** @description Tool display name for the model. */
921
+ name?: string;
922
+ /** @description Tool description shown to the model. */
923
+ description?: string;
924
+ /** @description Pre-filled tool config (fields left empty are filled by the model). */
963
925
  input?: {
964
926
  [key: string]: unknown;
965
927
  };
966
- /** @description Display name for the step node. */
967
- name?: string;
968
- /** @description Step description. */
969
- description?: string;
970
928
  };
971
- UpsertWorkflowBySlugDto: {
929
+ UpsertAgentBySlugDto: {
972
930
  /**
973
- * @description Stable project-scoped slug (lowercase, digits, hyphens). Used as the upsert key.
974
- * @example sync-orders
931
+ * @description Stable workspace-scoped slug (lowercase, digits, hyphens). Used as the upsert key.
932
+ * @example support-triage
975
933
  */
976
934
  slug: string;
977
935
  /** @description Display name. Defaults to the slug when omitted. */
978
936
  name?: string;
979
937
  description?: string;
980
- /** @description Whether the workflow is active. */
981
- isActive?: boolean;
982
- /** @description Linear catalogue-action steps (v1; no branches). */
983
- steps: components["schemas"]["UpsertWorkflowStepDto"][];
938
+ /** @description System instructions / prompt for the agent. */
939
+ instructions: string;
940
+ /** @description Selected model id on the AI provider connection (e.g. `gpt-4o`). */
941
+ model: string;
942
+ /** @description AiProviderConnection UUID. When omitted, platform AI defaults apply. */
943
+ aiConnectionId?: string;
944
+ /** @description App Connection UUIDs the agent may use for tools. */
945
+ connectionIds?: string[];
946
+ /** @description Workflow UUIDs the agent may run (AgentWorkflow links). */
947
+ workflowIds?: string[];
948
+ /** @description Catalogue action tools (WorkflowNodeForRunner-shaped). */
949
+ tools?: components["schemas"]["UpsertAgentToolDto"][];
984
950
  /** @description Marks the row as managed by code (CLI / SDK). Defaults to true on this endpoint. */
985
951
  managedByCode?: boolean;
986
952
  };
@@ -995,7 +961,7 @@ interface components {
995
961
  * @example Invoice Triage Agent
996
962
  */
997
963
  name: string;
998
- /** @description Stable project-scoped slug for CLI / code deploy upserts. Included when `expansion=slug` is requested. */
964
+ /** @description Stable workspace-scoped slug for CLI / code deploy upserts. Included when `expansion=slug` is requested. */
999
965
  slug?: string | null;
1000
966
  /** @description True when last written by code (CLI / SDK). Included when `expansion=managedByCode` is requested. */
1001
967
  managedByCode?: boolean;
@@ -1238,51 +1204,6 @@ interface components {
1238
1204
  outboundCallsEnabled?: boolean;
1239
1205
  inboundCallsEnabled?: boolean;
1240
1206
  } | null;
1241
- /** @description Project the agent belongs to. Included when `expansion=project` is requested. */
1242
- project?: {
1243
- id?: string;
1244
- name?: string;
1245
- };
1246
- };
1247
- UpsertAgentToolDto: {
1248
- /** @description Workflow app id (catalogue slug). */
1249
- appId: string;
1250
- /** @description Catalogue action id. */
1251
- actionId: string;
1252
- /** @description Connection instance UUID pre-bound on the tool. */
1253
- connectionId?: string;
1254
- /** @description Tool display name for the model. */
1255
- name?: string;
1256
- /** @description Tool description shown to the model. */
1257
- description?: string;
1258
- /** @description Pre-filled tool config (fields left empty are filled by the model). */
1259
- input?: {
1260
- [key: string]: unknown;
1261
- };
1262
- };
1263
- UpsertAgentBySlugDto: {
1264
- /**
1265
- * @description Stable project-scoped slug (lowercase, digits, hyphens). Used as the upsert key.
1266
- * @example support-triage
1267
- */
1268
- slug: string;
1269
- /** @description Display name. Defaults to the slug when omitted. */
1270
- name?: string;
1271
- description?: string;
1272
- /** @description System instructions / prompt for the agent. */
1273
- instructions: string;
1274
- /** @description Selected model id on the AI provider connection (e.g. `gpt-4o`). */
1275
- model: string;
1276
- /** @description AiProviderConnection UUID. When omitted, platform AI defaults apply. */
1277
- aiConnectionId?: string;
1278
- /** @description App Connection UUIDs the agent may use for tools. */
1279
- connectionIds?: string[];
1280
- /** @description Workflow UUIDs the agent may run (AgentWorkflow links). */
1281
- workflowIds?: string[];
1282
- /** @description Catalogue action tools (WorkflowNodeForRunner-shaped). */
1283
- tools?: components["schemas"]["UpsertAgentToolDto"][];
1284
- /** @description Marks the row as managed by code (CLI / SDK). Defaults to true on this endpoint. */
1285
- managedByCode?: boolean;
1286
1207
  };
1287
1208
  WorkflowAppResponseDto: {
1288
1209
  /** @description App ID, e.g. `gmail`. Matches the appId used in workflow execution steps. */
@@ -1835,21 +1756,13 @@ interface components {
1835
1756
  /** @description Workspace name */
1836
1757
  name: string;
1837
1758
  };
1838
- ExecutionProjectSummaryDto: {
1839
- /** @description Project ID */
1840
- id: string;
1841
- /** @description Project name */
1842
- name: string;
1843
- /** @description The workspace the project belongs to. Included when `expansion=workspace` is requested alongside `workflow` and `project`. */
1844
- workspace?: components["schemas"]["ExecutionWorkspaceSummaryDto"];
1845
- };
1846
1759
  ExecutionWorkflowSummaryDto: {
1847
1760
  /** @description Workflow ID */
1848
1761
  id: string;
1849
1762
  /** @description Workflow name */
1850
1763
  name: string;
1851
- /** @description The project the workflow belongs to. Included when `expansion=project` is requested alongside `workflow`. */
1852
- project?: components["schemas"]["ExecutionProjectSummaryDto"];
1764
+ /** @description The workspace the workflow belongs to. Included when `expansion=workspace` is requested alongside `workflow`. */
1765
+ workspace?: components["schemas"]["ExecutionWorkspaceSummaryDto"];
1853
1766
  };
1854
1767
  ExecutionPathStepDto: {
1855
1768
  /** @description ID of the workflow node this step represents */
@@ -1997,8 +1910,6 @@ interface components {
1997
1910
  actionId: string;
1998
1911
  /** @description Connection instance UUID (`Connection.id`). Required when the action needs a connection and the workspace has more than one connection for the app with no single workspace default. When omitted: sole usable connection for the app is used; else the workspace default (`isDefault`); else 400 with candidates. Never silently picks among multiple non-default connections. */
1999
1912
  connectionId?: string;
2000
- /** @description Project UUID used for variable/project scoping. When omitted and the workspace has exactly one project, that project is used; otherwise the request fails with 400. */
2001
- projectId?: string;
2002
1913
  /** @description Action input fields (mirrors the action `inputConfig` keys). Combined with `connectionId` into the action configValue. */
2003
1914
  input?: {
2004
1915
  [key: string]: unknown;
@@ -2040,8 +1951,6 @@ interface components {
2040
1951
  StartRunDto: {
2041
1952
  /** @description Linear catalogue-action steps. Executed as one multi-step Execution with `source: SDK` (not a soft batch / correlation id). */
2042
1953
  steps: components["schemas"]["RunStepDto"][];
2043
- /** @description Project UUID for variable/project scoping. When omitted and the workspace has exactly one project, that project is used. */
2044
- projectId?: string;
2045
1954
  /** @description Optional display name for the ad-hoc Execution. */
2046
1955
  name?: string;
2047
1956
  };
@@ -2051,17 +1960,15 @@ interface components {
2051
1960
  /** @description Description of the variable. */
2052
1961
  description?: string;
2053
1962
  /**
2054
- * @description Scope of the variable (system, workspace or project).
1963
+ * @description Scope of the variable (system or workspace).
2055
1964
  * @enum {string}
2056
1965
  */
2057
- type: "system" | "workspace" | "project";
1966
+ type: "system" | "workspace";
2058
1967
  /**
2059
1968
  * @description Data type of the variable value.
2060
1969
  * @enum {string}
2061
1970
  */
2062
1971
  dataType: "string" | "number" | "boolean" | "date" | "json";
2063
- /** @description Project ID to scope the variable to. Must belong to the current workspace. */
2064
- projectId?: string;
2065
1972
  /** @description Variable value, submitted as a string. Values with dataType `number` are converted to numbers on save. */
2066
1973
  value: string;
2067
1974
  };
@@ -2071,12 +1978,6 @@ interface components {
2071
1978
  /** @description Workspace name. */
2072
1979
  name: string;
2073
1980
  };
2074
- VariableProjectDto: {
2075
- /** @description Project ID. */
2076
- id: string;
2077
- /** @description Project name. */
2078
- name: string;
2079
- };
2080
1981
  VariableResponseDto: {
2081
1982
  /** @description Variable ID. */
2082
1983
  id: string;
@@ -2088,10 +1989,10 @@ interface components {
2088
1989
  */
2089
1990
  dataType: "string" | "number" | "boolean" | "date" | "json";
2090
1991
  /**
2091
- * @description Scope of the variable (system, workspace or project).
1992
+ * @description Scope of the variable (system or workspace).
2092
1993
  * @enum {string}
2093
1994
  */
2094
- type: "system" | "workspace" | "project";
1995
+ type: "system" | "workspace";
2095
1996
  /** @description Variable value. Included when `expansion=value` is requested. */
2096
1997
  value?: Record<string, never>;
2097
1998
  /** @description Variable description. Included when `expansion=description` is requested. */
@@ -2108,8 +2009,6 @@ interface components {
2108
2009
  updatedAt?: string;
2109
2010
  /** @description Owning workspace. Included when `expansion=workspace` is requested. */
2110
2011
  workspace?: components["schemas"]["VariableWorkspaceDto"];
2111
- /** @description Owning project for project-scoped variables. Included when `expansion=project` is requested. */
2112
- project?: components["schemas"]["VariableProjectDto"];
2113
2012
  };
2114
2013
  UpdateVariableDto: {
2115
2014
  /** @description Name of the variable. */
@@ -2117,17 +2016,15 @@ interface components {
2117
2016
  /** @description Description of the variable. */
2118
2017
  description?: string;
2119
2018
  /**
2120
- * @description Scope of the variable (system, workspace or project).
2019
+ * @description Scope of the variable (system or workspace).
2121
2020
  * @enum {string}
2122
2021
  */
2123
- type?: "system" | "workspace" | "project";
2022
+ type?: "system" | "workspace";
2124
2023
  /**
2125
2024
  * @description Data type of the variable value.
2126
2025
  * @enum {string}
2127
2026
  */
2128
2027
  dataType?: "string" | "number" | "boolean" | "date" | "json";
2129
- /** @description Project ID to scope the variable to. Must belong to the current workspace. */
2130
- projectId?: string;
2131
2028
  /** @description Variable value, submitted as a string. Values with dataType `number` are converted to numbers on save. */
2132
2029
  value?: string;
2133
2030
  };
@@ -2136,8 +2033,6 @@ interface components {
2136
2033
  name?: string;
2137
2034
  /** @description What the table contains. Agents use this to choose a table. */
2138
2035
  description?: string;
2139
- /** @description Project ID to scope the table to. Omit for a workspace-wide table. */
2140
- projectId?: string;
2141
2036
  /** @description Column names: [{ key }]. */
2142
2037
  columns?: {
2143
2038
  [key: string]: unknown;
@@ -2151,10 +2046,6 @@ interface components {
2151
2046
  /** @description Marks the table as code-managed. Defaults to true on upsert. */
2152
2047
  managedByCode?: boolean;
2153
2048
  };
2154
- TableProjectDto: {
2155
- id: string;
2156
- name: string;
2157
- };
2158
2049
  TableColumnDto: {
2159
2050
  /** @description Column key used in rows. */
2160
2051
  key: string;
@@ -2172,9 +2063,6 @@ interface components {
2172
2063
  description?: string | null;
2173
2064
  /** @description Whether the table is managed by code (CLI / API upsert). */
2174
2065
  managedByCode: boolean;
2175
- /** @description Project the table is scoped to, or null for workspace-wide. */
2176
- FK_projectId?: string | null;
2177
- project?: components["schemas"]["TableProjectDto"] | null;
2178
2066
  /** @description Columns. Returned by get and upsert, not by list. */
2179
2067
  columns?: components["schemas"]["TableColumnDto"][];
2180
2068
  /** @description Rows keyed by column key. Returned by get and upsert, not by list. */
@@ -2260,14 +2148,10 @@ interface components {
2260
2148
  [key: string]: unknown;
2261
2149
  } | null;
2262
2150
  }[];
2263
- /** @description Agent the task belongs to. Included when `expansion=agent` is requested. The nested `project` is included when `expansion=project` is also requested. */
2151
+ /** @description Agent the task belongs to. Included when `expansion=agent` is requested. */
2264
2152
  agent?: {
2265
2153
  id?: string;
2266
2154
  name?: string;
2267
- project?: {
2268
- id?: string;
2269
- name?: string;
2270
- };
2271
2155
  };
2272
2156
  };
2273
2157
  TaskLatestRunDto: {
@@ -2342,14 +2226,10 @@ interface components {
2342
2226
  [key: string]: unknown;
2343
2227
  } | null;
2344
2228
  }[];
2345
- /** @description Agent the task belongs to. Included when `expansion=agent` is requested. The nested `project` is included when `expansion=project` is also requested. */
2229
+ /** @description Agent the task belongs to. Included when `expansion=agent` is requested. */
2346
2230
  agent?: {
2347
2231
  id?: string;
2348
2232
  name?: string;
2349
- project?: {
2350
- id?: string;
2351
- name?: string;
2352
- };
2353
2233
  };
2354
2234
  };
2355
2235
  UpdateTaskDto: {
@@ -2468,8 +2348,6 @@ interface components {
2468
2348
 
2469
2349
  type Schemas = components['schemas'];
2470
2350
  type EnabledFeatures = Schemas['EnabledFeaturesResponseDto'];
2471
- type Project = Schemas['ProjectResponseDto'];
2472
- type CreateProjectInput = Schemas['CreateProjectDto'];
2473
2351
  type Agent = Schemas['AgentResponseDto'];
2474
2352
  type Task = Schemas['TaskResponseDto'];
2475
2353
  type TaskListItem = Schemas['TaskListItemResponseDto'];
@@ -2700,11 +2578,6 @@ interface RunActionOptions {
2700
2578
  * and exactly one connection exists, the platform uses that connection.
2701
2579
  */
2702
2580
  connectionId?: string;
2703
- /**
2704
- * Project UUID for variable/project scoping. Required when the workspace has
2705
- * more than one project.
2706
- */
2707
- projectId?: string;
2708
2581
  /** Action input fields (keys from the action `inputConfig`). */
2709
2582
  input?: Record<string, unknown>;
2710
2583
  /** Optional display name for the ad-hoc Execution. */
@@ -2792,7 +2665,7 @@ interface WorkflowStepDefinition {
2792
2665
  }
2793
2666
  interface WorkflowDefinition {
2794
2667
  kind: typeof DEFINE_KINDS.workflow;
2795
- /** Stable project-scoped slug (upsert key). */
2668
+ /** Stable slug, unique in the workspace (upsert key). */
2796
2669
  slug: string;
2797
2670
  name?: string;
2798
2671
  description?: string;
@@ -2805,7 +2678,7 @@ type AgentToolDefinition = ActionDefinition | WorkflowDefinition | {
2805
2678
  };
2806
2679
  interface AgentDefinition {
2807
2680
  kind: typeof DEFINE_KINDS.agent;
2808
- /** Stable project-scoped slug (upsert key). */
2681
+ /** Stable slug, unique in the workspace (upsert key). */
2809
2682
  slug: string;
2810
2683
  name?: string;
2811
2684
  description?: string;
@@ -2866,10 +2739,10 @@ declare class AgentsResource {
2866
2739
  /** Returns a single agent. */
2867
2740
  get(agentId: string, options?: Pick<ListQueryOptions, 'expansion'>): Promise<Agent>;
2868
2741
  /**
2869
- * Upsert an agent by project-scoped slug.
2742
+ * Upsert an agent by slug inside the workspace on the API key.
2870
2743
  * Prefer the CLI (`npx @lunnoa/client agents deploy`) for happy-path deploy.
2871
2744
  */
2872
- upsertBySlug(projectId: string, body: UpsertAgentBySlugInput | AgentDefinition, options?: {
2745
+ upsertBySlug(body: UpsertAgentBySlugInput | AgentDefinition, options?: {
2873
2746
  workflowIds?: string[];
2874
2747
  }): Promise<Agent>;
2875
2748
  }
@@ -3169,9 +3042,7 @@ declare class TablesResource {
3169
3042
  private readonly http;
3170
3043
  constructor(http: HttpClient);
3171
3044
  /** Lists tables in the API key's workspace (without columns and rows). */
3172
- list(options?: {
3173
- projectId?: string;
3174
- }): Promise<Table[]>;
3045
+ list(): Promise<Table[]>;
3175
3046
  /** Returns a single table by ID, including columns and rows. */
3176
3047
  get(id: string): Promise<Table>;
3177
3048
  /** Returns a single table by its workspace slug, including columns and rows. */
@@ -3272,17 +3143,6 @@ declare class KnowledgeResource {
3272
3143
  deleteDocumentGroup(knowledgeId: string, groupId: string): Promise<boolean>;
3273
3144
  }
3274
3145
 
3275
- declare class ProjectsResource {
3276
- private readonly http;
3277
- constructor(http: HttpClient);
3278
- /** Lists projects in the workspace, most recently updated first. */
3279
- list(options?: ListQueryOptions): Promise<Project[]>;
3280
- /** Returns a single project. */
3281
- get(projectId: string, options?: Pick<ListQueryOptions, 'expansion'>): Promise<Project>;
3282
- /** Creates a project. */
3283
- create(data: CreateProjectInput): Promise<Project>;
3284
- }
3285
-
3286
3146
  type QueueItemStatus = 'PENDING' | 'PROCESSING' | 'SUCCESS' | 'FAILED' | 'RETRYING';
3287
3147
  interface AddQueueItemErrorInput {
3288
3148
  /** Error message recorded on the item. */
@@ -3396,7 +3256,6 @@ interface StartRunStep {
3396
3256
  }
3397
3257
  interface StartRunOptions {
3398
3258
  steps: StartRunStep[];
3399
- projectId?: string;
3400
3259
  name?: string;
3401
3260
  }
3402
3261
  type StartRunInput = StartRunOptions | WorkflowDefinition | WorkflowStepDefinition[] | StartRunStep[];
@@ -3411,7 +3270,7 @@ declare class RunsResource {
3411
3270
  * Start a linear multi-step ad-hoc Execution.
3412
3271
  *
3413
3272
  * Accepts a `defineWorkflow` result, a step array, or an explicit
3414
- * `{ steps, projectId?, name? }` payload.
3273
+ * `{ steps, name? }` payload.
3415
3274
  */
3416
3275
  start(input: StartRunInput): Promise<RunActionResult>;
3417
3276
  /** Convenience: start and wait until terminal / NEEDS_INPUT. */
@@ -3568,10 +3427,10 @@ declare class WorkflowsResource {
3568
3427
  */
3569
3428
  get(workflowId: string, options?: Pick<ListQueryOptions, 'expansion'>): Promise<Workflow>;
3570
3429
  /**
3571
- * Upsert a workflow by project-scoped slug from a linear step list.
3430
+ * Upsert a workflow by slug inside the workspace on the API key.
3572
3431
  * Prefer the CLI (`npx @lunnoa/client workflows deploy`) for happy-path deploy.
3573
3432
  */
3574
- upsertBySlug(projectId: string, body: UpsertWorkflowBySlugInput | WorkflowDefinition): Promise<Workflow>;
3433
+ upsertBySlug(body: UpsertWorkflowBySlugInput | WorkflowDefinition): Promise<Workflow>;
3575
3434
  /**
3576
3435
  * Starts a new execution of the workflow with the given trigger inputs.
3577
3436
  * Returns immediately with the execution ID.
@@ -3642,7 +3501,6 @@ declare class LunnoaClient {
3642
3501
  readonly variables: VariablesResource;
3643
3502
  readonly scorecards: ScorecardsResource;
3644
3503
  readonly connections: ConnectionsResource;
3645
- readonly projects: ProjectsResource;
3646
3504
  readonly workflowApps: WorkflowAppsResource;
3647
3505
  readonly discovery: DiscoveryResource;
3648
3506
  constructor(options: LunnoaClientOptions);
package/dist/react.js CHANGED
@@ -700,12 +700,12 @@ var AgentsResource = class {
700
700
  });
701
701
  }
702
702
  /**
703
- * Upsert an agent by project-scoped slug.
703
+ * Upsert an agent by slug inside the workspace on the API key.
704
704
  * Prefer the CLI (`npx @lunnoa/client agents deploy`) for happy-path deploy.
705
705
  */
706
- upsertBySlug(projectId, body, options) {
706
+ upsertBySlug(body, options) {
707
707
  const payload = "kind" in body && body.kind === "agent" ? agentDefinitionToUpsert(body, options) : body;
708
- return this.http.post(`/api/projects/${projectId}/agents/upsert`, {
708
+ return this.http.post("/api/agents/upsert", {
709
709
  body: payload
710
710
  });
711
711
  }
@@ -1129,10 +1129,8 @@ var TablesResource = class {
1129
1129
  }
1130
1130
  http;
1131
1131
  /** Lists tables in the API key's workspace (without columns and rows). */
1132
- list(options = {}) {
1133
- return this.http.get("/api/tables", {
1134
- query: { projectId: options.projectId }
1135
- });
1132
+ list() {
1133
+ return this.http.get("/api/tables");
1136
1134
  }
1137
1135
  /** Returns a single table by ID, including columns and rows. */
1138
1136
  get(id) {
@@ -1552,30 +1550,6 @@ var KnowledgeResource = class {
1552
1550
  }
1553
1551
  };
1554
1552
 
1555
- // src/resources/projects.ts
1556
- var ProjectsResource = class {
1557
- constructor(http) {
1558
- this.http = http;
1559
- }
1560
- http;
1561
- /** Lists projects in the workspace, most recently updated first. */
1562
- list(options) {
1563
- return this.http.get("/api/projects", {
1564
- query: serializeListQuery(options)
1565
- });
1566
- }
1567
- /** Returns a single project. */
1568
- get(projectId, options) {
1569
- return this.http.get(`/api/projects/${projectId}`, {
1570
- query: serializeListQuery(options)
1571
- });
1572
- }
1573
- /** Creates a project. */
1574
- create(data) {
1575
- return this.http.post("/api/projects", { body: data });
1576
- }
1577
- };
1578
-
1579
1553
  // src/resources/queue-items.ts
1580
1554
  var QueueItemsResource = class {
1581
1555
  constructor(http) {
@@ -1855,7 +1829,7 @@ var RunsResource = class {
1855
1829
  * Start a linear multi-step ad-hoc Execution.
1856
1830
  *
1857
1831
  * Accepts a `defineWorkflow` result, a step array, or an explicit
1858
- * `{ steps, projectId?, name? }` payload.
1832
+ * `{ steps, name? }` payload.
1859
1833
  */
1860
1834
  start(input) {
1861
1835
  const options = normalizeStartRunInput(input);
@@ -2073,15 +2047,14 @@ var WorkflowsResource = class {
2073
2047
  });
2074
2048
  }
2075
2049
  /**
2076
- * Upsert a workflow by project-scoped slug from a linear step list.
2050
+ * Upsert a workflow by slug inside the workspace on the API key.
2077
2051
  * Prefer the CLI (`npx @lunnoa/client workflows deploy`) for happy-path deploy.
2078
2052
  */
2079
- upsertBySlug(projectId, body) {
2053
+ upsertBySlug(body) {
2080
2054
  const payload = "kind" in body && body.kind === "workflow" ? workflowDefinitionToUpsert(body) : body;
2081
- return this.http.post(
2082
- `/api/projects/${projectId}/workflows/upsert`,
2083
- { body: payload }
2084
- );
2055
+ return this.http.post("/api/workflows/upsert", {
2056
+ body: payload
2057
+ });
2085
2058
  }
2086
2059
  /**
2087
2060
  * Starts a new execution of the workflow with the given trigger inputs.
@@ -2143,7 +2116,6 @@ var LunnoaClient = class {
2143
2116
  variables;
2144
2117
  scorecards;
2145
2118
  connections;
2146
- projects;
2147
2119
  workflowApps;
2148
2120
  discovery;
2149
2121
  constructor(options) {
@@ -2167,7 +2139,6 @@ var LunnoaClient = class {
2167
2139
  this.variables = new VariablesResource(this.http);
2168
2140
  this.scorecards = new ScorecardsResource(this.http);
2169
2141
  this.connections = new ConnectionsResource(this.http);
2170
- this.projects = new ProjectsResource(this.http);
2171
2142
  this.discovery = new DiscoveryResource(this.http);
2172
2143
  }
2173
2144
  };