Actions6
Overview
This node integrates with the Letter Xpress API to send physical letters and retrieve related information such as account balance, print jobs, email jobs, transactions, and invoices. The primary use case is automating the sending of postal mail directly from digital documents (PDFs) via an API, which is useful for businesses that need to send invoices, contracts, or other official correspondence without manual handling.
The "Brief Senden" (Send Letter) operation allows users to upload a PDF file and specify printing and shipping options to send a letter through the Letter Xpress service. This can be used in scenarios like automated billing, legal document dispatch, or marketing campaigns where physical mail is required.
Properties
| Name | Meaning |
|---|---|
| PDF Datei Key | Key name of the input binary data containing the PDF file to send. |
| Farbe | Print color: "Schwarz/Weiß" (Black & White) or "Farbe" (Color). |
| Modus | Print mode: "Einseitig" (single-sided) or "Doppelseitig" (double-sided). |
| Versand | Shipping type: "National", "International", or "Automatisch" (automatic selection). |
| C4 Umschlag | Use C4 envelope for letters under 9 pages (0 = no, 1 = yes). |
| Original Dateiname | Original filename of the PDF (e.g., "Rechnung-123456.pdf"). |
| Einschreiben | Registered mail type (only national): None, "Einschreiben Einwurf" (registered drop-off), or "Einschreiben" (registered mail). |
| Versanddatum | Dispatch date in format YYYY-MM-DD; must be a future date. |
| Serienbrief Aktivieren | Enable serial letter mode (batch processing multiple letters in one PDF). |
| Serienbrief Trenntyp | Separator type for serial letters: "String" (keyword) or "Nummer" (page count). |
| Serienbrief Trennwert | Separator value (keyword or page number) for splitting serial letters. |
Output
The node outputs JSON data representing the response from the Letter Xpress API for the selected operation.
For the "Brief Senden" operation, the output JSON contains details about the created print job, including status and identifiers returned by the API.
No binary data output is produced by this node.
Dependencies
- Requires an API key credential for authenticating with the Letter Xpress API.
- The node uses the Letter Xpress REST API at
https://api.letterxpress.de. - The user must provide a valid PDF file as binary input under the specified key.
- The node depends on n8n's HTTP request helper methods and cryptographic hashing for checksum calculation.
Troubleshooting
Common issues:
- Invalid or missing API credentials will cause authentication errors.
- Providing a non-PDF or corrupted binary file under the specified key will result in API errors.
- Specifying a dispatch date in the past will likely cause validation errors.
- Using registered mail options for international shipping may not be supported.
- Incorrect separator values when enabling serial letter mode can cause failures in batch processing.
Error messages:
- API errors are wrapped and thrown as NodeApiError with the original message.
- Operation not supported error if an invalid operation is selected.
Resolutions:
- Verify API credentials and permissions.
- Ensure the binary input contains a valid PDF file.
- Check date formats and ensure dispatch dates are future dates.
- Review Letter Xpress API documentation for allowed combinations of options.
Links and References
- Letter Xpress API Documentation (official API endpoint)
- n8n documentation on Creating Custom Nodes