Create node | Copy a node
POST {{baseUrl}}/v2/nodes
Creates a node OR Copies a node.
NOTE: The 'body' parameter must be used. This 'body' parameter contains a JSON string, and must be specified in the Body as a key-value pair where the key is 'body' and the value is the JSON string. See the [IMPLEMENTATION NOTES] for more details.
The following examples will assume that there is are two categories available:
Category1 (ID 9830)
- TextField (Attribute ID 2)
- Set (Attribute ID 3) with two rows. The Set has a multi-value Textfield (Set Attribute ID 4) that can have a maximum of 3 values
- TextField (Attribute ID 2)
Create a Folder:
{type
:0, parent_id
:2000, name
:New Folder
}
Create a Folder with Category1 and Category2 and use the default attribute values for both categories:
{type
:0, parent_id
:2000, name
:New Folder
, roles
:{categories
:{9830_1
:{}, 6228_1
:{}}}}
Create a Folder with Category1 and Category2. Category1's Set Textfield on the second row has 'aaa' in the Set Textfield's third value; Category2's Textfield is 'bbb':
{type
:0, parent_id
:2000, name
:New Folder
, roles
:{categories
:{9830_3_2_4
:[,
,aaa
], 6228_2
:bbb
}}}
Copy a node 12345 to a folder 5678 (which doesn't have any categories):
{original_id
:12345, parent_id
:5678}
Copy a node 12345 to a folder 5678 (which doesn't have any categories) while applying Category2 with default values:
{original_id
:12345, parent_id
:5678, roles
:{categories
:{6228_1
:{}}}}
Create a node - required fields: type, name, parent_id
Copy a node - required fields: originalid, parentid - NOTE: originalid is the ID of the node to copy, parentid is the ID of the node to copy original_id to
The parameters for creating nodes of a specific subtype are listed below:
Create category - required fields: type, parent_id, name - defaults: type = 131
Create channel - required fields: type, parent_id, name - defaults: type = 207
Create document - required fields: type, parent_id, name, file - defaults: type = 144
Create compound document - required fields: type, parent_id, name - defaults: type = 136
Create folder - required fields: type, parent_id, name - defaults: type = 0
Create news - required fields: type, parent_id, name - defaults: type = 208
Create project - required fields: type, parent_id, name - defaults: type = 202
Create shortcut - required fields: type, parent_id, name - defaults: type = 1
Create generation - required fields: type, parent_id, name - defaults: type = 2
Create task - required fields: type, parent_id, name - defaults: type = 206
Create task group - required fields: type, parent_id, name - defaults: type = 205
Create task list - required fields: type, parent_id, name - defaults: type = 204
Create task milestone - required fields: type, parent_id, name - defaults: type = 212
Create URL - required fields: type, parent_id, name - defaults: type = 140
Create virtual folder - required fields: type, parent_id, name - defaults: type = 899
Request Body
[{"name"=>"type", "value"=>"15976475", "datatype"=>"number"}, {"name"=>"parent_id", "value"=>"95890361", "datatype"=>"number"}, {"name"=>"name", "value"=>"minim dolore aute", "datatype"=>"string"}, {"name"=>"description", "value"=>"velit Excepteur", "datatype"=>"string"}, {"name"=>"external_create_date", "value"=>"1973-06-22", "datatype"=>"string"}, {"name"=>"external_modify_date", "value"=>"1949-09-18", "datatype"=>"string"}, {"name"=>"external_source", "value"=>"optical_disk", "datatype"=>"string"}, {"name"=>"external_identity", "value"=>"nulla laboris", "datatype"=>"string"}, {"name"=>"external_identity_type", "value"=>"windows_sid", "datatype"=>"string"}, {"name"=>"image_id", "value"=>"83733821", "datatype"=>"number"}, {"name"=>"image_alt_text", "value"=>"incididunt fugiat ex ipsum", "datatype"=>"string"}, {"name"=>"file", "value"=>"consectetur nisi Duis tempor", "datatype"=>"string"}, {"name"=>"advanced_versioning", "value"=>"false", "datatype"=>"boolean"}, {"name"=>"effective_date", "value"=>"1954-02-01", "datatype"=>"string"}, {"name"=>"expiration_date", "value"=>"1998-12-05", "datatype"=>"string"}, {"name"=>"headline", "value"=>"ex", "datatype"=>"string"}, {"name"=>"highlights", "value"=>"minim irure ut", "datatype"=>"string"}, {"name"=>"story", "value"=>"dolor dolore", "datatype"=>"string"}, {"name"=>"attachments", "value"=>"-22957306", "datatype"=>"number"}, {"name"=>"status", "value"=>"11015295", "datatype"=>"number"}, {"name"=>"due_date", "value"=>"2001-04-17T07:51:21.267Z", "datatype"=>"string"}, {"name"=>"start_date", "value"=>"1944-02-04", "datatype"=>"string"}, {"name"=>"mission", "value"=>"exercitation reprehenderit Ut", "datatype"=>"string"}, {"name"=>"goals", "value"=>"proident Lorem voluptate ullamco Ut", "datatype"=>"string"}, {"name"=>"objectives", "value"=>"magna qui veniam id", "datatype"=>"string"}, {"name"=>"initiatives", "value"=>"adipisicing veniam et", "datatype"=>"string"}, {"name"=>"original_id", "value"=>"92102155", "datatype"=>"number"}, {"name"=>"version_number", "value"=>"laboris sint anim", "datatype"=>"string"}, {"name"=>"assigned_member_id", "value"=>"-83060065", "datatype"=>"number"}, {"name"=>"priority", "value"=>"-21039814", "datatype"=>"number"}, {"name"=>"milestone_id", "value"=>"-36837379", "datatype"=>"number"}, {"name"=>"instructions", "value"=>"dolor magna aliquip eu", "datatype"=>"string"}, {"name"=>"attachment_id", "value"=>"in tempor laborum in", "datatype"=>"string"}, {"name"=>"complete_date", "value"=>"1966-10-08", "datatype"=>"string"}, {"name"=>"url", "value"=>"aliquip Lorem", "datatype"=>"string"}, {"name"=>"location_id", "value"=>"18024303", "datatype"=>"number"}, {"name"=>"selected_facets", "value"=>"quis eiusmod voluptate adipisicing", "datatype"=>"string"}, {"name"=>"location_column_visible", "value"=>"false", "datatype"=>"boolean"}, {"name"=>"selected_facets_visible", "value"=>"false", "datatype"=>"boolean"}, {"name"=>"selected_location_visible", "value"=>"true", "datatype"=>"boolean"}]
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Accept | string |
RESPONSES
status: OK
{"results":[{"data":[{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"}]},{"data":[{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"}]}],"links":[{"data":[{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"}]},{"data":[{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"},{"value":"\u003cError: Too many levels of nesting to fake this schema\u003e"}]}]}