npm build successful

This commit is contained in:
atharva.dev 2025-10-22 10:14:14 +00:00
parent 23179f4513
commit 9f6db09edf
4 changed files with 214 additions and 212 deletions

2
.gitignore vendored
View File

@ -1,2 +1,4 @@
dist
node_modules
package-lock.json
.n8n/.env

View File

@ -123,12 +123,7 @@ export class SecloreProtect implements INodeType {
const tenantSecret = credentials.tenantSecret as string;
// Initialize the file service
const fileService = new SecloreDRMFileService(
this,
baseUrl,
tenantId,
tenantSecret
);
const fileService = new SecloreDRMFileService(this, baseUrl, tenantId, tenantSecret);
// Get node parameters
const operation = this.getNodeParameter('operation', 0) as string;
@ -139,7 +134,10 @@ export class SecloreProtect implements INodeType {
// Get parameters for this item
const hotfolderId = this.getNodeParameter('hotfolderId', i) as string;
const binaryPropertyName = this.getNodeParameter('binaryPropertyName', i) as string;
const outputBinaryPropertyName = this.getNodeParameter('outputBinaryPropertyName', i) as string;
const outputBinaryPropertyName = this.getNodeParameter(
'outputBinaryPropertyName',
i,
) as string;
const correlationId = this.getNodeParameter('correlationId', i) as string;
const retryCount = this.getNodeParameter('retryCount', i) as number;
@ -159,7 +157,7 @@ export class SecloreProtect implements INodeType {
new Uint8Array(fileBuffer),
binaryData.fileName || 'file',
correlationId || undefined,
retryCount
retryCount,
);
// Protect the uploaded file with HotFolder
@ -169,21 +167,21 @@ export class SecloreProtect implements INodeType {
fileStorageId: uploadResult.fileStorageId,
},
correlationId || undefined,
retryCount
retryCount,
);
// Download the protected file
const protectedFileData = await fileService.downloadFile(
protectResult.fileStorageId,
correlationId || undefined,
retryCount
retryCount,
);
// Create output binary data
const outputBinaryData = await this.helpers.prepareBinaryData(
protectedFileData.buffer,
Buffer.from(protectedFileData),
binaryData.fileName || 'protected_file',
binaryData.mimeType
binaryData.mimeType,
);
// Create return item with binary data and metadata

View File

@ -1,15 +1,15 @@
{
"name": "n8n-nodes-secloreprotect",
"version": "0.1.0",
"description": "",
"description": "n8n community node for Seclore Protect - secure file protection using DRM technology",
"license": "MIT",
"homepage": "",
"keywords": [
"n8n-community-node-package"
],
"author": {
"name": "",
"email": ""
"name": "Seclore Technology",
"email": "support@seclore.com"
},
"repository": {
"type": "git",
@ -39,6 +39,7 @@
},
"devDependencies": {
"@n8n/node-cli": "*",
"@types/node": "^24.9.1",
"eslint": "9.32.0",
"prettier": "3.6.2",
"release-it": "^19.0.4",

View File

@ -19,7 +19,8 @@
"declaration": true,
"sourceMap": true,
"skipLibCheck": true,
"outDir": "./dist/"
"outDir": "./dist/",
"types": ["node"]
},
"include": ["credentials/**/*", "nodes/**/*", "nodes/**/*.json", "package.json"]
}