@egose/n8n-client 0.1.1 → 0.2.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/CHANGELOG.md +21 -1
- package/README.md +188 -46
- package/chunk-2R6A6NJE.js +38 -0
- package/chunk-3FDDCKAY.js +95 -0
- package/chunk-3YWWR6UD.cjs +98 -0
- package/chunk-4M2HGY3F.cjs +12 -0
- package/chunk-4VK7K4IF.js +29 -0
- package/chunk-54MX3Y2M.cjs +15 -0
- package/{chunk-MNL65GQB.js → chunk-54N6YD4R.js} +30 -8
- package/chunk-5DDMSYH2.js +54 -0
- package/chunk-5ZRUF6XZ.cjs +15 -0
- package/chunk-6JJ6RA5B.cjs +32 -0
- package/chunk-7H75UBMH.cjs +29 -0
- package/chunk-B7CINZ27.cjs +43 -0
- package/chunk-BA4KTRMX.cjs +15 -0
- package/{chunk-TCPZWXKM.js → chunk-BQ2OTUXQ.js} +27 -8
- package/chunk-C3JBYESS.cjs +35 -0
- package/chunk-C6W6ERQD.js +53 -0
- package/{chunk-TRHGCMFH.cjs → chunk-CCS5ALTN.cjs} +8 -8
- package/chunk-DTDNBA7W.cjs +59 -0
- package/chunk-ETVDSJLY.js +48 -0
- package/chunk-F5RPJMNK.js +15 -0
- package/chunk-FIKGC2EL.cjs +29 -0
- package/{chunk-YPK2BDPO.cjs → chunk-FTIVM52X.cjs} +27 -8
- package/chunk-GEWLPVNV.cjs +48 -0
- package/{chunk-I7NGIQIM.cjs → chunk-GZ3POWDP.cjs} +30 -8
- package/chunk-HISH4ORK.js +59 -0
- package/chunk-I4MMTW33.js +98 -0
- package/chunk-KRPRS2E5.cjs +46 -0
- package/chunk-L2FFL3BY.js +35 -0
- package/{chunk-5DYA4LAX.cjs → chunk-LC3TKRMX.cjs} +1 -1
- package/chunk-LQULSPET.cjs +55 -0
- package/chunk-LTYQTCHM.js +196 -0
- package/chunk-MMN2UKTI.cjs +41 -0
- package/chunk-NBLW25ME.cjs +67 -0
- package/chunk-NS2RDZ7W.js +15 -0
- package/chunk-OUOWDGL7.js +15 -0
- package/chunk-PT5DDLHC.js +46 -0
- package/chunk-Q6FSREKN.js +12 -0
- package/chunk-QJR4WFNV.js +55 -0
- package/{chunk-DK5NLZ6U.js → chunk-RMEH2UPX.js} +1 -1
- package/chunk-RPB226OX.cjs +54 -0
- package/chunk-S4ZASMBT.js +43 -0
- package/chunk-T62VHXNY.js +67 -0
- package/chunk-TLBDBRPJ.js +29 -0
- package/chunk-TY76RTXQ.cjs +32 -0
- package/chunk-USTEEQQG.js +43 -0
- package/chunk-W5P34RYO.cjs +196 -0
- package/chunk-XJP6FPN3.js +41 -0
- package/chunk-YBMEMKCN.cjs +53 -0
- package/chunk-YE2OS2KS.js +32 -0
- package/chunk-YHSDCE3I.js +32 -0
- package/chunk-YSWBOCXJ.cjs +38 -0
- package/chunk-YUCX7HE3.js +15 -0
- package/chunk-Z3D4URRD.cjs +43 -0
- package/chunk-ZIIR24GM.cjs +95 -0
- package/chunk-ZPU6PQES.cjs +15 -0
- package/{chunk-CUO2M75Z.js → chunk-ZVZIMJRM.js} +8 -8
- package/clients/audit.cjs +8 -0
- package/clients/audit.d.cts +10 -0
- package/clients/audit.d.ts +10 -0
- package/clients/audit.js +8 -0
- package/clients/base.cjs +7 -0
- package/clients/base.d.cts +10 -0
- package/clients/base.d.ts +10 -0
- package/clients/base.js +7 -0
- package/clients/community-package.cjs +12 -0
- package/clients/community-package.d.cts +6 -0
- package/clients/community-package.d.ts +6 -0
- package/clients/community-package.js +12 -0
- package/clients/credential.cjs +10 -0
- package/clients/credential.d.cts +6 -0
- package/clients/credential.d.ts +6 -0
- package/clients/credential.js +10 -0
- package/clients/data-table.cjs +10 -0
- package/clients/data-table.d.cts +6 -0
- package/clients/data-table.d.ts +6 -0
- package/clients/data-table.js +10 -0
- package/clients/discover.cjs +8 -0
- package/clients/discover.d.cts +10 -0
- package/clients/discover.d.ts +10 -0
- package/clients/discover.js +8 -0
- package/clients/execution.cjs +10 -0
- package/clients/execution.d.cts +6 -0
- package/clients/execution.d.ts +6 -0
- package/clients/execution.js +10 -0
- package/clients/folder.cjs +10 -0
- package/clients/folder.d.cts +6 -0
- package/clients/folder.d.ts +6 -0
- package/clients/folder.js +10 -0
- package/clients/insights.cjs +8 -0
- package/clients/insights.d.cts +10 -0
- package/clients/insights.d.ts +10 -0
- package/clients/insights.js +8 -0
- package/clients/n8n-package.cjs +8 -0
- package/clients/n8n-package.d.cts +11 -0
- package/clients/n8n-package.d.ts +11 -0
- package/clients/n8n-package.js +8 -0
- package/clients/project.cjs +22 -0
- package/clients/project.d.cts +11 -0
- package/clients/project.d.ts +11 -0
- package/clients/project.js +22 -0
- package/clients/source-control.cjs +8 -0
- package/clients/source-control.d.cts +10 -0
- package/clients/source-control.d.ts +10 -0
- package/clients/source-control.js +8 -0
- package/clients/tag.cjs +10 -0
- package/clients/tag.d.cts +6 -0
- package/clients/tag.d.ts +6 -0
- package/clients/tag.js +10 -0
- package/clients/user.cjs +10 -0
- package/clients/user.d.cts +6 -0
- package/clients/user.d.ts +6 -0
- package/clients/user.js +10 -0
- package/clients/variable.cjs +12 -0
- package/clients/variable.d.cts +6 -0
- package/clients/variable.d.ts +6 -0
- package/clients/variable.js +12 -0
- package/clients/workflow.cjs +14 -0
- package/clients/workflow.d.cts +7 -0
- package/clients/workflow.d.ts +7 -0
- package/clients/workflow.js +14 -0
- package/community-package-CyzAqqwH.d.ts +26 -0
- package/community-package-DBpReCPV.d.cts +26 -0
- package/credential-BWcrGfqd.d.ts +34 -0
- package/credential-CEH7XbGn.d.cts +34 -0
- package/data-table-CHGUClGF.d.ts +60 -0
- package/data-table-CzR5kl9T.d.cts +60 -0
- package/execution-BjR6z5Vu.d.ts +33 -0
- package/execution-C0c9utwa.d.cts +33 -0
- package/folder-DvgIxSea.d.cts +31 -0
- package/folder-bjRPcy2j.d.ts +31 -0
- package/http-client.cjs +2 -2
- package/http-client.d.cts +6 -18
- package/http-client.d.ts +6 -18
- package/http-client.js +1 -1
- package/index.cjs +86 -44
- package/index.d.cts +48 -46
- package/index.d.ts +48 -46
- package/index.js +100 -58
- package/package.json +16 -16
- package/project-BS1fXSLW.d.cts +94 -0
- package/project-uws9k24H.d.ts +94 -0
- package/resources/base.cjs +7 -0
- package/resources/base.d.cts +11 -0
- package/resources/base.d.ts +11 -0
- package/resources/base.js +7 -0
- package/resources/community-package.cjs +8 -0
- package/resources/community-package.d.cts +6 -0
- package/resources/community-package.d.ts +6 -0
- package/resources/community-package.js +8 -0
- package/resources/credential.cjs +8 -0
- package/resources/credential.d.cts +6 -0
- package/resources/credential.d.ts +6 -0
- package/resources/credential.js +8 -0
- package/resources/data-table.cjs +8 -0
- package/resources/data-table.d.cts +6 -0
- package/resources/data-table.d.ts +6 -0
- package/resources/data-table.js +8 -0
- package/resources/execution.cjs +8 -0
- package/resources/execution.d.cts +6 -0
- package/resources/execution.d.ts +6 -0
- package/resources/execution.js +8 -0
- package/resources/folder.cjs +8 -0
- package/resources/folder.d.cts +6 -0
- package/resources/folder.d.ts +6 -0
- package/resources/folder.js +8 -0
- package/resources/project.cjs +11 -0
- package/resources/project.d.cts +11 -0
- package/resources/project.d.ts +11 -0
- package/resources/project.js +11 -0
- package/resources/tag.cjs +8 -0
- package/resources/tag.d.cts +6 -0
- package/resources/tag.d.ts +6 -0
- package/resources/tag.js +8 -0
- package/resources/user.cjs +8 -0
- package/resources/user.d.cts +6 -0
- package/resources/user.d.ts +6 -0
- package/resources/user.js +8 -0
- package/resources/variable.cjs +8 -0
- package/resources/variable.d.cts +6 -0
- package/resources/variable.d.ts +6 -0
- package/resources/variable.js +8 -0
- package/resources/workflow.cjs +10 -0
- package/resources/workflow.d.cts +7 -0
- package/resources/workflow.d.ts +7 -0
- package/resources/workflow.js +10 -0
- package/tag-CzazpR40.d.cts +27 -0
- package/tag-lmf8obZe.d.ts +27 -0
- package/types.d.cts +201 -55
- package/types.d.ts +201 -55
- package/user-B0WdVahA.d.ts +27 -0
- package/user-CBa2VjYj.d.cts +27 -0
- package/variable-C2LmlaTx.d.ts +29 -0
- package/variable-CuCiwy0G.d.cts +29 -0
- package/workflow-8pMj_fR_.d.ts +56 -0
- package/workflow-B2nxUmWq.d.cts +56 -0
- package/chunk-3SBD4UJS.js +0 -15
- package/chunk-4AODYIOB.cjs +0 -36
- package/chunk-4FXZT5HT.js +0 -27
- package/chunk-5FIB7YIT.js +0 -24
- package/chunk-5PHEDSSO.cjs +0 -27
- package/chunk-5SY4KM4Q.js +0 -15
- package/chunk-BWLFUF76.js +0 -36
- package/chunk-CES6KIG5.cjs +0 -36
- package/chunk-DJCG37LZ.js +0 -32
- package/chunk-FHAZIAHR.js +0 -15
- package/chunk-FZX275Y3.js +0 -24
- package/chunk-JR7A75YV.js +0 -15
- package/chunk-M7GX3MEN.cjs +0 -15
- package/chunk-NAZ5MLBL.cjs +0 -32
- package/chunk-NM6A7DX4.cjs +0 -15
- package/chunk-NSCKTOQK.cjs +0 -15
- package/chunk-OOMGKLOT.cjs +0 -24
- package/chunk-QLAAM7TG.cjs +0 -27
- package/chunk-QYAIEIF5.js +0 -36
- package/chunk-RATHO5IW.cjs +0 -15
- package/chunk-SK4VCTMD.js +0 -27
- package/chunk-U7PGEXKS.cjs +0 -36
- package/chunk-ZAZJHB3O.cjs +0 -24
- package/chunk-ZEQL5KU2.js +0 -36
- package/handles/audit.cjs +0 -7
- package/handles/audit.d.cts +0 -11
- package/handles/audit.d.ts +0 -11
- package/handles/audit.js +0 -7
- package/handles/community-package.cjs +0 -7
- package/handles/community-package.d.cts +0 -17
- package/handles/community-package.d.ts +0 -17
- package/handles/community-package.js +0 -7
- package/handles/credential.cjs +0 -7
- package/handles/credential.d.cts +0 -18
- package/handles/credential.d.ts +0 -18
- package/handles/credential.js +0 -7
- package/handles/data-table.cjs +0 -7
- package/handles/data-table.d.cts +0 -38
- package/handles/data-table.d.ts +0 -38
- package/handles/data-table.js +0 -7
- package/handles/discover.cjs +0 -7
- package/handles/discover.d.cts +0 -15
- package/handles/discover.d.ts +0 -15
- package/handles/discover.js +0 -7
- package/handles/execution.cjs +0 -7
- package/handles/execution.d.cts +0 -29
- package/handles/execution.d.ts +0 -29
- package/handles/execution.js +0 -7
- package/handles/folder.cjs +0 -7
- package/handles/folder.d.cts +0 -23
- package/handles/folder.d.ts +0 -23
- package/handles/folder.js +0 -7
- package/handles/insights.cjs +0 -7
- package/handles/insights.d.cts +0 -15
- package/handles/insights.d.ts +0 -15
- package/handles/insights.js +0 -7
- package/handles/n8n-package.cjs +0 -7
- package/handles/n8n-package.d.cts +0 -18
- package/handles/n8n-package.d.ts +0 -18
- package/handles/n8n-package.js +0 -7
- package/handles/project.cjs +0 -7
- package/handles/project.d.cts +0 -25
- package/handles/project.d.ts +0 -25
- package/handles/project.js +0 -7
- package/handles/source-control.cjs +0 -7
- package/handles/source-control.d.cts +0 -11
- package/handles/source-control.d.ts +0 -11
- package/handles/source-control.js +0 -7
- package/handles/tag.cjs +0 -7
- package/handles/tag.d.cts +0 -19
- package/handles/tag.d.ts +0 -19
- package/handles/tag.js +0 -7
- package/handles/user.cjs +0 -7
- package/handles/user.d.cts +0 -21
- package/handles/user.d.ts +0 -21
- package/handles/user.js +0 -7
- package/handles/variable.cjs +0 -7
- package/handles/variable.d.cts +0 -17
- package/handles/variable.d.ts +0 -17
- package/handles/variable.js +0 -7
- package/handles/workflow.cjs +0 -7
- package/handles/workflow.d.cts +0 -35
- package/handles/workflow.d.ts +0 -35
- package/handles/workflow.js +0 -7
package/index.d.ts
CHANGED
|
@@ -1,58 +1,60 @@
|
|
|
1
1
|
import { RequestOptions } from './http-client.js';
|
|
2
2
|
export { HttpClient, HttpError } from './http-client.js';
|
|
3
3
|
import { N8nClientConfig } from './types.js';
|
|
4
|
-
export { ActiveVersion, Audit, AuditAdditionalOptions, AuditRequest, AuditRiskReport, AuditRiskSection, CommunityPackage, CreateColumnRequest, CreateDataTableRequest, Credential, CredentialCreate, CredentialListItem, CredentialListResponse, CredentialResponse, CredentialSharedItem, CredentialTestResponse, CredentialUpdate, DataTable, DataTableColumn, DataTableFilter, DataTableListResponse, DataTableRow, DataTableRowListResponse, DeleteRowsBooleanParams, DeleteRowsDataParams, DeleteRowsParams, DiscoverEndpoint, DiscoverFilter, DiscoverResource, DiscoverResponse, Execution, ExecutionListResponse, ExecutionMode, ExecutionStatus, ExportWorkflowsRequest, Folder, FolderCreate, FolderDetail, FolderListResponse, FolderUpdate, ImportPackageBindings, ImportPackageConflictError, ImportPackageResponse, ImportPackageUnprocessableError, ImportPackageWorkflow, InsertRowsAllRequest, InsertRowsCountRequest, InsertRowsIdsRequest, InsertRowsRequest, InsightsMetric, InsightsSummary, InstallCommunityPackageRequest, N8nApiError, Project, ProjectListResponse, ProjectMember, ProjectMemberListResponse, PullRequest, SharedWorkflow, SourceControlledFile, StopManyExecutionsRequest, StopManyExecutionsResponse, Tag, TagId, TagListResponse, UpdateColumnRequest, UpdateDataTableRequest, UpdateRowsBooleanRequest, UpdateRowsDataRequest, UpdateRowsRequest, UpsertRowBooleanRequest, UpsertRowDataRequest, UpsertRowRequest, User, UserCreate, UserCreateResponse, UserListResponse, Variable, VariableCreate, VariableListResponse, Workflow, WorkflowCreate, WorkflowListResponse, WorkflowNode, WorkflowSettings, WorkflowUpdate, WorkflowVersion } from './types.js';
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
import
|
|
8
|
-
|
|
9
|
-
import
|
|
10
|
-
|
|
11
|
-
import
|
|
12
|
-
|
|
13
|
-
import
|
|
14
|
-
|
|
15
|
-
import
|
|
16
|
-
|
|
17
|
-
import
|
|
18
|
-
|
|
19
|
-
import
|
|
4
|
+
export { ActiveVersion, Audit, AuditAdditionalOptions, AuditCommunityLocation, AuditCredentialLocation, AuditNodeLocation, AuditRequest, AuditRisk, AuditRiskLocation, AuditRiskReport, AuditRiskSection, CommunityPackage, CommunityPackageNode, CreateColumnRequest, CreateDataTableRequest, Credential, CredentialCreate, CredentialListItem, CredentialListResponse, CredentialResponse, CredentialSharedItem, CredentialTestResponse, CredentialUpdate, DataTable, DataTableColumn, DataTableFilter, DataTableListParams, DataTableListResponse, DataTableRow, DataTableRowListParams, DataTableRowListResponse, DeleteRowsBooleanParams, DeleteRowsDataParams, DeleteRowsParams, DiscoverEndpoint, DiscoverFilter, DiscoverParams, DiscoverResource, DiscoverResponse, Execution, ExecutionGetParams, ExecutionListParams, ExecutionListResponse, ExecutionMode, ExecutionRetryRequest, ExecutionStatus, ExportWorkflowsRequest, Folder, FolderCreate, FolderDetail, FolderListParams, FolderListResponse, FolderUpdate, ImportPackageBindings, ImportPackageConflictError, ImportPackageOptions, ImportPackageResponse, ImportPackageUnprocessableError, ImportPackageWorkflow, InsertRowsAllRequest, InsertRowsCountRequest, InsertRowsIdsRequest, InsertRowsRequest, InsightsMetric, InsightsSummary, InsightsSummaryParams, InstallCommunityPackageRequest, JsonArray, JsonObject, JsonPrimitive, JsonValue, N8nApiError, Project, ProjectListResponse, ProjectMember, ProjectMemberListResponse, ProjectMemberRelation, ProjectMemberRoleChangeRequest, ProjectMutation, PullRequest, SharedWorkflow, SharedWorkflowProject, SourceControlledFile, SourceControlledOwner, StopManyExecutionsRequest, StopManyExecutionsResponse, Tag, TagId, TagListResponse, TagMutation, UpdateColumnRequest, UpdateCommunityPackageRequest, UpdateDataTableRequest, UpdateRowsBooleanRequest, UpdateRowsDataRequest, UpdateRowsRequest, UpsertRowBooleanRequest, UpsertRowDataRequest, UpsertRowRequest, User, UserCreate, UserCreateResponse, UserGetParams, UserListParams, UserListResponse, UserRoleChangeRequest, Variable, VariableCreate, VariableListParams, VariableListResponse, Workflow, WorkflowActivateRequest, WorkflowConnection, WorkflowConnectionBranch, WorkflowConnectionTypeMap, WorkflowConnections, WorkflowCreate, WorkflowGetParams, WorkflowListParams, WorkflowListResponse, WorkflowMeta, WorkflowNode, WorkflowNodeTelemetryTags, WorkflowPinData, WorkflowSettings, WorkflowTelemetryTag, WorkflowUpdate, WorkflowVersion } from './types.js';
|
|
5
|
+
import { W as WorkflowClient } from './workflow-8pMj_fR_.js';
|
|
6
|
+
export { a as WorkflowExecutionResourceCollection, b as WorkflowResource } from './workflow-8pMj_fR_.js';
|
|
7
|
+
import { E as ExecutionClient } from './execution-BjR6z5Vu.js';
|
|
8
|
+
export { a as ExecutionResource } from './execution-BjR6z5Vu.js';
|
|
9
|
+
import { C as CredentialClient } from './credential-BWcrGfqd.js';
|
|
10
|
+
export { a as CredentialResource } from './credential-BWcrGfqd.js';
|
|
11
|
+
import { T as TagClient } from './tag-lmf8obZe.js';
|
|
12
|
+
export { a as TagResource } from './tag-lmf8obZe.js';
|
|
13
|
+
import { U as UserClient } from './user-B0WdVahA.js';
|
|
14
|
+
export { a as UserResource } from './user-B0WdVahA.js';
|
|
15
|
+
import { V as VariableClient } from './variable-C2LmlaTx.js';
|
|
16
|
+
export { a as VariableResource } from './variable-C2LmlaTx.js';
|
|
17
|
+
import { P as ProjectClient } from './project-uws9k24H.js';
|
|
18
|
+
export { a as ProjectDataTableResourceCollection, b as ProjectExecutionResourceCollection, c as ProjectFolderResourceCollection, d as ProjectResource, e as ProjectVariableResourceCollection, f as ProjectWorkflowResourceCollection } from './project-uws9k24H.js';
|
|
19
|
+
import { D as DataTableClient } from './data-table-CHGUClGF.js';
|
|
20
|
+
export { a as DataTableResource } from './data-table-CHGUClGF.js';
|
|
21
|
+
import { F as FolderClient } from './folder-bjRPcy2j.js';
|
|
22
|
+
export { a as FolderResource } from './folder-bjRPcy2j.js';
|
|
23
|
+
import { C as CommunityPackageClient } from './community-package-CyzAqqwH.js';
|
|
24
|
+
export { a as CommunityPackageResource } from './community-package-CyzAqqwH.js';
|
|
25
|
+
import AuditClient from './clients/audit.js';
|
|
26
|
+
import InsightsClient from './clients/insights.js';
|
|
27
|
+
import SourceControlClient from './clients/source-control.js';
|
|
28
|
+
import DiscoverClient from './clients/discover.js';
|
|
29
|
+
import N8nPackageClient from './clients/n8n-package.js';
|
|
20
30
|
export { PaginatedResponse, PaginationParams } from './pagination.js';
|
|
31
|
+
import './clients/base.js';
|
|
32
|
+
import './resources/base.js';
|
|
21
33
|
|
|
22
34
|
declare class N8nClient {
|
|
23
35
|
#private;
|
|
24
36
|
constructor(config: N8nClientConfig);
|
|
25
37
|
request<T>(options: RequestOptions): Promise<T>;
|
|
26
|
-
get<T>(path: string, query?:
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
variable(): VariableHandle;
|
|
47
|
-
project(): ProjectHandle;
|
|
48
|
-
dataTable(): DataTableHandle;
|
|
49
|
-
folder(projectId: string): FolderHandle;
|
|
50
|
-
communityPackage(): CommunityPackageHandle;
|
|
51
|
-
audit(): AuditHandle;
|
|
52
|
-
insights(): InsightsHandle;
|
|
53
|
-
sourceControl(): SourceControlHandle;
|
|
54
|
-
discover(): DiscoverHandle;
|
|
55
|
-
n8nPackage(): N8nPackageHandle;
|
|
38
|
+
get<T>(path: string, query?: object, headers?: Record<string, string>): Promise<T>;
|
|
39
|
+
post<T>(path: string, body?: unknown, query?: object, headers?: Record<string, string>): Promise<T>;
|
|
40
|
+
put<T>(path: string, body?: unknown, query?: object, headers?: Record<string, string>): Promise<T>;
|
|
41
|
+
patch<T>(path: string, body?: unknown, query?: object, headers?: Record<string, string>): Promise<T>;
|
|
42
|
+
delete<T>(path: string, query?: object, headers?: Record<string, string>): Promise<T>;
|
|
43
|
+
workflows(): WorkflowClient;
|
|
44
|
+
executions(): ExecutionClient;
|
|
45
|
+
credentials(): CredentialClient;
|
|
46
|
+
tags(): TagClient;
|
|
47
|
+
users(): UserClient;
|
|
48
|
+
variables(): VariableClient;
|
|
49
|
+
projects(): ProjectClient;
|
|
50
|
+
dataTables(): DataTableClient;
|
|
51
|
+
folders(projectId: string): FolderClient;
|
|
52
|
+
communityPackages(): CommunityPackageClient;
|
|
53
|
+
audit(): AuditClient;
|
|
54
|
+
insights(): InsightsClient;
|
|
55
|
+
sourceControl(): SourceControlClient;
|
|
56
|
+
discover(): DiscoverClient;
|
|
57
|
+
n8nPackage(): N8nPackageClient;
|
|
56
58
|
}
|
|
57
59
|
|
|
58
60
|
export { N8nClientConfig, RequestOptions, N8nClient as default };
|
package/index.js
CHANGED
|
@@ -1,53 +1,85 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
TagClient
|
|
3
|
+
} from "./chunk-PT5DDLHC.js";
|
|
4
4
|
import {
|
|
5
|
-
|
|
6
|
-
} from "./chunk-
|
|
5
|
+
TagResource
|
|
6
|
+
} from "./chunk-4VK7K4IF.js";
|
|
7
7
|
import {
|
|
8
|
-
|
|
9
|
-
} from "./chunk-
|
|
8
|
+
UserClient
|
|
9
|
+
} from "./chunk-USTEEQQG.js";
|
|
10
10
|
import {
|
|
11
|
-
|
|
12
|
-
} from "./chunk-
|
|
11
|
+
UserResource
|
|
12
|
+
} from "./chunk-L2FFL3BY.js";
|
|
13
13
|
import {
|
|
14
|
-
|
|
15
|
-
} from "./chunk-
|
|
14
|
+
DiscoverClient
|
|
15
|
+
} from "./chunk-F5RPJMNK.js";
|
|
16
16
|
import {
|
|
17
|
-
|
|
18
|
-
} from "./chunk-
|
|
17
|
+
InsightsClient
|
|
18
|
+
} from "./chunk-NS2RDZ7W.js";
|
|
19
19
|
import {
|
|
20
|
-
|
|
21
|
-
} from "./chunk-
|
|
20
|
+
N8nPackageClient
|
|
21
|
+
} from "./chunk-ZVZIMJRM.js";
|
|
22
22
|
import {
|
|
23
|
-
|
|
24
|
-
} from "./chunk-
|
|
23
|
+
ProjectClient
|
|
24
|
+
} from "./chunk-3FDDCKAY.js";
|
|
25
25
|
import {
|
|
26
|
-
|
|
27
|
-
} from "./chunk-
|
|
26
|
+
ProjectResource
|
|
27
|
+
} from "./chunk-LTYQTCHM.js";
|
|
28
28
|
import {
|
|
29
|
-
|
|
30
|
-
} from "./chunk-
|
|
29
|
+
VariableClient
|
|
30
|
+
} from "./chunk-HISH4ORK.js";
|
|
31
31
|
import {
|
|
32
|
-
|
|
33
|
-
} from "./chunk-
|
|
32
|
+
VariableResource
|
|
33
|
+
} from "./chunk-2R6A6NJE.js";
|
|
34
|
+
import {
|
|
35
|
+
WorkflowClient
|
|
36
|
+
} from "./chunk-54N6YD4R.js";
|
|
37
|
+
import {
|
|
38
|
+
WorkflowResource
|
|
39
|
+
} from "./chunk-I4MMTW33.js";
|
|
40
|
+
import {
|
|
41
|
+
DataTableClient
|
|
42
|
+
} from "./chunk-BQ2OTUXQ.js";
|
|
43
|
+
import {
|
|
44
|
+
DataTableResource
|
|
45
|
+
} from "./chunk-T62VHXNY.js";
|
|
46
|
+
import {
|
|
47
|
+
ExecutionClient
|
|
48
|
+
} from "./chunk-C6W6ERQD.js";
|
|
49
|
+
import {
|
|
50
|
+
ExecutionResource
|
|
51
|
+
} from "./chunk-S4ZASMBT.js";
|
|
52
|
+
import {
|
|
53
|
+
FolderClient
|
|
54
|
+
} from "./chunk-5DDMSYH2.js";
|
|
55
|
+
import {
|
|
56
|
+
FolderResource
|
|
57
|
+
} from "./chunk-YE2OS2KS.js";
|
|
58
|
+
import {
|
|
59
|
+
SourceControlClient
|
|
60
|
+
} from "./chunk-OUOWDGL7.js";
|
|
61
|
+
import {
|
|
62
|
+
AuditClient
|
|
63
|
+
} from "./chunk-YUCX7HE3.js";
|
|
64
|
+
import {
|
|
65
|
+
CommunityPackageClient
|
|
66
|
+
} from "./chunk-ETVDSJLY.js";
|
|
67
|
+
import {
|
|
68
|
+
CommunityPackageResource
|
|
69
|
+
} from "./chunk-YHSDCE3I.js";
|
|
34
70
|
import {
|
|
35
71
|
HttpClient,
|
|
36
72
|
HttpError
|
|
37
|
-
} from "./chunk-
|
|
73
|
+
} from "./chunk-RMEH2UPX.js";
|
|
38
74
|
import "./chunk-DURH6QOX.js";
|
|
39
75
|
import {
|
|
40
|
-
|
|
41
|
-
} from "./chunk-
|
|
42
|
-
import {
|
|
43
|
-
CommunityPackageHandle
|
|
44
|
-
} from "./chunk-5FIB7YIT.js";
|
|
45
|
-
import {
|
|
46
|
-
CredentialHandle
|
|
47
|
-
} from "./chunk-BWLFUF76.js";
|
|
76
|
+
CredentialClient
|
|
77
|
+
} from "./chunk-QJR4WFNV.js";
|
|
48
78
|
import {
|
|
49
|
-
|
|
50
|
-
} from "./chunk-
|
|
79
|
+
CredentialResource
|
|
80
|
+
} from "./chunk-XJP6FPN3.js";
|
|
81
|
+
import "./chunk-TLBDBRPJ.js";
|
|
82
|
+
import "./chunk-Q6FSREKN.js";
|
|
51
83
|
|
|
52
84
|
// src/index.ts
|
|
53
85
|
var N8nClient = class {
|
|
@@ -73,55 +105,65 @@ var N8nClient = class {
|
|
|
73
105
|
delete(path, query, headers) {
|
|
74
106
|
return this.#http.delete(path, query, headers);
|
|
75
107
|
}
|
|
76
|
-
|
|
77
|
-
return new
|
|
108
|
+
workflows() {
|
|
109
|
+
return new WorkflowClient(this.#http);
|
|
78
110
|
}
|
|
79
|
-
|
|
80
|
-
return new
|
|
111
|
+
executions() {
|
|
112
|
+
return new ExecutionClient(this.#http);
|
|
81
113
|
}
|
|
82
|
-
|
|
83
|
-
return new
|
|
114
|
+
credentials() {
|
|
115
|
+
return new CredentialClient(this.#http);
|
|
84
116
|
}
|
|
85
|
-
|
|
86
|
-
return new
|
|
117
|
+
tags() {
|
|
118
|
+
return new TagClient(this.#http);
|
|
87
119
|
}
|
|
88
|
-
|
|
89
|
-
return new
|
|
120
|
+
users() {
|
|
121
|
+
return new UserClient(this.#http);
|
|
90
122
|
}
|
|
91
|
-
|
|
92
|
-
return new
|
|
123
|
+
variables() {
|
|
124
|
+
return new VariableClient(this.#http);
|
|
93
125
|
}
|
|
94
|
-
|
|
95
|
-
return new
|
|
126
|
+
projects() {
|
|
127
|
+
return new ProjectClient(this.#http);
|
|
96
128
|
}
|
|
97
|
-
|
|
98
|
-
return new
|
|
129
|
+
dataTables() {
|
|
130
|
+
return new DataTableClient(this.#http);
|
|
99
131
|
}
|
|
100
|
-
|
|
101
|
-
return new
|
|
132
|
+
folders(projectId) {
|
|
133
|
+
return new FolderClient(this.#http, projectId);
|
|
102
134
|
}
|
|
103
|
-
|
|
104
|
-
return new
|
|
135
|
+
communityPackages() {
|
|
136
|
+
return new CommunityPackageClient(this.#http);
|
|
105
137
|
}
|
|
106
138
|
audit() {
|
|
107
|
-
return new
|
|
139
|
+
return new AuditClient(this.#http);
|
|
108
140
|
}
|
|
109
141
|
insights() {
|
|
110
|
-
return new
|
|
142
|
+
return new InsightsClient(this.#http);
|
|
111
143
|
}
|
|
112
144
|
sourceControl() {
|
|
113
|
-
return new
|
|
145
|
+
return new SourceControlClient(this.#http);
|
|
114
146
|
}
|
|
115
147
|
discover() {
|
|
116
|
-
return new
|
|
148
|
+
return new DiscoverClient(this.#http);
|
|
117
149
|
}
|
|
118
150
|
n8nPackage() {
|
|
119
|
-
return new
|
|
151
|
+
return new N8nPackageClient(this.#http);
|
|
120
152
|
}
|
|
121
153
|
};
|
|
122
154
|
export {
|
|
155
|
+
CommunityPackageResource,
|
|
156
|
+
CredentialResource,
|
|
157
|
+
DataTableResource,
|
|
158
|
+
ExecutionResource,
|
|
159
|
+
FolderResource,
|
|
123
160
|
HttpClient,
|
|
124
161
|
HttpError,
|
|
162
|
+
ProjectResource,
|
|
163
|
+
TagResource,
|
|
164
|
+
UserResource,
|
|
165
|
+
VariableResource,
|
|
166
|
+
WorkflowResource,
|
|
125
167
|
N8nClient as default
|
|
126
168
|
};
|
|
127
169
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "0.
|
|
2
|
+
"version": "0.2.0",
|
|
3
3
|
"description": "TypeScript client for the n8n Public API with cursor-based pagination and typed resource handles.",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"n8n",
|
|
@@ -10,24 +10,13 @@
|
|
|
10
10
|
"client",
|
|
11
11
|
"api-client"
|
|
12
12
|
],
|
|
13
|
+
"author": "J.Dev",
|
|
14
|
+
"license": "Apache-2.0",
|
|
15
|
+
"sideEffects": false,
|
|
13
16
|
"files": [
|
|
14
17
|
"**/*",
|
|
15
18
|
"!**/*.map"
|
|
16
19
|
],
|
|
17
|
-
"homepage": "https://n8n-client.pages.dev/",
|
|
18
|
-
"bugs": {
|
|
19
|
-
"url": "https://github.com/egose/n8n-client/issues"
|
|
20
|
-
},
|
|
21
|
-
"license": "Apache-2.0",
|
|
22
|
-
"author": "J.Dev",
|
|
23
|
-
"sideEffects": false,
|
|
24
|
-
"repository": {
|
|
25
|
-
"type": "git",
|
|
26
|
-
"url": "https://github.com/egose/n8n-client"
|
|
27
|
-
},
|
|
28
|
-
"engines": {
|
|
29
|
-
"node": ">=20"
|
|
30
|
-
},
|
|
31
20
|
"main": "./index.cjs",
|
|
32
21
|
"module": "./index.js",
|
|
33
22
|
"types": "./index.d.ts",
|
|
@@ -38,5 +27,16 @@
|
|
|
38
27
|
"import": "./index.js"
|
|
39
28
|
}
|
|
40
29
|
},
|
|
30
|
+
"repository": {
|
|
31
|
+
"type": "git",
|
|
32
|
+
"url": "https://github.com/egose/n8n-client"
|
|
33
|
+
},
|
|
34
|
+
"bugs": {
|
|
35
|
+
"url": "https://github.com/egose/n8n-client/issues"
|
|
36
|
+
},
|
|
37
|
+
"homepage": "https://n8n-client.pages.dev/",
|
|
38
|
+
"engines": {
|
|
39
|
+
"node": ">=20"
|
|
40
|
+
},
|
|
41
41
|
"name": "@egose/n8n-client"
|
|
42
|
-
}
|
|
42
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { PaginationParams, PaginatedResponse } from './pagination.cjs';
|
|
2
|
+
import { Project, ProjectMutation, ProjectMemberListResponse, ProjectMemberRelation, WorkflowListParams, WorkflowListResponse, Workflow, WorkflowCreate, WorkflowUpdate, FolderListParams, FolderListResponse, FolderCreate, Folder, FolderDetail, FolderUpdate, VariableListParams, VariableListResponse, Variable, VariableCreate, DataTable, CreateDataTableRequest, UpdateDataTableRequest, ExecutionListParams, ExecutionListResponse, ExecutionGetParams, Execution, ProjectListResponse } from './types.cjs';
|
|
3
|
+
import BaseClient from './clients/base.cjs';
|
|
4
|
+
import { D as DataTableClient, a as DataTableResource } from './data-table-CzR5kl9T.cjs';
|
|
5
|
+
import { E as ExecutionClient, a as ExecutionResource } from './execution-C0c9utwa.cjs';
|
|
6
|
+
import { F as FolderClient, a as FolderResource } from './folder-DvgIxSea.cjs';
|
|
7
|
+
import { V as VariableClient, a as VariableResource } from './variable-CuCiwy0G.cjs';
|
|
8
|
+
import { W as WorkflowClient, b as WorkflowResource } from './workflow-B2nxUmWq.cjs';
|
|
9
|
+
import BaseResource from './resources/base.cjs';
|
|
10
|
+
|
|
11
|
+
interface ProjectWorkflowResourceCollection {
|
|
12
|
+
list(params?: Omit<WorkflowListParams, 'projectId'>): Promise<WorkflowListResponse>;
|
|
13
|
+
listResources(params?: Omit<WorkflowListParams, 'projectId'>): Promise<PaginatedResponse<WorkflowResource>>;
|
|
14
|
+
get(id: string): Promise<Workflow>;
|
|
15
|
+
getResource(id: string): Promise<WorkflowResource>;
|
|
16
|
+
createResource(data: Omit<WorkflowCreate, 'projectId'>): Promise<WorkflowResource>;
|
|
17
|
+
create(data: Omit<WorkflowCreate, 'projectId'>): Promise<Workflow>;
|
|
18
|
+
update(id: string, data: WorkflowUpdate): Promise<Workflow>;
|
|
19
|
+
updateResource(id: string, data: WorkflowUpdate): Promise<WorkflowResource>;
|
|
20
|
+
}
|
|
21
|
+
interface ProjectFolderResourceCollection {
|
|
22
|
+
list(params?: FolderListParams): Promise<FolderListResponse>;
|
|
23
|
+
listResources(params?: FolderListParams): Promise<PaginatedResponse<FolderResource>>;
|
|
24
|
+
getResource(id: string): Promise<FolderResource>;
|
|
25
|
+
createResource(data: FolderCreate): Promise<FolderResource>;
|
|
26
|
+
create(data: FolderCreate): Promise<Folder>;
|
|
27
|
+
get(id: string): Promise<FolderDetail>;
|
|
28
|
+
update(id: string, data: FolderUpdate): Promise<Folder>;
|
|
29
|
+
updateResource(id: string, data: FolderUpdate): Promise<FolderResource>;
|
|
30
|
+
delete(id: string, transferToFolderId?: string): Promise<void>;
|
|
31
|
+
}
|
|
32
|
+
interface ProjectVariableResourceCollection {
|
|
33
|
+
list(params?: Omit<VariableListParams, 'projectId'>): Promise<VariableListResponse>;
|
|
34
|
+
listResources(params?: Omit<VariableListParams, 'projectId'>): Promise<PaginatedResponse<VariableResource>>;
|
|
35
|
+
get(id: string): Promise<Variable>;
|
|
36
|
+
getResource(id: string): Promise<VariableResource>;
|
|
37
|
+
create(data: Omit<VariableCreate, 'projectId'>): Promise<void>;
|
|
38
|
+
update(id: string, data: Omit<VariableCreate, 'projectId'>): Promise<void>;
|
|
39
|
+
updateResource(id: string, data: Omit<VariableCreate, 'projectId'>): Promise<VariableResource>;
|
|
40
|
+
delete(id: string): Promise<void>;
|
|
41
|
+
}
|
|
42
|
+
interface ProjectDataTableResourceCollection {
|
|
43
|
+
get(id: string): Promise<DataTable>;
|
|
44
|
+
getResource(id: string): Promise<DataTableResource>;
|
|
45
|
+
create(data: Omit<CreateDataTableRequest, 'projectId'>): Promise<DataTable>;
|
|
46
|
+
createResource(data: Omit<CreateDataTableRequest, 'projectId'>): Promise<DataTableResource>;
|
|
47
|
+
update(id: string, data: UpdateDataTableRequest): Promise<DataTable>;
|
|
48
|
+
updateResource(id: string, data: UpdateDataTableRequest): Promise<DataTableResource>;
|
|
49
|
+
delete(id: string): Promise<void>;
|
|
50
|
+
}
|
|
51
|
+
interface ProjectExecutionResourceCollection {
|
|
52
|
+
list(params?: Omit<ExecutionListParams, 'projectId'>): Promise<ExecutionListResponse>;
|
|
53
|
+
listResources(params?: Omit<ExecutionListParams, 'projectId'>): Promise<PaginatedResponse<ExecutionResource>>;
|
|
54
|
+
get(id: number, params?: ExecutionGetParams): Promise<Execution>;
|
|
55
|
+
getResource(id: number, params?: ExecutionGetParams): Promise<ExecutionResource>;
|
|
56
|
+
}
|
|
57
|
+
declare class ProjectResource extends BaseResource<Project> {
|
|
58
|
+
private readonly projects;
|
|
59
|
+
private readonly relations;
|
|
60
|
+
constructor(projects: ProjectClient, workflowsClient: WorkflowClient, foldersClient: FolderClient, variablesClient: VariableClient, dataTablesClient: DataTableClient, executionsClient: ExecutionClient, project: Project);
|
|
61
|
+
get id(): string;
|
|
62
|
+
get name(): string;
|
|
63
|
+
get type(): string | undefined;
|
|
64
|
+
update(data: ProjectMutation): Promise<this>;
|
|
65
|
+
delete(): Promise<void>;
|
|
66
|
+
listMembers(params?: PaginationParams): Promise<ProjectMemberListResponse>;
|
|
67
|
+
addMembers(relations: ProjectMemberRelation[]): Promise<void>;
|
|
68
|
+
removeMember(userId: string): Promise<void>;
|
|
69
|
+
changeMemberRole(userId: string, role: string): Promise<void>;
|
|
70
|
+
workflows(): ProjectWorkflowResourceCollection;
|
|
71
|
+
folders(): ProjectFolderResourceCollection;
|
|
72
|
+
variables(): ProjectVariableResourceCollection;
|
|
73
|
+
dataTables(): ProjectDataTableResourceCollection;
|
|
74
|
+
executions(): ProjectExecutionResourceCollection;
|
|
75
|
+
private getProjectDataTableOrThrow;
|
|
76
|
+
private hasResourceInProject;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
declare class ProjectClient extends BaseClient {
|
|
80
|
+
list(params?: PaginationParams): Promise<ProjectListResponse>;
|
|
81
|
+
getResource(id: string): Promise<ProjectResource>;
|
|
82
|
+
listResources(params?: PaginationParams): Promise<PaginatedResponse<ProjectResource>>;
|
|
83
|
+
create(data: ProjectMutation): Promise<void>;
|
|
84
|
+
update(id: string, data: ProjectMutation): Promise<void>;
|
|
85
|
+
delete(id: string): Promise<void>;
|
|
86
|
+
listMembers(projectId: string, params?: PaginationParams): Promise<ProjectMemberListResponse>;
|
|
87
|
+
addMembers(projectId: string, relations: ProjectMemberRelation[]): Promise<void>;
|
|
88
|
+
removeMember(projectId: string, userId: string): Promise<void>;
|
|
89
|
+
changeMemberRole(projectId: string, userId: string, role: string): Promise<void>;
|
|
90
|
+
private createResource;
|
|
91
|
+
private findProject;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export { ProjectClient as P, type ProjectDataTableResourceCollection as a, type ProjectExecutionResourceCollection as b, type ProjectFolderResourceCollection as c, ProjectResource as d, type ProjectVariableResourceCollection as e, type ProjectWorkflowResourceCollection as f };
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { PaginationParams, PaginatedResponse } from './pagination.js';
|
|
2
|
+
import { Project, ProjectMutation, ProjectMemberListResponse, ProjectMemberRelation, WorkflowListParams, WorkflowListResponse, Workflow, WorkflowCreate, WorkflowUpdate, FolderListParams, FolderListResponse, FolderCreate, Folder, FolderDetail, FolderUpdate, VariableListParams, VariableListResponse, Variable, VariableCreate, DataTable, CreateDataTableRequest, UpdateDataTableRequest, ExecutionListParams, ExecutionListResponse, ExecutionGetParams, Execution, ProjectListResponse } from './types.js';
|
|
3
|
+
import BaseClient from './clients/base.js';
|
|
4
|
+
import { D as DataTableClient, a as DataTableResource } from './data-table-CHGUClGF.js';
|
|
5
|
+
import { E as ExecutionClient, a as ExecutionResource } from './execution-BjR6z5Vu.js';
|
|
6
|
+
import { F as FolderClient, a as FolderResource } from './folder-bjRPcy2j.js';
|
|
7
|
+
import { V as VariableClient, a as VariableResource } from './variable-C2LmlaTx.js';
|
|
8
|
+
import { W as WorkflowClient, b as WorkflowResource } from './workflow-8pMj_fR_.js';
|
|
9
|
+
import BaseResource from './resources/base.js';
|
|
10
|
+
|
|
11
|
+
interface ProjectWorkflowResourceCollection {
|
|
12
|
+
list(params?: Omit<WorkflowListParams, 'projectId'>): Promise<WorkflowListResponse>;
|
|
13
|
+
listResources(params?: Omit<WorkflowListParams, 'projectId'>): Promise<PaginatedResponse<WorkflowResource>>;
|
|
14
|
+
get(id: string): Promise<Workflow>;
|
|
15
|
+
getResource(id: string): Promise<WorkflowResource>;
|
|
16
|
+
createResource(data: Omit<WorkflowCreate, 'projectId'>): Promise<WorkflowResource>;
|
|
17
|
+
create(data: Omit<WorkflowCreate, 'projectId'>): Promise<Workflow>;
|
|
18
|
+
update(id: string, data: WorkflowUpdate): Promise<Workflow>;
|
|
19
|
+
updateResource(id: string, data: WorkflowUpdate): Promise<WorkflowResource>;
|
|
20
|
+
}
|
|
21
|
+
interface ProjectFolderResourceCollection {
|
|
22
|
+
list(params?: FolderListParams): Promise<FolderListResponse>;
|
|
23
|
+
listResources(params?: FolderListParams): Promise<PaginatedResponse<FolderResource>>;
|
|
24
|
+
getResource(id: string): Promise<FolderResource>;
|
|
25
|
+
createResource(data: FolderCreate): Promise<FolderResource>;
|
|
26
|
+
create(data: FolderCreate): Promise<Folder>;
|
|
27
|
+
get(id: string): Promise<FolderDetail>;
|
|
28
|
+
update(id: string, data: FolderUpdate): Promise<Folder>;
|
|
29
|
+
updateResource(id: string, data: FolderUpdate): Promise<FolderResource>;
|
|
30
|
+
delete(id: string, transferToFolderId?: string): Promise<void>;
|
|
31
|
+
}
|
|
32
|
+
interface ProjectVariableResourceCollection {
|
|
33
|
+
list(params?: Omit<VariableListParams, 'projectId'>): Promise<VariableListResponse>;
|
|
34
|
+
listResources(params?: Omit<VariableListParams, 'projectId'>): Promise<PaginatedResponse<VariableResource>>;
|
|
35
|
+
get(id: string): Promise<Variable>;
|
|
36
|
+
getResource(id: string): Promise<VariableResource>;
|
|
37
|
+
create(data: Omit<VariableCreate, 'projectId'>): Promise<void>;
|
|
38
|
+
update(id: string, data: Omit<VariableCreate, 'projectId'>): Promise<void>;
|
|
39
|
+
updateResource(id: string, data: Omit<VariableCreate, 'projectId'>): Promise<VariableResource>;
|
|
40
|
+
delete(id: string): Promise<void>;
|
|
41
|
+
}
|
|
42
|
+
interface ProjectDataTableResourceCollection {
|
|
43
|
+
get(id: string): Promise<DataTable>;
|
|
44
|
+
getResource(id: string): Promise<DataTableResource>;
|
|
45
|
+
create(data: Omit<CreateDataTableRequest, 'projectId'>): Promise<DataTable>;
|
|
46
|
+
createResource(data: Omit<CreateDataTableRequest, 'projectId'>): Promise<DataTableResource>;
|
|
47
|
+
update(id: string, data: UpdateDataTableRequest): Promise<DataTable>;
|
|
48
|
+
updateResource(id: string, data: UpdateDataTableRequest): Promise<DataTableResource>;
|
|
49
|
+
delete(id: string): Promise<void>;
|
|
50
|
+
}
|
|
51
|
+
interface ProjectExecutionResourceCollection {
|
|
52
|
+
list(params?: Omit<ExecutionListParams, 'projectId'>): Promise<ExecutionListResponse>;
|
|
53
|
+
listResources(params?: Omit<ExecutionListParams, 'projectId'>): Promise<PaginatedResponse<ExecutionResource>>;
|
|
54
|
+
get(id: number, params?: ExecutionGetParams): Promise<Execution>;
|
|
55
|
+
getResource(id: number, params?: ExecutionGetParams): Promise<ExecutionResource>;
|
|
56
|
+
}
|
|
57
|
+
declare class ProjectResource extends BaseResource<Project> {
|
|
58
|
+
private readonly projects;
|
|
59
|
+
private readonly relations;
|
|
60
|
+
constructor(projects: ProjectClient, workflowsClient: WorkflowClient, foldersClient: FolderClient, variablesClient: VariableClient, dataTablesClient: DataTableClient, executionsClient: ExecutionClient, project: Project);
|
|
61
|
+
get id(): string;
|
|
62
|
+
get name(): string;
|
|
63
|
+
get type(): string | undefined;
|
|
64
|
+
update(data: ProjectMutation): Promise<this>;
|
|
65
|
+
delete(): Promise<void>;
|
|
66
|
+
listMembers(params?: PaginationParams): Promise<ProjectMemberListResponse>;
|
|
67
|
+
addMembers(relations: ProjectMemberRelation[]): Promise<void>;
|
|
68
|
+
removeMember(userId: string): Promise<void>;
|
|
69
|
+
changeMemberRole(userId: string, role: string): Promise<void>;
|
|
70
|
+
workflows(): ProjectWorkflowResourceCollection;
|
|
71
|
+
folders(): ProjectFolderResourceCollection;
|
|
72
|
+
variables(): ProjectVariableResourceCollection;
|
|
73
|
+
dataTables(): ProjectDataTableResourceCollection;
|
|
74
|
+
executions(): ProjectExecutionResourceCollection;
|
|
75
|
+
private getProjectDataTableOrThrow;
|
|
76
|
+
private hasResourceInProject;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
declare class ProjectClient extends BaseClient {
|
|
80
|
+
list(params?: PaginationParams): Promise<ProjectListResponse>;
|
|
81
|
+
getResource(id: string): Promise<ProjectResource>;
|
|
82
|
+
listResources(params?: PaginationParams): Promise<PaginatedResponse<ProjectResource>>;
|
|
83
|
+
create(data: ProjectMutation): Promise<void>;
|
|
84
|
+
update(id: string, data: ProjectMutation): Promise<void>;
|
|
85
|
+
delete(id: string): Promise<void>;
|
|
86
|
+
listMembers(projectId: string, params?: PaginationParams): Promise<ProjectMemberListResponse>;
|
|
87
|
+
addMembers(projectId: string, relations: ProjectMemberRelation[]): Promise<void>;
|
|
88
|
+
removeMember(projectId: string, userId: string): Promise<void>;
|
|
89
|
+
changeMemberRole(projectId: string, userId: string, role: string): Promise<void>;
|
|
90
|
+
private createResource;
|
|
91
|
+
private findProject;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export { ProjectClient as P, type ProjectDataTableResourceCollection as a, type ProjectExecutionResourceCollection as b, type ProjectFolderResourceCollection as c, ProjectResource as d, type ProjectVariableResourceCollection as e, type ProjectWorkflowResourceCollection as f };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
declare abstract class BaseResource<TData> {
|
|
2
|
+
private snapshot;
|
|
3
|
+
constructor(snapshot: TData);
|
|
4
|
+
get data(): TData;
|
|
5
|
+
toObject(): TData;
|
|
6
|
+
toJSON(): TData;
|
|
7
|
+
protected replaceSnapshot(data: TData): this;
|
|
8
|
+
protected mergeSnapshot(data: Partial<TData>): this;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export { BaseResource as default };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
declare abstract class BaseResource<TData> {
|
|
2
|
+
private snapshot;
|
|
3
|
+
constructor(snapshot: TData);
|
|
4
|
+
get data(): TData;
|
|
5
|
+
toObject(): TData;
|
|
6
|
+
toJSON(): TData;
|
|
7
|
+
protected replaceSnapshot(data: TData): this;
|
|
8
|
+
protected mergeSnapshot(data: Partial<TData>): this;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export { BaseResource as default };
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
var _chunkTY76RTXQcjs = require('../chunk-TY76RTXQ.cjs');
|
|
4
|
+
require('../chunk-FIKGC2EL.cjs');
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
exports.default = _chunkTY76RTXQcjs.CommunityPackageResource;
|
|
8
|
+
//# sourceMappingURL=community-package.cjs.map
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
var _chunkMMN2UKTIcjs = require('../chunk-MMN2UKTI.cjs');
|
|
4
|
+
require('../chunk-FIKGC2EL.cjs');
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
exports.default = _chunkMMN2UKTIcjs.CredentialResource;
|
|
8
|
+
//# sourceMappingURL=credential.cjs.map
|