{"id":13908,"date":"2023-11-15T10:08:00","date_gmt":"2023-11-15T10:08:00","guid":{"rendered":"https:\/\/www.bay20.com\/?p=13908"},"modified":"2025-05-14T15:15:00","modified_gmt":"2025-05-14T09:30:00","slug":"so-greifen-sie-in-bigcommerce-auf-digitale-produkte-von-dropbox-zu","status":"publish","type":"post","link":"https:\/\/www.bay20.com\/de\/so-greifen-sie-in-bigcommerce-auf-digitale-produkte-von-dropbox-zu\/","title":{"rendered":"Schritt-f\u00fcr-Schritt-Anleitung zur Integration von Dropbox in BigCommerce f\u00fcr nahtlosen Zugriff auf digitale Produkte"},"content":{"rendered":"\n<p>Die Verwendung digitaler Produkte in Ihrem BigCommerce-Shop kann aufgrund der Beschr\u00e4nkungen von BigCommerce hinsichtlich der Dateigr\u00f6\u00dfen beim Hochladen eine Herausforderung darstellen.<\/p>\n\n\n\n<p>Als L\u00f6sung entscheiden sich Experten h\u00e4ufig daf\u00fcr, digitale Produktdateien auf Dropbox zu speichern und Dropbox mit BigCommerce zu integrieren.<\/p>\n\n\n\n<p>Zun\u00e4chst m\u00fcssen wir eine App in Dropbox erstellen, Berechtigungen erteilen, ein API-Token generieren und dann ein Skript hinzuf\u00fcgen, das die Datei abfragt und einen Link zum Herunterladen generiert.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Gehen Sie folgenderma\u00dfen vor, um eine App in Dropbox zu erstellen:<\/strong><\/h2>\n\n\n\n<p>Schritt 1: Gehen Sie zun\u00e4chst zu dropbox.com\/developers\/apps.<br>Schritt 2: Klicken Sie anschlie\u00dfend auf die Option App erstellen.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"980\" height=\"394\" src=\"https:\/\/www.bay20.com\/wp-content\/uploads\/2023\/09\/image-980x394.png\" alt=\"Create app in dropbox\" class=\"wp-image-13909\" srcset=\"https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-980x394.png 980w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-300x121.png 300w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-800x321.png 800w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-768x309.png 768w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1000x402.png 1000w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image.png 1272w\" sizes=\"auto, (max-width: 980px) 100vw, 980px\" \/><\/figure>\n\n\n\n<p>Schritt 3: W\u00e4hlen Sie dann eine API-Option und die Art des ben\u00f6tigten Zugriffs aus. Benennen Sie die App und klicken Sie abschlie\u00dfend auf die Schaltfl\u00e4che &#8222;App erstellen&#8220;.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"980\" height=\"734\" src=\"https:\/\/www.bay20.com\/wp-content\/uploads\/2023\/09\/image-1-980x734.png\" alt=\"permissions in dropbox app\" class=\"wp-image-13910\" srcset=\"https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1-980x734.png 980w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1-300x225.png 300w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1-800x599.png 800w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1-768x575.png 768w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1-1000x749.png 1000w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-1.png 1278w\" sizes=\"auto, (max-width: 980px) 100vw, 980px\" \/><\/figure>\n\n\n\n<p>Schritt 4: Geben Sie anschlie\u00dfend einige Berechtigungen an, z. B:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>files.metadata.read:- Informationen \u00fcber Ihre Dropbox-Dateien und -Ordner anzeigen.<\/li><li>sharing.write:- Anzeigen und Verwalten Ihrer Dropbox-Freigabeeinstellungen und Mitwirkenden.<\/li><\/ul>\n\n\n\n<p>Schritt 5: Generieren Sie dann das API-Token, indem Sie auf die Schaltfl\u00e4che \u201eGenerieren\u201c klicken, behalten Sie das API-Token und f\u00fcgen Sie es dem Skript hinzu.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"980\" height=\"531\" src=\"https:\/\/www.bay20.com\/wp-content\/uploads\/2023\/09\/image-2-980x531.png\" alt=\"Dropbox Generate access token\" class=\"wp-image-13911\" title=\"\" srcset=\"https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-2-980x531.png 980w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-2-300x162.png 300w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-2-800x433.png 800w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-2-768x416.png 768w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-2-1000x541.png 1000w, https:\/\/www.bay20.com\/de\/wp-content\/uploads\/2023\/09\/image-2.png 1280w\" sizes=\"auto, (max-width: 980px) 100vw, 980px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">Folgen Sie diesen Schritten, um das Skript zu implementieren und Bigcommerce Digital Products Links zu erhalten:<\/h2>\n\n\n\n<p>Schritt 1: Erstellen Sie zun\u00e4chst eine benutzerdefinierte js-Datei in Ihrem Thema.<\/p>\n\n\n\n<p>Schritt 2: Erstellen Sie dann ein Skript, das den Produktnamen abruft, einen Link zum Herunterladen generiert und das Skript so anpasst, dass der Link zum Herunterladen in das Produkt integriert wird. Stellen Sie au\u00dferdem sicher, dass der Link nach der Bestellbest\u00e4tigung w\u00e4hrend der Kaufabwicklung an den Kunden gesendet wird.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\nconst access_token = 'access_token';\n\nconst search_query = 'digitalproduct';\n\/\/ Set the API endpoints and headers\nconst search_url = 'https:\/\/api.dropboxapi.com\/2\/files\/search';\nconst sharing_url = 'https:\/\/api.dropboxapi.com\/2\/sharing\/list_shared_links';\n\nconst headers = {\n    'Authorization': `Bearer ${access_token}`,\n    'Content-Type': 'application\/json'\n};\n\n\nasync function getDownloadableLink(query) {\n  const search_data = {\n      \"query\": query,\n      \"path\": \"\",  \/\/ Specify the folder path where you want to search\n      \"start\": 0,\n      \"max_results\": 1 \/\/ Limit the results to 1 for the first match\n  };\n\n    \/\/ Perform the file search\n    const search_response = await fetch(search_url, {\n        method: 'POST',\n        headers: headers,\n        body: JSON.stringify(search_data)\n    });\n\n    try {\n        if (search_response.status === 200) {\n            const contentType = search_response.headers.get('content-type');\n            if (contentType &amp;&amp; contentType.includes('application\/json')) {\n                const search_response_data = await search_response.json();\n                const matches = search_response_data.matches || &#91;];\n\n                if (matches.length &gt; 0) {\n                    const metadata = matches&#91;0].metadata;\n                    const file_id = metadata.id;\n\n                    \/\/ Check if a shared link already exists for the file\n                    const sharing_list_response = await fetch(sharing_url, {\n                        method: 'POST',\n                        headers: headers,\n                        body: JSON.stringify({ \"path\": file_id })\n                    });\n\n                    const sharing_list_response_data = await sharing_list_response.json();\n                    const existingLinks = sharing_list_response_data.links || &#91;];\n\n                    if (existingLinks.length &gt; 0) {\n                        const existingLink = existingLinks&#91;0];\n                        return existingLink.url; \/\/ Return the existing link\n                    } else {\n                        \/\/ Create a shared link for the file\n                        const sharing_data = {\n                            \"path\": file_id\n                        };\n\n                        const sharing_response = await fetch(sharing_url, {\n                            method: 'POST',\n                            headers: headers,\n                            body: JSON.stringify(sharing_data)\n                        });\n\n                        if (sharing_response.status === 200) {\n                            const sharing_response_data = await sharing_response.json();\n                            if (sharing_response_data.url) {\n                                return sharing_response_data.url; \/\/ Return the new link\n                            }\n                        }\n                    }\n                }\n            }\n        }\n    } catch (error) {\n        console.error(\"Failed to process the response:\", error);\n    }\n\n    return null; \/\/ Return null if no link is found\n}\n\n\/\/ Call the function and get the downloadable link\ngetDownloadableLink()\n    .then((link) =&gt; {\n        if (link) {\n            console.log(\"Downloadable Link:\", link);\n        } else {\n            console.log(\"No link found.\");\n        }\n    });<\/code><\/pre>\n\n\n\n<p><strong>F\u00fcr jegliche Unterst\u00fctzung zu <a href=\"https:\/\/www.bay20.com\/de\/bigcommerce-entwicklungsunternehmen\/\">Bigcommerce<\/a> und um das vollst\u00e4ndige Skript zu erhalten, kontaktieren Sie uns bitte unter <a href=\"mailto:manish@bay20.com\">manish@bay20.com<\/a> oder WhatsApp unter <a href=\"https:\/\/api.whatsapp.com\/send?phone=+918800519180&amp;text=Hi,%20I%20contacted%20you%20through%20your%20website.\">+91-8800519180<\/a>.<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Utilizing digital products in your BigCommerce store can be challenging due to BigCommerce&#8217;s limitations on file upload sizes.<\/p>\n","protected":false},"author":90,"featured_media":13921,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[13,85,84],"tags":[],"class_list":["post-13908","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-bigcommerce","category-bigcommerce-stencil","category-bigcommerce-lehrgang"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/posts\/13908","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/users\/90"}],"replies":[{"embeddable":true,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/comments?post=13908"}],"version-history":[{"count":13,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/posts\/13908\/revisions"}],"predecessor-version":[{"id":17027,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/posts\/13908\/revisions\/17027"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/media\/13921"}],"wp:attachment":[{"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/media?parent=13908"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/categories?post=13908"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.bay20.com\/de\/wp-json\/wp\/v2\/tags?post=13908"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}