如何获取bucket文件的urn [英] how to get the urn of the bucket file

查看:25
本文介绍了如何获取bucket文件的urn的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请告诉我如何获取bucket文件的urn.您可以在上传到存储桶时获取响应中包含的 urn,但我想获取已上传到存储桶的文件的 urn.有什么办法吗?

Please tell me how to get the urn of the bucket file. You can get the urn that is included in the response when uploading to the bucket, but I'd like to obtain the urn of the file already uploaded to the bucket. Is there any way?

推荐答案

您可以使用 GET/buckets/:bucketKey/objects 端点以获取存储桶中所有文件的列表.在响应中,每个文件都有其 objectId(例如,urn:adsk.objects:os.object:mybucket/myfile).取 objectId 并将其编码为 base64,例如,使用 https://www.base64encode.组织.编码后的字符串是您的 URN.

You can use the GET /buckets/:bucketKey/objects endpoint to get a list of all files in your bucket. In the response, each file will have its objectId (for example, urn:adsk.objects:os.object:mybucket/myfile). Take the objectId and encode it in base64, for example, using https://www.base64encode.org. The encoded string is your URN.

这篇关于如何获取bucket文件的urn的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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