Get Folders or Documents Metadata by Path

GET /ws/rest/service/v1/dm/node/properties

Purpose

This service allows you to retrieve a folder's or a document's meta data using a folder path.

Prerequisites

To use this REST service:

  • Configure the Document Manager (DM) in the shell where folder is to be created.
  • To include categories and phases in the request, ensure the categories are configured in the Project Phase.
    1. Go to the Company Workspace tab, and switch to Admin mode.
    2. In the left Navigator, select Data Structure Setup, select Data Definitions, and then select Basic.
    3. Open Project Phase.

    Multiple categories and phases can be included in the request.

  • As an integration user, you must also have update access on DM functionality.

Request Format

Send a request in the following format.

URL: http://<host>:<port>/ws/rest/service/v1/dm/node/properties?projectnumber=<value>&parentpath=<value>

Supported Request Parameters

The following parameters can be included in the request.

Request Parameter Required? Data Type Description
projectnumber Yes String The shell in which the folder is to be created. Empty for company level DM.
parentpath Yes String The path of the folder in Document Manager whose meta data is being requested.
nodetype No String

The properties of the Folder or Document depending on the nodetype. Valid values include: "Folder" and "Document".

If no value is specified, both the folder and document properties will be returned.

Sample Request

To obtain the meta data of the project, TestProj-C, with parentpath, /u17.1, send a request as shown below.

http://<host>:<port>/ws/rest/service/v1/dm/node/properties?projectnumber=TestProj-C&parentpath=/u17.1

Response Format

A JSON object is returned in the following format.

{

"data": [],

"message": [],

"status": <REST status code value>

}

Sample Success Response

This is an example where the "data" is an array of document or folder properties.

{

"data":

[

{

"Owner":"Company Administrator",

"projectnumber":null,

"node_path":"/Company Documents",

"Description":"",

"type":"Folder",

"foreignKeyId":-1000,

"parentUuid":null,

"Name":"Company Documents",

"parent_node_id":285,

"foreignEntityType":"company",

"% Complete":"0",

"Location":"/",

"node_id":700,

"upload_date":"2017-12-07T07:54"

},

{

"Revision No.":"",

"Owner":"Company Administrator",

"projectnumber":null,

"node_path":"/Folder City/Fremont/AutoVue_Applet-Free_Client_TUD.pdf",

"Description":"",

"Pub No.":"1",

"file_name":"AutoVue_Applet-Free_Client_TUD.pdf",

"annotate":true,

"type":"Document",

"title":"",

"foreignKeyId":-1000,

"parentUuid":294,

"file_size":"448519",

"uuu_create_by":"Company Administrator",

"file_id":58,

"Issue Date":"",

"foreignEntityType":"company",

"% Complete":"0",

"Location":"/Folder City/Fremont",

"node_id":306,

"upload_date":"2017-11-03T14:02"

},

],

"message":

[

],

"status":200

}

Sample Failed Response

The REST service returns a failed response with status code 1039 when a parentpath is incorrect or blank in the following format:

{

"data":[ ],

"message":[

{

"message":"Parent path or node id is invalid or does not exists."

}

],

"status":1039

}