Package 

Interface SharedLinksApi

    • Method Summary

      Modifier and Type Method Description
      abstract SharedLinkEntry createSharedLink(@Body() SharedLinkBodyCreate sharedLinkBodyCreate, @Query(value = include) List<String> include, @Query(value = fields) List<String> fields) Create a shared link to a file Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract Unit deleteSharedLink(@Path(value = sharedId) String sharedId) Deletes a shared link Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract Unit emailSharedLink(@Path(value = sharedId) String sharedId, @Body() SharedLinkBodyEmail sharedLinkBodyEmail) Email shared link Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract SharedLinkEntry getSharedLink(@Path(value = sharedId) String sharedId, @Query(value = fields) List<String> fields) Get a shared link Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract ResponseBody getSharedLinkContent(@Path(value = sharedId) String sharedId, @Query(value = attachment) Boolean attachment, @Header(value = If-Modified-Since) ZonedDateTime ifModifiedSince, @Header(value = Range) String range) Get shared link content Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract RenditionEntry getSharedLinkRendition(@Path(value = sharedId) String sharedId, @Path(value = renditionId) String renditionId) Get shared link rendition information Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract ResponseBody getSharedLinkRenditionContent(@Path(value = sharedId) String sharedId, @Path(value = renditionId) String renditionId, @Query(value = attachment) Boolean attachment, @Header(value = If-Modified-Since) ZonedDateTime ifModifiedSince, @Header(value = Range) String range) Get shared link rendition content Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract RenditionPaging listSharedLinkRenditions(@Path(value = sharedId) String sharedId) List renditions for a shared link Note: this endpoint is available in Alfresco 5.2 and newer versions.
      abstract SharedLinkPaging listSharedLinks(@Query(value = skipCount) Integer skipCount, @Query(value = maxItems) Integer maxItems, @Query(value = where) String where, @Query(value = include) List<String> include, @Query(value = fields) List<String> fields) List shared links Note: this endpoint is available in Alfresco 5.2 and newer versions.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • createSharedLink

        @Headers(value = {Content-Type: application/json})@POST(value = alfresco/versions/1/shared-links) abstract SharedLinkEntry createSharedLink(@Body() SharedLinkBodyCreate sharedLinkBodyCreate, @Query(value = include) List<String> include, @Query(value = fields) List<String> fields)

        Create a shared link to a file Note: this endpoint is available in Alfresco 5.2 and newer versions. Create a shared link to the file nodeId in the request body. Also, an optional expiry date could be set, so the shared link would become invalid when the expiry date is reached. For example: ``JSON { \"nodeId\": \"1ff9da1a-ee2f-4b9c-8c34-3333333333\", \"expiresAt\": \"2017-03-23T23:00:00.000+0000\" } ``Note: You can create shared links to more than one file specifying a list of nodeIds in the JSON body like this: ``JSON [ { \"nodeId\": \"1ff9da1a-ee2f-4b9c-8c34-4444444444\" }, { \"nodeId\": \"1ff9da1a-ee2f-4b9c-8c34-5555555555\" } ] `` If you specify a list as input, then a paginated list rather than an entry is returned in the response body. For example: ``JSON { \"list\": { \"pagination\": { \"count\": 2, \"hasMoreItems\": false, \"totalItems\": 2, \"skipCount\": 0, \"maxItems\": 100 }, \"entries\": [ { \"entry\": { ... } }, { \"entry\": { ... } } ] } } `` The endpoint is owned by defaultname service owner @param sharedLinkBodyCreate The nodeId to create a shared link for. (required) @param include Returns additional information about the shared link, the following optional fields can be requested: * allowableOperations * path * properties * isFavorite * aspectNames (optional) @param fields A list of field names. You can use this parameter to restrict the fields returned within a response if, for example, you want to save on overall bandwidth. The list applies to a returned individual entity or entries within a collection. If the API method also supports the include parameter, then the fields specified in the include parameter are returned in addition to those specified in the fields parameter. (optional)

      • deleteSharedLink

        @Headers(value = {Content-Type: application/json})@DELETE(value = alfresco/versions/1/shared-links/{sharedId}) abstract Unit deleteSharedLink(@Path(value = sharedId) String sharedId)

        Deletes a shared link Note: this endpoint is available in Alfresco 5.2 and newer versions. Deletes the shared link with identifier sharedId. The endpoint is owned by defaultname service owner

        Parameters:
        sharedId - The identifier of a shared link to a file.
      • emailSharedLink

        @Headers(value = {Content-Type: application/json})@POST(value = alfresco/versions/1/shared-links/{sharedId}/email) abstract Unit emailSharedLink(@Path(value = sharedId) String sharedId, @Body() SharedLinkBodyEmail sharedLinkBodyEmail)

        Email shared link Note: this endpoint is available in Alfresco 5.2 and newer versions. Sends email with app-specific url including identifier sharedId. The client and recipientEmails properties are mandatory in the request body. For example, to email a shared link with minimum info: ``JSON { \"client\": \"myClient\", \"recipientEmails\": [\"john.doe@acme.com\", \"joe.bloggs@acme.com\"] } `` A plain text message property can be optionally provided in the request body to customise the sent email. Also, a locale property can be optionally provided in the request body to send the emails in a particular language (if the locale is supported by Alfresco). For example, to email a shared link with a messages and a locale: ``JSON { \"client\": \"myClient\", \"recipientEmails\": [\"john.doe@acme.com\", \"joe.bloggs@acme.com\"], \"message\": \"myMessage\", \"locale\":\"en-GB\" } ``Note: The client must be registered before you can send a shared link email. See server documentation. However, out-of-the-box share is registered as a default client, so you could pass share as the client name: ``JSON { \"client\": \"share\", \"recipientEmails\": [\"john.doe@acme.com\"] } `` The endpoint is owned by defaultname service owner @param sharedId The identifier of a shared link to a file. (required) @param sharedLinkBodyEmail The shared link email to send. (required)

      • getSharedLink

        @Headers(value = {Content-Type: application/json})@GET(value = alfresco/versions/1/shared-links/{sharedId}) abstract SharedLinkEntry getSharedLink(@Path(value = sharedId) String sharedId, @Query(value = fields) List<String> fields)

        Get a shared link Note: this endpoint is available in Alfresco 5.2 and newer versions. Gets minimal information for the file with shared link identifier sharedId. Note: No authentication is required to call this endpoint. The endpoint is owned by defaultname service owner

        Parameters:
        sharedId - The identifier of a shared link to a file.
        fields - A list of field names.
      • getSharedLinkContent

        @Headers(value = {Content-Type: application/json})@GET(value = alfresco/versions/1/shared-links/{sharedId}/content) abstract ResponseBody getSharedLinkContent(@Path(value = sharedId) String sharedId, @Query(value = attachment) Boolean attachment, @Header(value = If-Modified-Since) ZonedDateTime ifModifiedSince, @Header(value = Range) String range)

        Get shared link content Note: this endpoint is available in Alfresco 5.2 and newer versions. Gets the content of the file with shared link identifier sharedId. Note: No authentication is required to call this endpoint. The endpoint is owned by defaultname service owner

        Parameters:
        sharedId - The identifier of a shared link to a file.
        attachment - true enables a web browser to download the file as an attachment.
        ifModifiedSince - Only returns the content if it has been modified since the date provided.
        range - The Range header indicates the part of a document that the server should return.
      • getSharedLinkRendition

        @Headers(value = {Content-Type: application/json})@GET(value = alfresco/versions/1/shared-links/{sharedId}/renditions/{renditionId}) abstract RenditionEntry getSharedLinkRendition(@Path(value = sharedId) String sharedId, @Path(value = renditionId) String renditionId)

        Get shared link rendition information Note: this endpoint is available in Alfresco 5.2 and newer versions. Gets rendition information for the file with shared link identifier sharedId. This API method returns rendition information where the rendition status is CREATED, which means the rendition is available to view/download. Note: No authentication is required to call this endpoint. The endpoint is owned by defaultname service owner

        Parameters:
        sharedId - The identifier of a shared link to a file.
        renditionId - The name of a thumbnail rendition, for example doclib, or pdf.
      • getSharedLinkRenditionContent

        @Headers(value = {Content-Type: application/json})@GET(value = alfresco/versions/1/shared-links/{sharedId}/renditions/{renditionId}/content) abstract ResponseBody getSharedLinkRenditionContent(@Path(value = sharedId) String sharedId, @Path(value = renditionId) String renditionId, @Query(value = attachment) Boolean attachment, @Header(value = If-Modified-Since) ZonedDateTime ifModifiedSince, @Header(value = Range) String range)

        Get shared link rendition content Note: this endpoint is available in Alfresco 5.2 and newer versions. Gets the rendition content for file with shared link identifier sharedId. Note: No authentication is required to call this endpoint. The endpoint is owned by defaultname service owner

        Parameters:
        sharedId - The identifier of a shared link to a file.
        renditionId - The name of a thumbnail rendition, for example doclib, or pdf.
        attachment - true enables a web browser to download the file as an attachment.
        ifModifiedSince - Only returns the content if it has been modified since the date provided.
        range - The Range header indicates the part of a document that the server should return.
      • listSharedLinkRenditions

        @Headers(value = {Content-Type: application/json})@GET(value = alfresco/versions/1/shared-links/{sharedId}/renditions) abstract RenditionPaging listSharedLinkRenditions(@Path(value = sharedId) String sharedId)

        List renditions for a shared link Note: this endpoint is available in Alfresco 5.2 and newer versions. Gets a list of the rendition information for the file with shared link identifier sharedId. This API method returns rendition information, including the rendition id, for each rendition where the rendition status is CREATED, which means the rendition is available to view/download. Note: No authentication is required to call this endpoint. The endpoint is owned by defaultname service owner

        Parameters:
        sharedId - The identifier of a shared link to a file.
      • listSharedLinks

        @Headers(value = {Content-Type: application/json})@GET(value = alfresco/versions/1/shared-links) abstract SharedLinkPaging listSharedLinks(@Query(value = skipCount) Integer skipCount, @Query(value = maxItems) Integer maxItems, @Query(value = where) String where, @Query(value = include) List<String> include, @Query(value = fields) List<String> fields)

        List shared links Note: this endpoint is available in Alfresco 5.2 and newer versions. Get a list of links that the current user has read permission on source node. The list is ordered in descending modified order. Note: The list of links is eventually consistent so newly created shared links may not appear immediately. The endpoint is owned by defaultname service owner

        Parameters:
        skipCount - The number of entities that exist in the collection before those included in this list.
        maxItems - The maximum number of items to return in the list.
        where - Optionally filter the list by \&quot;sharedByUser\&quot; userid of person who shared the link (can also use -me-) * &#x60;&#x60;&#x60;where&#x3D;(sharedByUser&#x3D;&#39;jbloggs&#39;)&#x60;&#x60;&#x60; * &#x60;&#x60;&#x60;where&#x3D;(sharedByUser&#x3D;&#39;-me-&#39;)&#x60;&#x60;&#x60; (optional)
        include - Returns additional information about the shared link, the following optional fields can be requested: * allowableOperations * path * properties * isFavorite * aspectNames (optional)
        fields - A list of field names.