Tax Filing Service

<back to all web services

BatchProtokollRequest17Async

AsyncDatenabholungVerarbeitungsprotokolleBatch

Represents the service request to retrieve logs about tax statements.

Requires Authentication
The following routes are available for this service:
POST/async/datenabholungen/protokolle/17/verarbeitungsprotokoll/batch
import datetime
import decimal
from marshmallow.fields import *
from servicestack import *
from typing import *
from dataclasses import dataclass, field
from dataclasses_json import dataclass_json, LetterCase, Undefined, config
from enum import Enum, IntEnum


# @Api(Description="Represents a base class for a file with raw data.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class FileBase:
    """
    Represents a base class for a file with raw data.
    """

    # @ApiMember(Description="The raw data content of the file.", Name="Content")
    content: Optional[bytes] = None
    """
    The raw data content of the file.
    """


# @Api(Description="Represents a portal certificate that is protected by a password.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class PortalCertificate(FileBase, ISecuredCertificate, IHasIndex):
    """
    Represents a portal certificate that is protected by a password.
    """

    # @ApiMember(Description="The unique identifier of the certificate.")
    id: Optional[str] = None
    """
    The unique identifier of the certificate.
    """


    # @ApiMember(Description="The position of the certificate element in an indexed collection of certificates.")
    index: int = 0
    """
    The position of the certificate element in an indexed collection of certificates.
    """


    # @StringLength(255)
    # @ApiMember(Description="The password to protect the certificate from unauthorized access.")
    pin: Optional[str] = None
    """
    The password to protect the certificate from unauthorized access.
    """


    # @StringLength(2147483647)
    # @ApiMember(Description="The description of the certificate.")
    description: Optional[str] = None
    """
    The description of the certificate.
    """


    # @ApiMember(Description="Tags that can be used to label or identify the certificate.")
    tags: Optional[List[str]] = None
    """
    Tags that can be used to label or identify the certificate.
    """


    # @ApiMember(Description="Gets or sets the file name of the certificate.")
    name: Optional[str] = None
    """
    Gets or sets the file name of the certificate.
    """


    # @ApiMember(Description="The raw data content of the file.", Name="Content")
    content: Optional[bytes] = None
    """
    The raw data content of the file.
    """


# @Api(Description="Represents a base service request to retrieve processing records from specified tax statements.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BatchProtokollRequestBase(IReturn[List[ProtokollResponse]], IPost):
    """
    Represents a base service request to retrieve processing records from specified tax statements.
    """

    # @ApiMember(Description="The authentification certificate.", IsRequired=true, Name="Zertifikat")
    zertifikat: Optional[PortalCertificate] = None
    """
    The authentification certificate.
    """
    @staticmethod
    def response_type(): return List[ProtokollResponse]


class Uebertragungsweg(str, Enum):
    """
    Represents the transmission path.
    """

    DIREKT = 'direkt'
    LINK = 'link'
    SAMMELLINK = 'sammellink'


# @Api(Description="The data packet from the retrieval operation.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Datenpaket:
    """
    The data packet from the retrieval operation.
    """

    # @ApiMember(Description="Encoded (compressed and encrypted) requested data record")
    value: Optional[str] = None
    """
    Encoded (compressed and encrypted) requested data record
    """


# @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.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Download:
    """
    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.
    """

    # @ApiMember(Description="The link to the data on the web server.")
    url: Optional[str] = None
    """
    The link to the data on the web server.
    """


    # @ApiMember(Description="The user name for the web server.")
    benutzer: Optional[str] = None
    """
    The user name for the web server.
    """


    # @ApiMember(Description="Password for the web server.")
    passwort: Optional[str] = None
    """
    Password for the web server.
    """


# @Api(Description="Represents the request to retrieve tax assessments by means of a specfied ID.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Abholung:
    """
    Represents the request to retrieve tax assessments by means of a specfied ID.
    """

    # @ApiMember(Description="The identifier of the data record.")
    id: Optional[str] = None
    """
    The identifier of the data record.
    """


    # @ApiMember(Description="The ID number of the receipt owner. This attribute is only required for the tax type 'ElsterVaStDaten'.")
    idnr: Optional[str] = None
    """
    The ID number of the receipt owner. 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'.")
    veranlagungsjahr: Optional[int] = None
    """
    The assessment year (YYYY) of the receipt. This attribute is only required for the tax type 'ElsterVaStDaten'.
    """


    # @ApiMember(Description="The transmission path used.")
    uebertragungsweg: Optional[Uebertragungsweg] = None
    """
    The transmission path used.
    """


    # @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.")
    encoding: Optional[str] = None
    """
    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 client number; only applicable to the tax type 'ElsterDIVADaten'.")
    mandantennummer: Optional[str] = None
    """
    The client number; only applicable to the tax type 'ElsterDIVADaten'.
    """


    # @ApiMember(Description="The tax number; only applicable to the tax type 'ElsterDIVADaten'.")
    steuernummer: Optional[str] = None
    """
    The tax number; only applicable to the tax type 'ElsterDIVADaten'.
    """


    # @ApiMember(Description="The asessment date; only applicable to the tax type 'ElsterDIVADaten'.")
    bescheiddatum: Optional[datetime.datetime] = None
    """
    The asessment date; only applicable to the tax type 'ElsterDIVADaten'.
    """


    # @ApiMember(Description="Das Datenpaket angeforderter Datensaetze. Nur bei der Direktsendung ueber das ERiClet.")
    datenpaket: Optional[Datenpaket] = None
    """
    Das Datenpaket angeforderter Datensaetze. Nur bei der Direktsendung ueber das ERiClet.
    """


    # @ApiMember(Description="Download requested data records.  Ensure the second payload data block  is empty for bulk retrieval operations.")
    download: Optional[Download] = None
    """
    Download requested data records.  Ensure the second payload data block  is empty for bulk retrieval operations.
    """


class Steuerart(str, Enum):
    """
    Represents the various tax types for the retrieval of data.
    """

    ESB = 'ESB'
    GSB = 'GSB'
    USB = 'USB'
    EP_BESCHEID = 'EPBescheid'
    EP_MITTEILUNG = 'EPMitteilung'
    GEWERBESTEUERBESCHEID = 'Gewerbesteuerbescheid'
    GEWERBESTEUERMITTEILUNG = 'Gewerbesteuermitteilung'
    GEWMB = 'GEWMB'
    DIVA_ANZEIGE_EINER_LOTTERIE = 'DIVAAnzeigeEinerLotterie'
    DIVA_BESCHEID = 'DIVABescheid'
    DIVA_BESCHEID_E_ST = 'DivaBescheidESt'
    DIVA_BUCHMACHERSTEUER = 'DIVABuchmachersteuer'
    DIVA_LOTTERIESTEUER_EINMAL = 'DIVALotteriesteuerEinmal'
    DIVA_LOTTERIESTEUER_MEHR = 'DIVALotteriesteuerMehr'
    DIVA_SPORTWETTENSTEUER = 'DIVASportwettensteuer'
    DIVA_TOTALISATOR = 'DIVATotalisator'
    OZG_BESCHEID = 'OZGBescheid'
    VERBINDLICHE_AUSKUNFT = 'VerbindlicheAuskunft'
    VERBINDLICHE_ZUSAGE = 'VerbindlicheZusage'
    DIVA_SONSTIGER_V_A = 'DivaSonstigerVA'
    DIVA_BESCHEID_ERB_ST = 'DivaBescheidErbSt'
    DIVA_BESCHEID_F_E_I_N = 'DivaBescheidFEIN'
    DIVA_BESCHEID_GEW_ST = 'DivaBescheidGewSt'
    DIVA_BESCHEID_K_ST = 'DivaBescheidKSt'
    DIVA_BESCHEID_U_ST = 'DivaBescheidUSt'
    DIVA_BESCHEID_SCHENK_ST = 'DivaBescheidSchenkSt'
    DIVA_TRONCABGABE = 'DIVATroncabgabe'
    DIVA_VIRTUELLE_AUTOMATEN_ST_B = 'DIVAVirtuelleAutomatenStB'
    DIVA_ONLINE_POKER_ST_B = 'DIVAOnlinePokerStB'
    L_ST_H_V_V_M_R_M = 'LStHVVMRM'
    EINLAGENRUECKGEWAEHR_V_A = 'EinlagenrueckgewaehrVA'
    FTT_MELDUNG_V_A = 'FTTMeldungVA'
    STATUS_INV_ST_G_V_A = 'StatusInvStGVA'
    U_ST_V_E_U_V_A = 'UStVEUVA'
    VERSVA = 'VERSVA'
    ALT_ZERT_V_A = 'AltZertVA'
    KAP_E_ST_ENTLASTUNG_V_A = 'KapEStEntlastungVA'
    POST_U_D_L_V_A = 'PostUDLVA'
    ST_AB50A_V_A = 'StAb50aVA'
    ST_AB_ENTLASTUNG_V_A = 'StAbEntlastungVA'
    KASSENANGELEGENHEITEN_V_A = 'KassenangelegenheitenVA'
    K_ST_OPT_V_A = 'KStOptVA'
    STEUEROASENABWEHR_V_A = 'SteueroasenabwehrVA'
    KDB_VOLLMACHT_R_M = 'KDBVollmachtRM'
    STBKE = 'STBKE'
    VDBKDB_RUECKMELDUNG_LIEF = 'VDBKDBRueckmeldungLief'
    ANHANG_RUECKMELDUNG = 'AnhangRueckmeldung'
    DIVA_EINWILLIGUNG_R_M = 'DivaEinwilligungRM'
    GLUECKSPIEL_F = 'GlueckspielF'
    OZG_MITTEILUNG = 'OZGMitteilung'
    VERBINDLICHE_AUSKUNFT_INFO_F = 'VerbindlicheAuskunftInfoF'
    ELO_PROTOKOLL = 'ELOProtokoll'


class Coding(str, Enum):
    """
    Specifies the encoding of the metadata.
    """

    TEXT = 'text'
    BASE64 = 'base64'


# @Api(Description="Represents the metadata of a data record.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Meta17:
    """
    Represents the metadata of a data record.
    """

    # @ApiMember(Description="The type of metadata, e.g. datei [file]")
    name: Optional[str] = None
    """
    The type of metadata, e.g. datei [file]
    """


    # @ApiMember(Description="The encoding of the metadata (text or base64)")
    coding: Optional[Coding] = None
    """
    The encoding of the metadata (text or base64)
    """


    # @ApiMember(Description="The content of the metadata")
    value: Optional[str] = None
    """
    The content of the metadata
    """


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class MetaInfoMaps17:
    """
    Represents a list of meta information maps.
    """

    pass


# @Api(Description="Represents meta information.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class MetaInformationen17:
    """
    Represents meta information.
    """

    # @ApiMember(Description="List of metadata.")
    meta: Optional[List[Meta17]] = None
    """
    List of metadata.
    """


    # @ApiMember(Description="List of meta infomation maps.")
    meta_info_maps: Optional[MetaInfoMaps17] = None
    """
    List of meta infomation maps.
    """


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Anhaenge17:
    """
    Represents a list of attachments.
    """

    pass


# @Api(Description="Represents a request to retrieve data records by means of one or more IDs.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class Abholung17(Abholung):
    """
    Represents a request to retrieve data records by means of one or more IDs.
    """

    # @ApiMember(Description="The tax type (e.g. ESB) of the data record.")
    steuerart: Optional[Steuerart] = None
    """
    The tax type (e.g. ESB) of the data record.
    """


    # @ApiMember(Description="The meta information of the identifier.")
    meta_informationen: Optional[MetaInformationen17] = None
    """
    The meta information of the identifier.
    """


    # @ApiMember(Description="Die Transfertickets der Datensaetze. Es duerfen max. 100 Bereitstellungstickets in einem Request angegeben werden.")
    bereitstellungsticket: Optional[str] = None
    """
    Die Transfertickets der Datensaetze. Es duerfen max. 100 Bereitstellungstickets in einem Request angegeben werden.
    """


    # @ApiMember(Description="The attachments of the data records.")
    anhaenge: Optional[Anhaenge17] = None
    """
    The attachments of the data records.
    """


    # @ApiMember(Description="The identifier of the data record.")
    id: Optional[str] = None
    """
    The identifier of the data record.
    """


    # @ApiMember(Description="The ID number of the receipt owner. This attribute is only required for the tax type 'ElsterVaStDaten'.")
    idnr: Optional[str] = None
    """
    The ID number of the receipt owner. 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'.")
    veranlagungsjahr: Optional[int] = None
    """
    The assessment year (YYYY) of the receipt. This attribute is only required for the tax type 'ElsterVaStDaten'.
    """


    # @ApiMember(Description="The transmission path used.")
    uebertragungsweg: Optional[Uebertragungsweg] = None
    """
    The transmission path used.
    """


    # @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.")
    encoding: Optional[str] = None
    """
    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 client number; only applicable to the tax type 'ElsterDIVADaten'.")
    mandantennummer: Optional[str] = None
    """
    The client number; only applicable to the tax type 'ElsterDIVADaten'.
    """


    # @ApiMember(Description="The tax number; only applicable to the tax type 'ElsterDIVADaten'.")
    steuernummer: Optional[str] = None
    """
    The tax number; only applicable to the tax type 'ElsterDIVADaten'.
    """


    # @ApiMember(Description="The asessment date; only applicable to the tax type 'ElsterDIVADaten'.")
    bescheiddatum: Optional[datetime.datetime] = None
    """
    The asessment date; only applicable to the tax type 'ElsterDIVADaten'.
    """


    # @ApiMember(Description="Das Datenpaket angeforderter Datensaetze. Nur bei der Direktsendung ueber das ERiClet.")
    datenpaket: Optional[Datenpaket] = None
    """
    Das Datenpaket angeforderter Datensaetze. Nur bei der Direktsendung ueber das ERiClet.
    """


    # @ApiMember(Description="Download requested data records.  Ensure the second payload data block  is empty for bulk retrieval operations.")
    download: Optional[Download] = None
    """
    Download requested data records.  Ensure the second payload data block  is empty for bulk retrieval operations.
    """


# @Api(Description="Represents a base service request to retrieve processing records from specified tax statements. Applicable to version 17..")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BatchProtokollRequestBase17(BatchProtokollRequestBase):
    """
    Represents a base service request to retrieve processing records from specified tax statements. Applicable to version 17..
    """

    # @ApiMember(Description="The tax assessements, whose processing records shall be obtained.", Name="Bescheide")
    bescheide: Optional[List[Abholung17]] = None
    """
    The tax assessements, whose processing records shall be obtained.
    """


    # @ApiMember(Description="The authentification certificate.", IsRequired=true, Name="Zertifikat")
    zertifikat: Optional[PortalCertificate] = None
    """
    The authentification certificate.
    """


# @Api(Description="Represents the service request to retrieve logs about tax statements.")
@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BatchProtokollRequest17Async(BatchProtokollRequestBase17):
    """
    Represents the service request to retrieve logs about tax statements.
    """

    # @ApiMember(Description="The tax assessements, whose processing records shall be obtained.", Name="Bescheide")
    bescheide: Optional[List[Abholung17]] = None
    """
    The tax assessements, whose processing records shall be obtained.
    """


    # @ApiMember(Description="The authentification certificate.", IsRequired=true, Name="Zertifikat")
    zertifikat: Optional[PortalCertificate] = None
    """
    The authentification certificate.
    """

Python BatchProtokollRequest17Async DTOs

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

HTTP + XML

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

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

<BatchProtokollRequest17Async xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Services.Contracts.Datenabholungen.Requests.Protokolle">
  <Zertifikat xmlns:d2p1="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Domain.Concretes.Models">
    <Content xmlns="http://schemas.datacontract.org/2004/07/PwC.DigitalHub.Utilities.IO.Core.Contracts.Models">AA==</Content>
    <d2p1:Description>String</d2p1:Description>
    <d2p1:Id>00000000-0000-0000-0000-000000000000</d2p1:Id>
    <d2p1:Index>0</d2p1:Index>
    <d2p1:Name>String</d2p1:Name>
    <d2p1:Pin>String</d2p1:Pin>
    <d2p1:Tags xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>String</d3p1:string>
    </d2p1:Tags>
  </Zertifikat>
  <Bescheide xmlns:d2p1="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Domain.Concretes.Datenabholungen.Models">
    <d2p1:Abholung17 id="String" idnr="String" veranlagungsjahr="0" uebertragungsweg="direkt" encoding="String" bereitstellungsticket="String">
      <MetaInformationen>
        <Meta art="String" coding="text">String</Meta>
        <MetaInfoMaps>
          <MetaInfoMap typ="String">
            <Meta art="String" coding="text">String</Meta>
          </MetaInfoMap>
        </MetaInfoMaps>
      </MetaInformationen>
      <Datenpaket>String</Datenpaket>
      <Download>
        <Url>String</Url>
        <Benutzer>String</Benutzer>
        <Passwort>String</Passwort>
      </Download>
      <Anhaenge version="0">
        <Anhang>
          <Dateibezeichnung>String</Dateibezeichnung>
          <Dateityp>String</Dateityp>
          <Dateiinhalt>String</Dateiinhalt>
          <MetadatumAnhang>
            <SchluesselAnhang DateibezeichnungID="String" DateibezeichnungKurz="String">String</SchluesselAnhang>
            <WertAnhang DateibezeichnungID="String" DateibezeichnungKurz="String">String</WertAnhang>
          </MetadatumAnhang>
        </Anhang>
      </Anhaenge>
    </d2p1:Abholung17>
  </Bescheide>
</BatchProtokollRequest17Async>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<ArrayOfProtokollResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Services.Contracts.Datenabholungen.Responses">
  <ProtokollResponse>
    <Id xmlns="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Services.Contracts.Responses">String</Id>
    <Index xmlns="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Services.Contracts.Responses">0</Index>
    <ResponseStatus xmlns:d3p1="http://schemas.servicestack.net/types" xmlns="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Services.Contracts.Responses">
      <d3p1:ErrorCode>String</d3p1:ErrorCode>
      <d3p1:Message>String</d3p1:Message>
      <d3p1:StackTrace>String</d3p1:StackTrace>
      <d3p1:Errors>
        <d3p1:ResponseError>
          <d3p1:ErrorCode>String</d3p1:ErrorCode>
          <d3p1:FieldName>String</d3p1:FieldName>
          <d3p1:Message>String</d3p1:Message>
          <d3p1:Meta xmlns:d6p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
            <d6p1:KeyValueOfstringstring>
              <d6p1:Key>String</d6p1:Key>
              <d6p1:Value>String</d6p1:Value>
            </d6p1:KeyValueOfstringstring>
          </d3p1:Meta>
        </d3p1:ResponseError>
      </d3p1:Errors>
      <d3p1:Meta xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
        <d4p1:KeyValueOfstringstring>
          <d4p1:Key>String</d4p1:Key>
          <d4p1:Value>String</d4p1:Value>
        </d4p1:KeyValueOfstringstring>
      </d3p1:Meta>
    </ResponseStatus>
    <Protokoll version="0" xmlns="http://www.elsterfachmethodik.de/protokollverfahren/version6/XMLSchema">
      <ZeitStempel>00010101000000</ZeitStempel>
      <DatenTeil transferTicket="String" code="0" text="String">
        <Nutzdatenblock nutzdatenTicket="String" code="0" text="String" verarbeiteteNdS="0" nichtverarbeiteteNdS="0">
          <NdSFehler lfdNr="String" kmId="String" ordnungsMerkmal="String" fehlerNummer="0" fehlerText="String" />
        </Nutzdatenblock>
      </DatenTeil>
    </Protokoll>
  </ProtokollResponse>
</ArrayOfProtokollResponse>