SDKs
Official client libraries wrap the REST API with typed request/response models, an async polling helper, and mapped error types — so you don't have to hand-roll multipart uploads or status polling yourself.
Java
Available now on Maven Central. Requires Java 11+; built on java.net.http.HttpClient, with Jackson as the only dependency.
Install
Gradle (Kotlin DSL)
dependencies {
implementation("de.xingen:xingen-sdk:0.1.0")
} Maven
<dependency>
<groupId>de.xingen</groupId>
<artifactId>xingen-sdk</artifactId>
<version>0.1.0</version>
</dependency> Usage
XingenClient client = XingenClient.builder()
.apiKey(System.getenv("XINGEN_API_KEY"))
.build();
InvoiceRecord result = client.invoices().validateFileAndWait(
Path.of("invoice.xml"),
ValidationProfile.XRECHNUNG,
PollOptions.defaults());
if (result.getValidationResult().isValid()) {
System.out.println("Valid!");
} else {
result.getValidationResult().getErrors().forEach(error ->
System.out.println(error.getSeverity() + ": " + error.getMessage()));
} Maven Central ↗ · Source & full README ↗
Python
Available now on PyPI ↗. Requires Python 3.10+; built on requests and pydantic v2.
Install
pip install xingen-sdk Usage
from xingen import XingenClient
from xingen.models.enums import InvoiceStatus, ValidationProfile
client = XingenClient(api_key=os.environ["XINGEN_API_KEY"])
result = client.invoices.validate_file_and_wait("invoice.xml", ValidationProfile.XRECHNUNG)
if result.status is InvoiceStatus.VALIDATED and result.validation_result.valid:
print("Valid!")
else:
for error in result.validation_result.errors:
print(f"{error.severity}: {error.message}") PyPI ↗ · Source & full README ↗
TypeScript
Available now on npm ↗. Requires Node 22+; built on native fetch/FormData, with lossless-json ↗ as the only dependency. Ships both ESM and CommonJS builds.
Install
npm install xingen-sdk Usage
import { InvoiceStatus, ValidationProfile, XingenClient } from "xingen-sdk";
const client = new XingenClient({ apiKey: process.env.XINGEN_API_KEY! });
const result = await client.invoices.validateFileAndWait("invoice.xml", ValidationProfile.XRECHNUNG);
if (result.status === InvoiceStatus.VALIDATED && result.validationResult?.valid) {
console.log("Valid!");
} else {
for (const error of result.validationResult?.errors ?? []) {
console.log(`${error.severity}: ${error.message}`);
}
} npm ↗ · Source & full README ↗
C#
Available now on NuGet ↗. Targets .NET 8+; built on System.Net.Http.HttpClient and System.Text.Json, with no third-party dependencies.
Install
dotnet add package Xingen.Sdk Usage
using var client = new XingenClient(Environment.GetEnvironmentVariable("XINGEN_API_KEY")!);
var result = await client.Invoices.ValidateFileAndWaitAsync(
"invoice.xml", ValidationProfile.XRECHNUNG);
if (result.Status == InvoiceStatus.Validated && result.ValidationResult!.Valid)
{
Console.WriteLine("Valid!");
}
else
{
foreach (var error in result.ValidationResult!.Errors)
{
Console.WriteLine($"{error.Severity}: {error.Message} ({error.Field})");
}
} NuGet ↗ · Source & full README ↗
PHP
Available now on Packagist ↗. Requires PHP 8.1+ with the curl and json extensions (both bundled by default). No third-party runtime dependencies.
Install
composer require xingen/xingen-sdk Usage
use Xingen\Sdk\XingenClient;
use Xingen\Sdk\Models\InvoiceStatus;
use Xingen\Sdk\Models\ValidationProfile;
$client = new XingenClient(apiKey: getenv('XINGEN_API_KEY'));
$result = $client->invoices->validateFileAndWait('invoice.xml', ValidationProfile::XRECHNUNG);
if ($result->status === InvoiceStatus::VALIDATED && $result->validationResult->valid) {
echo "Valid!\n";
} else {
foreach ($result->validationResult->errors as $error) {
echo "{$error->severity->value}: {$error->message} ({$error->field})\n";
}
} Packagist ↗ · Source & full README ↗
Go
Available now on pkg.go.dev ↗. Requires Go 1.23+; zero third-party dependencies, built entirely on the standard library.
Install
go get github.com/nko-technologies/xingen-go-sdk Usage
record, err := client.Invoices.ValidateFileAndWait(ctx, "invoice.xml", xingen.ProfileXRechnung, xingen.DefaultPollOptions())
if err != nil {
log.Fatal(err)
}
if record.Status == xingen.StatusValidated && record.ValidationResult.Valid {
fmt.Println("Valid!")
} else {
for _, e := range record.ValidationResult.Errors {
fmt.Printf("%s: %s (%s)\n", *e.Severity, *e.Message, *e.Field)
}
}