PUT | /orgs/{OrganizationId}/members/{Slug} |
---|
import 'package:servicestack/servicestack.dart';
class OrganizationLabelResponse implements IConvertible
{
ResponseStatus? responseStatus;
OrganizationLabelResponse({this.responseStatus});
OrganizationLabelResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
responseStatus = JsonConverters.fromJson(json['responseStatus'],'ResponseStatus',context!);
return this;
}
Map<String, dynamic> toJson() => {
'responseStatus': JsonConverters.toJson(responseStatus,'ResponseStatus',context!)
};
getTypeName() => "OrganizationLabelResponse";
TypeContext? context = _ctx;
}
class UpdateOrganizationLabel implements IPut, IConvertible
{
int? organizationId;
String? slug;
String? description;
String? color;
UpdateOrganizationLabel({this.organizationId,this.slug,this.description,this.color});
UpdateOrganizationLabel.fromJson(Map<String, dynamic> json) { fromMap(json); }
fromMap(Map<String, dynamic> json) {
organizationId = json['organizationId'];
slug = json['slug'];
description = json['description'];
color = json['color'];
return this;
}
Map<String, dynamic> toJson() => {
'organizationId': organizationId,
'slug': slug,
'description': description,
'color': color
};
getTypeName() => "UpdateOrganizationLabel";
TypeContext? context = _ctx;
}
TypeContext _ctx = TypeContext(library: 'techstacks.io', types: <String, TypeInfo> {
'OrganizationLabelResponse': TypeInfo(TypeOf.Class, create:() => OrganizationLabelResponse()),
'UpdateOrganizationLabel': TypeInfo(TypeOf.Class, create:() => UpdateOrganizationLabel()),
});
Dart UpdateOrganizationLabel 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.
PUT /orgs/{OrganizationId}/members/{Slug} HTTP/1.1
Host: techstacks.io
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
organizationId: 0,
slug: String,
description: String,
color: String
}
HTTP/1.1 200 OK Content-Type: text/jsv Content-Length: length { responseStatus: { errorCode: String, message: String, stackTrace: String, errors: [ { errorCode: String, fieldName: String, message: String, meta: { String: String } } ], meta: { String: String } } }