Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Deck of Cards
idbimCreateObjectTypeInProject


Card
labelURL / Resource / JSON Structure

Resource: projects/<project_id>/objecttypes

URLhttps://api-stage.bimplus.net/v2/<team_slug>/projects/<project_id>/objecttypes

Examplehttps://api-stage.bimplus.net/v2/bimplus/projects/e2120b81-aff4-4ac7-b53d-83676ccdbe7d/objecttypes

JSON Structure

Name

Mandatory / Optional

Type

Description

idwill be ignoredstring (guid)Id of the objecttype
projectIdwill be ignored
string (guid)The id of the project the objecttype belongs to
typeoptionalmandatorystringType of the objecttype. Can be one of the 'DocumentType', 'GroupType' or 'ModelType'

name

mandatory

string

Name of the objecttype

description

optional

string

Description of the objecttype

customModeTypeoptionalboolean When this flag is true the objectype is custom and can be modified
definedByoptionalJSON arrayArray of the definition layers (disciplines) for which the objecttype is valid



Card
labelHTTP Method
 POST


Card
labelDescription
 Creates a new objecttype in a project.


Card
labelRequest


Code Block
borderColorGreen
langxml
titleHeaders
Authorization: BimPlus 9c1874a62c974dcfa75e0132c423a088
Content-Type: application/json


Code Block
borderColorRed
langxml
titleJSON
{
  "name":"UpdateTestObjectType",
  "definedBy":[{
      "id":"d5106d4d-0eba-4d20-86bd-7fe56f33fc76"
    },
    {
      "id":"2e5d5f07-6431-4bc6-b17c-49b5b8c585b7"
    }
  ]
}



Card
labelResponse


Code Block
borderColorGreen
langxml
titleStatus
Status: 201 Created


Code Block
borderColorRed
langxml
titleJSON
{
  "id":"c7d15b4e-02da-42c6-a1be-9082d3668cda",
  "projectId":"e2120b81-aff4-4ac7-b53d-83676ccdbe7d",
  "type":"ModelType",
  "name":"TestObjectType",
  "customModeType":true,
  "definedBy":[{
      "name":"CommonMEP",
      "id":"d5106d4d-0eba-4d20-86bd-7fe56f33fc76"
    },
    {
      "name":"Heating",
      "id":"2e5d5f07-6431-4bc6-b17c-49b5b8c585b7"
    }
  ]
}



...