All Verbs | /my-session |
---|
import 'package:servicestack/servicestack.dart';
abstract class TechnologyStackBase
{
int? id;
String? name;
String? vendorName;
String? description;
String? appUrl;
String? screenshotUrl;
DateTime? created;
String? createdBy;
DateTime? lastModified;
String? lastModifiedBy;
bool? isLocked;
String? ownerId;
String? slug;
// @StringLength(2147483647)
String? details;
// @StringLength(2147483647)
String? detailsHtml;
DateTime? lastStatusUpdate;
int? organizationId;
int? commentsPostId;
int? viewCount;
int? favCount;
TechnologyStackBase({this.id,this.name,this.vendorName,this.description,this.appUrl,this.screenshotUrl,this.created,this.createdBy,this.lastModified,this.lastModifiedBy,this.isLocked,this.ownerId,this.slug,this.details,this.detailsHtml,this.lastStatusUpdate,this.organizationId,this.commentsPostId,this.viewCount,this.favCount});
TechnologyStackBase.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
name = json['name'];
vendorName = json['vendorName'];
description = json['description'];
appUrl = json['appUrl'];
screenshotUrl = json['screenshotUrl'];
created = JsonConverters.fromJson(json['created'],'DateTime',context!);
createdBy = json['createdBy'];
lastModified = JsonConverters.fromJson(json['lastModified'],'DateTime',context!);
lastModifiedBy = json['lastModifiedBy'];
isLocked = json['isLocked'];
ownerId = json['ownerId'];
slug = json['slug'];
details = json['details'];
detailsHtml = json['detailsHtml'];
lastStatusUpdate = JsonConverters.fromJson(json['lastStatusUpdate'],'DateTime',context!);
organizationId = json['organizationId'];
commentsPostId = json['commentsPostId'];
viewCount = json['viewCount'];
favCount = json['favCount'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'name': name,
'vendorName': vendorName,
'description': description,
'appUrl': appUrl,
'screenshotUrl': screenshotUrl,
'created': JsonConverters.toJson(created,'DateTime',context!),
'createdBy': createdBy,
'lastModified': JsonConverters.toJson(lastModified,'DateTime',context!),
'lastModifiedBy': lastModifiedBy,
'isLocked': isLocked,
'ownerId': ownerId,
'slug': slug,
'details': details,
'detailsHtml': detailsHtml,
'lastStatusUpdate': JsonConverters.toJson(lastStatusUpdate,'DateTime',context!),
'organizationId': organizationId,
'commentsPostId': commentsPostId,
'viewCount': viewCount,
'favCount': favCount
};
getTypeName() => "TechnologyStackBase";
TypeContext? context = _ctx;
}
class TechnologyStack extends TechnologyStackBase implements IConvertible
{
TechnologyStack();
TechnologyStack.fromJson(Map<String, dynamic> json) : super.fromJson(json);
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
return this;
}
Map<String, dynamic> toJson() => super.toJson();
getTypeName() => "TechnologyStack";
TypeContext? context = _ctx;
}
enum TechnologyTier
{
ProgrammingLanguage,
Client,
Http,
Server,
Data,
SoftwareInfrastructure,
OperatingSystem,
HardwareInfrastructure,
ThirdPartyServices,
}
abstract class TechnologyBase
{
int? id;
String? name;
String? vendorName;
String? vendorUrl;
String? productUrl;
String? logoUrl;
String? description;
DateTime? created;
String? createdBy;
DateTime? lastModified;
String? lastModifiedBy;
String? ownerId;
String? slug;
bool? logoApproved;
bool? isLocked;
TechnologyTier? tier;
DateTime? lastStatusUpdate;
int? organizationId;
int? commentsPostId;
int? viewCount;
int? favCount;
TechnologyBase({this.id,this.name,this.vendorName,this.vendorUrl,this.productUrl,this.logoUrl,this.description,this.created,this.createdBy,this.lastModified,this.lastModifiedBy,this.ownerId,this.slug,this.logoApproved,this.isLocked,this.tier,this.lastStatusUpdate,this.organizationId,this.commentsPostId,this.viewCount,this.favCount});
TechnologyBase.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
name = json['name'];
vendorName = json['vendorName'];
vendorUrl = json['vendorUrl'];
productUrl = json['productUrl'];
logoUrl = json['logoUrl'];
description = json['description'];
created = JsonConverters.fromJson(json['created'],'DateTime',context!);
createdBy = json['createdBy'];
lastModified = JsonConverters.fromJson(json['lastModified'],'DateTime',context!);
lastModifiedBy = json['lastModifiedBy'];
ownerId = json['ownerId'];
slug = json['slug'];
logoApproved = json['logoApproved'];
isLocked = json['isLocked'];
tier = JsonConverters.fromJson(json['tier'],'TechnologyTier',context!);
lastStatusUpdate = JsonConverters.fromJson(json['lastStatusUpdate'],'DateTime',context!);
organizationId = json['organizationId'];
commentsPostId = json['commentsPostId'];
viewCount = json['viewCount'];
favCount = json['favCount'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'name': name,
'vendorName': vendorName,
'vendorUrl': vendorUrl,
'productUrl': productUrl,
'logoUrl': logoUrl,
'description': description,
'created': JsonConverters.toJson(created,'DateTime',context!),
'createdBy': createdBy,
'lastModified': JsonConverters.toJson(lastModified,'DateTime',context!),
'lastModifiedBy': lastModifiedBy,
'ownerId': ownerId,
'slug': slug,
'logoApproved': logoApproved,
'isLocked': isLocked,
'tier': JsonConverters.toJson(tier,'TechnologyTier',context!),
'lastStatusUpdate': JsonConverters.toJson(lastStatusUpdate,'DateTime',context!),
'organizationId': organizationId,
'commentsPostId': commentsPostId,
'viewCount': viewCount,
'favCount': favCount
};
getTypeName() => "TechnologyBase";
TypeContext? context = _ctx;
}
class Technology extends TechnologyBase implements IConvertible
{
Technology();
Technology.fromJson(Map<String, dynamic> json) : super.fromJson(json);
fromMap(Map<String, dynamic> json) {
super.fromMap(json);
return this;
}
Map<String, dynamic> toJson() => super.toJson();
getTypeName() => "Technology";
TypeContext? context = _ctx;
}
class UserActivity implements IConvertible
{
int? id;
String? userName;
int? karma;
int? technologyCount;
int? techStacksCount;
int? postsCount;
int? postUpVotes;
int? postDownVotes;
int? commentUpVotes;
int? commentDownVotes;
int? postCommentsCount;
int? pinnedCommentCount;
int? postReportCount;
int? postCommentReportCount;
DateTime? created;
DateTime? modified;
UserActivity({this.id,this.userName,this.karma,this.technologyCount,this.techStacksCount,this.postsCount,this.postUpVotes,this.postDownVotes,this.commentUpVotes,this.commentDownVotes,this.postCommentsCount,this.pinnedCommentCount,this.postReportCount,this.postCommentReportCount,this.created,this.modified});
UserActivity.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
userName = json['userName'];
karma = json['karma'];
technologyCount = json['technologyCount'];
techStacksCount = json['techStacksCount'];
postsCount = json['postsCount'];
postUpVotes = json['postUpVotes'];
postDownVotes = json['postDownVotes'];
commentUpVotes = json['commentUpVotes'];
commentDownVotes = json['commentDownVotes'];
postCommentsCount = json['postCommentsCount'];
pinnedCommentCount = json['pinnedCommentCount'];
postReportCount = json['postReportCount'];
postCommentReportCount = json['postCommentReportCount'];
created = JsonConverters.fromJson(json['created'],'DateTime',context!);
modified = JsonConverters.fromJson(json['modified'],'DateTime',context!);
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'userName': userName,
'karma': karma,
'technologyCount': technologyCount,
'techStacksCount': techStacksCount,
'postsCount': postsCount,
'postUpVotes': postUpVotes,
'postDownVotes': postDownVotes,
'commentUpVotes': commentUpVotes,
'commentDownVotes': commentDownVotes,
'postCommentsCount': postCommentsCount,
'pinnedCommentCount': pinnedCommentCount,
'postReportCount': postReportCount,
'postCommentReportCount': postCommentReportCount,
'created': JsonConverters.toJson(created,'DateTime',context!),
'modified': JsonConverters.toJson(modified,'DateTime',context!)
};
getTypeName() => "UserActivity";
TypeContext? context = _ctx;
}
class OrganizationMember implements IConvertible
{
int? id;
int? organizationId;
int? userId;
String? userName;
bool? isOwner;
bool? isModerator;
bool? denyAll;
bool? denyPosts;
bool? denyComments;
String? notes;
OrganizationMember({this.id,this.organizationId,this.userId,this.userName,this.isOwner,this.isModerator,this.denyAll,this.denyPosts,this.denyComments,this.notes});
OrganizationMember.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
organizationId = json['organizationId'];
userId = json['userId'];
userName = json['userName'];
isOwner = json['isOwner'];
isModerator = json['isModerator'];
denyAll = json['denyAll'];
denyPosts = json['denyPosts'];
denyComments = json['denyComments'];
notes = json['notes'];
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'organizationId': organizationId,
'userId': userId,
'userName': userName,
'isOwner': isOwner,
'isModerator': isModerator,
'denyAll': denyAll,
'denyPosts': denyPosts,
'denyComments': denyComments,
'notes': notes
};
getTypeName() => "OrganizationMember";
TypeContext? context = _ctx;
}
class OrganizationMemberInvite implements IConvertible
{
int? id;
int? organizationId;
int? userId;
String? userName;
DateTime? dismissed;
OrganizationMemberInvite({this.id,this.organizationId,this.userId,this.userName,this.dismissed});
OrganizationMemberInvite.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
organizationId = json['organizationId'];
userId = json['userId'];
userName = json['userName'];
dismissed = JsonConverters.fromJson(json['dismissed'],'DateTime',context!);
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'organizationId': organizationId,
'userId': userId,
'userName': userName,
'dismissed': JsonConverters.toJson(dismissed,'DateTime',context!)
};
getTypeName() => "OrganizationMemberInvite";
TypeContext? context = _ctx;
}
class OrganizationSubscription implements IConvertible
{
int? id;
int? organizationId;
int? userId;
String? userName;
List<String>? postTypes;
int? frequencyDays;
int? lastSyncedId;
DateTime? lastSynced;
DateTime? created;
OrganizationSubscription({this.id,this.organizationId,this.userId,this.userName,this.postTypes,this.frequencyDays,this.lastSyncedId,this.lastSynced,this.created});
OrganizationSubscription.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
id = json['id'];
organizationId = json['organizationId'];
userId = json['userId'];
userName = json['userName'];
postTypes = JsonConverters.fromJson(json['postTypes'],'List<String>',context!);
frequencyDays = json['frequencyDays'];
lastSyncedId = json['lastSyncedId'];
lastSynced = JsonConverters.fromJson(json['lastSynced'],'DateTime',context!);
created = JsonConverters.fromJson(json['created'],'DateTime',context!);
return this;
}
Map<String, dynamic> toJson() => {
'id': id,
'organizationId': organizationId,
'userId': userId,
'userName': userName,
'postTypes': JsonConverters.toJson(postTypes,'List<String>',context!),
'frequencyDays': frequencyDays,
'lastSyncedId': lastSyncedId,
'lastSynced': JsonConverters.toJson(lastSynced,'DateTime',context!),
'created': JsonConverters.toJson(created,'DateTime',context!)
};
getTypeName() => "OrganizationSubscription";
TypeContext? context = _ctx;
}
class SessionInfoResponse implements IConvertible
{
DateTime? created;
String? id;
String? referrerUrl;
String? userAuthId;
String? userAuthName;
String? userName;
String? displayName;
String? firstName;
String? lastName;
String? email;
DateTime? createdAt;
DateTime? lastModified;
List<String>? roles;
List<String>? permissions;
bool? isAuthenticated;
String? authProvider;
String? profileUrl;
String? githubProfileUrl;
String? twitterProfileUrl;
String? accessToken;
String? avatarUrl;
List<TechnologyStack>? techStacks;
List<TechnologyStack>? favoriteTechStacks;
List<Technology>? favoriteTechnologies;
UserActivity? userActivity;
List<OrganizationMember>? members;
List<OrganizationMemberInvite>? memberInvites;
List<OrganizationSubscription>? subscriptions;
ResponseStatus? responseStatus;
SessionInfoResponse({this.created,this.id,this.referrerUrl,this.userAuthId,this.userAuthName,this.userName,this.displayName,this.firstName,this.lastName,this.email,this.createdAt,this.lastModified,this.roles,this.permissions,this.isAuthenticated,this.authProvider,this.profileUrl,this.githubProfileUrl,this.twitterProfileUrl,this.accessToken,this.avatarUrl,this.techStacks,this.favoriteTechStacks,this.favoriteTechnologies,this.userActivity,this.members,this.memberInvites,this.subscriptions,this.responseStatus});
SessionInfoResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
created = JsonConverters.fromJson(json['created'],'DateTime',context!);
id = json['id'];
referrerUrl = json['referrerUrl'];
userAuthId = json['userAuthId'];
userAuthName = json['userAuthName'];
userName = json['userName'];
displayName = json['displayName'];
firstName = json['firstName'];
lastName = json['lastName'];
email = json['email'];
createdAt = JsonConverters.fromJson(json['createdAt'],'DateTime',context!);
lastModified = JsonConverters.fromJson(json['lastModified'],'DateTime',context!);
roles = JsonConverters.fromJson(json['roles'],'List<String>',context!);
permissions = JsonConverters.fromJson(json['permissions'],'List<String>',context!);
isAuthenticated = json['isAuthenticated'];
authProvider = json['authProvider'];
profileUrl = json['profileUrl'];
githubProfileUrl = json['githubProfileUrl'];
twitterProfileUrl = json['twitterProfileUrl'];
accessToken = json['accessToken'];
avatarUrl = json['avatarUrl'];
techStacks = JsonConverters.fromJson(json['techStacks'],'List<TechnologyStack>',context!);
favoriteTechStacks = JsonConverters.fromJson(json['favoriteTechStacks'],'List<TechnologyStack>',context!);
favoriteTechnologies = JsonConverters.fromJson(json['favoriteTechnologies'],'List<Technology>',context!);
userActivity = JsonConverters.fromJson(json['userActivity'],'UserActivity',context!);
members = JsonConverters.fromJson(json['members'],'List<OrganizationMember>',context!);
memberInvites = JsonConverters.fromJson(json['memberInvites'],'List<OrganizationMemberInvite>',context!);
subscriptions = JsonConverters.fromJson(json['subscriptions'],'List<OrganizationSubscription>',context!);
responseStatus = JsonConverters.fromJson(json['responseStatus'],'ResponseStatus',context!);
return this;
}
Map<String, dynamic> toJson() => {
'created': JsonConverters.toJson(created,'DateTime',context!),
'id': id,
'referrerUrl': referrerUrl,
'userAuthId': userAuthId,
'userAuthName': userAuthName,
'userName': userName,
'displayName': displayName,
'firstName': firstName,
'lastName': lastName,
'email': email,
'createdAt': JsonConverters.toJson(createdAt,'DateTime',context!),
'lastModified': JsonConverters.toJson(lastModified,'DateTime',context!),
'roles': JsonConverters.toJson(roles,'List<String>',context!),
'permissions': JsonConverters.toJson(permissions,'List<String>',context!),
'isAuthenticated': isAuthenticated,
'authProvider': authProvider,
'profileUrl': profileUrl,
'githubProfileUrl': githubProfileUrl,
'twitterProfileUrl': twitterProfileUrl,
'accessToken': accessToken,
'avatarUrl': avatarUrl,
'techStacks': JsonConverters.toJson(techStacks,'List<TechnologyStack>',context!),
'favoriteTechStacks': JsonConverters.toJson(favoriteTechStacks,'List<TechnologyStack>',context!),
'favoriteTechnologies': JsonConverters.toJson(favoriteTechnologies,'List<Technology>',context!),
'userActivity': JsonConverters.toJson(userActivity,'UserActivity',context!),
'members': JsonConverters.toJson(members,'List<OrganizationMember>',context!),
'memberInvites': JsonConverters.toJson(memberInvites,'List<OrganizationMemberInvite>',context!),
'subscriptions': JsonConverters.toJson(subscriptions,'List<OrganizationSubscription>',context!),
'responseStatus': JsonConverters.toJson(responseStatus,'ResponseStatus',context!)
};
getTypeName() => "SessionInfoResponse";
TypeContext? context = _ctx;
}
// @ValidateRequest(Validator="IsAuthenticated")
class SessionInfo implements IGet, IConvertible
{
SessionInfo();
SessionInfo.fromJson(Map<String, dynamic> json) : super();
fromMap(Map<String, dynamic> json) {
return this;
}
Map<String, dynamic> toJson() => {};
getTypeName() => "SessionInfo";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'techstacks.io', types: <String, TypeInfo> {
'TechnologyStackBase': TypeInfo(TypeOf.AbstractClass),
'TechnologyStack': TypeInfo(TypeOf.Class, create:() => TechnologyStack()),
'TechnologyTier': TypeInfo(TypeOf.Enum, enumValues:TechnologyTier.values),
'TechnologyBase': TypeInfo(TypeOf.AbstractClass),
'Technology': TypeInfo(TypeOf.Class, create:() => Technology()),
'UserActivity': TypeInfo(TypeOf.Class, create:() => UserActivity()),
'OrganizationMember': TypeInfo(TypeOf.Class, create:() => OrganizationMember()),
'OrganizationMemberInvite': TypeInfo(TypeOf.Class, create:() => OrganizationMemberInvite()),
'OrganizationSubscription': TypeInfo(TypeOf.Class, create:() => OrganizationSubscription()),
'SessionInfoResponse': TypeInfo(TypeOf.Class, create:() => SessionInfoResponse()),
'List<TechnologyStack>': TypeInfo(TypeOf.Class, create:() => <TechnologyStack>[]),
'List<Technology>': TypeInfo(TypeOf.Class, create:() => <Technology>[]),
'List<OrganizationMember>': TypeInfo(TypeOf.Class, create:() => <OrganizationMember>[]),
'List<OrganizationMemberInvite>': TypeInfo(TypeOf.Class, create:() => <OrganizationMemberInvite>[]),
'List<OrganizationSubscription>': TypeInfo(TypeOf.Class, create:() => <OrganizationSubscription>[]),
'SessionInfo': TypeInfo(TypeOf.Class, create:() => SessionInfo()),
});
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 /my-session HTTP/1.1
Host: techstacks.io
Accept: application/json
Content-Type: application/json
Content-Length: length
{}
HTTP/1.1 200 OK Content-Type: application/json Content-Length: length {"created":"0001-01-01T00:00:00.0000000","id":"String","referrerUrl":"String","userAuthId":"String","userAuthName":"String","userName":"String","displayName":"String","firstName":"String","lastName":"String","email":"String","createdAt":"0001-01-01T00:00:00.0000000","lastModified":"0001-01-01T00:00:00.0000000","roles":["String"],"permissions":["String"],"isAuthenticated":false,"authProvider":"String","profileUrl":"String","githubProfileUrl":"String","twitterProfileUrl":"String","accessToken":"String","avatarUrl":"String","techStacks":[{"id":0,"name":"String","vendorName":"String","description":"String","appUrl":"String","screenshotUrl":"String","created":"0001-01-01T00:00:00.0000000","createdBy":"String","lastModified":"0001-01-01T00:00:00.0000000","lastModifiedBy":"String","isLocked":false,"ownerId":"String","slug":"String","details":"String","detailsHtml":"String","lastStatusUpdate":"0001-01-01T00:00:00.0000000","organizationId":0,"commentsPostId":0,"viewCount":0,"favCount":0}],"favoriteTechStacks":[{"id":0,"name":"String","vendorName":"String","description":"String","appUrl":"String","screenshotUrl":"String","created":"0001-01-01T00:00:00.0000000","createdBy":"String","lastModified":"0001-01-01T00:00:00.0000000","lastModifiedBy":"String","isLocked":false,"ownerId":"String","slug":"String","details":"String","detailsHtml":"String","lastStatusUpdate":"0001-01-01T00:00:00.0000000","organizationId":0,"commentsPostId":0,"viewCount":0,"favCount":0}],"favoriteTechnologies":[{"id":0,"name":"String","vendorName":"String","vendorUrl":"String","productUrl":"String","logoUrl":"String","description":"String","created":"0001-01-01T00:00:00.0000000","createdBy":"String","lastModified":"0001-01-01T00:00:00.0000000","lastModifiedBy":"String","ownerId":"String","slug":"String","logoApproved":false,"isLocked":false,"tier":"ProgrammingLanguage","lastStatusUpdate":"0001-01-01T00:00:00.0000000","organizationId":0,"commentsPostId":0,"viewCount":0,"favCount":0}],"userActivity":{"id":0,"userName":"String","karma":0,"technologyCount":0,"techStacksCount":0,"postsCount":0,"postUpVotes":0,"postDownVotes":0,"commentUpVotes":0,"commentDownVotes":0,"postCommentsCount":0,"pinnedCommentCount":0,"postReportCount":0,"postCommentReportCount":0,"created":"0001-01-01T00:00:00.0000000","modified":"0001-01-01T00:00:00.0000000"},"members":[{"id":0,"organizationId":0,"userId":0,"userName":"String","isOwner":false,"isModerator":false,"denyAll":false,"denyPosts":false,"denyComments":false,"notes":"String"}],"memberInvites":[{"id":0,"organizationId":0,"userId":0,"userName":"String","dismissed":"0001-01-01T00:00:00.0000000"}],"subscriptions":[{"id":0,"organizationId":0,"userId":0,"userName":"String","postTypes":["String"],"frequencyDays":0,"lastSyncedId":0,"lastSynced":"0001-01-01T00:00:00.0000000","created":"0001-01-01T00:00:00.0000000"}],"responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}