fileOverview

The ceric and cotto command-line tools are the core components of mini-eric, providing direct access to the ERiC API for processing German ELSTER XML documents and Otto API to download objects.

What is ceric?

ceric is a C++ application that interfaces with the ERiC API to process XML documents. It supports three main use cases:

  • Draft: Validate and preview XML documents without transmission

  • Send: Process and transmit documents with PDF generation

  • Transmit: Transmit documents without PDF generation

What is cotto?

cotto is a C++ application that interfaces with the Otto API to download objects (text or binary). It supports only one use case:

  • Download: Download content for the given UUID

Key Features

  • JSON Output: All results are returned as standarized JSON for easy parsing

  • Error Handling: Detailed error codes and messages

  • Flexible Configuration: Support for custom paths and parameters

  • Multiple Data Types: Support for various ELSTER data types

  • Cross-Platform: Available for Linux, macOS, and Windows

Basic Usage

Supported Data Types

See Data Types

Use Cases

Draft (Default)

Validates XML and generates PDF preview without transmission:

Send

Validates XML, transmits to ERiC server, and generates PDF:

Transmit

Validates XML and transmits to ERiC server without PDF generation:

Download

Downloads data from OTTER server using object UUID:

JSON Output Format

ceric and cotto always output a single JSON object to stdout, which follows the Response schema:

Environment Variables

For a complete list of environment variables and detailed configuration instructions, see Environment Variables.

Variable
Default
Description

PATH_CERTIFICATE

bin/eric/test-softorg-pse.pfx

Path to certificate file for send/transmit operations

CERTIFICATE_PIN

123456

PIN for certificate access

Error Handling

ceric uses structured exit codes for different error categories:

  • 1-19: Command line and argument errors

  • 20-29: File I/O errors

  • 30-39: Validation errors

  • 100-109: ERiC/certificate initialization errors

  • 110-119: ERiC header creation errors

  • 120-129: XML validation errors

  • 130-139: File output errors

  • 140-149: ERiC processing errors

  • 150-159: Buffer/content errors

  • 160-169: ELSTER server errors

  • 170-179: Download use case errors

  • 190-199: Internal errors

Next Steps

Last updated