Need to see if your shared folder is taking up space on your dropbox 👨💻? Find out how to check here.
Forum Discussion
Saif Lajmi
2 years agoExplorer | Level 4
Upload and rendering Pdf files using dropbox into nextjs app
Hello , i need to know about how i can integrate dropbox api to my new nextjs app for dynamicly upload file throw my nextjs page into dropbox and rendreing this pdf file to the user in my app page .....
Greg-DB
Dropbox Community Moderator
2 years agoDropbox doesn't offer resources for Next.js in particular, but we do offer an API you can use for listing, uploading, and downloading files, among other operations, from any platform that can make HTTPS requests. You can find everything you need to get started with the Dropbox API, including documentation, tutorials, and SDKs here: https://www.dropbox.com/developers
And while I can't say if it would be suitable for your particular scenario, Dropbox does offer an official JavaScript SDK for accessing the Dropbox API here: https://github.com/dropbox/dropbox-sdk-js
- Saif Lajmi2 years agoExplorer | Level 4
thank you for the time but i need simple example how to implement this api of dropbox inside any app javascript and the feautre that i need to create this integration like accesToken and the library for render the file inside my web app because i use this code to render my dropbox file still give me the error of 500 internal server error :
import React from 'react';interface FileOptions {zoom?: "best" | "fit";}interface FolderOptions {view?: "list" | "grid";headerSize?: "normal" | "small";}interface EmbedOptions {link: string;file?: FileOptions;folder?: FolderOptions;}interface DropboxProps {options: EmbedOptions;}const DropboxEmbed: React.FC<DropboxProps> = ({ options }) => {const { link } = options;return (<iframesrc={link}width="600"height="400"frameBorder="0"allowFullScreentitle="Embedded Dropbox Content"/>);};// Example usageconst exampleOptions: EmbedOptions = {// Shared link to Dropbox filefile: {// Sets the zoom mode for embedded files. Defaults to 'best'.zoom: "best" // or "fit"},folder: {// Sets the view mode for embedded folders. Defaults to 'list'.view: "list", // or "grid"headerSize: "normal" // or "small"}};const Secure: React.FC = () => {return (<div><h1>Embedded Dropbox Content</h1><DropboxEmbed options={exampleOptions} /></div>);};export default Secure;- Здравко2 years agoLegendary | Level 20
Hi Saif Lajmi,
Dropbox Embedder is a prebuilt component, not just some name as you think as seems! Ensure usage of this component and don't "transform" it to inline frame. Dropbox links cannot be rendered in such a way.
Hope this gives some direction.
- Saif Lajmi2 years agoExplorer | Level 4
thank for your answer please can you explain to me the prebuilt Dropbox embeder because i dont find any documentation contain the embeder using typscript to allow the rendring of my dropbox file inside my nextjs app ?
About Dropbox API Support & Feedback
Find help with the Dropbox API from other developers.
The Dropbox Community team is active from Monday to Friday. We try to respond to you as soon as we can, usually within 2 hours.
If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X, Facebook or Instagram.
For more info on available support options for your Dropbox plan, see this article.
If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!