Create Binder Template Node
Create nodes in an existing binder template.
POST
/api/{version}/objects/binders/templates/{template_name}/bindernodesHeaders
Section link for Headers| Name | Description |
|---|---|
Content-Type | application/json or text/csv |
Accept | application/json (default) or application/xml |
URI Path Parameters
Section link for URI Path Parameters| Name | Description |
|---|---|
{template_name} | The binder template name__v field value. |
Body Parameters
Section link for Body ParametersWhen creating binder template nodes, the following fields are required in all Vaults:
| Name | Description |
|---|---|
idrequired | The ID of the binder node. This must be set to a unique number. |
parent_id__vrequired | Enter the id of the parent section. To create a node in the top level of the binder (rootNode), leave the value blank. |
node_type__vrequired | Set to section or planned_document. |
label__vrequired | Label for the section or planned document. For planned documents, this corresponds to "Planned Name" in the UI. |
type__voptional | The name of the document type to which the template will be associated. |
subtype__voptional | The name of the document subtype to which the templates will be associated. This is only required if associating the template with a document subtype. |
classification__voptional | The name of the document classification to which the template will be associated. This is only required if associating the template with a document classification. |
active__voptional | Set to true or false to indicate whether or not the binder template should be set to active, i.e., available for selection when creating a binder. |
order__voptional | Order of the component (planned document or section) within the binder template or within the template section. A value of 1 has special behavior and instructs Vault to place the node at the first ordinal position of the binder, regardless of any existing order__v values. If provided with a negative value or omitted, Vault places the node at the last ordinal position of the binder, regardless of any existing order__v values. |
Example CSV Input: Create Top-Level Section Binder Nodes
Section link for Example CSV Input: Create Top-Level Section Binder Nodesid | node_type__v | label__v | order__v | number__v | parent_id__v |
|---|---|---|---|---|---|
| 100 | section | Folder A | 1 | 01 | |
| 200 | section | Folder B | 2 | 02 | |
| 300 | section | Folder C | 3 | 03 |
In this example input, we're creating three new binder nodes in the template.
- These will be new
sectionnode types. - The required
parent_id__vname is included but its value left blank. By default, the new sections will be added to the top-level in the binder hierarchy. - The optional section order and number are set. These define the position of the three new sections in the binder template hierarchy.
Example CSV Input: Create Sub-Level Section Binder Nodes
Section link for Example CSV Input: Create Sub-Level Section Binder Nodesid | node_type__v | label__v | order__v | number__v | parent_id__v |
|---|---|---|---|---|---|
| 101 | section | SubFolder A1 | 1 | 01.01 | 100 |
| 102 | section | SubFolder A2 | 2 | 01.02 | 100 |
In this example input, we're creating three new binder nodes in the template.
- These will be new
sectionnode types. - The required
parent_id__vname is included. If the values are left blank, the new sections will be added to the top-level in the binder hierarchy by default. - The optional section order and number are set. These define the position of the three new sections in the binder template hierarchy.
Example CSV Input: Create Planned Document Binder Node
Section link for Example CSV Input: Create Planned Document Binder Nodeid | node_type__v | label__v | order__v | parent_id__v | type__v | subtype__v | classification__v | lifecycle__v |
|---|---|---|---|---|---|---|---|---|
| 101PD | planned_document | Planned Document A1 | 1 | 101 | promotional_piece__vs | advertisement__vs | web__vs | promotional_piece__vs |
In this example input, we're creating new binder node of the type planned_document.
- The required
parent_id__vname is included. If the values are left blank, the planned document will be added to the top-level in the binder hierarchy by default. - The optional section order and number are set. These define the position of the planned document in the binder template hierarchy.
In this example:
- The input file format is set to CSV.
- The response format is not set and will default to JSON.
- The path/name of the CSV input file in our local directory is specified.
Request
Section link for Requestcurl -X POST -H "Authorization: {SESSION_ID}" \
-H "Content-Type: text/csv" \
--data-binary @"C:\Vault\Templates\add_binder_template_nodes.csv" \
https://myvault.veevavault.com/api/v23.2/objects/binders/templates/binder_template_1__c/bindernodes