All Verbs | /app-overview |
---|
import 'package:servicestack/servicestack.dart';
enum TechnologyTier
{
ProgrammingLanguage,
Client,
Http,
Server,
Data,
SoftwareInfrastructure,
OperatingSystem,
HardwareInfrastructure,
ThirdPartyServices,
}
// @DataContract
class Option implements IConvertible
{
// @DataMember(Name="name")
String? name;
// @DataMember(Name="title")
String? title;
// @DataMember(Name="value")
TechnologyTier? value;
Option({this.name,this.title,this.value});
Option.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
name = json['name'];
title = json['title'];
value = JsonConverters.fromJson(json['value'],'TechnologyTier',context!);
return this;
}
Map<String, dynamic> toJson() => {
'name': name,
'title': title,
'value': JsonConverters.toJson(value,'TechnologyTier',context!)
};
getTypeName() => "Option";
TypeContext? context = _ctx;
}
class TechnologyInfo implements IConvertible
{
TechnologyTier? tier;
String? slug;
String? name;
String? logoUrl;
int? stacksCount;
TechnologyInfo({this.tier,this.slug,this.name,this.logoUrl,this.stacksCount});
TechnologyInfo.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
tier = JsonConverters.fromJson(json['tier'],'TechnologyTier',context!);
slug = json['slug'];
name = json['name'];
logoUrl = json['logoUrl'];
stacksCount = json['stacksCount'];
return this;
}
Map<String, dynamic> toJson() => {
'tier': JsonConverters.toJson(tier,'TechnologyTier',context!),
'slug': slug,
'name': name,
'logoUrl': logoUrl,
'stacksCount': stacksCount
};
getTypeName() => "TechnologyInfo";
TypeContext? context = _ctx;
}
class AppOverviewResponse implements IConvertible
{
DateTime? created;
List<Option>? allTiers;
List<TechnologyInfo>? topTechnologies;
ResponseStatus? responseStatus;
AppOverviewResponse({this.created,this.allTiers,this.topTechnologies,this.responseStatus});
AppOverviewResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
created = JsonConverters.fromJson(json['created'],'DateTime',context!);
allTiers = JsonConverters.fromJson(json['allTiers'],'List<Option>',context!);
topTechnologies = JsonConverters.fromJson(json['topTechnologies'],'List<TechnologyInfo>',context!);
responseStatus = JsonConverters.fromJson(json['responseStatus'],'ResponseStatus',context!);
return this;
}
Map<String, dynamic> toJson() => {
'created': JsonConverters.toJson(created,'DateTime',context!),
'allTiers': JsonConverters.toJson(allTiers,'List<Option>',context!),
'topTechnologies': JsonConverters.toJson(topTechnologies,'List<TechnologyInfo>',context!),
'responseStatus': JsonConverters.toJson(responseStatus,'ResponseStatus',context!)
};
getTypeName() => "AppOverviewResponse";
TypeContext? context = _ctx;
}
class AppOverview implements IGet, IConvertible
{
bool? reload;
AppOverview({this.reload});
AppOverview.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
reload = json['reload'];
return this;
}
Map<String, dynamic> toJson() => {
'reload': reload
};
getTypeName() => "AppOverview";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'techstacks.io', types: <String, TypeInfo> {
'TechnologyTier': TypeInfo(TypeOf.Enum, enumValues:TechnologyTier.values),
'Option': TypeInfo(TypeOf.Class, create:() => Option()),
'TechnologyInfo': TypeInfo(TypeOf.Class, create:() => TechnologyInfo()),
'AppOverviewResponse': TypeInfo(TypeOf.Class, create:() => AppOverviewResponse()),
'List<Option>': TypeInfo(TypeOf.Class, create:() => <Option>[]),
'List<TechnologyInfo>': TypeInfo(TypeOf.Class, create:() => <TechnologyInfo>[]),
'AppOverview': TypeInfo(TypeOf.Class, create:() => AppOverview()),
});
To override the Content-type in your clients, use the HTTP Accept Header, append the .xml suffix or ?format=xml
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /app-overview HTTP/1.1
Host: techstacks.io
Accept: application/xml
Content-Type: application/xml
Content-Length: length
<AppOverview xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TechStacks.ServiceModel">
<Reload>false</Reload>
</AppOverview>
HTTP/1.1 200 OK Content-Type: application/xml Content-Length: length <AppOverviewResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/TechStacks.ServiceModel"> <AllTiers> <Option> <name>String</name> <title>String</title> <value>ProgrammingLanguage</value> </Option> </AllTiers> <Created>0001-01-01T00:00:00</Created> <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types"> <d2p1:ErrorCode>String</d2p1:ErrorCode> <d2p1:Message>String</d2p1:Message> <d2p1:StackTrace>String</d2p1:StackTrace> <d2p1:Errors> <d2p1:ResponseError> <d2p1:ErrorCode>String</d2p1:ErrorCode> <d2p1:FieldName>String</d2p1:FieldName> <d2p1:Message>String</d2p1:Message> <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d5p1:KeyValueOfstringstring> <d5p1:Key>String</d5p1:Key> <d5p1:Value>String</d5p1:Value> </d5p1:KeyValueOfstringstring> </d2p1:Meta> </d2p1:ResponseError> </d2p1:Errors> <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d3p1:KeyValueOfstringstring> <d3p1:Key>String</d3p1:Key> <d3p1:Value>String</d3p1:Value> </d3p1:KeyValueOfstringstring> </d2p1:Meta> </ResponseStatus> <TopTechnologies> <TechnologyInfo> <LogoUrl>String</LogoUrl> <Name>String</Name> <Slug>String</Slug> <StacksCount>0</StacksCount> <Tier>ProgrammingLanguage</Tier> </TechnologyInfo> </TopTechnologies> </AppOverviewResponse>