# Asset Operations Invoke the Asset API to create, retrieve, manipulate, and share Assets. This API also provides operations to manage Asset relationships and download Asset content. ## Create an Asset. - [POST /asset](https://api.tenovos.com/openapi/v1/asset-operations/createasset.md): Use this service to perform one of the following operations: 1) Create a new Asset 2) Create a new Version of an existing Asset 3) Create a new Metadata-only Asset Once the new Asset or Asset Version is created, a new Object ID is returned to identify the new Asset / Asset Version. When a new Asset is created, the Asset is considered a metadata-only Asset until a corresponding content file is uploaded. The Asset's content file size must be less than or equal to 5GB. After invoking the Create Asset service, the response shall include a signed URL to upload the content file. The upload should be performed using a PUT request with the file content attached as binary data in the request body. After creating an asset greater than 100MB, multiple presigned urls will be returned. You must upload file chunks of 100MB to each one. You must call the /asset/complete endpoint to complete or cancel a multi-part file upload, otherwise the file will not be available to Tenovos. The user submitting the request to create an Asset must have the Upload Security Role Privilege and be granted access to at least one Security Template to assign to the new Asset. ## Bulk edit one or more Assets. - [PATCH /asset](https://api.tenovos.com/openapi/v1/asset-operations/editassets.md): Perform metadata edits and/or reassign Security Templates to one or more Assets. Assets are identified by Object ID. If multiple Assets are specified, the same metadata and/or security edits will be applied to all Assets in the request. Each Metadata Attribute is identified by a Metadata Definition ID. The user performing the bulk edit must have the Edit Metadata permission granted on each Asset being edited. ## Get a single Asset. - [GET /asset/{id}](https://api.tenovos.com/openapi/v1/asset-operations/getasset.md): Retrieve an Asset by specifying an Object ID or File ID in the request path. The user requesting the Asset must have view access to the Asset in order to retrieve the Asset. ## Update a single Asset. - [PATCH /asset/{id}](https://api.tenovos.com/openapi/v1/asset-operations/updateasset.md): Update the metadata attributes and/or the Security Template assignments for an Asset identified by Object ID. The Object ID must be specified in the request path. The user submitting the request must have edit access to the Asset. ## Get the content file download link of an Asset. - [GET /asset/{id}/content](https://api.tenovos.com/openapi/v1/asset-operations/getassetcontent.md): Retrieve a presigned URL to the Asset's source file by Object ID. The user requesting the Asset's source file must have download access to the Asset. ## Soft Delete or Un-delete an Asset. - [POST /asset/{id}/delete](https://api.tenovos.com/openapi/v1/asset-operations/deleteasset.md): Soft delete or un-delete an Asset. An Asset that has been soft-deleted can be later purged from the recycle bin. A soft-deleted Asset cannot be edited or downloaded. The user attempting to soft delete or un-delete an Asset must be granted the Delete Security Template permission on the Asset. ## Get latest version of an Asset. - [GET /asset/{id}/latest](https://api.tenovos.com/openapi/v1/asset-operations/getlatestversion.md): Retrieve latest version of an Asset by specifying an Object ID in the request path. The user requesting the Asset must have view access to the Asset in order to retrieve the Asset. ## Retrieve Asset relationships associated with an Asset. - [GET /asset/{id}/link](https://api.tenovos.com/openapi/v1/asset-operations/getassetrelationship.md): Retrieve all Asset relationships associated with an Asset specified by Object ID. In a relationship, the Asset can be a primary or secondary (related) Asset. For example, in a parent / derivative relationship, the primary Asset would be the parent, while the secondary Asset would be the derivative. Both the Object ID and relationship type for each Asset will be returned. Relationships will be retrieved where the Asset is a primary or secondary Asset. The user requesting the Asset relationships must have View access to both the primary Asset and the secondary Assets in order to retrieve the relationships. ## Create a relationship between Assets. - [POST /asset/{id}/link](https://api.tenovos.com/openapi/v1/asset-operations/createrelationship.md): Create a bidirectional relationship between a primary Asset and one or more secondary Assets. Asset relationships allow a user to quickly navigate from one Asset to another related Asset. The user attempting to create a relationship using Asset must be granted the Relationship Security Template permission on the Asset. ## Remove a relationship between Assets. - [PATCH /asset/{id}/link](https://api.tenovos.com/openapi/v1/asset-operations/removerelationship.md): Remove a relationship between a primary Asset and one or more secondary Assets. Specify the primary Asset Object ID as a path parameter. Specify the secondary Asset Object IDs and Link Types as an array in the request body. The user requesting the Asset relationships must have view access to both the primary Asset and the related Assets in order to relationships and the related Assets. ## Get the version history of an Asset. - [GET /asset/{id}/version](https://api.tenovos.com/openapi/v1/asset-operations/getversions.md): Retrieve a list of all versions of an Asset by specifying an Object ID or Original File ID in the request path. The user requesting the Asset must have view access to the Asset in order to retrieve the Asset version history. ## Complete Upload. - [POST /asset/complete](https://api.tenovos.com/openapi/v1/asset-operations/finishupload.md): Complete/Cancel multipart upload once all parts are uploaded. This endpoint must be called after creating asset when the file is sent in chunks of 100MB each. For files 100MB or less in size this operation is not needed. ## Assign an image or PDF to be the new preview for one or more Assets. - [POST /asset/content/preview](https://api.tenovos.com/openapi/v1/asset-operations/replacepreview.md): Generate a request to upload an image or PDF file to be the new preview for one or more Assets. Supported preview image formats include: GIF, JPG, PNG, and TIFF. If a PDF file is uploaded to be the preview for a document Asset, then the PDF will also be displayed in the Asset Detail page as the multi-page PDF preview. After submitting the request to replace an Asset preview, The user replacing the Asset previews must be granted the Replace Mezzanine and Upload User Role Permissions and View Security Template Permission on the Assets being updated. For Federated Assets, if user provides optional contentPaths key in the request body, then files referenced in the contentPaths > properties are used as renditions. ## Exposes Content. - [POST /asset/expose](https://api.tenovos.com/openapi/v1/asset-operations/getasseturl.md): Exposes Asset's pre-signed urls with expiration time given in seconds Asset being exposed needs to have a Security Template with Download permission and and User must have role with Download privilege. ## Share a selection of Assets. - [POST /asset/share](https://api.tenovos.com/openapi/v1/asset-operations/shareassets.md): Share a selection of Assets to a user specified by Email address. The user sharing the Assets must be granted the Download Security Template permission on the Assets being shared. ## Share or download transformation of an Assets. - [POST /asset/transform](https://api.tenovos.com/openapi/v1/asset-operations/gettransformation.md): Transform asset and download or share transformation with an email. If email is available then this API will share link (send email) of transformed file. Note: Access to this API Service is currently limited. Contact Tenovos Customer Support to inquire further about access to this API Service if needed.