| Requires the role: | Admin |
| POST | /recurringPayments/run-charge |
|---|
import 'package:servicestack/servicestack.dart';
class RecurringChargeJobSummary implements IConvertible
{
bool? masterEnabled;
bool? autoSubmitEnabled;
bool? dunningEnabled;
bool? expireLapsedEnabled;
bool? endOfTermRevokeEnabled;
int? chargeHour;
int? batchSize;
DateTime? asOfUtc;
bool? dryRun;
bool? chargeLive;
bool? dunningLive;
int? charged;
int? declined;
int? ambiguous;
int? skippedAlreadyCharged;
int? nullOwnerCharged;
int? skippedSinglePayment;
int? expiredCards;
int? endOfTermClosed;
int? endOfTermRevoked;
int? hardClosed;
int? cappedClosed;
int? expiredCardNotified;
int? checkFirst;
bool? circuitBroken;
String? circuitBreakerCode;
int? wouldCharge;
int? wouldStopHard;
int? wouldStopCapped;
int? wouldSms;
int? wouldEmail;
int? wouldClose;
int? wouldExpire;
int? wouldEndOfTermClose;
int? wouldEndOfTermRevoke;
int? smsSent;
int? emails;
int? closed;
List<String>? log;
int? statusCode;
String? message;
RecurringChargeJobSummary({this.masterEnabled,this.autoSubmitEnabled,this.dunningEnabled,this.expireLapsedEnabled,this.endOfTermRevokeEnabled,this.chargeHour,this.batchSize,this.asOfUtc,this.dryRun,this.chargeLive,this.dunningLive,this.charged,this.declined,this.ambiguous,this.skippedAlreadyCharged,this.nullOwnerCharged,this.skippedSinglePayment,this.expiredCards,this.endOfTermClosed,this.endOfTermRevoked,this.hardClosed,this.cappedClosed,this.expiredCardNotified,this.checkFirst,this.circuitBroken,this.circuitBreakerCode,this.wouldCharge,this.wouldStopHard,this.wouldStopCapped,this.wouldSms,this.wouldEmail,this.wouldClose,this.wouldExpire,this.wouldEndOfTermClose,this.wouldEndOfTermRevoke,this.smsSent,this.emails,this.closed,this.log,this.statusCode,this.message});
RecurringChargeJobSummary.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
masterEnabled = json['masterEnabled'];
autoSubmitEnabled = json['autoSubmitEnabled'];
dunningEnabled = json['dunningEnabled'];
expireLapsedEnabled = json['expireLapsedEnabled'];
endOfTermRevokeEnabled = json['endOfTermRevokeEnabled'];
chargeHour = json['chargeHour'];
batchSize = json['batchSize'];
asOfUtc = JsonConverters.fromJson(json['asOfUtc'],'DateTime',context!);
dryRun = json['dryRun'];
chargeLive = json['chargeLive'];
dunningLive = json['dunningLive'];
charged = json['charged'];
declined = json['declined'];
ambiguous = json['ambiguous'];
skippedAlreadyCharged = json['skippedAlreadyCharged'];
nullOwnerCharged = json['nullOwnerCharged'];
skippedSinglePayment = json['skippedSinglePayment'];
expiredCards = json['expiredCards'];
endOfTermClosed = json['endOfTermClosed'];
endOfTermRevoked = json['endOfTermRevoked'];
hardClosed = json['hardClosed'];
cappedClosed = json['cappedClosed'];
expiredCardNotified = json['expiredCardNotified'];
checkFirst = json['checkFirst'];
circuitBroken = json['circuitBroken'];
circuitBreakerCode = json['circuitBreakerCode'];
wouldCharge = json['wouldCharge'];
wouldStopHard = json['wouldStopHard'];
wouldStopCapped = json['wouldStopCapped'];
wouldSms = json['wouldSms'];
wouldEmail = json['wouldEmail'];
wouldClose = json['wouldClose'];
wouldExpire = json['wouldExpire'];
wouldEndOfTermClose = json['wouldEndOfTermClose'];
wouldEndOfTermRevoke = json['wouldEndOfTermRevoke'];
smsSent = json['smsSent'];
emails = json['emails'];
closed = json['closed'];
log = JsonConverters.fromJson(json['log'],'List<String>',context!);
statusCode = json['statusCode'];
message = json['message'];
return this;
}
Map<String, dynamic> toJson() => {
'masterEnabled': masterEnabled,
'autoSubmitEnabled': autoSubmitEnabled,
'dunningEnabled': dunningEnabled,
'expireLapsedEnabled': expireLapsedEnabled,
'endOfTermRevokeEnabled': endOfTermRevokeEnabled,
'chargeHour': chargeHour,
'batchSize': batchSize,
'asOfUtc': JsonConverters.toJson(asOfUtc,'DateTime',context!),
'dryRun': dryRun,
'chargeLive': chargeLive,
'dunningLive': dunningLive,
'charged': charged,
'declined': declined,
'ambiguous': ambiguous,
'skippedAlreadyCharged': skippedAlreadyCharged,
'nullOwnerCharged': nullOwnerCharged,
'skippedSinglePayment': skippedSinglePayment,
'expiredCards': expiredCards,
'endOfTermClosed': endOfTermClosed,
'endOfTermRevoked': endOfTermRevoked,
'hardClosed': hardClosed,
'cappedClosed': cappedClosed,
'expiredCardNotified': expiredCardNotified,
'checkFirst': checkFirst,
'circuitBroken': circuitBroken,
'circuitBreakerCode': circuitBreakerCode,
'wouldCharge': wouldCharge,
'wouldStopHard': wouldStopHard,
'wouldStopCapped': wouldStopCapped,
'wouldSms': wouldSms,
'wouldEmail': wouldEmail,
'wouldClose': wouldClose,
'wouldExpire': wouldExpire,
'wouldEndOfTermClose': wouldEndOfTermClose,
'wouldEndOfTermRevoke': wouldEndOfTermRevoke,
'smsSent': smsSent,
'emails': emails,
'closed': closed,
'log': JsonConverters.toJson(log,'List<String>',context!),
'statusCode': statusCode,
'message': message
};
getTypeName() => "RecurringChargeJobSummary";
TypeContext? context = _ctx;
}
class RunRecurringChargeJobRequest implements IConvertible
{
bool? dryRun;
DateTime? asOf;
RunRecurringChargeJobRequest({this.dryRun,this.asOf});
RunRecurringChargeJobRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
dryRun = json['dryRun'];
asOf = JsonConverters.fromJson(json['asOf'],'DateTime',context!);
return this;
}
Map<String, dynamic> toJson() => {
'dryRun': dryRun,
'asOf': JsonConverters.toJson(asOf,'DateTime',context!)
};
getTypeName() => "RunRecurringChargeJobRequest";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'stubbur_app.azurewebsites.net', types: <String, TypeInfo> {
'RecurringChargeJobSummary': TypeInfo(TypeOf.Class, create:() => RecurringChargeJobSummary()),
'RunRecurringChargeJobRequest': TypeInfo(TypeOf.Class, create:() => RunRecurringChargeJobRequest()),
});
Dart RunRecurringChargeJobRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /recurringPayments/run-charge HTTP/1.1
Host: stubbur-app.azurewebsites.net
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
dryRun: False,
asOf: 0001-01-01
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
masterEnabled: False,
autoSubmitEnabled: False,
dunningEnabled: False,
expireLapsedEnabled: False,
endOfTermRevokeEnabled: False,
chargeHour: 0,
batchSize: 0,
asOfUtc: 0001-01-01,
dryRun: False,
chargeLive: False,
dunningLive: False,
charged: 0,
declined: 0,
ambiguous: 0,
skippedAlreadyCharged: 0,
nullOwnerCharged: 0,
skippedSinglePayment: 0,
expiredCards: 0,
endOfTermClosed: 0,
endOfTermRevoked: 0,
hardClosed: 0,
cappedClosed: 0,
expiredCardNotified: 0,
checkFirst: 0,
circuitBroken: False,
circuitBreakerCode: String,
wouldCharge: 0,
wouldStopHard: 0,
wouldStopCapped: 0,
wouldSms: 0,
wouldEmail: 0,
wouldClose: 0,
wouldExpire: 0,
wouldEndOfTermClose: 0,
wouldEndOfTermRevoke: 0,
smsSent: 0,
emails: 0,
closed: 0,
log:
[
String
],
statusCode: 0,
message: String
}