6 Dec 2019

Node.js SDK update

We are happy to announce we did update the Forge Node.js SDK to support the Data Management filters / pagination, the 'Commands' API, and support for 2legged users. This new version (0.5.0) of the SDK is a minor rewrite of the 0.4.8 code base. Your code will continue to run as is with this version, but if you want to use the latest API features, you may need to use the new methods. Here is the list of the new API, and how to use the new features.

New API: Commands API

/**
* Checks if a user has permission to perform specified actions on specified resources.
* @param {String} projectId - the project id
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Object} body - API payload
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function checkPermission (projectId, body, opts, oauth2client, credentials)

/**
* Retrieves the custom relationships between specified versions of items and other resources in the data domain service (folders, items, and versions). You can retrieve the relationships of up to 50 versions.
* @param {String} projectId - the project id
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Object} body - API payload
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function listRefs (projectId, body, opts, oauth2client, credentials)

/**
* Retrieves metadata for up to 50 specified items. For example, an item name, or the date it was created. It returns the tip (latest) version of the items.
* @param {String} projectId - the project id
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Object} body - API payload
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function listItems (projectId, body, opts, oauth2client, credentials)

/**
* Creates folders in BIM 360 Docs.
* @param {String} projectId - the project id
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Object} body - API payload
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function createFolder (projectId, body, opts, oauth2client, credentials)

/**
* Publishes the latest version of a Collaboration for Revit (C4R) model to BIM 360 Docs.
* @param {String} projectId - the project id
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Object} body - API payload
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function publishModel (projectId, body, opts, oauth2client, credentials)

/**
* Verifies whether a Collaboration for Revit (C4R) model needs to be published to BIM 360 Docs.
* @param {String} projectId - the project id
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Object} body - API payload
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function getPublishModelJob (projectId, body, opts, oauth2client, credentials)

 

Updated API: Data Management API (anything in bold in new)

Hubs API

/**
* Returns data on a specific hub_id
* @param {String} hubId - the hub id for the current operation
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Hub}
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function getHub2 = function(hubId, opts, oauth2client, credentials)

HubsApi.getHub remains unchanged

/**
* Returns a collection of accessible hubs for this member. A Hub represents an A360 Team/Personal hub or a BIM 360 account.
* @param {Object} opts - Optional parameters
* @param {String} opts.xuserid - API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterId - filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterName - filter by the `name` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType - filter by the extension type
* @param {Array.<*>} opts['filter[*]<-modifier>'] - generic filter / <-modifier> is optional
* data is of type: {module:model/Hubs}
* @param {Object} oauth2client - oauth2client for the call
* @param {Object} credentials - credentials for the call
*/
function getHubs (opts, oauth2client, credentials)

opts.filters is a generic and mode complete version of filtering data when running the API and follow the principles describe on this page. For example

filter[lastModifiedTime]-ge=2016 would be described as opts.filters = { 'filter[lastModifiedTime]-ge': [ '2016' ] }
filter[fileType]-eq=rvt,dwg and filter[lastModifiedTime]-ge=2016 would be described as opts.filters = { 'filter[lastModifiedTime]-ge': [ '2016' ], 'filter[fileType]-eq': [ 'rvt', 'dwg' ] }

Syntax: 'filter[<json path>]<modifier>': Array<*> - modifier is optional and should include the '-' if present.

Projects API

/**
* Returns a collection of projects for a given hub_id. A project represents an A360 project or a BIM 360 project which is set up under an A360 hub or BIM 360 account, respectively. Within a hub or an account, multiple projects can be created to be used.
* @param {String} hubId the hub id for the current operation
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<Integer>} opts.pageNumber Specify the page number.
* @param {Array.<Integer>} opts.pageLimit Specify the maximal number of elements per page.
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/Projects}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getHubProjects (hubId, opts, oauth2client, credentials)

/**
* Returns a project for a given project_id.
* @param {String} hubId the hub id for the current operation
* @param {String} projectId the project id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* data is of type: {module:model/Project}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
this.getProject2 = function(hubId, projectId, opts, oauth2client, credentials) {

ProjectsApi.getProject remains unchanged

/**
* Returns the hub for a given project_id.
* @param {String} hubId the hub id for the current operation
* @param {String} projectId the project id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Hub}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getProjectHub2 (hubId, projectId, opts, oauth2client, credentials)

ProjectsApi.getProjectHub remains unchanged

/**
* Returns the details of the highest level folders the user has access to for a given project
* @param {String} hubId the hub id for the current operation
* @param {String} projectId the project id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/TopFolders}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getProjectTopFolders2 (hubId, projectId, opts, oauth2client, credentials)

ProjectsApi.getProjectTopFolders remains unchanged

/**
* Returns the details for a specific download.
* @param {String} projectId the project id
* @param {String} downloadId The unique identifier of a download job.
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* data is of type: {module:model/TopFolders}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getDownload (projectId, downloadId, opts, oauth2client, credentials)

/**
* Returns the job_id object.
* @param {String} projectId the project id
* @param {String} jobId The unique identifier of a job.
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* data is of type: {module:model/TopFolders}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getJob (projectId, jobId, opts, oauth2client, credentials)

/**
* Request the creation of a new download for a specific and supported file type.
* @param {String} projectId the project id
* @param {module:model/CreateStorage} body describe the file the storage is created for
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* data is of type: {module:model/StorageCreated}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postDownload (projectId, body, opts, oauth2client, credentials)

/**
* Creates a storage location in the OSS where data can be uploaded to.
* @param {String} projectId the project id
* @param {module:model/CreateStorage} body describe the file the storage is created for
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/StorageCreated}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
this.postStorage2 = function(projectId, body, opts, oauth2client, credentials)

ProjectsApi.postStorage remains unchanged

Folders API

/**
* 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.
* @param {String} projectId the &#x60;project id&#x60;
* @param {String} folderId the &#x60;folder id&#x60;
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {String} opts.ifModifiedSince If the requested object has not been modified since the time specified in this field, an entity will not be returned from the server; instead, a 304 (not modified) response will be returned without any message body.

* data is of type: {module:model/Folder}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getFolder2 (projectId, folderId, opts, oauth2client, credentials) 

FoldersApi.getFolder remains unchanged

/**
* Returns a collection of items and folders within a folder. Items represent word documents, fusion design files, drawings, spreadsheets, etc.
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Integer} opts.pageNumber specify the page number
* @param {Integer} opts.pageLimit specify the maximal number of elements per page
* @param {Boolean} opts.includeHidden Refers to items and folders that were deleted from BIM 360 Docs projects.
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional

* data is of type: {module:model/JsonApiCollection}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getFolderContents (projectId, folderId, opts, oauth2client, credentials)

/**
* 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.
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Folder}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getFolderParent2 (projectId, folderId, opts, oauth2client, credentials)

FoldersApi.getFolderParent remains unchanged

/**
* 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).
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/JsonApiCollection}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getFolderRefs (projectId, folderId, opts, oauth2client, credentials)

/**
* Returns a collection of links for the given folder_id. Custom relationships can be established between a folder and other external resources residing outside the data domain service. A link’s href defines the target URI to access a resource.
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<String>} opts.filterMimeType Filter by mime type.
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/JsonApiCollection}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getFolderRelationshipsLinks (projectId, folderId, opts, oauth2client, credentials)

/**
* 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 &#39;data&#39; domain service (folders, items, and versions).
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterRefType filter by `refType`
* @param {module:model/String} opts.filterDirection filter by the direction of the reference
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/Refs}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getFolderRelationshipsRefs (projectId, folderId, opts, oauth2client, credentials)

/**
* Filters the data of a folder and recursively in the subfolders of any project accessible to you.
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* @param {Integer} opts.pageNumber specify the page number
* @param {Integer} opts.pageLimit specify the maximal number of elements per page

* data is of type: {module:model/Refs}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function search (projectId, folderId, opts, oauth2client, credentials)

/**
* Creates a new folder in the data domain service
* @param {String} projectId the project id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* @param {module:model/CreateFolder} body describe the folder to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postFolder2 (projectId, body, opts, oauth2client, credentials)

FoldersApi.postFolder remains unchanged

/**
* Creates a custom relationship between a folder and another resource within the &#39;data&#39; domain service (folder, item, or version).
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* @param {module:model/CreateRef} body describe the ref to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postFolderRelationshipsRef2 (projectId, folderId, body, opts, oauth2client, credentials)

FoldersApi.postFolderRelationshipsRef remains unchanged

/**
* Modifies folder names. You can also use this endpoint to delete and restore BIM 360 Docs folders by using the hidden attribute.
* @param {String} projectId the project id
* @param {String} folderId the folder id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Object} body describe the ref to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function patchFolder (projectId, folderId, body, opts, oauth2client, credentials)

Items API

/**
* Returns a resource item by ID for any item within a given project. Resource items represent word documents, fusion design files, drawings, spreadsheets, etc.
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Boolean} opts.includePathInProject Specify whether to return pathInProject attribute in response for BIM 360 Docs projects.

* data is of type: {module:model/Item}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItem2 (projectId, itemId, opts, oauth2client, credentials)

ItemsApi.getItem remains unchanged

/**
* Returns the parent folder for the given item.
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Folder}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItemParentFolder2 (projectId, itemId, opts, oauth2client, credentials)

ItemsApi.getItemParentFolder remains unchanged

/**
* Returns the resources (items, folders, and versions) which have a custom relationship with the given item_id. Custom relationships can be established between an item and other resources within the data domain service (folders, items, and versions).
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/JsonApiCollection}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItemRefs (projectId, itemId, opts, oauth2client, credentials)

/**
* Returns the custom relationships that are associated to the given item_id. Custom relationships can be established between an item and other resources within the data domain service (folders, items, and versions).
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<String>} opts.filterMimeType Filter by mime type.
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/Refs}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItemRelationshipsLinks (projectId, itemId, opts, oauth2client, credentials) 

/**
* Returns the custom relationships that are associated to the given item_id. Custom relationships can be established between an item and other resources within the &#39;data&#39; domain service (folders, items, and versions).
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterRefType filter by `refType`
* @param {module:model/String} opts.filterDirection filter by the direction of the reference
* @param {Array.<String>} opts.filterExtensionType filter by the extension type

* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/Refs}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItemRelationshipsRefs (projectId, itemId, opts, oauth2client, credentials)

/**
* Returns the tip version for the given item. Multiple versions of a resource item can be uploaded in a project. The tip version is the most recent one.
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Version}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItemTip2 (projectId, itemId, opts, oauth2client, credentials)

ItemsApi.getItemTip remains unchanged

/**
* Returns versions for the given item. Multiple versions of a resource item can be uploaded in a project.
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<Integer>} opts.filterVersionNumber filter by `versionNumber`
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* @param {Integer} opts.pageNumber specify the page number
* @param {Integer} opts.pageLimit specify the maximal number of elements per page

* data is of type: {module:model/Versions}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getItemVersions (projectId, itemId, opts, oauth2client, credentials)

/**
* Creates a new item in the data domain service.
* @param {String} projectId the project id
* @param {module:model/CreateItem} body describe the item to be created
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {String} opts.copyFrom Only relevant for copying files to BIM 360 Docs - the version ID (URN) of the file to copy.

* data is of type: {module:model/ItemCreated}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postItem2 (projectId, body, opts, oauth2client, credentials)

ItemsApi.postItem remains unchanged

/**
* Creates a custom relationship between an item and another resource within the &#39;data&#39; domain service (folder, item, or version).
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* @param {module:model/CreateRef} body describe the ref to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postItemRelationshipsRef2 (projectId, itemId, body, opts, oauth2client, credentials)

ItemsApi.postItemRelationshipsRef remains unchanged

/**
* Updates the properties of the given item_id object.
* @param {String} projectId the project id
* @param {String} itemId the item id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Object} body describe the ref to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function patchItem (projectId, itemId, body, opts, oauth2client, credentials)

Versions API

/**
* Returns the version with the given version_id.
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Version}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getVersion2 (projectId, versionId, opts, oauth2client, credentials)

VersionsApi.getVersion remains unchanged

/**
* Returns a collection of file formats this version could be converted to and downloaded as.
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* data is of type: {module:model/Version}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getVersionDownloadFormats (projectId, versionId, opts, oauth2client, credentials)

/**
* Returns a collection of file formats this version could be converted to and downloaded as.
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/Version}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getVersionDownloads (projectId, versionId, opts, oauth2client, credentials)

/**
* Returns the item the given version is associated with.
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/Item}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getVersionItem2 (projectId, versionId, opts, oauth2client, credentials)

VersionsApi.getVersionItem remains unchanged

/**
* Returns the resources (items, folders, and versions) which have a custom relationship with the given version_id. Custom relationships can be established between a version of an item and other resources within the data domain service (folders, items, and versions).
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/JsonApiCollection}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getVersionRefs (projectId, versionId, opts, oauth2client, credentials)

/**
* Returns a collection of links for the given item_id-version_id object.
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional
* data is of type: {module:model/JsonApiCollection}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function getVersionRelationshipsLinks (projectId, versionId, opts, oauth2client, credentials)

/**
* Returns the custom relationships that are associated to the given version_id. Custom relationships can be established between a version of an item and other resources within the datadomain service (folders, items, and versions).
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {Array.<String>} opts.filterType filter by the `type` of the `ref` target
* @param {Array.<String>} opts.filterId filter by the `id` of the `ref` target
* @param {Array.<String>} opts.filterRefType filter by `refType`
* @param {module:model/String} opts.filterDirection filter by the direction of the reference
* @param {Array.<String>} opts.filterExtensionType filter by the extension type
* @param {Array.<*>} opts['filter[*]<-modifier>'] generic filter / <-modifier> is optional

* data is of type: {module:model/Refs}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
this.getVersionRelationshipsRefs = function(projectId, versionId, opts, oauth2client, credentials)

/**
* Creates a new version of an item in the data domain service.
* @param {String} projectId the project id
* @param {module:model/CreateVersion} body describe the version to be created
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* data is of type: {module:model/VersionCreated}
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postVersion2 (projectId, body, opts, oauth2client, credentials)

VersionsApi.postVersion remains unchanged

/**
* Creates a custom relationship between a version and another resource within the &#39;data&#39; domain service (folder, item, or version).
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified

* @param {module:model/CreateRef} body describe the ref to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function postVersionRelationshipsRef2 (projectId, versionId, body, opts, oauth2client, credentials)

VersionsApi.postVersionRelationshipsRef remains unchanged

/**
* Updates the properties of the given version_id object.
* @param {String} projectId the project id
* @param {String} versionId the version id
* @param {Object} opts Optional parameters
* @param {String} opts.xuserid API call will be limited to act on behalf of only the user specified
* @param {module:model/CreateRef} body describe the ref to be created
* @param {Object} oauth2client oauth2client for the call
* @param {Object} credentials credentials for the call
*/
function patchVersion (projectId, versionId, body, opts, oauth2client, credentials)

 

 

Related Article