Trendsic Platform Service

<back to all web services

BluebeamCommitRequest

Requires Authentication
The following routes are available for this service:
POST,OPTIONS/v1/projects/{ProjectID}/bluebeam/import/commit
import 'package:servicestack/servicestack.dart';
import 'dart:typed_data';

class BluebeamRow implements IConvertible
{
    int? RowNo;
    String? Subject;
    String? PageLabel;
    int? PageIndex;
    String? Author;
    String? Date;
    String? Status;
    String? Color;
    String? Comments;
    String? Label;
    String? Layer;
    String? Space;
    double? Length;
    double? Area;
    double? Count;
    double? Volume;
    String? Measurement;
    double? X;
    double? Y;
    double? Width;
    double? Height;
    Map<String,String?>? Extras = {};

    BluebeamRow({this.RowNo,this.Subject,this.PageLabel,this.PageIndex,this.Author,this.Date,this.Status,this.Color,this.Comments,this.Label,this.Layer,this.Space,this.Length,this.Area,this.Count,this.Volume,this.Measurement,this.X,this.Y,this.Width,this.Height,this.Extras});
    BluebeamRow.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        RowNo = json['RowNo'];
        Subject = json['Subject'];
        PageLabel = json['PageLabel'];
        PageIndex = json['PageIndex'];
        Author = json['Author'];
        Date = json['Date'];
        Status = json['Status'];
        Color = json['Color'];
        Comments = json['Comments'];
        Label = json['Label'];
        Layer = json['Layer'];
        Space = json['Space'];
        Length = JsonConverters.toDouble(json['Length']);
        Area = JsonConverters.toDouble(json['Area']);
        Count = JsonConverters.toDouble(json['Count']);
        Volume = JsonConverters.toDouble(json['Volume']);
        Measurement = json['Measurement'];
        X = JsonConverters.toDouble(json['X']);
        Y = JsonConverters.toDouble(json['Y']);
        Width = JsonConverters.toDouble(json['Width']);
        Height = JsonConverters.toDouble(json['Height']);
        Extras = JsonConverters.toStringMap(json['Extras']);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'RowNo': RowNo,
        'Subject': Subject,
        'PageLabel': PageLabel,
        'PageIndex': PageIndex,
        'Author': Author,
        'Date': Date,
        'Status': Status,
        'Color': Color,
        'Comments': Comments,
        'Label': Label,
        'Layer': Layer,
        'Space': Space,
        'Length': Length,
        'Area': Area,
        'Count': Count,
        'Volume': Volume,
        'Measurement': Measurement,
        'X': X,
        'Y': Y,
        'Width': Width,
        'Height': Height,
        'Extras': Extras
    };

    getTypeName() => "BluebeamRow";
    TypeContext? context = _ctx;
}

class BluebeamMappedRow implements IConvertible
{
    int? RowNo;
    String? Target;
    String? Title;
    String? Description;
    String? Area;
    String? Trade;
    String? AssignedSub;
    String? Priority;
    double? Quantity;
    String? QuantityKind;
    String? Unit;
    int? TaskSeq;
    String? Reason;
    BluebeamRow? Source;

    BluebeamMappedRow({this.RowNo,this.Target,this.Title,this.Description,this.Area,this.Trade,this.AssignedSub,this.Priority,this.Quantity,this.QuantityKind,this.Unit,this.TaskSeq,this.Reason,this.Source});
    BluebeamMappedRow.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        RowNo = json['RowNo'];
        Target = json['Target'];
        Title = json['Title'];
        Description = json['Description'];
        Area = json['Area'];
        Trade = json['Trade'];
        AssignedSub = json['AssignedSub'];
        Priority = json['Priority'];
        Quantity = JsonConverters.toDouble(json['Quantity']);
        QuantityKind = json['QuantityKind'];
        Unit = json['Unit'];
        TaskSeq = json['TaskSeq'];
        Reason = json['Reason'];
        Source = JsonConverters.fromJson(json['Source'],'BluebeamRow',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'RowNo': RowNo,
        'Target': Target,
        'Title': Title,
        'Description': Description,
        'Area': Area,
        'Trade': Trade,
        'AssignedSub': AssignedSub,
        'Priority': Priority,
        'Quantity': Quantity,
        'QuantityKind': QuantityKind,
        'Unit': Unit,
        'TaskSeq': TaskSeq,
        'Reason': Reason,
        'Source': JsonConverters.toJson(Source,'BluebeamRow',context!)
    };

    getTypeName() => "BluebeamMappedRow";
    TypeContext? context = _ctx;
}

class BluebeamCommitResult implements IConvertible
{
    int? PunchCreated;
    int? RfisCreated;
    int? Skipped;
    List<String>? Created = [];
    List<BluebeamMappedRow>? Quantities = [];
    List<String>? Errors = [];

    BluebeamCommitResult({this.PunchCreated,this.RfisCreated,this.Skipped,this.Created,this.Quantities,this.Errors});
    BluebeamCommitResult.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        PunchCreated = json['PunchCreated'];
        RfisCreated = json['RfisCreated'];
        Skipped = json['Skipped'];
        Created = JsonConverters.fromJson(json['Created'],'List<String>',context!);
        Quantities = JsonConverters.fromJson(json['Quantities'],'List<BluebeamMappedRow>',context!);
        Errors = JsonConverters.fromJson(json['Errors'],'List<String>',context!);
        return this;
    }

    Map<String, dynamic> toJson() => {
        'PunchCreated': PunchCreated,
        'RfisCreated': RfisCreated,
        'Skipped': Skipped,
        'Created': JsonConverters.toJson(Created,'List<String>',context!),
        'Quantities': JsonConverters.toJson(Quantities,'List<BluebeamMappedRow>',context!),
        'Errors': JsonConverters.toJson(Errors,'List<String>',context!)
    };

    getTypeName() => "BluebeamCommitResult";
    TypeContext? context = _ctx;
}

class BluebeamCommitResponse implements IConvertible
{
    ResponseStatus? ResponseStatus;
    BluebeamCommitResult? Result;
    String? QuantitiesCsv;
    int? QuantitiesWritten;

    BluebeamCommitResponse({this.ResponseStatus,this.Result,this.QuantitiesCsv,this.QuantitiesWritten});
    BluebeamCommitResponse.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ResponseStatus = JsonConverters.fromJson(json['ResponseStatus'],'ResponseStatus',context!);
        Result = JsonConverters.fromJson(json['Result'],'BluebeamCommitResult',context!);
        QuantitiesCsv = json['QuantitiesCsv'];
        QuantitiesWritten = json['QuantitiesWritten'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ResponseStatus': JsonConverters.toJson(ResponseStatus,'ResponseStatus',context!),
        'Result': JsonConverters.toJson(Result,'BluebeamCommitResult',context!),
        'QuantitiesCsv': QuantitiesCsv,
        'QuantitiesWritten': QuantitiesWritten
    };

    getTypeName() => "BluebeamCommitResponse";
    TypeContext? context = _ctx;
}

class BluebeamCommitRequest implements IConvertible
{
    int? ProjectID;
    String? FileName;
    List<BluebeamMappedRow>? Rows = [];
    String? RfpDocumentUID;

    BluebeamCommitRequest({this.ProjectID,this.FileName,this.Rows,this.RfpDocumentUID});
    BluebeamCommitRequest.fromJson(Map<String, dynamic> json) { fromMap(json); }

    fromMap(Map<String, dynamic> json) {
        ProjectID = json['ProjectID'];
        FileName = json['FileName'];
        Rows = JsonConverters.fromJson(json['Rows'],'List<BluebeamMappedRow>',context!);
        RfpDocumentUID = json['RfpDocumentUID'];
        return this;
    }

    Map<String, dynamic> toJson() => {
        'ProjectID': ProjectID,
        'FileName': FileName,
        'Rows': JsonConverters.toJson(Rows,'List<BluebeamMappedRow>',context!),
        'RfpDocumentUID': RfpDocumentUID
    };

    getTypeName() => "BluebeamCommitRequest";
    TypeContext? context = _ctx;
}

TypeContext _ctx = TypeContext(library: 'api.dev.dynamics.trendsic.com', types: <String, TypeInfo> {
    'BluebeamRow': TypeInfo(TypeOf.Class, create:() => BluebeamRow()),
    'BluebeamMappedRow': TypeInfo(TypeOf.Class, create:() => BluebeamMappedRow()),
    'BluebeamCommitResult': TypeInfo(TypeOf.Class, create:() => BluebeamCommitResult()),
    'List<BluebeamMappedRow>': TypeInfo(TypeOf.Class, create:() => <BluebeamMappedRow>[]),
    'BluebeamCommitResponse': TypeInfo(TypeOf.Class, create:() => BluebeamCommitResponse()),
    'BluebeamCommitRequest': TypeInfo(TypeOf.Class, create:() => BluebeamCommitRequest()),
});

Dart BluebeamCommitRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other

HTTP + OTHER

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /v1/projects/{ProjectID}/bluebeam/import/commit HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length

{"ProjectID":0,"FileName":"String","Rows":[{"RowNo":0,"Target":"String","Title":"String","Description":"String","Area":"String","Trade":"String","AssignedSub":"String","Priority":"String","Quantity":0,"QuantityKind":"String","Unit":"String","TaskSeq":0,"Reason":"String","Source":{"RowNo":0,"Subject":"String","PageLabel":"String","PageIndex":0,"Author":"String","Date":"String","Status":"String","Color":"String","Comments":"String","Label":"String","Layer":"String","Space":"String","Length":0,"Area":0,"Count":0,"Volume":0,"Measurement":"String","X":0,"Y":0,"Width":0,"Height":0,"Extras":{"String":"String"}}}],"RfpDocumentUID":"00000000000000000000000000000000"}
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length

{"ResponseStatus":{"ErrorCode":"String","Message":"String","StackTrace":"String","Errors":[{"ErrorCode":"String","FieldName":"String","Message":"String","Meta":{"String":"String"}}],"Meta":{"String":"String"}},"Result":{"PunchCreated":0,"RfisCreated":0,"Skipped":0,"Created":["String"],"Quantities":[{"RowNo":0,"Target":"String","Title":"String","Description":"String","Area":"String","Trade":"String","AssignedSub":"String","Priority":"String","Quantity":0,"QuantityKind":"String","Unit":"String","TaskSeq":0,"Reason":"String","Source":{"RowNo":0,"Subject":"String","PageLabel":"String","PageIndex":0,"Author":"String","Date":"String","Status":"String","Color":"String","Comments":"String","Label":"String","Layer":"String","Space":"String","Length":0,"Area":0,"Count":0,"Volume":0,"Measurement":"String","X":0,"Y":0,"Width":0,"Height":0,"Extras":{"String":"String"}}}],"Errors":["String"]},"QuantitiesCsv":"String","QuantitiesWritten":0}