Need file ID to construct sharelinkURL
Hi,
My box folder is mounted as a volume on my unix terminal (macos high sierra). I am able to find certain files that match a certain pattern via a bash script (a find command). Now I want to extend the script to generate for each file that matches the pattern, its BOX sharelinkURL. I can't think of a way to do this and have looked at the documentation and cannot find a direct answer.
The stumbling block is obtaining the file ID, because once I have that, I can potentially construct the sharelinkURL myself.
Is there a way to get the box client (Box Drive) to tell me what the file ID is?
Is there a way to query the box.com api to tell me, given a file path, what that file's ID is?
Is there a way to query the box.com api to send me a dump of all my files with their IDs, and I can then hunt for the files that I want and get their IDs from that dump?
Many thanks,
str82ais
-
- Is there a way to get the box client (Box Drive) to tell me what the file ID is?
- No, but you can pluck the file id from the url on the Box Web UI
- Is there a way to query the box.com api to tell me, given a file path, what that file's ID is?
- Box works off of file and folder ids, so you'd probably need to use search https://developer.box.com/reference/get-search/ to query for the file
- Is there a way to query the box.com api to send me a dump of all my files with their IDs, and I can then hunt for the files that I want and get their IDs from that dump?
- This endpoint will give you a list of items at the root level https://developer.box.com/reference/get-folders-id-items/ .You could probably write a script to iterate through and print out all of the files in your root folder.
- Is there a way to get the box client (Box Drive) to tell me what the file ID is?
サインインしてコメントを残してください。
コメント
1件のコメント