Skip to main content
Question

Pushing Temp Download URL to View API

  • May 21, 2025
  • 4 replies
  • 45 views

Forum|alt.badge.img

Hi all,

 

I am building a web app integration that receives a temporary download file and would then like to push this link through to the View API.

 

Based on some of the Box API documentation, when working with the Content and View API together, I should be able to execute the following code to accomplish the above task: 

 

curl https://view-api.box.com/1/documents \
-H "Authorization: Token YOUR_API_KEY" \
-H "Content-type: application/json" \
-d '{"url": "https://dl.boxcloud.com/*"}' \
-X POST

 

However, I am receiving an error of {"message": "Invalid token", "type": "error"}.

I am using the API token found at the bottom of the page on the Application page. 

 

  • Is the View API no longer reachable from the Content API?
  • Does Content API have an equivalent to the View API functionality?

 

Thank you!

 

4 replies

Forum|alt.badge.img

Hi  - 

 

Thank you for your interest in Box View API! We are developing our upgraded version of this content preview service. Because we don't want our customers to migrate just after creating a new app, we have shut down the ability to create new apps with View API (Existing apps should work as-is).

In the interim, our Content API does have the ability to use similar technology to generate document viewing sessions. Please see the documentation on our website here: https://box-content.readme.io/reference#get-embed-link


Forum|alt.badge.img

Thanks  so much for your response!

 

Once I have the temporary embed link, what should I do to allow users to automatically begin viewing the file?

 

Thank you!


Forum|alt.badge.img

Once you have the embed link, you can view the content by opening the link in an iFrame.


Forum|alt.badge.img

Is there any way that we can return the embedded link (in some form) to Box from our web app (via callbacks?) such that it causes the page to redirect to the provided link?  

 

Thank you!