用于下载文档的 Alfresco REST API [英] Alfresco REST API for downloading document

查看:44
本文介绍了用于下载文档的 Alfresco REST API的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用 Afresco REST API 下载文档.经过一番研究,我发现了这个 REST API:

I want to use the Afresco REST API to download a document. After some research I find out this REST API:

/alfresco/s/api/node/content{property}/{store_type}/{store_id}/{id}

但是我不确定如何传递参数.

But I am not sure how to pass the parameters.

如果我在 Share 中的文档详细信息 URL 是:

If my document details URL in Share is :

http://127.0.0.1:8080/share/page/context/mine/document-details?nodeRef=workspace://SpacesStore/7f77488a-60a0-48c3-9369-77183ccad0d2 

{property}{store_type}{store_id}{id} 中应该传递什么>?

What should be passed in {property}, {store_type}, {store_id} and {id}?

推荐答案

对于这个 NodeRef

For this NodeRef

workspace://SpacesStore/7f77488a-60a0-48c3-9369-77183ccad0d2

参数的值将是:

{property}: content
{store_type}: Workspace
{store_id}: spaceStore
{id}: 7f77488a-60a0-48c3-9369-77183ccad0d2 

Krutik 已经指定了与每个参数相关的详细信息.

Details related to each parameter is already specified by Krutik.

你应该使用这个下载网址.

And you should use this download url.

/alfresco/d/<d|a>/<workspace>/<store>/<nodeId>/<filename>

其中 d=directa=attached.

attachdirect 元素用于指示是直接在浏览器中显示流还是将其作为文件附件下载.

The attach or direct element is used to indicate whether to display the stream directly in the browser or download it as a file attachment.

这篇关于用于下载文档的 Alfresco REST API的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆