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 datetime
import decimal
from marshmallow.fields import *
from servicestack import *
from typing import *
from dataclasses import dataclass, field
from dataclasses_json import dataclass_json, LetterCase, Undefined, config
from enum import Enum, IntEnum


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BluebeamRow:
    row_no: int = 0
    subject: Optional[str] = None
    page_label: Optional[str] = None
    page_index: Optional[int] = None
    author: Optional[str] = None
    date: Optional[str] = None
    status: Optional[str] = None
    color: Optional[str] = None
    comments: Optional[str] = None
    label: Optional[str] = None
    layer: Optional[str] = None
    space: Optional[str] = None
    length: Optional[float] = None
    area: Optional[float] = None
    count: Optional[float] = None
    volume: Optional[float] = None
    measurement: Optional[str] = None
    x: Optional[float] = None
    y: Optional[float] = None
    width: Optional[float] = None
    height: Optional[float] = None
    extras: Dict[str, str] = field(default_factory=dict)


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BluebeamMappedRow:
    row_no: int = 0
    target: Optional[str] = None
    title: Optional[str] = None
    description: Optional[str] = None
    area: Optional[str] = None
    trade: Optional[str] = None
    assigned_sub: Optional[str] = None
    priority: Optional[str] = None
    quantity: Optional[float] = None
    quantity_kind: Optional[str] = None
    unit: Optional[str] = None
    task_seq: Optional[int] = None
    reason: Optional[str] = None
    source: Optional[BluebeamRow] = None


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BluebeamCommitResult:
    punch_created: int = 0
    rfis_created: int = 0
    skipped: int = 0
    created: List[str] = field(default_factory=list)
    quantities: List[BluebeamMappedRow] = field(default_factory=list)
    errors: List[str] = field(default_factory=list)


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BluebeamCommitResponse:
    response_status: Optional[ResponseStatus] = None
    result: Optional[BluebeamCommitResult] = None
    quantities_csv: Optional[str] = None
    quantities_written: int = 0


@dataclass_json(letter_case=LetterCase.CAMEL, undefined=Undefined.EXCLUDE)
@dataclass
class BluebeamCommitRequest:
    project_i_d: int = 0
    file_name: Optional[str] = None
    rows: List[BluebeamMappedRow] = field(default_factory=list)
    rfp_document_u_i_d: Optional[str] = None

Python BluebeamCommitRequest DTOs

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

HTTP + XML

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: application/xml
Content-Type: application/xml
Content-Length: length

<BluebeamCommitRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <FileName>String</FileName>
  <ProjectID>0</ProjectID>
  <RfpDocumentUID>00000000-0000-0000-0000-000000000000</RfpDocumentUID>
  <Rows>
    <BluebeamMappedRow>
      <Area>String</Area>
      <AssignedSub>String</AssignedSub>
      <Description>String</Description>
      <Priority>String</Priority>
      <Quantity>0</Quantity>
      <QuantityKind>String</QuantityKind>
      <Reason>String</Reason>
      <RowNo>0</RowNo>
      <Source>
        <Area>0</Area>
        <Author>String</Author>
        <Color>String</Color>
        <Comments>String</Comments>
        <Count>0</Count>
        <Date>String</Date>
        <Extras xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </Extras>
        <Height>0</Height>
        <Label>String</Label>
        <Layer>String</Layer>
        <Length>0</Length>
        <Measurement>String</Measurement>
        <PageIndex>0</PageIndex>
        <PageLabel>String</PageLabel>
        <RowNo>0</RowNo>
        <Space>String</Space>
        <Status>String</Status>
        <Subject>String</Subject>
        <Volume>0</Volume>
        <Width>0</Width>
        <X>0</X>
        <Y>0</Y>
      </Source>
      <Target>String</Target>
      <TaskSeq>0</TaskSeq>
      <Title>String</Title>
      <Trade>String</Trade>
      <Unit>String</Unit>
    </BluebeamMappedRow>
  </Rows>
</BluebeamCommitRequest>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<BluebeamCommitResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/CRM.AgencyPlatform.API.Internal">
  <QuantitiesCsv>String</QuantitiesCsv>
  <QuantitiesWritten>0</QuantitiesWritten>
  <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>
  <Result>
    <Created xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>String</d3p1:string>
    </Created>
    <Errors xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:string>String</d3p1:string>
    </Errors>
    <PunchCreated>0</PunchCreated>
    <Quantities>
      <BluebeamMappedRow>
        <Area>String</Area>
        <AssignedSub>String</AssignedSub>
        <Description>String</Description>
        <Priority>String</Priority>
        <Quantity>0</Quantity>
        <QuantityKind>String</QuantityKind>
        <Reason>String</Reason>
        <RowNo>0</RowNo>
        <Source>
          <Area>0</Area>
          <Author>String</Author>
          <Color>String</Color>
          <Comments>String</Comments>
          <Count>0</Count>
          <Date>String</Date>
          <Extras xmlns:d6p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
            <d6p1:KeyValueOfstringstring>
              <d6p1:Key>String</d6p1:Key>
              <d6p1:Value>String</d6p1:Value>
            </d6p1:KeyValueOfstringstring>
          </Extras>
          <Height>0</Height>
          <Label>String</Label>
          <Layer>String</Layer>
          <Length>0</Length>
          <Measurement>String</Measurement>
          <PageIndex>0</PageIndex>
          <PageLabel>String</PageLabel>
          <RowNo>0</RowNo>
          <Space>String</Space>
          <Status>String</Status>
          <Subject>String</Subject>
          <Volume>0</Volume>
          <Width>0</Width>
          <X>0</X>
          <Y>0</Y>
        </Source>
        <Target>String</Target>
        <TaskSeq>0</TaskSeq>
        <Title>String</Title>
        <Trade>String</Trade>
        <Unit>String</Unit>
      </BluebeamMappedRow>
    </Quantities>
    <RfisCreated>0</RfisCreated>
    <Skipped>0</Skipped>
  </Result>
</BluebeamCommitResponse>