DX STF Client API

<back to all web services

UpdateDebitNoteClientProcessed

Debit Note Requests

Debit Note

Requires Authentication
The following routes are available for this service:
PUT/api/debitNote/{DebitNoteId}/processedUpdate debit note as customer processed, will also acknowledge credit note if not yet set.
import 'package:servicestack/servicestack.dart';

class TokenDto implements ICommandResponse, IConvertible
{
    String token = "";

    TokenDto({this.token});
    TokenDto.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        token = json['token'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'token': token
    };

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

/**
* Debit Note
*/
// @Api(Description="Debit Note")
// @ApiResponse(Description="Command received", IsDefaultResponse=true, ResponseType=typeof(TokenDto), StatusCode=202)
class UpdateDebitNoteClientProcessed implements IConvertible
{
    /**
    * Debit Note ID or Token
    */
    // @ApiMember(Description="Debit Note ID or Token", ParameterType="path")
    String debitNoteId = "";

    /**
    * Customer debit note reference in destination system
    */
    // @ApiMember(Description="Customer debit note reference in destination system")
    String customerReference = "";

    /**
    * Date and Time debit note was processed in destination system
    */
    // @ApiMember(Description="Date and Time debit note was processed in destination system")
    DateTime customerProcessedDate = DateTime(0);

    UpdateDebitNoteClientProcessed({this.debitNoteId,this.customerReference,this.customerProcessedDate});
    UpdateDebitNoteClientProcessed.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        debitNoteId = json['debitNoteId'];
        customerReference = json['customerReference'];
        customerProcessedDate = JsonConverters.fromJson(json['customerProcessedDate'],'DateTime',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'debitNoteId': debitNoteId,
        'customerReference': customerReference,
        'customerProcessedDate': JsonConverters.toJson(customerProcessedDate,'DateTime',context!)
    };

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

TypeContext _ctx = TypeContext(library: 'stf_api_uat.data_xchange.co.za', types: <String, TypeInfo> {
    'TokenDto': TypeInfo(TypeOf.Class, create:() => TokenDto()),
    'UpdateDebitNoteClientProcessed': TypeInfo(TypeOf.Class, create:() => UpdateDebitNoteClientProcessed()),
});

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

PUT /api/debitNote/{DebitNoteId}/processed HTTP/1.1 
Host: stf-api-uat.data-xchange.co.za 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	customerReference: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length

{
	
}