Tax Filing Service

<back to all web services

BatchProtokollRequest17

SyncDatenabholungVerarbeitungsprotokolleBatch

Represents the service request to retrieve logs about tax statements.

Requires Authentication
The following routes are available for this service:
POST/datenabholungen/protokolle/17/verarbeitungsprotokoll/batch
<?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 specified tax statements. */
// @Api(Description="Represents a base service request to retrieve processing records from specified tax statements.")
class BatchProtokollRequestBase 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 processing records from specified tax statements. Applicable to version 17.. */
// @Api(Description="Represents a base service request to retrieve processing records from specified tax statements. Applicable to version 17..")
class BatchProtokollRequestBase17 extends BatchProtokollRequestBase implements JsonSerializable
{
    /**
     * @param PortalCertificate|null $zertifikat
     */
    public function __construct(
        ?PortalCertificate $zertifikat=null,
        /** @description The tax assessements, whose processing records shall be obtained. */
        // @ApiMember(Description="The tax assessements, whose processing records shall be obtained.", Name="Bescheide")
        /** @var array<Abholung17>|null */
        public ?array $bescheide=null
    ) {
        parent::__construct($zertifikat);
    }

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

/** @description Represents the service request to retrieve logs about tax statements. */
// @Api(Description="Represents the service request to retrieve logs about tax statements.")
class BatchProtokollRequest17 extends BatchProtokollRequestBase17 implements JsonSerializable
{
    /**
     * @param PortalCertificate|null $zertifikat
     * @param array<Abholung17>|null $bescheide
     * @param PortalCertificate|null $zertifikat
     */
    public function __construct(
        ?PortalCertificate $zertifikat=null,
        ?array $bescheide=null,
        ?PortalCertificate $zertifikat=null
    ) {
        parent::__construct($zertifikat,$bescheide,$zertifikat);
    }

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

PHP BatchProtokollRequest17 DTOs

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

HTTP + JSV

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

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

{
	bescheide: 
	[
		{
			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: 0001-01-01,
			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/jsv
Content-Length: length

[
	{
		protokoll: 
		{
			version: 0,
			zeitStempel: 0001-01-01,
			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
			}
		}
	}
]