Skip to content

Latest commit

 

History

History
196 lines (120 loc) · 7.1 KB

FoldersApi.md

File metadata and controls

196 lines (120 loc) · 7.1 KB

FoldersApi

All URIs are relative to https://developer.api.autodesk.com/

Method HTTP request Description
getFolder GET /data/v1/projects/{project_id}/folders/{folder_id}
getFolderContents GET /data/v1/projects/{project_id}/folders/{folder_id}/contents
getFolderParent GET /data/v1/projects/{project_id}/folders/{folder_id}/parent
getFolderRefs GET /data/v1/projects/{project_id}/folders/{folder_id}/refs
getFolderRelationshipsRefs GET /data/v1/projects/{project_id}/folders/{folder_id}/relationships/refs
postFolderRelationshipsRef POST /data/v1/projects/{project_id}/folders/{folder_id}/relationships/refs

getFolder

Folder getFolder(projectId, folderId)

Returns the folder by ID for any folder within a given project. All folders or sub-folders within a project are associated with their own unique ID, including the root folder.

Parameters

Name Type Description Notes
projectId String the `project id`
folderId String the `folder id`

Return type

Folder

Authorization

oauth2_access_code

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json, application/json

getFolderContents

JsonApiCollection getFolderContents(projectId, folderId, filterType, filterId, filterExtensionType, pageNumber, pageLimit)

Returns a collection of items and folders within a folder. Items represent word documents, fusion design files, drawings, spreadsheets, etc.

Parameters

Name Type Description Notes
projectId String the `project id`
folderId String the `folder id`
filterType List<String> filter by the `type` of the `ref` target [optional]
filterId List<String> filter by the `id` of the `ref` target [optional]
filterExtensionType List<String> filter by the extension type [optional]
pageNumber Integer specify the page number [optional]
pageLimit Integer specify the maximal number of elements per page [optional]

Return type

JsonApiCollection

Authorization

oauth2_access_code

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json, application/json

getFolderParent

Folder getFolderParent(projectId, folderId)

Returns the parent folder (if it exists). In a project, subfolders and resource items are stored under a folder except the root folder which does not have a parent of its own.

Parameters

Name Type Description Notes
projectId String the `project id`
folderId String the `folder id`

Return type

Folder

Authorization

oauth2_access_code

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json, application/json

getFolderRefs

JsonApiCollection getFolderRefs(projectId, folderId, filterType, filterId, filterExtensionType)

Returns the resources (`items`, `folders`, and `versions`) which have a custom relationship with the given `folder_id`. Custom relationships can be established between a folder and other resources within the 'data' domain service (folders, items, and versions).

Parameters

Name Type Description Notes
projectId String the `project id`
folderId String the `folder id`
filterType List<String> filter by the `type` of the `ref` target [optional]
filterId List<String> filter by the `id` of the `ref` target [optional]
filterExtensionType List<String> filter by the extension type [optional]

Return type

JsonApiCollection

Authorization

oauth2_access_code

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json, application/json

getFolderRelationshipsRefs

Refs getFolderRelationshipsRefs(projectId, folderId, filterType, filterId, filterRefType, filterDirection, filterExtensionType)

Returns the custom relationships that are associated to the given `folder_id`. Custom relationships can be established between a folder and other resources within the 'data' domain service (folders, items, and versions).

Parameters

Name Type Description Notes
projectId String the `project id`
folderId String the `folder id`
filterType List<String> filter by the `type` of the `ref` target [optional]
filterId List<String> filter by the `id` of the `ref` target [optional]
filterRefType List<String> filter by `refType` [optional]
filterDirection String filter by the direction of the reference [optional] [enum: from, to]
filterExtensionType List<String> filter by the extension type [optional]

Return type

Refs

Authorization

oauth2_access_code

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json, application/json

postFolderRelationshipsRef

postFolderRelationshipsRef(projectId, folderId, body)

Creates a custom relationship between a folder and another resource within the 'data' domain service (folder, item, or version).

Parameters

Name Type Description Notes
projectId String the `project id`
folderId String the `folder id`
body CreateRef describe the ref to be created

Return type

null (empty response body)

Authorization

oauth2_access_code

HTTP request headers

  • Content-Type: application/vnd.api+json
  • Accept: application/vnd.api+json, application/json