Add ZUGFeRD endpoint examples - #135
Merged
datalogics-cgreen merged 6 commits intoSep 18, 2026
Merged
Conversation
added 3 commits
September 17, 2026 16:43
Assisted-by: Codex
Assisted-by: Codex
Assisted-by: Codex
datalogics-erics
marked this pull request as ready for review
September 17, 2026 22:03
datalogics-cgreen
approved these changes
Sep 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why this change
pdfRest now supports creating and validating ZUGFeRD and Factur-X hybrid invoices. These examples give developers a clear, runnable starting point for both endpoints in each of the repository primary languages.
What changed
Adds 24 endpoint examples for Create ZUGFeRD PDF (
/zugferd-pdf) and Validate ZUGFeRD PDF (/validated-zugferd) in C#, Java, JavaScript, PHP, Python, and cURL. Each endpoint has a direct multipart upload example and an upload-then-JSON resource-ID example.Creation examples submit invoice XML with an existing visual PDF and set
regenerate_pdftotrue, so the API preserves the PDF when it matches and generates a replacement from canonical XML when it does not. The inline comments explain that fallback behavior and clarify that the presentation settings apply only to a replacement PDF. Validation examples submit an existing hybrid ZUGFeRD/Factur-X PDF and print the full validation response.The .NET dispatcher and usage help expose the four new .NET example commands alongside the existing endpoint samples. The Java samples use the repository-standard 60-second request timeout for the longer-running creation flow.
Behavior changes
The JSON creation samples upload the local XML and PDF first, then pass both returned resource IDs to the processing endpoint. Multipart creation samples send both source files directly. Validation samples use the corresponding single-PDF flows. No existing samples or API behavior change.
Validation
node --check: JavaScript samplespython3 -m py_compile: Python samplesphp -l: PHP samplesmvn package: Java multipart and JSON directoriesdotnet build: .NET samplesVALID.Risks and follow-ups
These examples use placeholder API keys and local input paths consistent with the rest of the repository. Users replace those values before running a sample. This PR adds endpoint examples only; it does not change API behavior.