| POST | /profile/purge/{SubscriptionId} |
|---|
import 'package:servicestack/servicestack.dart';
class Response implements IConvertible
{
String? statusCode;
int? recordCount;
int? errorCount;
Response({this.statusCode,this.recordCount,this.errorCount});
Response.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
statusCode = json['statusCode'];
recordCount = json['recordCount'];
errorCount = json['errorCount'];
return this;
}
Map<String, dynamic> toJson() => {
'statusCode': statusCode,
'recordCount': recordCount,
'errorCount': errorCount
};
getTypeName() => "Response";
TypeContext? context = _ctx;
}
enum ProfileMergePurgeSource
{
Other,
Messaging,
DirectDBExtract,
ReportImport,
}
class ProfilePurgeContainer implements IConvertible
{
DateTime? transactionDate;
String? retiredProfileId;
ProfileMergePurgeSource? sourceId;
String? importSource;
String? importSourceId;
String? cendynPropertyID;
ProfilePurgeContainer({this.transactionDate,this.retiredProfileId,this.sourceId,this.importSource,this.importSourceId,this.cendynPropertyID});
ProfilePurgeContainer.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
transactionDate = JsonConverters.fromJson(json['transactionDate'],'DateTime',context!);
retiredProfileId = json['retiredProfileId'];
sourceId = JsonConverters.fromJson(json['sourceId'],'ProfileMergePurgeSource',context!);
importSource = json['importSource'];
importSourceId = json['importSourceId'];
cendynPropertyID = json['cendynPropertyID'];
return this;
}
Map<String, dynamic> toJson() => {
'transactionDate': JsonConverters.toJson(transactionDate,'DateTime',context!),
'retiredProfileId': retiredProfileId,
'sourceId': JsonConverters.toJson(sourceId,'ProfileMergePurgeSource',context!),
'importSource': importSource,
'importSourceId': importSourceId,
'cendynPropertyID': cendynPropertyID
};
getTypeName() => "ProfilePurgeContainer";
TypeContext? context = _ctx;
}
class ProfilePurgePost implements IConvertible
{
ProfilePurgeContainer? profilePurgeContainer;
String? subscriptionId;
ProfilePurgePost({this.profilePurgeContainer,this.subscriptionId});
ProfilePurgePost.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
profilePurgeContainer = JsonConverters.fromJson(json['profilePurgeContainer'],'ProfilePurgeContainer',context!);
subscriptionId = json['subscriptionId'];
return this;
}
Map<String, dynamic> toJson() => {
'profilePurgeContainer': JsonConverters.toJson(profilePurgeContainer,'ProfilePurgeContainer',context!),
'subscriptionId': subscriptionId
};
getTypeName() => "ProfilePurgePost";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'cert.cendyn.com', types: <String, TypeInfo> {
'Response': TypeInfo(TypeOf.Class, create:() => Response()),
'ProfileMergePurgeSource': TypeInfo(TypeOf.Enum, enumValues:ProfileMergePurgeSource.values),
'ProfilePurgeContainer': TypeInfo(TypeOf.Class, create:() => ProfilePurgeContainer()),
'ProfilePurgePost': TypeInfo(TypeOf.Class, create:() => ProfilePurgePost()),
});
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /profile/purge/{SubscriptionId} HTTP/1.1
Host: cert.cendyn.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"profilePurgeContainer":{"transactionDate":"0001-01-01T00:00:00.0000000","retiredProfileId":"String","sourceId":"Other","importSource":"String","importSourceId":"String","cendynPropertyID":"String"},"subscriptionId":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length
{"statusCode":"String","recordCount":0,"errorCount":0}