Add Document to Binder
Add a document to a binder.
Binders cannot exceed 50,000 nodes. Nodes include documents, sections, and component binders. If a binder has reached its limit, binder nodes cannot be added to the binder or any of its component binders, even if the component binders have not reached the 50,000 node limit.
POST
/api/{version}/objects/binders/{binder_id}/documentsHeaders
Section link for Headers| Name | Description |
|---|---|
Content-Type | application/x-www-form-urlencoded |
Accept | application/json (default) or application/xml |
URI Path Parameters
Section link for URI Path Parameters| Name | Description |
|---|---|
{binder_id} | The binder id field value. |
Body Parameters
Section link for Body Parameters| Field Name | Description |
|---|---|
document_id__vrequired | ID of the document being added to the binder. |
parent_id__voptional | Section ID of the parent section, if the document will be in a section rather than top-level. Note: the section ID is unique no matter where it is in the binder hierarchy. Blank means adding the document at the top-level binder. |
order__voptional | Enter a number reflecting the position of the document within the binder or section. A value of 1 has special behavior and instructs Vault to place the document 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 document at the last ordinal position of the binder, regardless of any existing order__v values. |
binding_rule__voptional | The binding rule indicating which version of the document will be linked to the binder and the ongoing behavior. Options are: default (bind to the latest available version (assumed if binding_rule is blank)), steady-state (bind to latest version in a steady-state), current (bind to current version), or specific (bind to a specific version). |
major_version_number__voptional | If binding_rule__v=specific, then this is required and indicates the major version of the document to be linked. Otherwise it is ignored. |
minor_version_number__voptional | If binding_rule__v=specific, then this is required and indicates the minor version of the document to be linked. Otherwise it is ignored. |
Request
Section link for Requestcurl -X POST -H "Authorization: {SESSION_ID}" \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "document_id__v=585" \
-d "parent_id__v=1427232809771:1381853041" \
-d "section_id__v=1" \
-d "binding_rule__v=steady-state" \
https://myvault.veevavault.com/api/v26.1/objects/binders/566/documentsResponse
Section link for Response{
"responseStatus": "SUCCESS",
"id": "1427491342404:-1828014479"
}