@jnymmt/n8n-nodes-ffmpeg 0.1.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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 yambal
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,64 @@
1
+ # n8n-nodes-ffmpeg
2
+
3
+ [n8n](https://n8n.io/) コミュニティノード。ワークフロー内で [FFmpeg](https://ffmpeg.org/) を使って音声ファイルを変換します。
4
+
5
+ ## 前提条件
6
+
7
+ n8n が動作する環境に `ffmpeg` コマンドがインストールされている必要があります。
8
+
9
+ ## インストール
10
+
11
+ n8n の Settings > Community Nodes で以下を入力してインストール:
12
+
13
+ ```
14
+ n8n-nodes-ffmpeg
15
+ ```
16
+
17
+ ## オペレーション
18
+
19
+ ### Convert(フォーマット変換)
20
+
21
+ 音声ファイルを別のフォーマットに変換します。
22
+
23
+ | パラメータ | 説明 | デフォルト |
24
+ |---|---|---|
25
+ | Output Format | 出力フォーマット(MP3, WAV, OGG, FLAC, AAC, M4A) | MP3 |
26
+ | Bitrate (option) | 出力ビットレート(64k〜320k) | Auto |
27
+ | Sample Rate (option) | サンプルレート(22050, 44100, 48000 Hz) | Auto |
28
+
29
+ ### Change Bitrate(ビットレート変換)
30
+
31
+ 音声ファイルのビットレートを変更します(フォーマットはそのまま)。
32
+
33
+ | パラメータ | 説明 | デフォルト |
34
+ |---|---|---|
35
+ | Bitrate | 出力ビットレート(64k〜320k) | 128k |
36
+
37
+ ## 共通パラメータ
38
+
39
+ | パラメータ | 説明 | デフォルト |
40
+ |---|---|---|
41
+ | Binary Property | 入力バイナリデータのプロパティ名 | `data` |
42
+ | Output Binary Property | 出力バイナリデータのプロパティ名 | `data` |
43
+
44
+ ## 使用例
45
+
46
+ ### WAV を MP3 128kbps に変換
47
+
48
+ 1. **Read Binary File** ノード: WAV ファイルを読み込み
49
+ 2. **FFmpeg** ノード: Operation = Convert, Output Format = MP3, Bitrate = 128k
50
+ 3. **Write Binary File** ノード: 変換後のファイルを保存
51
+
52
+ ## 互換性
53
+
54
+ - n8n 1.0+
55
+ - FFmpeg が n8n 実行環境にインストール済みであること
56
+
57
+ ## リンク
58
+
59
+ - [npm](https://www.npmjs.com/package/n8n-nodes-ffmpeg)
60
+ - [GitHub](https://github.com/yambal/n8n-node-ffmpeg)
61
+
62
+ ## ライセンス
63
+
64
+ MIT
@@ -0,0 +1,5 @@
1
+ import { IExecuteFunctions, INodeExecutionData, INodeType, INodeTypeDescription } from 'n8n-workflow';
2
+ export declare class Ffmpeg implements INodeType {
3
+ description: INodeTypeDescription;
4
+ execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]>;
5
+ }
@@ -0,0 +1,259 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Ffmpeg = void 0;
4
+ const n8n_workflow_1 = require("n8n-workflow");
5
+ const child_process_1 = require("child_process");
6
+ const util_1 = require("util");
7
+ const promises_1 = require("fs/promises");
8
+ const os_1 = require("os");
9
+ const path_1 = require("path");
10
+ const crypto_1 = require("crypto");
11
+ const execFileAsync = (0, util_1.promisify)(child_process_1.execFile);
12
+ const MIME_TYPES = {
13
+ mp3: 'audio/mpeg',
14
+ wav: 'audio/wav',
15
+ ogg: 'audio/ogg',
16
+ flac: 'audio/flac',
17
+ aac: 'audio/aac',
18
+ m4a: 'audio/mp4',
19
+ };
20
+ class Ffmpeg {
21
+ constructor() {
22
+ this.description = {
23
+ displayName: 'FFmpeg',
24
+ name: 'ffmpeg',
25
+ icon: 'file:ffmpeg.svg',
26
+ group: ['transform'],
27
+ version: 1,
28
+ subtitle: '={{$parameter["operation"]}}',
29
+ description: 'Convert audio files using FFmpeg',
30
+ defaults: {
31
+ name: 'FFmpeg',
32
+ },
33
+ inputs: ['main'],
34
+ outputs: ['main'],
35
+ properties: [
36
+ {
37
+ displayName: 'Operation',
38
+ name: 'operation',
39
+ type: 'options',
40
+ noDataExpression: true,
41
+ options: [
42
+ {
43
+ name: 'Convert',
44
+ value: 'convert',
45
+ description: 'Convert audio to a different format',
46
+ action: 'Convert audio format',
47
+ },
48
+ {
49
+ name: 'Change Bitrate',
50
+ value: 'changeBitrate',
51
+ description: 'Change audio bitrate',
52
+ action: 'Change audio bitrate',
53
+ },
54
+ ],
55
+ default: 'convert',
56
+ },
57
+ {
58
+ displayName: 'Binary Property',
59
+ name: 'binaryPropertyName',
60
+ type: 'string',
61
+ default: 'data',
62
+ description: 'Name of the binary property containing the input audio file',
63
+ },
64
+ {
65
+ displayName: 'Output Format',
66
+ name: 'outputFormat',
67
+ type: 'options',
68
+ options: [
69
+ { name: 'MP3', value: 'mp3' },
70
+ { name: 'WAV', value: 'wav' },
71
+ { name: 'OGG', value: 'ogg' },
72
+ { name: 'FLAC', value: 'flac' },
73
+ { name: 'AAC', value: 'aac' },
74
+ { name: 'M4A', value: 'm4a' },
75
+ ],
76
+ default: 'mp3',
77
+ description: 'Output audio format',
78
+ displayOptions: {
79
+ show: {
80
+ operation: ['convert'],
81
+ },
82
+ },
83
+ },
84
+ {
85
+ displayName: 'Bitrate',
86
+ name: 'bitrate',
87
+ type: 'options',
88
+ options: [
89
+ { name: '64 kbps', value: '64k' },
90
+ { name: '128 kbps', value: '128k' },
91
+ { name: '192 kbps', value: '192k' },
92
+ { name: '256 kbps', value: '256k' },
93
+ { name: '320 kbps', value: '320k' },
94
+ ],
95
+ default: '128k',
96
+ description: 'Audio bitrate',
97
+ displayOptions: {
98
+ show: {
99
+ operation: ['changeBitrate'],
100
+ },
101
+ },
102
+ },
103
+ {
104
+ displayName: 'Options',
105
+ name: 'options',
106
+ type: 'collection',
107
+ placeholder: 'Add Option',
108
+ default: {},
109
+ displayOptions: {
110
+ show: {
111
+ operation: ['convert'],
112
+ },
113
+ },
114
+ options: [
115
+ {
116
+ displayName: 'Bitrate',
117
+ name: 'bitrate',
118
+ type: 'options',
119
+ options: [
120
+ { name: 'Auto', value: '' },
121
+ { name: '64 kbps', value: '64k' },
122
+ { name: '128 kbps', value: '128k' },
123
+ { name: '192 kbps', value: '192k' },
124
+ { name: '256 kbps', value: '256k' },
125
+ { name: '320 kbps', value: '320k' },
126
+ ],
127
+ default: '',
128
+ description: 'Audio bitrate (leave empty for auto)',
129
+ },
130
+ {
131
+ displayName: 'Sample Rate',
132
+ name: 'sampleRate',
133
+ type: 'options',
134
+ options: [
135
+ { name: 'Auto', value: 0 },
136
+ { name: '22050 Hz', value: 22050 },
137
+ { name: '44100 Hz', value: 44100 },
138
+ { name: '48000 Hz', value: 48000 },
139
+ ],
140
+ default: 0,
141
+ description: 'Audio sample rate (leave auto to keep original)',
142
+ },
143
+ ],
144
+ },
145
+ {
146
+ displayName: 'Output Binary Property',
147
+ name: 'outputBinaryPropertyName',
148
+ type: 'string',
149
+ default: 'data',
150
+ description: 'Name of the binary property for the output audio file',
151
+ },
152
+ ],
153
+ };
154
+ }
155
+ async execute() {
156
+ const items = this.getInputData();
157
+ const returnData = [];
158
+ for (let i = 0; i < items.length; i++) {
159
+ const operation = this.getNodeParameter('operation', i);
160
+ const binaryPropertyName = this.getNodeParameter('binaryPropertyName', i);
161
+ const outputBinaryPropertyName = this.getNodeParameter('outputBinaryPropertyName', i);
162
+ // Validate binary data exists
163
+ const binaryData = this.helpers.assertBinaryData(i, binaryPropertyName);
164
+ const inputBuffer = await this.helpers.getBinaryDataBuffer(i, binaryPropertyName);
165
+ // Determine input extension from mime type or file name
166
+ const inputExt = getExtensionFromBinary(binaryData);
167
+ // Determine output extension
168
+ let outputExt;
169
+ if (operation === 'convert') {
170
+ outputExt = this.getNodeParameter('outputFormat', i);
171
+ }
172
+ else {
173
+ // changeBitrate: keep same format
174
+ outputExt = inputExt;
175
+ }
176
+ // Create temp files
177
+ const id = (0, crypto_1.randomUUID)();
178
+ const inputPath = (0, path_1.join)((0, os_1.tmpdir)(), `ffmpeg_in_${id}.${inputExt}`);
179
+ const outputPath = (0, path_1.join)((0, os_1.tmpdir)(), `ffmpeg_out_${id}.${outputExt}`);
180
+ try {
181
+ // Write input to temp file
182
+ await (0, promises_1.writeFile)(inputPath, inputBuffer);
183
+ // Build ffmpeg arguments
184
+ const args = ['-i', inputPath];
185
+ if (operation === 'convert') {
186
+ const options = this.getNodeParameter('options', i, {});
187
+ if (options.bitrate) {
188
+ args.push('-b:a', options.bitrate);
189
+ }
190
+ if (options.sampleRate) {
191
+ args.push('-ar', String(options.sampleRate));
192
+ }
193
+ }
194
+ else if (operation === 'changeBitrate') {
195
+ const bitrate = this.getNodeParameter('bitrate', i);
196
+ args.push('-b:a', bitrate);
197
+ }
198
+ args.push('-y', outputPath);
199
+ // Execute ffmpeg
200
+ try {
201
+ await execFileAsync('ffmpeg', args, { timeout: 120000 });
202
+ }
203
+ catch (err) {
204
+ throw new n8n_workflow_1.NodeOperationError(this.getNode(), `FFmpeg failed: ${err.stderr || err.message}`, { itemIndex: i });
205
+ }
206
+ // Read output file and prepare binary data
207
+ const outputBuffer = await (0, promises_1.readFile)(outputPath);
208
+ const mimeType = MIME_TYPES[outputExt] || 'application/octet-stream';
209
+ const fileName = replaceExtension(binaryData.fileName || 'audio', outputExt);
210
+ const outputBinary = await this.helpers.prepareBinaryData(outputBuffer, fileName, mimeType);
211
+ returnData.push({
212
+ json: {
213
+ operation,
214
+ inputFormat: inputExt,
215
+ outputFormat: outputExt,
216
+ inputSize: inputBuffer.length,
217
+ outputSize: outputBuffer.length,
218
+ },
219
+ binary: {
220
+ [outputBinaryPropertyName]: outputBinary,
221
+ },
222
+ pairedItem: { item: i },
223
+ });
224
+ }
225
+ finally {
226
+ // Clean up temp files
227
+ await (0, promises_1.unlink)(inputPath).catch(() => { });
228
+ await (0, promises_1.unlink)(outputPath).catch(() => { });
229
+ }
230
+ }
231
+ return [returnData];
232
+ }
233
+ }
234
+ exports.Ffmpeg = Ffmpeg;
235
+ function getExtensionFromBinary(binary) {
236
+ if (binary.fileName) {
237
+ const parts = binary.fileName.split('.');
238
+ if (parts.length > 1) {
239
+ return parts.pop().toLowerCase();
240
+ }
241
+ }
242
+ // Fallback: derive from mime type
243
+ const mimeMap = {
244
+ 'audio/mpeg': 'mp3',
245
+ 'audio/wav': 'wav',
246
+ 'audio/x-wav': 'wav',
247
+ 'audio/ogg': 'ogg',
248
+ 'audio/flac': 'flac',
249
+ 'audio/aac': 'aac',
250
+ 'audio/mp4': 'm4a',
251
+ };
252
+ return mimeMap[binary.mimeType] || 'bin';
253
+ }
254
+ function replaceExtension(fileName, newExt) {
255
+ const dotIndex = fileName.lastIndexOf('.');
256
+ const baseName = dotIndex > 0 ? fileName.substring(0, dotIndex) : fileName;
257
+ return `${baseName}.${newExt}`;
258
+ }
259
+ //# sourceMappingURL=Ffmpeg.node.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Ffmpeg.node.js","sourceRoot":"","sources":["../../../nodes/Ffmpeg/Ffmpeg.node.ts"],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C;IAC9E,IAAI,MAAM,CAAC,QAAQ,EAAE,CAAC;QACrB,MAAM,KAAK,GAAG,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACzC,IAAI,KAAK,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;YACtB,OAAO,KAAK,CAAC,GAAG,EAAG,CAAC,WAAW,EAAE,CAAC;QACnC,CAAC;IACF,CAAC;IACD,kCAAkC;IAClC,MAAM,OAAO,GAA2B;QACvC,YAAY,EAAE,KAAK;QACnB,WAAW,EAAE,KAAK;QAClB,aAAa,EAAE,KAAK;QACpB,WAAW,EAAE,KAAK;QAClB,YAAY,EAAE,MAAM;QACpB,WAAW,EAAE,KAAK;QAClB,WAAW,EAAE,KAAK;KAClB,CAAC;IACF,OAAO,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,KAAK,CAAC;AAC1C,CAAC;AAED,SAAS,gBAAgB,CAAC,QAAgB,EAAE,MAAc;IACzD,MAAM,QAAQ,GAAG,QAAQ,CAAC,WAAW,CAAC,GAAG,CAAC,CAAC;IAC3C,MAAM,QAAQ,GAAG,QAAQ,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,SAAS,CAAC,CAAC,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC;IAC3E,OAAO,GAAG,QAAQ,IAAI,MAAM,EAAE,CAAC;AAChC,CAAC"}
@@ -0,0 +1,5 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" width="64" height="64">
2
+ <rect width="64" height="64" rx="8" fill="#3B8526"/>
3
+ <text x="32" y="24" text-anchor="middle" font-family="Arial,sans-serif" font-weight="bold" font-size="11" fill="white">FF</text>
4
+ <text x="32" y="44" text-anchor="middle" font-family="Arial,sans-serif" font-weight="bold" font-size="11" fill="white">mpeg</text>
5
+ </svg>
package/package.json ADDED
@@ -0,0 +1,42 @@
1
+ {
2
+ "name": "@jnymmt/n8n-nodes-ffmpeg",
3
+ "version": "0.1.0",
4
+ "description": "n8n community node for audio conversion using FFmpeg",
5
+ "keywords": [
6
+ "n8n-community-node-package"
7
+ ],
8
+ "license": "MIT",
9
+ "author": {
10
+ "name": "yambal"
11
+ },
12
+ "repository": {
13
+ "type": "git",
14
+ "url": "https://github.com/yambal/n8n-node-ffmpeg.git"
15
+ },
16
+ "main": "index.js",
17
+ "scripts": {
18
+ "build": "tsc && gulp build:icons",
19
+ "dev": "tsc --watch",
20
+ "lint": "tsc --noEmit",
21
+ "prepublishOnly": "npm run build"
22
+ },
23
+ "files": [
24
+ "dist"
25
+ ],
26
+ "n8n": {
27
+ "n8nNodesApiVersion": 1,
28
+ "credentials": [],
29
+ "nodes": [
30
+ "dist/nodes/Ffmpeg/Ffmpeg.node.js"
31
+ ]
32
+ },
33
+ "devDependencies": {
34
+ "@types/node": "^22.0.0",
35
+ "gulp": "^5.0.0",
36
+ "n8n-workflow": "^1.0.0",
37
+ "typescript": "^5.7.0"
38
+ },
39
+ "peerDependencies": {
40
+ "n8n-workflow": "*"
41
+ }
42
+ }