Skip to main content
Version: 1.0.1

Export & Audit Packages


The two forms of tax-authority data access beyond direct read access (Z1): a CSV export of the filtered archive (Z2), and a downloadable ZIP audit package of a period (Z3).

CSV export (Z2)​

Stream the rows matched by the archive filter as a single CSV file — the same filter used by Archive listing.

Endpoint​

PropertyValue
URLGET /germany/archive/{companyId}/export.csv
MethodGET
AuthR-Auth: <company-jwt>
Base URLStage Environment https://api-stage.docnova.ai/
Production Environment https://api.docnova.ai/

Example Request​

curl --location '{{baseUrl}}/germany/archive/{{companyId}}/export.csv?periodFrom=2026-01-01&periodTo=2026-06-30' \
--header 'R-Auth: {{companyJwt}}' \
--output gobd-archiv.csv

Path parameters​

ParameterTypeRequiredDescription
companyIdUUIDYesCompany UUID

Query parameters​

Same filter as List archive rows: periodFrom, periodTo, direction, kind, status, copyQualifier, invoiceNumber, expired. No page / size — every matching row is streamed.

Response​

200 OK
Content-Type: text/csv; charset=UTF-8
Content-Disposition: attachment; filename="gobd-archiv-<companyId>.csv"

A CSV file: header row, ; as column separator, , as decimal symbol, CRLF line endings, every text field double-quoted, UTF-8 encoded, dates as DD.MM.YYYY.

CSV columns​

ColumnDescription
ArchivIdArchive row ID
RechnungsnummerInvoice number
RechnungsdatumInvoice issue date
RichtungINCOMING or OUTGOING
DokumentartArchived document kind — see Document kind values
KopiequalifikationORIGINAL, GENERATED_AT_INTAKE, or NON_ORIGINAL_COPY
VerkaeuferNameSeller name
VerkaeuferUStIdSeller VAT ID
KaeuferNameBuyer name
KaeuferUStIdBuyer VAT ID
WaehrungInvoice currency (ISO 4217)
NettobetragNet amount
SteuerbetragTax amount
BruttobetragGross amount
ZahlbetragPayable amount
DateinameFile name of the archived document
SHA256SHA-256 checksum of the archived document
ArchiviertAmWhen the document was archived
AufbewahrungBisEnd of the retention period
StatushinweisNotes — unprocessable, not yet archived, unreadable amounts, legal hold

The amount, seller and buyer columns are read from each archived document's own XML and verified against its checksum at export time; a row whose archived document cannot be read keeps its line with empty amount columns and a note in Statushinweis.

Error responses​

HTTPerrorTypeMeaning
400INVALID_ARGUMENTperiodTo is before periodFrom
400GERMANY_ARCHIVE_NOT_AVAILABLEThe company is not archived under the German GoBD rules
403AUTHORIZATION_FAILEDCaller has no view rights for either direction, or requested a direction it may not view
403GERMANY_AUDITOR_ACCESS_EXPIREDCaller's time-limited auditor access (Z1) has ended

Request audit package (Z3)​

Queue a downloadable ZIP package for a period. Building happens asynchronously — poll List audit packages for status.

Endpoint​

PropertyValue
URLPOST /germany/archive/{companyId}/audit-packages
MethodPOST
AuthR-Auth: <company-jwt>
Content-Typeapplication/json
Base URLStage Environment https://api-stage.docnova.ai/
Production Environment https://api.docnova.ai/

Example Request​

curl --location '{{baseUrl}}/germany/archive/{{companyId}}/audit-packages' \
--header 'Content-Type: application/json' \
--header 'R-Auth: {{companyJwt}}' \
--data-raw '{
"periodFrom": "2026-01-01",
"periodTo": "2026-06-30",
"direction": null
}'

Path parameters​

ParameterTypeRequiredDescription
companyIdUUIDYesCompany UUID

Request body​

FieldTypeRequiredDescription
periodFromdateYesStart of the period (yyyy-MM-dd)
periodTodateYesEnd of the period (yyyy-MM-dd)
directionstringNoINCOMING or OUTGOING. Omit or null for both — requires view rights for both directions

Response​

{
"id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
"requestedBy": "a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d",
"periodFrom": "2026-01-01",
"periodTo": "2026-06-30",
"direction": null,
"status": "QUEUED",
"invoiceCount": 0,
"fileCount": 0,
"sizeBytes": null,
"createdAt": "2026-07-01T09:00:00",
"readyAt": null,
"expiresAt": null,
"failureReason": null
}

Response fields​

FieldDescription
idAudit package UUID
requestedByUser ID who requested the package
periodFrom / periodToRequested period
directionINCOMING, OUTGOING, or null for both
statusSee Package status values
invoiceCountNumber of invoices included, once built
fileCountNumber of files in the package, once built
sizeBytesPackage size in bytes, once built
createdAtWhen the package was requested
readyAtWhen the package became downloadable
expiresAtWhen the package will be deleted — 7 days after readyAt
failureReasonWhy building failed, if status is FAILED

Error responses​

HTTPerrorTypeMeaning
400GERMANY_AUDIT_PACKAGE_PERIOD_INVALIDperiodFrom/periodTo missing, or periodTo before periodFrom
400GERMANY_AUDIT_PACKAGE_EMPTY_PERIODNo invoices match the requested period/direction
400GERMANY_ARCHIVE_NOT_AVAILABLEThe company is not archived under the German GoBD rules
403AUTHORIZATION_FAILEDCaller requested a direction (or both, when omitted) it may not fully view
403GERMANY_AUDITOR_ACCESS_EXPIREDCaller's time-limited auditor access (Z1) has ended
409GERMANY_AUDIT_PACKAGE_IN_PROGRESSAn identical request (same company, period and direction) is already queued or building

List audit packages​

Endpoint​

PropertyValue
URLGET /germany/archive/{companyId}/audit-packages
MethodGET
AuthR-Auth: <company-jwt>
Base URLStage Environment https://api-stage.docnova.ai/
Production Environment https://api.docnova.ai/

Example Request​

curl --location '{{baseUrl}}/germany/archive/{{companyId}}/audit-packages' \
--header 'R-Auth: {{companyJwt}}'

Path parameters​

ParameterTypeRequiredDescription
companyIdUUIDYesCompany UUID

Response​

[
{
"id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
"requestedBy": "a1b2c3d4-5e6f-7a8b-9c0d-1e2f3a4b5c6d",
"periodFrom": "2026-01-01",
"periodTo": "2026-06-30",
"direction": null,
"status": "READY",
"invoiceCount": 128,
"fileCount": 260,
"sizeBytes": 18874368,
"createdAt": "2026-07-01T09:00:00",
"readyAt": "2026-07-01T09:04:12",
"expiresAt": "2026-07-08T09:04:12",
"failureReason": null
}
]

Response fields are the same as Request audit package. Only packages whose direction the caller may view are returned.

Error responses​

HTTPerrorTypeMeaning
400GERMANY_ARCHIVE_NOT_AVAILABLEThe company is not archived under the German GoBD rules
403AUTHORIZATION_FAILEDCaller has no view rights for either direction
403GERMANY_AUDITOR_ACCESS_EXPIREDCaller's time-limited auditor access (Z1) has ended

Package status values​

ValueDescription
QUEUEDAccepted, waiting to be built
BUILDINGCurrently being assembled
READYBuilt and downloadable
FAILEDBuilding failed — see failureReason
EXPIREDDeleted 7 days after it became ready; request a new one

Download audit package​

Stream the package ZIP through this authenticated endpoint — there is no presigned or public link.

Endpoint​

PropertyValue
URLGET /germany/archive/{companyId}/audit-packages/{packageId}/download
MethodGET
AuthR-Auth: <company-jwt>
Base URLStage Environment https://api-stage.docnova.ai/
Production Environment https://api.docnova.ai/

Example Request​

curl --location '{{baseUrl}}/germany/archive/{{companyId}}/audit-packages/{{packageId}}/download' \
--header 'R-Auth: {{companyJwt}}' \
--output audit-package.zip

Path parameters​

ParameterTypeRequiredDescription
companyIdUUIDYesCompany UUID
packageIdUUIDYesAudit package UUID, from Request or List audit packages

Response​

200 OK
Content-Type: application/zip
Content-Disposition: attachment; filename="<package file name>.zip"

The ZIP contains:

FileContent
invoices.csvSame format as the CSV export
index.xmlColumn descriptions per the GDPdU data description standard
gdpdu-01-09-2004.dtdThe DTD index.xml validates against
originals/<archiveId>.<extension>The archived document of each included row
sha256.txtChecksums of every file in the package
package-info.txtPackage metadata

Error responses​

HTTPerrorTypeMeaning
400GERMANY_ARCHIVE_NOT_AVAILABLEThe company is not archived under the German GoBD rules
400GERMANY_AUDIT_PACKAGE_NOT_READYPackage status is still QUEUED or BUILDING
400GERMANY_AUDIT_PACKAGE_EXPIREDPackage expiresAt has passed — request a new one
403AUTHORIZATION_FAILEDCaller has no view rights at all, or may not view the package's direction
403GERMANY_AUDITOR_ACCESS_EXPIREDCaller's time-limited auditor access (Z1) has ended
404GERMANY_AUDIT_PACKAGE_NOT_FOUNDNo audit package with this packageId for this company