| POST | /integrations/api/{integrationType}/core/verifytoken |
|---|
import 'package:servicestack/servicestack.dart';
class VerifyTokenRs implements IConvertible
{
String? CardRef;
bool? Success;
String? Message;
VerifyTokenRs({this.CardRef,this.Success,this.Message});
VerifyTokenRs.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
CardRef = json['CardRef'];
Success = json['Success'];
Message = json['Message'];
return this;
}
Map<String, dynamic> toJson() => {
'CardRef': CardRef,
'Success': Success,
'Message': Message
};
getTypeName() => "VerifyTokenRs";
TypeContext? context = _ctx;
}
class ApiClientHeader implements IConvertible
{
int? ClientId;
String? Referrer;
String? IpAddress;
int? LoggedInUserId;
int? GroupId;
String? Task;
String? Machine;
String? Location;
int? CreatedBy;
int? CampaignId;
double? ReCaptchaScore;
ApiClientHeader({this.ClientId,this.Referrer,this.IpAddress,this.LoggedInUserId,this.GroupId,this.Task,this.Machine,this.Location,this.CreatedBy,this.CampaignId,this.ReCaptchaScore});
ApiClientHeader.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
ClientId = json['ClientId'];
Referrer = json['Referrer'];
IpAddress = json['IpAddress'];
LoggedInUserId = json['LoggedInUserId'];
GroupId = json['GroupId'];
Task = json['Task'];
Machine = json['Machine'];
Location = json['Location'];
CreatedBy = json['CreatedBy'];
CampaignId = json['CampaignId'];
ReCaptchaScore = JsonConverters.toDouble(json['ReCaptchaScore']);
return this;
}
Map<String, dynamic> toJson() => {
'ClientId': ClientId,
'Referrer': Referrer,
'IpAddress': IpAddress,
'LoggedInUserId': LoggedInUserId,
'GroupId': GroupId,
'Task': Task,
'Machine': Machine,
'Location': Location,
'CreatedBy': CreatedBy,
'CampaignId': CampaignId,
'ReCaptchaScore': ReCaptchaScore
};
getTypeName() => "ApiClientHeader";
TypeContext? context = _ctx;
}
class VerifyTokenRq implements IConvertible
{
ApiClientHeader? Header;
String? IntegrationType;
int? NationalId;
int? ChapterId;
int? IntegrationPartnerId;
String? Token;
String? VerificationTypes;
VerifyTokenRq({this.Header,this.IntegrationType,this.NationalId,this.ChapterId,this.IntegrationPartnerId,this.Token,this.VerificationTypes});
VerifyTokenRq.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
Header = JsonConverters.fromJson(json['Header'],'ApiClientHeader',context!);
IntegrationType = json['IntegrationType'];
NationalId = json['NationalId'];
ChapterId = json['ChapterId'];
IntegrationPartnerId = json['IntegrationPartnerId'];
Token = json['Token'];
VerificationTypes = json['VerificationTypes'];
return this;
}
Map<String, dynamic> toJson() => {
'Header': JsonConverters.toJson(Header,'ApiClientHeader',context!),
'IntegrationType': IntegrationType,
'NationalId': NationalId,
'ChapterId': ChapterId,
'IntegrationPartnerId': IntegrationPartnerId,
'Token': Token,
'VerificationTypes': VerificationTypes
};
getTypeName() => "VerifyTokenRq";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'devapi.billhighway.com', types: <String, TypeInfo> {
'VerifyTokenRs': TypeInfo(TypeOf.Class, create:() => VerifyTokenRs()),
'ApiClientHeader': TypeInfo(TypeOf.Class, create:() => ApiClientHeader()),
'VerifyTokenRq': TypeInfo(TypeOf.Class, create:() => VerifyTokenRq()),
});
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 /integrations/api/{integrationType}/core/verifytoken HTTP/1.1
Host: devapi.billhighway.com
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
Header:
{
ClientId: 0,
Referrer: String,
IpAddress: String,
LoggedInUserId: 0,
GroupId: 0,
Task: String,
Machine: String,
Location: String,
CreatedBy: 0,
CampaignId: 0,
ReCaptchaScore: 0
},
IntegrationType: String,
NationalId: 0,
ChapterId: 0,
IntegrationPartnerId: 0,
Token: String,
VerificationTypes: String
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
CardRef: String,
Success: False,
Message: String
}