Tax Filing Service

<back to all web services

ProtokollRequest17

SyncDatenabholungVerarbeitungsprotokolle

Represents the service request to retrieve logs about a specified tax assessement.

Requires Authentication
The following routes are available for this service:
POST/datenabholungen/protokolle/17/verarbeitungsprotokoll
<?php namespace dtos;

use DateTime;
use Exception;
use DateInterval;
use JsonSerializable;
use ServiceStack\{IReturn,IReturnVoid,IGet,IPost,IPut,IDelete,IPatch,IMeta,IHasSessionId,IHasBearerToken,IHasVersion};
use ServiceStack\{ICrud,ICreateDb,IUpdateDb,IPatchDb,IDeleteDb,ISaveDb,AuditBase,QueryDb,QueryDb2,QueryData,QueryData2,QueryResponse};
use ServiceStack\{ResponseStatus,ResponseError,EmptyResponse,IdResponse,ArrayList,KeyValuePair2,StringResponse,StringsResponse,Tuple2,Tuple3,ByteArray};
use ServiceStack\{JsonConverters,Returns,TypeContext};


/** @description Represents a base class for a file with raw data. */
// @Api(Description="Represents a base class for a file with raw data.")
class FileBase implements JsonSerializable
{
    public function __construct(
        /** @description The raw data content of the file. */
        // @ApiMember(Description="The raw data content of the file.", Name="Content")
        /** @var ByteArray|null */
        public ?ByteArray $content=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['content'])) $this->content = JsonConverters::from('ByteArray', $o['content']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->content)) $o['content'] = JsonConverters::to('ByteArray', $this->content);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a portal certificate that is protected by a password. */
// @Api(Description="Represents a portal certificate that is protected by a password.")
class PortalCertificate extends FileBase implements ISecuredCertificate, IHasIndex, JsonSerializable
{
    /**
     * @param ByteArray|null $content
     */
    public function __construct(
        ?ByteArray $content=null,
        /** @description The unique identifier of the certificate. */
        // @ApiMember(Description="The unique identifier of the certificate.")
        /** @var string */
        public string $id='',

        /** @description The position of the certificate element in an indexed collection of certificates. */
        // @ApiMember(Description="The position of the certificate element in an indexed collection of certificates.")
        /** @var int */
        public int $index=0,

        /** @description The password to protect the certificate from unauthorized access. */
        // @StringLength(255)
        // @ApiMember(Description="The password to protect the certificate from unauthorized access.")
        /** @var string|null */
        public ?string $pin=null,

        /** @description The description of the certificate. */
        // @StringLength(2147483647)
        // @ApiMember(Description="The description of the certificate.")
        /** @var string|null */
        public ?string $description=null,

        /** @description Tags that can be used to label or identify the certificate. */
        // @ApiMember(Description="Tags that can be used to label or identify the certificate.")
        /** @var array<string>|null */
        public ?array $tags=null,

        /** @description Gets or sets the file name of the certificate. */
        // @ApiMember(Description="Gets or sets the file name of the certificate.")
        /** @var string|null */
        public ?string $name=null
    ) {
        parent::__construct($content);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['id'])) $this->id = $o['id'];
        if (isset($o['index'])) $this->index = $o['index'];
        if (isset($o['pin'])) $this->pin = $o['pin'];
        if (isset($o['description'])) $this->description = $o['description'];
        if (isset($o['tags'])) $this->tags = JsonConverters::fromArray('string', $o['tags']);
        if (isset($o['name'])) $this->name = $o['name'];
        if (isset($o['content'])) $this->content = JsonConverters::from('ByteArray', $o['content']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->id)) $o['id'] = $this->id;
        if (isset($this->index)) $o['index'] = $this->index;
        if (isset($this->pin)) $o['pin'] = $this->pin;
        if (isset($this->description)) $o['description'] = $this->description;
        if (isset($this->tags)) $o['tags'] = JsonConverters::toArray('string', $this->tags);
        if (isset($this->name)) $o['name'] = $this->name;
        if (isset($this->content)) $o['content'] = JsonConverters::to('ByteArray', $this->content);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a base service request to retrieve processing records from a specified tax assessement. */
// @Api(Description="Represents a base service request to retrieve processing records from a specified tax assessement.")
class ProtokollRequestBase implements IPost, JsonSerializable
{
    public function __construct(
        /** @description The authentification certificate. */
        // @ApiMember(Description="The authentification certificate.", IsRequired=true, Name="Zertifikat")
        /** @var PortalCertificate|null */
        public ?PortalCertificate $zertifikat=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['zertifikat'])) $this->zertifikat = JsonConverters::from('PortalCertificate', $o['zertifikat']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->zertifikat)) $o['zertifikat'] = JsonConverters::to('PortalCertificate', $this->zertifikat);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents the transmission path. */
enum Uebertragungsweg : string
{
    case direkt = 'direkt';
    case link = 'link';
    case sammellink = 'sammellink';
}

/** @description The data packet from the retrieval operation. */
// @Api(Description="The data packet from the retrieval operation.")
class Datenpaket implements JsonSerializable
{
    public function __construct(
        /** @description Encoded (compressed and encrypted) requested data record */
        // @ApiMember(Description="Encoded (compressed and encrypted) requested data record")
        /** @var string|null */
        public ?string $value=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['value'])) $this->value = $o['value'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->value)) $o['value'] = $this->value;
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents the download of requested records. The downloaded content from the web server takes place: a) with https b) on port 443 c) on datenabholung1.elster.de or datenabholung2.elster.de. The HTTP Basic Authentication mechanism according to RFC 2617 is used for authentication. */
// @Api(Description="Represents the download of requested records. The downloaded content from the web server takes place: a) with https b) on port 443 c) on datenabholung1.elster.de or datenabholung2.elster.de. The HTTP Basic Authentication mechanism according to RFC 2617 is used for authentication.")
class Download implements JsonSerializable
{
    public function __construct(
        /** @description The link to the data on the web server. */
        // @ApiMember(Description="The link to the data on the web server.")
        /** @var string|null */
        public ?string $url=null,

        /** @description The user name for the web server. */
        // @ApiMember(Description="The user name for the web server.")
        /** @var string|null */
        public ?string $benutzer=null,

        /** @description Password for the web server. */
        // @ApiMember(Description="Password for the web server.")
        /** @var string|null */
        public ?string $passwort=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['url'])) $this->url = $o['url'];
        if (isset($o['benutzer'])) $this->benutzer = $o['benutzer'];
        if (isset($o['passwort'])) $this->passwort = $o['passwort'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->url)) $o['url'] = $this->url;
        if (isset($this->benutzer)) $o['benutzer'] = $this->benutzer;
        if (isset($this->passwort)) $o['passwort'] = $this->passwort;
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents the request to retrieve tax assessments by means of a specfied ID. */
// @Api(Description="Represents the request to retrieve tax assessments by means of a specfied ID.")
class Abholung implements JsonSerializable
{
    public function __construct(
        /** @description The identifier of the data record. */
        // @ApiMember(Description="The identifier of the data record.")
        /** @var string|null */
        public ?string $id=null,

        /** @description The ID number of the receipt owner. This attribute is only required for the tax type 'ElsterVaStDaten'. */
        // @ApiMember(Description="The ID number of the receipt owner. This attribute is only required for the tax type 'ElsterVaStDaten'.")
        /** @var string|null */
        public ?string $idnr=null,

        /** @description The assessment year (YYYY) of the receipt. This attribute is only required for the tax type 'ElsterVaStDaten'. */
        // @ApiMember(Description="The assessment year (YYYY) of the receipt. This attribute is only required for the tax type 'ElsterVaStDaten'.")
        /** @var int|null */
        public ?int $veranlagungsjahr=null,

        /** @description The transmission path used. */
        // @ApiMember(Description="The transmission path used.")
        /** @var Uebertragungsweg|null */
        public ?Uebertragungsweg $uebertragungsweg=null,

        /** @description The character encoding of the data record (e.g. ISO-8859-15). The exception is the data type ElsterVaStDaten, here we submit KEIN ENCODING. */
        // @ApiMember(Description="The character encoding of the data record (e.g. ISO-8859-15). The exception is the data type ElsterVaStDaten, here we submit KEIN ENCODING.")
        /** @var string|null */
        public ?string $encoding=null,

        /** @description The client number; only applicable to the tax type 'ElsterDIVADaten'. */
        // @ApiMember(Description="The client number; only applicable to the tax type 'ElsterDIVADaten'.")
        /** @var string|null */
        public ?string $mandantennummer=null,

        /** @description The tax number; only applicable to the tax type 'ElsterDIVADaten'. */
        // @ApiMember(Description="The tax number; only applicable to the tax type 'ElsterDIVADaten'.")
        /** @var string|null */
        public ?string $steuernummer=null,

        /** @description The asessment date; only applicable to the tax type 'ElsterDIVADaten'. */
        // @ApiMember(Description="The asessment date; only applicable to the tax type 'ElsterDIVADaten'.")
        /** @var DateTime|null */
        public ?DateTime $bescheiddatum=null,

        /** @description Das Datenpaket angeforderter Datensaetze. Nur bei der Direktsendung ueber das ERiClet. */
        // @ApiMember(Description="Das Datenpaket angeforderter Datensaetze. Nur bei der Direktsendung ueber das ERiClet.")
        /** @var Datenpaket|null */
        public ?Datenpaket $datenpaket=null,

        /** @description Download requested data records.  Ensure the second payload data block  is empty for bulk retrieval operations. */
        // @ApiMember(Description="Download requested data records.  Ensure the second payload data block  is empty for bulk retrieval operations.")
        /** @var Download|null */
        public ?Download $download=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['id'])) $this->id = $o['id'];
        if (isset($o['idnr'])) $this->idnr = $o['idnr'];
        if (isset($o['veranlagungsjahr'])) $this->veranlagungsjahr = $o['veranlagungsjahr'];
        if (isset($o['uebertragungsweg'])) $this->uebertragungsweg = JsonConverters::from('Uebertragungsweg', $o['uebertragungsweg']);
        if (isset($o['encoding'])) $this->encoding = $o['encoding'];
        if (isset($o['mandantennummer'])) $this->mandantennummer = $o['mandantennummer'];
        if (isset($o['steuernummer'])) $this->steuernummer = $o['steuernummer'];
        if (isset($o['bescheiddatum'])) $this->bescheiddatum = JsonConverters::from('DateTime', $o['bescheiddatum']);
        if (isset($o['datenpaket'])) $this->datenpaket = JsonConverters::from('Datenpaket', $o['datenpaket']);
        if (isset($o['download'])) $this->download = JsonConverters::from('Download', $o['download']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->id)) $o['id'] = $this->id;
        if (isset($this->idnr)) $o['idnr'] = $this->idnr;
        if (isset($this->veranlagungsjahr)) $o['veranlagungsjahr'] = $this->veranlagungsjahr;
        if (isset($this->uebertragungsweg)) $o['uebertragungsweg'] = JsonConverters::to('Uebertragungsweg', $this->uebertragungsweg);
        if (isset($this->encoding)) $o['encoding'] = $this->encoding;
        if (isset($this->mandantennummer)) $o['mandantennummer'] = $this->mandantennummer;
        if (isset($this->steuernummer)) $o['steuernummer'] = $this->steuernummer;
        if (isset($this->bescheiddatum)) $o['bescheiddatum'] = JsonConverters::to('DateTime', $this->bescheiddatum);
        if (isset($this->datenpaket)) $o['datenpaket'] = JsonConverters::to('Datenpaket', $this->datenpaket);
        if (isset($this->download)) $o['download'] = JsonConverters::to('Download', $this->download);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents the various tax types for the retrieval of data. */
enum Steuerart : string
{
    case ESB = 'ESB';
    case GSB = 'GSB';
    case USB = 'USB';
    case EPBescheid = 'EPBescheid';
    case EPMitteilung = 'EPMitteilung';
    case Gewerbesteuerbescheid = 'Gewerbesteuerbescheid';
    case Gewerbesteuermitteilung = 'Gewerbesteuermitteilung';
    case GEWMB = 'GEWMB';
    case DIVAAnzeigeEinerLotterie = 'DIVAAnzeigeEinerLotterie';
    case DIVABescheid = 'DIVABescheid';
    case DivaBescheidESt = 'DivaBescheidESt';
    case DIVABuchmachersteuer = 'DIVABuchmachersteuer';
    case DIVALotteriesteuerEinmal = 'DIVALotteriesteuerEinmal';
    case DIVALotteriesteuerMehr = 'DIVALotteriesteuerMehr';
    case DIVASportwettensteuer = 'DIVASportwettensteuer';
    case DIVATotalisator = 'DIVATotalisator';
    case OZGBescheid = 'OZGBescheid';
    case VerbindlicheAuskunft = 'VerbindlicheAuskunft';
    case VerbindlicheZusage = 'VerbindlicheZusage';
    case DivaSonstigerVA = 'DivaSonstigerVA';
    case DivaBescheidErbSt = 'DivaBescheidErbSt';
    case DivaBescheidFEIN = 'DivaBescheidFEIN';
    case DivaBescheidGewSt = 'DivaBescheidGewSt';
    case DivaBescheidKSt = 'DivaBescheidKSt';
    case DivaBescheidUSt = 'DivaBescheidUSt';
    case DivaBescheidSchenkSt = 'DivaBescheidSchenkSt';
    case DIVATroncabgabe = 'DIVATroncabgabe';
    case DIVAVirtuelleAutomatenStB = 'DIVAVirtuelleAutomatenStB';
    case DIVAOnlinePokerStB = 'DIVAOnlinePokerStB';
    case LStHVVMRM = 'LStHVVMRM';
    case EinlagenrueckgewaehrVA = 'EinlagenrueckgewaehrVA';
    case FTTMeldungVA = 'FTTMeldungVA';
    case StatusInvStGVA = 'StatusInvStGVA';
    case UStVEUVA = 'UStVEUVA';
    case VERSVA = 'VERSVA';
    case AltZertVA = 'AltZertVA';
    case KapEStEntlastungVA = 'KapEStEntlastungVA';
    case PostUDLVA = 'PostUDLVA';
    case StAb50aVA = 'StAb50aVA';
    case StAbEntlastungVA = 'StAbEntlastungVA';
    case KassenangelegenheitenVA = 'KassenangelegenheitenVA';
    case KStOptVA = 'KStOptVA';
    case SteueroasenabwehrVA = 'SteueroasenabwehrVA';
    case KDBVollmachtRM = 'KDBVollmachtRM';
    case STBKE = 'STBKE';
    case VDBKDBRueckmeldungLief = 'VDBKDBRueckmeldungLief';
    case AnhangRueckmeldung = 'AnhangRueckmeldung';
    case DivaEinwilligungRM = 'DivaEinwilligungRM';
    case GlueckspielF = 'GlueckspielF';
    case OZGMitteilung = 'OZGMitteilung';
    case VerbindlicheAuskunftInfoF = 'VerbindlicheAuskunftInfoF';
    case ELOProtokoll = 'ELOProtokoll';
}

/** @description Specifies the encoding of the metadata. */
enum Coding : string
{
    case text = 'text';
    case base64 = 'base64';
}

/** @description Represents the metadata of a data record. */
// @Api(Description="Represents the metadata of a data record.")
class Meta17 implements JsonSerializable
{
    public function __construct(
        /** @description The type of metadata, e.g. datei [file] */
        // @ApiMember(Description="The type of metadata, e.g. datei [file]")
        /** @var string|null */
        public ?string $name=null,

        /** @description The encoding of the metadata (text or base64) */
        // @ApiMember(Description="The encoding of the metadata (text or base64)")
        /** @var Coding|null */
        public ?Coding $coding=null,

        /** @description The content of the metadata */
        // @ApiMember(Description="The content of the metadata")
        /** @var string|null */
        public ?string $value=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['name'])) $this->name = $o['name'];
        if (isset($o['coding'])) $this->coding = JsonConverters::from('Coding', $o['coding']);
        if (isset($o['value'])) $this->value = $o['value'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->name)) $o['name'] = $this->name;
        if (isset($this->coding)) $o['coding'] = JsonConverters::to('Coding', $this->coding);
        if (isset($this->value)) $o['value'] = $this->value;
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a list of meta information maps. */
class MetaInfoMaps17 implements JsonSerializable
{
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents meta information. */
// @Api(Description="Represents meta information.")
class MetaInformationen17 implements JsonSerializable
{
    public function __construct(
        /** @description List of metadata. */
        // @ApiMember(Description="List of metadata.")
        /** @var array<Meta17>|null */
        public ?array $meta=null,

        /** @description List of meta infomation maps. */
        // @ApiMember(Description="List of meta infomation maps.")
        /** @var MetaInfoMaps17|null */
        public ?MetaInfoMaps17 $metaInfoMaps=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['meta'])) $this->meta = JsonConverters::fromArray('Meta17', $o['meta']);
        if (isset($o['metaInfoMaps'])) $this->metaInfoMaps = JsonConverters::from('MetaInfoMaps17', $o['metaInfoMaps']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->meta)) $o['meta'] = JsonConverters::toArray('Meta17', $this->meta);
        if (isset($this->metaInfoMaps)) $o['metaInfoMaps'] = JsonConverters::to('MetaInfoMaps17', $this->metaInfoMaps);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a list of attachments. */
class Anhaenge17 implements JsonSerializable
{
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a request to retrieve data records by means of one or more IDs. */
// @Api(Description="Represents a request to retrieve data records by means of one or more IDs.")
class Abholung17 extends Abholung implements JsonSerializable
{
    /**
     * @param string|null $id
     * @param string|null $idnr
     * @param int|null $veranlagungsjahr
     * @param Uebertragungsweg|null $uebertragungsweg
     * @param string|null $encoding
     * @param string|null $mandantennummer
     * @param string|null $steuernummer
     * @param DateTime|null $bescheiddatum
     * @param Datenpaket|null $datenpaket
     * @param Download|null $download
     */
    public function __construct(
        ?string $id=null,
        ?string $idnr=null,
        ?int $veranlagungsjahr=null,
        ?Uebertragungsweg $uebertragungsweg=null,
        ?string $encoding=null,
        ?string $mandantennummer=null,
        ?string $steuernummer=null,
        ?DateTime $bescheiddatum=null,
        ?Datenpaket $datenpaket=null,
        ?Download $download=null,
        /** @description The tax type (e.g. ESB) of the data record. */
        // @ApiMember(Description="The tax type (e.g. ESB) of the data record.")
        /** @var Steuerart|null */
        public ?Steuerart $steuerart=null,

        /** @description The meta information of the identifier. */
        // @ApiMember(Description="The meta information of the identifier.")
        /** @var MetaInformationen17|null */
        public ?MetaInformationen17 $metaInformationen=null,

        /** @description Die Transfertickets der Datensaetze. Es duerfen max. 100 Bereitstellungstickets in einem Request angegeben werden. */
        // @ApiMember(Description="Die Transfertickets der Datensaetze. Es duerfen max. 100 Bereitstellungstickets in einem Request angegeben werden.")
        /** @var string|null */
        public ?string $bereitstellungsticket=null,

        /** @description The attachments of the data records. */
        // @ApiMember(Description="The attachments of the data records.")
        /** @var Anhaenge17|null */
        public ?Anhaenge17 $anhaenge=null
    ) {
        parent::__construct($id,$idnr,$veranlagungsjahr,$uebertragungsweg,$encoding,$mandantennummer,$steuernummer,$bescheiddatum,$datenpaket,$download);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['steuerart'])) $this->steuerart = JsonConverters::from('Steuerart', $o['steuerart']);
        if (isset($o['metaInformationen'])) $this->metaInformationen = JsonConverters::from('MetaInformationen17', $o['metaInformationen']);
        if (isset($o['bereitstellungsticket'])) $this->bereitstellungsticket = $o['bereitstellungsticket'];
        if (isset($o['anhaenge'])) $this->anhaenge = JsonConverters::from('Anhaenge17', $o['anhaenge']);
        if (isset($o['id'])) $this->id = $o['id'];
        if (isset($o['idnr'])) $this->idnr = $o['idnr'];
        if (isset($o['veranlagungsjahr'])) $this->veranlagungsjahr = $o['veranlagungsjahr'];
        if (isset($o['uebertragungsweg'])) $this->uebertragungsweg = JsonConverters::from('Uebertragungsweg', $o['uebertragungsweg']);
        if (isset($o['encoding'])) $this->encoding = $o['encoding'];
        if (isset($o['mandantennummer'])) $this->mandantennummer = $o['mandantennummer'];
        if (isset($o['steuernummer'])) $this->steuernummer = $o['steuernummer'];
        if (isset($o['bescheiddatum'])) $this->bescheiddatum = JsonConverters::from('DateTime', $o['bescheiddatum']);
        if (isset($o['datenpaket'])) $this->datenpaket = JsonConverters::from('Datenpaket', $o['datenpaket']);
        if (isset($o['download'])) $this->download = JsonConverters::from('Download', $o['download']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->steuerart)) $o['steuerart'] = JsonConverters::to('Steuerart', $this->steuerart);
        if (isset($this->metaInformationen)) $o['metaInformationen'] = JsonConverters::to('MetaInformationen17', $this->metaInformationen);
        if (isset($this->bereitstellungsticket)) $o['bereitstellungsticket'] = $this->bereitstellungsticket;
        if (isset($this->anhaenge)) $o['anhaenge'] = JsonConverters::to('Anhaenge17', $this->anhaenge);
        if (isset($this->id)) $o['id'] = $this->id;
        if (isset($this->idnr)) $o['idnr'] = $this->idnr;
        if (isset($this->veranlagungsjahr)) $o['veranlagungsjahr'] = $this->veranlagungsjahr;
        if (isset($this->uebertragungsweg)) $o['uebertragungsweg'] = JsonConverters::to('Uebertragungsweg', $this->uebertragungsweg);
        if (isset($this->encoding)) $o['encoding'] = $this->encoding;
        if (isset($this->mandantennummer)) $o['mandantennummer'] = $this->mandantennummer;
        if (isset($this->steuernummer)) $o['steuernummer'] = $this->steuernummer;
        if (isset($this->bescheiddatum)) $o['bescheiddatum'] = JsonConverters::to('DateTime', $this->bescheiddatum);
        if (isset($this->datenpaket)) $o['datenpaket'] = JsonConverters::to('Datenpaket', $this->datenpaket);
        if (isset($this->download)) $o['download'] = JsonConverters::to('Download', $this->download);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a base service request to retrieve logs about a specified tax assessement. */
// @Api(Description="Represents a base service request to retrieve logs about a specified tax assessement.")
class ProtokollRequestBase17 extends ProtokollRequestBase implements JsonSerializable
{
    /**
     * @param PortalCertificate|null $zertifikat
     */
    public function __construct(
        ?PortalCertificate $zertifikat=null,
        /** @description The tax assessement, whose processing records shall be obtained. */
        // @ApiMember(Description="The tax assessement, whose processing records shall be obtained.", Name="Bescheid")
        /** @var Abholung17|null */
        public ?Abholung17 $bescheid=null
    ) {
        parent::__construct($zertifikat);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['bescheid'])) $this->bescheid = JsonConverters::from('Abholung17', $o['bescheid']);
        if (isset($o['zertifikat'])) $this->zertifikat = JsonConverters::from('PortalCertificate', $o['zertifikat']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->bescheid)) $o['bescheid'] = JsonConverters::to('Abholung17', $this->bescheid);
        if (isset($this->zertifikat)) $o['zertifikat'] = JsonConverters::to('PortalCertificate', $this->zertifikat);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Specifies a service response from an ERiC service operation. */
// @Api(Description="Specifies a service response from an ERiC service operation.")
class ServiceReponseBase implements IHasIndex, JsonSerializable
{
    public function __construct(
        /** @description The unique identifier of the response. */
        // @ApiMember(Description="The unique identifier of the response.", Name="Id")
        /** @var string */
        public string $id='',

        /** @description The position of the response element in an indexed collection. */
        // @ApiMember(Description="The position of the response element in an indexed collection.", Name="Index")
        /** @var int */
        public int $index=0,

        /** @description Metadata that contains structured error information on the service response. */
        // @ApiMember(Description="Metadata that contains structured error information on the service response.", Name="ResponseStatus")
        /** @var ResponseStatus|null */
        public ?ResponseStatus $responseStatus=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['id'])) $this->id = $o['id'];
        if (isset($o['index'])) $this->index = $o['index'];
        if (isset($o['responseStatus'])) $this->responseStatus = JsonConverters::from('ResponseStatus', $o['responseStatus']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->id)) $o['id'] = $this->id;
        if (isset($this->index)) $o['index'] = $this->index;
        if (isset($this->responseStatus)) $o['responseStatus'] = JsonConverters::to('ResponseStatus', $this->responseStatus);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Stellt einen Nutzdatensatz-Fehler dar. Dabei besteht der Fehler aus: - einer laufenden Nummer(Attribut zum NdSFehler)- der KmId (Attribut zum NdSFehler) und/oder dem ordnungsMerkmal (Attribut zum NdSFehler)- einem Fehlernummer (Attribut zum NdSFehler)- einem Fehlertext (Inhalt des Tag NdSFehler) */
// @Api(Description="Stellt einen Nutzdatensatz-Fehler dar. Dabei besteht der Fehler aus: - einer laufenden Nummer(Attribut zum NdSFehler)- der KmId (Attribut zum NdSFehler) und/oder dem ordnungsMerkmal (Attribut zum NdSFehler)- einem Fehlernummer (Attribut zum NdSFehler)- einem Fehlertext (Inhalt des Tag NdSFehler)")
class NdSFehler06 implements JsonSerializable
{
    public function __construct(
        /** @description Die laufende Nummer des fehlerhaften Datensatzes in einem Nutzdatenblock. */
        // @ApiMember(Description="Die laufende Nummer des fehlerhaften Datensatzes in einem Nutzdatenblock.", Name="LfdNr")
        /** @var string|null */
        public ?string $lfdNr=null,

        /** @description Bei der kmId handelt es sich um die durch den Verfasser vorgegebene KmId des Nutzdatensatzes. */
        // @ApiMember(Description="Bei der kmId handelt es sich um die durch den Verfasser vorgegebene KmId des Nutzdatensatzes.", Name="KmId")
        /** @var string|null */
        public ?string $kmId=null,

        /** @description Die durch den Verfasser vorgegebene bundesweit eindeutige Identifikation des Nutzdatensatzes (z.B. bei LStB, Lohnersatzleistungen). */
        // @ApiMember(Description="Die durch den Verfasser vorgegebene bundesweit eindeutige Identifikation des Nutzdatensatzes (z.B. bei LStB, Lohnersatzleistungen).", Name="OrdnungsMerkmal")
        /** @var string|null */
        public ?string $ordnungsMerkmal=null,

        /** @description Es wird die vom Elstersystem für diesen Fehler vergebene Fehlernummer i.d.R. eine 9-stellige Nummer zurückgemeldet. */
        // @ApiMember(Description="Es wird die vom Elstersystem für diesen Fehler vergebene Fehlernummer i.d.R. eine 9-stellige Nummer zurückgemeldet.", Name="FehlerNummer")
        /** @var int|null */
        public ?int $fehlerNummer=null,

        /** @description Es wird der vom Elstersystem für diesen Fehler vergebene Fehlertext zurückgemeldet. */
        // @ApiMember(Description="Es wird der vom Elstersystem für diesen Fehler vergebene Fehlertext zurückgemeldet.", Name="FehlerText")
        /** @var string|null */
        public ?string $fehlerText=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['lfdNr'])) $this->lfdNr = $o['lfdNr'];
        if (isset($o['kmId'])) $this->kmId = $o['kmId'];
        if (isset($o['ordnungsMerkmal'])) $this->ordnungsMerkmal = $o['ordnungsMerkmal'];
        if (isset($o['fehlerNummer'])) $this->fehlerNummer = $o['fehlerNummer'];
        if (isset($o['fehlerText'])) $this->fehlerText = $o['fehlerText'];
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->lfdNr)) $o['lfdNr'] = $this->lfdNr;
        if (isset($this->kmId)) $o['kmId'] = $this->kmId;
        if (isset($this->ordnungsMerkmal)) $o['ordnungsMerkmal'] = $this->ordnungsMerkmal;
        if (isset($this->fehlerNummer)) $o['fehlerNummer'] = $this->fehlerNummer;
        if (isset($this->fehlerText)) $o['fehlerText'] = $this->fehlerText;
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Stellt ein Element eines Nutztdatenblockes dar. */
// @Api(Description="Stellt ein Element eines Nutztdatenblockes dar.")
class Nutzdatenblock06 implements JsonSerializable
{
    public function __construct(
        /** @description Über das Nutzdatenticket im Verarbeitungsprotokoll wird der Nutzdatenblock aus der Datenlieferung referenziert. */
        // @ApiMember(Description="Über das Nutzdatenticket im Verarbeitungsprotokoll wird der Nutzdatenblock aus der Datenlieferung referenziert.")
        /** @var string|null */
        public ?string $nutzdatenTicket=null,

        /** @description Der Statuscode zum Nutzdatenblock. */
        // @ApiMember(Description="Der Statuscode zum Nutzdatenblock.")
        /** @var int|null */
        public ?int $code=null,

        /** @description Der Statustext zum Nutzdatenblock. */
        // @ApiMember(Description="Der Statustext zum Nutzdatenblock.")
        /** @var string|null */
        public ?string $text=null,

        /** @description Anzahl der Verarbeiteten Nutzdatensätze. */
        // @ApiMember(Description="Anzahl der Verarbeiteten Nutzdatensätze.")
        /** @var int|null */
        public ?int $verarbeiteteNds=null,

        /** @description Anzahl der nichtverarbeiteten Nutzdatensätze. */
        // @ApiMember(Description="Anzahl der nichtverarbeiteten Nutzdatensätze.")
        /** @var int|null */
        public ?int $nichtverarbeiteteNds=null,

        /** @description Der Datenteil des Protokolls. */
        // @ApiMember(Description="Der Datenteil des Protokolls.")
        /** @var array<NdSFehler06>|null */
        public ?array $ndSFehler=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['nutzdatenTicket'])) $this->nutzdatenTicket = $o['nutzdatenTicket'];
        if (isset($o['code'])) $this->code = $o['code'];
        if (isset($o['text'])) $this->text = $o['text'];
        if (isset($o['verarbeiteteNds'])) $this->verarbeiteteNds = $o['verarbeiteteNds'];
        if (isset($o['nichtverarbeiteteNds'])) $this->nichtverarbeiteteNds = $o['nichtverarbeiteteNds'];
        if (isset($o['ndSFehler'])) $this->ndSFehler = JsonConverters::fromArray('NdSFehler06', $o['ndSFehler']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->nutzdatenTicket)) $o['nutzdatenTicket'] = $this->nutzdatenTicket;
        if (isset($this->code)) $o['code'] = $this->code;
        if (isset($this->text)) $o['text'] = $this->text;
        if (isset($this->verarbeiteteNds)) $o['verarbeiteteNds'] = $this->verarbeiteteNds;
        if (isset($this->nichtverarbeiteteNds)) $o['nichtverarbeiteteNds'] = $this->nichtverarbeiteteNds;
        if (isset($this->ndSFehler)) $o['ndSFehler'] = JsonConverters::toArray('NdSFehler06', $this->ndSFehler);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Stellt den Datenteil eines Protokolls dar. */
// @Api(Description="Stellt den Datenteil eines Protokolls dar.")
class DatenTeil06 implements JsonSerializable
{
    public function __construct(
        /** @description Das Transferticket der Datenlieferung. */
        // @ApiMember(Description="Das Transferticket der Datenlieferung.")
        /** @var string|null */
        public ?string $transferTicket=null,

        /** @description Der Statuscode zur gesamten Datenlieferung. 0 (Datenlieferung ok - Alle Datensätze konnten verarbeitet werden). 1 (Es sind Fehler aufgetreten - die Nutzdatenblöcke konnten nur teilweise verarbeitet werden). 2 (Datenlieferung konnte gar nicht verarbeitet werden - alle Nutzdatenblöcke fehlerhaft). 3 (Datenlieferung wurde noch nicht verarbeitet - bitte fordern Sie das Protokoll noch mal zu einen späteren Zeitpunkt an; für Onlinebetrieb relevant). */
        // @ApiMember(Description="Der Statuscode zur gesamten Datenlieferung. 0 (Datenlieferung ok - Alle Datensätze konnten verarbeitet werden). 1 (Es sind Fehler aufgetreten - die Nutzdatenblöcke konnten nur teilweise verarbeitet werden). 2 (Datenlieferung konnte gar nicht verarbeitet werden - alle Nutzdatenblöcke fehlerhaft). 3 (Datenlieferung wurde noch nicht verarbeitet - bitte fordern Sie das Protokoll noch mal zu einen späteren Zeitpunkt an; für Onlinebetrieb relevant).")
        /** @var int|null */
        public ?int $code=null,

        /** @description Der Datenteil des Protokolls.Datenlieferung ok - Alle Datensätze konnten verarbeitet werden. Es sind Fehler aufgetreten - die Nutzdatenblöcke konnten nur teilweise verarbeitet werden. Datenlieferung konnte gar nicht verarbeitet werden - alle Nutzdatenblöcke fehlerhaft. 3Datenlieferung wurde noch nicht verarbeitet - bitte fordern Sie das Protokoll noch mal zu einen späteren Zeitpunkt an; für Onlinebetrieb relevant. */
        // @ApiMember(Description="Der Datenteil des Protokolls.Datenlieferung ok - Alle Datensätze konnten verarbeitet werden. Es sind Fehler aufgetreten - die Nutzdatenblöcke konnten nur teilweise verarbeitet werden. Datenlieferung konnte gar nicht verarbeitet werden - alle Nutzdatenblöcke fehlerhaft. 3Datenlieferung wurde noch nicht verarbeitet - bitte fordern Sie das Protokoll noch mal zu einen späteren Zeitpunkt an; für Onlinebetrieb relevant.")
        /** @var string|null */
        public ?string $text=null,

        /** @description Der Datenteil des Protokolls. */
        // @ApiMember(Description="Der Datenteil des Protokolls.")
        /** @var array<Nutzdatenblock06>|null */
        public ?array $nutzdatenbloecke=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['transferTicket'])) $this->transferTicket = $o['transferTicket'];
        if (isset($o['code'])) $this->code = $o['code'];
        if (isset($o['text'])) $this->text = $o['text'];
        if (isset($o['nutzdatenbloecke'])) $this->nutzdatenbloecke = JsonConverters::fromArray('Nutzdatenblock06', $o['nutzdatenbloecke']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->transferTicket)) $o['transferTicket'] = $this->transferTicket;
        if (isset($this->code)) $o['code'] = $this->code;
        if (isset($this->text)) $o['text'] = $this->text;
        if (isset($this->nutzdatenbloecke)) $o['nutzdatenbloecke'] = JsonConverters::toArray('Nutzdatenblock06', $this->nutzdatenbloecke);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Das Verarbeitungsprotokoll einer Datenabholungsprozesses. */
// @Api(Description="Das Verarbeitungsprotokoll einer Datenabholungsprozesses.")
class Protokoll06 implements JsonSerializable
{
    public function __construct(
        /** @description Version des Protokolls. */
        // @ApiMember(Description="Version des Protokolls.", Name="Version")
        /** @var int|null */
        public ?int $version=null,

        /** @description Der Zeitstempel der Protokoll-Aufbereitung. Es wird der Zeitstempel der serverseitigen Verarbeitung der Protokollanfrage zurück übermittelt. Das String-Format des ZeitStempels lautet: JJJJMMTThhmmss. */
        // @ApiMember(Description="Der Zeitstempel der Protokoll-Aufbereitung. Es wird der Zeitstempel der serverseitigen Verarbeitung der Protokollanfrage zurück übermittelt. Das String-Format des ZeitStempels lautet: JJJJMMTThhmmss.", Name="ZeitStempel")
        /** @var DateTime|null */
        public ?DateTime $zeitStempel=null,

        /** @description Der Datenteil des Protokolls. */
        // @ApiMember(Description="Der Datenteil des Protokolls.", Name="DatenTeil")
        /** @var DatenTeil06|null */
        public ?DatenTeil06 $datenTeil=null
    ) {
    }

    /** @throws Exception */
    public function fromMap($o): void {
        if (isset($o['version'])) $this->version = $o['version'];
        if (isset($o['zeitStempel'])) $this->zeitStempel = JsonConverters::from('DateTime', $o['zeitStempel']);
        if (isset($o['datenTeil'])) $this->datenTeil = JsonConverters::from('DatenTeil06', $o['datenTeil']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = [];
        if (isset($this->version)) $o['version'] = $this->version;
        if (isset($this->zeitStempel)) $o['zeitStempel'] = JsonConverters::to('DateTime', $this->zeitStempel);
        if (isset($this->datenTeil)) $o['datenTeil'] = JsonConverters::to('DatenTeil06', $this->datenTeil);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents a type that encapulates the processing records of a tax statement. */
// @Api(Description="Represents a type that encapulates the processing records of a tax statement.")
class ProtokollResponse extends ServiceReponseBase implements JsonSerializable
{
    /**
     * @param string $id
     * @param int $index
     * @param ResponseStatus|null $responseStatus
     */
    public function __construct(
        string $id='',
        int $index=0,
        ?ResponseStatus $responseStatus=null,
        /** @description The processing record of a tax statement. */
        // @ApiMember(Description="The processing record of a tax statement.", Name="Protokoll")
        /** @var Protokoll06|null */
        public ?Protokoll06 $protokoll=null
    ) {
        parent::__construct($id,$index,$responseStatus);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['protokoll'])) $this->protokoll = JsonConverters::from('Protokoll06', $o['protokoll']);
        if (isset($o['id'])) $this->id = $o['id'];
        if (isset($o['index'])) $this->index = $o['index'];
        if (isset($o['responseStatus'])) $this->responseStatus = JsonConverters::from('ResponseStatus', $o['responseStatus']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->protokoll)) $o['protokoll'] = JsonConverters::to('Protokoll06', $this->protokoll);
        if (isset($this->id)) $o['id'] = $this->id;
        if (isset($this->index)) $o['index'] = $this->index;
        if (isset($this->responseStatus)) $o['responseStatus'] = JsonConverters::to('ResponseStatus', $this->responseStatus);
        return empty($o) ? new class(){} : $o;
    }
}

/** @description Represents the service request to retrieve logs about a specified tax assessement. */
// @Api(Description="Represents the service request to retrieve logs about a specified tax assessement.")
class ProtokollRequest17 extends ProtokollRequestBase17 implements JsonSerializable
{
    /**
     * @param PortalCertificate|null $zertifikat
     * @param Abholung17|null $bescheid
     * @param PortalCertificate|null $zertifikat
     */
    public function __construct(
        ?PortalCertificate $zertifikat=null,
        ?Abholung17 $bescheid=null,
        ?PortalCertificate $zertifikat=null
    ) {
        parent::__construct($zertifikat,$bescheid,$zertifikat);
    }

    /** @throws Exception */
    public function fromMap($o): void {
        parent::fromMap($o);
        if (isset($o['bescheid'])) $this->bescheid = JsonConverters::from('Abholung17', $o['bescheid']);
        if (isset($o['zertifikat'])) $this->zertifikat = JsonConverters::from('PortalCertificate', $o['zertifikat']);
    }
    
    /** @throws Exception */
    public function jsonSerialize(): mixed
    {
        $o = parent::jsonSerialize();
        if (isset($this->bescheid)) $o['bescheid'] = JsonConverters::to('Abholung17', $this->bescheid);
        if (isset($this->zertifikat)) $o['zertifikat'] = JsonConverters::to('PortalCertificate', $this->zertifikat);
        return empty($o) ? new class(){} : $o;
    }
}

PHP ProtokollRequest17 DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /datenabholungen/protokolle/17/verarbeitungsprotokoll HTTP/1.1 
Host: taxfiling.pwc.de 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"bescheid":{"steuerart":"ESB","metaInformationen":{"meta":[{"name":"String","coding":"text","value":"String"}],"metaInfoMaps":[{"typ":"String","meta":[{"name":"String","coding":"text","value":"String"}]}]},"bereitstellungsticket":"String","anhaenge":[{"metadatenAnhang":[{"schluesselAnhang":{"dateibezeichnungID":"String","dateibezeichnungKurz":"String","value":"String"},"wertAnhang":{"dateibezeichnungID":"String","dateibezeichnungKurz":"String","value":"String"}}],"dateibezeichnung":"String","dateityp":"String","dateiinhalt":"String"}],"id":"String","idnr":"String","veranlagungsjahr":0,"uebertragungsweg":"direkt","encoding":"String","mandantennummer":"String","steuernummer":"String","bescheiddatum":"\/Date(-62135596800000-0000)\/","datenpaket":{"value":"String"},"download":{"url":"String","benutzer":"String","passwort":"String"}},"zertifikat":{"id":"00000000000000000000000000000000","index":0,"pin":"String","description":"String","tags":["String"],"name":"String","content":"AA=="}}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"protokoll":{"version":0,"zeitStempel":"\/Date(-62135596800000-0000)\/","datenTeil":{"transferTicket":"String","code":0,"text":"String","nutzdatenbloecke":[{"nutzdatenTicket":"String","code":0,"text":"String","verarbeiteteNds":0,"nichtverarbeiteteNds":0,"ndSFehler":[{"lfdNr":"String","kmId":"String","ordnungsMerkmal":"String","fehlerNummer":0,"fehlerText":"String"}]}]}},"id":"String","index":0,"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}