Folders Endpoint

GET /folders

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request folders from querystring using token as a variable AccessToken # querystring of folderpath is mandatory for this endpoint curl -X GET \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders?folderPath={folderPath}
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders?folderpath=TestFolder"
  },
  "data": {
    "href": "~/folders/b5bcda94-d16d-e511-80d0-0050568dfc50",
    "dataType": "Folder",
    "id": "b5bcda94-d16d-e511-80d0-0050568dfc50",
    "name": "TestFolder",
    "modifyDate": "2015-10-08T08:31:02.683",
    "modifyById": "id",
    "createDate": "2015-10-08T08:31:02.653",
    "createById": "id",
    "topLevelFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144",
    "folderType": 2,
    "status": 0,
    "folderPath": "/TestFolder",
    "parentFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144"
  }
}
Data Types: Folder
Requests folder for the specefied folder path
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
folderPath string Path of the folder you want to retrieve
password string Password from Visual Vault
userName string User Name from Visual Vault

GET /folders/{id}

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request a folder by id using token as a variable AccessToken curl -X GET \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folder/{id}
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/b5bcda94-d16d-e511-80d0-0050568dfc50"
  },
  "data": {
    "href": "~/folders/b5bcda94-d16d-e511-80d0-0050568dfc50",
    "dataType": "Folder",
    "id": "b5bcda94-d16d-e511-80d0-0050568dfc50",
    "name": "TestFolder",
    "modifyDate": "2015-10-08T08:31:02.683",
    "modifyById": "id",
    "createDate": "2015-10-08T08:31:02.653",
    "createById": "id",
    "topLevelFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144",
    "folderType": 2,
    "status": 0,
    "folderPath": "/TestFolder",
    "parentFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144"
  }
}
Data Types: Folder
Requests a folder by Folder Id
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
id guid Folder Id
password string Password from Visual Vault
userName string User Name from Visual Vault

GET /folders/{id}/folders

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request child folders of a folder by id using token as a variable AccessToken curl -X GET \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{id}/folders
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/b5bcda94-d16d-e511-80d0-0050568dfc50/folders"
  },
  "data": [
    {
      "href": "~/folders/96b3cbe9-8876-e511-80d0-0050568dfc50",
      "dataType": "Folder",
      "id": "96b3cbe9-8876-e511-80d0-0050568dfc50",
      "name": "childTestFolder",
      "modifyDate": "2015-10-19T10:43:39.57",
      "modifyById": "id",
      "createDate": "2015-10-19T10:43:39.57",
      "createById": "id",
      "topLevelFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144",
      "folderType": 4,
      "status": 0,
      "folderPath": "/TestFolder/childTestFolder",
      "parentFolderId": "b5bcda94-d16d-e511-80d0-0050568dfc50"
    }
  ]
}
Data Types: Folder
Requests child folders of a folder by Folder Id
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
id guid Folder Id
password string Password from Visual Vault
userName string User Name from Visual Vault

GET /folders/{id}/documents

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request documents from folders using token as a variable AccessToken curl -X GET \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{id}/documents
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/b5bcda94-d16d-e511-80d0-0050568dfc50/documents/"
  },
  "data": [
    {
      "href": "~/folders/10000000-1000-2000-1111-100000000010/documents/",
      "dataType": "Document",
      "id": "b5d82c06-8c72-e511-befe-98991b71acc0",
      "documentId": "e10f2106-8c72-e511-befe-98991b71acc0",
      "name": "GEN-1",
      "description": "search.txt",
      "releaseState": 1,
      "checkInStatus": 0,
      "revision": "1",
      "reviewDate": "2015-10-14T00:00:00",
      "expireDate": "2015-10-14T00:00:00",
      "archive": 0,
      "abstract": "",
      "keywords": "",
      "changeText": null,
      "folderId": "10000000-1000-2000-1111-100000000010",
      "folderName": "General",
      "folderPath": "/General",
      "fileId": "e30f2106-8c72-e511-befe-98991b71acc0",
      "fileName": "search.txt",
      "fileSize": 1453,
      "extension": "txt",
      "contentType": "text/plain",
      "checkedInBy": "{userName}",
      "checkedOutById": "5eefec33-ca71-e511-befe-98991b71acc0",
      "checkedOutBy": "{userName}",
      "checkOutDate": "2015-10-14T08:55:43.983",
      "createDate": "2015-10-14T08:55:43.923",
      "createById": "5eefec33-ca71-e511-befe-98991b71acc0",
      "createBy": "{userName}",
      "modifyDate": "2015-10-14T08:55:44.013",
      "modifyById": "5eefec33-ca71-e511-befe-98991b71acc0",
      "modifyBy": "{userName}"
    }
  ]
}
Data Types: Document
Requests the Documents for the specified Folder Id.
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
id guid Folder Id
password string Password from Visual Vault
userName string User Name from Visual Vault

GET /folders/{id}/indexfields

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request Folder Index Fields from folder id using token as a variable AccessToken curl -X GET \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{id}/indexfields
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexfields"
  },
  "data": [
    {
      "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexfield/382b6ac9-1c40-e411-b405-005056806ba3",
      "dataType": "FolderIndexField",
      "id": "382b6ac9-1c40-e411-b405-005056806ba3",
      "definitionPkey": 8,
      "folderId": "c3996a8a-7b19-e211-a871-000c29753f96",
      "fieldType": 1,
      "label": "Employee ID",
      "description": "ID of the Employee",
      "ordinalPosition": 7,
      "folderOrdinalPosition": 0,
      "required": false,
      "connectionId": "00000000-0000-0000-0000-000000000000",
      "queryId": "00000000-0000-0000-0000-000000000000",
      "queryDisplayField": "",
      "queryValueField": "",
      "dropDownListId": "00000000-0000-0000-0000-000000000000",
      "defaultValue": "",
      "globalRequired": false,
      "globalConnectionId": "00000000-0000-0000-0000-000000000000",
      "globalQueryID": "00000000-0000-0000-0000-000000000000",
      "globalQueryValueField": "",
      "globalQueryDisplayField": "",
      "globalDropDownListId": "00000000-0000-0000-0000-000000000000",
      "globalDefaultValue": "",
      "createDate": "2014-09-19T16:48:32.04",
      "createById": "id",
      "createBy": "{userName}",
      "modifyDate": "2014-09-19T16:48:32.04",
      "modifyById": "id",
      "modifyBy": "{userName}"
    }
  ]
}
Data Types: FolderIndexField
Requests index fields of a folder by Folder Id
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
id guid Folder Id
password string Password from Visual Vault
userName string User Name from Visual Vault

GET /folders/{folderId}/indexfields/{id}

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request a specefic Folder Index Field from folder id and Folder Index Field id using token as a variable AccessToken curl -X GET \ -H "Content-Type: application/json" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{folderId}/indexfields/{id}
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexfields/382b6ac9-1c40-e411-b405-005056806ba3"
  },
  "data": {
    "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexfield/382b6ac9-1c40-e411-b405-005056806ba3",
    "dataType": "FolderIndexField",
    "id": "382b6ac9-1c40-e411-b405-005056806ba3",
    "definitionPkey": 8,
    "folderId": "c3996a8a-7b19-e211-a871-000c29753f96",
    "fieldType": 1,
    "label": "Employee ID",
    "description": "ID of the Employee",
    "ordinalPosition": 7,
    "folderOrdinalPosition": 0,
    "required": false,
    "connectionId": "00000000-0000-0000-0000-000000000000",
    "queryId": "00000000-0000-0000-0000-000000000000",
    "queryDisplayField": "",
    "queryValueField": "",
    "dropDownListId": "00000000-0000-0000-0000-000000000000",
    "defaultValue": "",
    "globalRequired": false,
    "globalConnectionId": "00000000-0000-0000-0000-000000000000",
    "globalQueryID": "00000000-0000-0000-0000-000000000000",
    "globalQueryValueField": "",
    "globalQueryDisplayField": "",
    "globalDropDownListId": "00000000-0000-0000-0000-000000000000",
    "globalDefaultValue": "",
    "createDate": "2014-09-19T16:48:32.04",
    "createById": "id",
    "createBy": "{userName}",
    "modifyDate": "2014-09-19T16:48:32.04",
    "modifyById": "id",
    "modifyBy": "{userName}"
  }
}
Data Types: FolderIndexField
Requests index fields of a folder by Folder Id and Folder Index Field Id
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
folderId guid Folder Id
id guid Folder Index Field Id
password string Password from Visual Vault
userName string User Name from Visual Vault

GET /folders/{folderId}/indexfields/{id}/selectoptions

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to request drop down options from Folder Index Fields from folder id using token as a variable AccessToken curl -X GET \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{folderId}/indexfields/{id}/selectoptions
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "GET",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexfields/307f8927-bf1b-e311-abed-000c291aac29/selectOptions"
  },
  "data": [
    {
      "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexFields/307f8927-bf1b-e311-abed-000c291aac29",
      "dataType": "IndexFieldSelectOption",
      "display": "Electrical Engineering",
      "value": "Electrical Engineering"
    },
    {
      "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexFields/307f8927-bf1b-e311-abed-000c291aac29",
      "dataType": "IndexFieldSelectOption",
      "display": "Finance",
      "value": "Finance"
    },
    {
      "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexFields/307f8927-bf1b-e311-abed-000c291aac29",
      "dataType": "IndexFieldSelectOption",
      "display": "Quality",
      "value": "Quality"
    },
    {
      "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexFields/307f8927-bf1b-e311-abed-000c291aac29",
      "dataType": "IndexFieldSelectOption",
      "display": "R and D",
      "value": "R and D"
    },
    {
      "href": "~/folders/c3996a8a-7b19-e211-a871-000c29753f96/indexFields/307f8927-bf1b-e311-abed-000c291aac29",
      "dataType": "IndexFieldSelectOption",
      "display": "Sales",
      "value": "Sales"
    }
  ]
}
Requests drop down list options from of an index field from Folder Index Field Id and Folder Id. Index Field should be a drop down list index field for response to result not NULL.
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
folderId guid Folder Id
id guid Folder Index Field Id
password string Password from Visual Vault
userName string User Name from Visual Vault

POST /folders

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to create a folder using token as a variable AccessToken curl -X POST \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ -d '{ "name": "newTestFolder", "description": "A folder for test creation", "allowRevisions": true }' \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "POST",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/"
  },
  "data": {
    "href": "~/folders/24da1a9f-8976-e511-80d0-0050568dfc50",
    "dataType": "Folder",
    "id": "24da1a9f-8976-e511-80d0-0050568dfc50",
    "name": "newTestFolder",
    "modifyDate": "2015-10-19T10:48:36.573",
    "modifyById": "id",
    "createDate": "2015-10-19T10:48:36.573",
    "createById": "id",
    "topLevelFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144",
    "folderType": 2,
    "status": 0,
    "folderPath": "/newTestFolder",
    "parentFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144"
  }
}
Data Types: Folder
Endpoint to create a folder. The name, description, and allowRevisions fields are required for folder creation using the API.
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
password string Password from Visual Vault
userName string User Name from Visual Vault

POST /folders/{id}

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to create a child folder of a folder by id using token as a variable AccessToken curl -X POST \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ -d '{ "name": "newChildTestFolder", "description": "A folder for test creation", "allowRevisions": true }' \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{id}
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "POST",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/24da1a9f-8976-e511-80d0-0050568dfc50"
  },
  "data": {
    "href": "~/folders/aea40c07-8a76-e511-80d0-0050568dfc50",
    "dataType": "Folder",
    "id": "aea40c07-8a76-e511-80d0-0050568dfc50",
    "name": "newChildTestFolder",
    "modifyDate": "2015-10-19T10:51:30.937",
    "modifyById": "id",
    "createDate": "2015-10-19T10:51:30.903",
    "createById": "id",
    "topLevelFolderId": "dd8654b1-f876-4c36-b54a-bd8660c6a144",
    "folderType": 4,
    "status": 0,
    "folderPath": "/newTestFolder/newChildTestFolder",
    "parentFolderId": "24da1a9f-8976-e511-80d0-0050568dfc50"
  }
}
Data Types: Folder
Creates a child folder of a folder by Folder Id. The name, description, and allowRevisions field are required to create a folder using the API.
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
id guid Folder Id
password string Password from Visual Vault
userName string User Name from Visual Vault

PUT /folders/{folderId}/indexfields/{id}

#!/bin/sh # script to get token AccessToken=$(curl -X POST -d "client_id={clientId}&client_secret={clientSecret}&username={userName}&password={password}&grant_type=password" \ https://demo.visualvault.com/oauth/token | python -c 'import sys, json; print json.load(sys.stdin)["access_token"]') # run command to update a specific Folder Index Field from folder id and Folder Index Field id using token as a variable AccessToken curl -X PUT \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $AccessToken" \ -d '{ "dropDownListId": "d19af16a-3678-e511-bf00-bfff3cb84a46", "queryId": "d19af16a-3678-e511-bf00-bfff3cb84a46", "queryValueField": "", "queryDisplayField": "", "required": true, "defaultValue": "New Default Value" }' \ https://demo.visualvault.com/api/v1/{customerAlias}/{databaseAlias}/folders/{folderId}/indexfields/{id}
{
  "meta": {
    "status": 200,
    "statusMsg": "OK",
    "method": "PUT",
    "href": "https://demo.visualvault.com/api/v1/{customerAlias}/default/folders/114c71af-4778-e511-bf00-bfff3cb84a46/indexfields/0ca8c2ae-3778-e511-bf00-bfff3cb84a46"
  }
}
Updates a folder index field by Folder Id and Folder Index Field Id. The above fields are requried fields for this request. You may override the global indexfield definition by inputting a new queryId or dropDownListId. You may also change the required field and the defaultValue.
Parameters
Key Type Description
clientId guid Client Id from Visual Vault
clientSecret guid Client Secret from Visual Vault
customerAlias string The alias of the customer you want to connect to
databaseAlias string The alias of the database of the customer you want to connect to
folderId guid Folder Id
id guid Folder Index Field Id
password string Password from Visual Vault
userName string User Name from Visual Vault