Tax Filing Service

<back to all web services

GetDefinitionKeysAsync

AsyncUmsatzsteuerKeysReturnBuilder

An asynchronous service to retrieve keys for the identification of VAT properties.

Requires Authentication
The following routes are available for this service:
GET/GetDefinitionKeysAsyncAn asynchronous service to retrieve keys for the identification of VAT properties.
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

enum VatType
{
    UStVA,
    UStDV,
    UStSV,
    USt,
    ZM,
}

/**
* Create a VAT return from a Return Builder definition. Use the retrieved values as keys for the dictionary of properties that Return Builder provides.
*/
// @Api(Description="Create a VAT return from a Return Builder definition.\n Use the retrieved values as keys for the dictionary of properties that Return Builder provides.")
abstract class GetDefinitionKeysBase implements IGet
{
    /**
    * The year of the assessment (Veranlagungsjahr).
    */
    // @ApiMember(Description="The year of the assessment (Veranlagungsjahr).")
    int? year;

    /**
    * The type of VAT return.
    */
    // @ApiMember(Description="The type of VAT return.")
    VatType? vatType;

    GetDefinitionKeysBase({this.year,this.vatType});
    GetDefinitionKeysBase.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        year = json['year'];
        vatType = JsonConverters.fromJson(json['vatType'],'VatType',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'year': year,
        'vatType': JsonConverters.toJson(vatType,'VatType',context!)
    };

    getTypeName() => "GetDefinitionKeysBase";
    TypeContext? context = _ctx;
}

/**
* An asynchronous service to retrieve keys for the identification of VAT properties.
*/
// @Api(Description="An asynchronous service to retrieve keys for the identification of VAT properties.")
class GetDefinitionKeysAsync extends GetDefinitionKeysBase implements IConvertible
{
    /**
    * The year of the assessment (Veranlagungsjahr).
    */
    // @ApiMember(Description="The year of the assessment (Veranlagungsjahr).")
    int? year;

    /**
    * The type of VAT return.
    */
    // @ApiMember(Description="The type of VAT return.")
    VatType? vatType;

    GetDefinitionKeysAsync({this.year,this.vatType});
    GetDefinitionKeysAsync.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        super.fromMap(json);
        year = json['year'];
        vatType = JsonConverters.fromJson(json['vatType'],'VatType',context!);
        return this;
    }

    Map<String, dynamic> toJson() => super.toJson()..addAll({
        'year': year,
        'vatType': JsonConverters.toJson(vatType,'VatType',context!)
    });

    getTypeName() => "GetDefinitionKeysAsync";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'taxfiling.pwc.de', types: <String, TypeInfo> {
    'VatType': TypeInfo(TypeOf.Enum, enumValues:VatType.values),
    'GetDefinitionKeysBase': TypeInfo(TypeOf.AbstractClass),
    'GetDefinitionKeysAsync': TypeInfo(TypeOf.Class, create:() => GetDefinitionKeysAsync()),
});

Dart GetDefinitionKeysAsync 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.

GET /GetDefinitionKeysAsync HTTP/1.1 
Host: taxfiling.pwc.de 
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<ArrayOfDefinitionKey xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/PwC.xEric.Core.Services.Contracts.Umsatzsteuer.ReturnBuilder.Helpers">
  <DefinitionKey>
    <Description>String</Description>
    <Mandatory>String</Mandatory>
    <Name>String</Name>
    <Type>String</Type>
  </DefinitionKey>
</ArrayOfDefinitionKey>