New:Introducing Socket Scanning for VS Code Marketplace Extensions.Learn more →
Get Started

@parallel-7/slicer-meta

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@parallel-7/slicer-meta

latest
Source
npmnpm
Version
1.5.3
Version published
Maintainers
1
Created
Source

Slicer Meta Parser

A TypeScript library for parsing metadata from 3D printing slicer files

npm version Node.js Version TypeScript License

Quick Start

Install the package:

npm install @parallel-7/slicer-meta

Use the parseSlicerFile function — it automatically handles all supported formats:

import { parseSlicerFile } from '@parallel-7/slicer-meta';

const metadata = await parseSlicerFile('path/to/your/file.gcode');

console.log('Slicer:', metadata.slicer);
console.log('File info:', metadata.file);

if (metadata.threeMf) {
  console.log('3MF data:', metadata.threeMf);
}

Features

  • Three file formats — G-Code (.gcode, .g), FlashForge binary (.gx), and 3MF archives (.3mf)
  • Four slicers detected — FlashPrint, Orca-FlashForge, OrcaSlicer, and Legacy GX, identified from file headers
  • Thumbnail extraction — Base64 thumbnails from G-Code and 3MF; binary thumbnails from GX files
  • Filament tracking — Usage in mm, meters, and grams; per-filament color and type for multi-material prints
  • 3MF-specific data — Support detection, plate preview images, and model file names from the archive
  • Single unified API — parseSlicerFile dispatches to the right parser automatically; individual parsers also exported for direct use

API

ParserFile TypesNotes
GCodeParser.gcode, .gAuto-detects FlashPrint vs Orca-FlashForge vs OrcaSlicer
FlashPrintParser.gcodeFlashPrint-specific files
OrcaFlashForgeParser.gcodeOrca-FlashForge files
GXParser.gxFlashForge binary format
ThreeMfParser.3mf3MF archives (optimized for OrcaSlicer)

For full return type definitions (Slicer Metadata, File Metadata, 3MF Specific Data), see docs/api.md.

For per-parser examples and multi-filament usage, see docs/usage.md.

Development

npm run build   # compile TypeScript
npm test        # run tests

FAQs

Package last updated on 13 Sep 2026

Related posts