<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Business API Node in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348388#M20025</link>
    <description>&lt;P&gt;I researched for the past 2 days and I can't find any tutorial or examples on how to access, create folder, share those folders to other team using DropboxTeam in node. I subscribed for a 30 day trial Business account so I can do the project, is there any resource with examples or tutorials out there? Can you please give me a hand? The documentation is confusing without example param values and how it look when applied.&lt;/P&gt;
&lt;P&gt;What I have so far is to show the team info.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thank you for those who can help.&lt;/P&gt;</description>
    <pubDate>Tue, 16 Jul 2019 09:54:20 GMT</pubDate>
    <dc:creator>arjoriesotelo</dc:creator>
    <dc:date>2019-07-16T09:54:20Z</dc:date>
    <item>
      <title>Business API Node</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348388#M20025</link>
      <description>&lt;P&gt;I researched for the past 2 days and I can't find any tutorial or examples on how to access, create folder, share those folders to other team using DropboxTeam in node. I subscribed for a 30 day trial Business account so I can do the project, is there any resource with examples or tutorials out there? Can you please give me a hand? The documentation is confusing without example param values and how it look when applied.&lt;/P&gt;
&lt;P&gt;What I have so far is to show the team info.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Thank you for those who can help.&lt;/P&gt;</description>
      <pubDate>Tue, 16 Jul 2019 09:54:20 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348388#M20025</guid>
      <dc:creator>arjoriesotelo</dc:creator>
      <dc:date>2019-07-16T09:54:20Z</dc:date>
    </item>
    <item>
      <title>Re: Business API Node</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348513#M20031</link>
      <description>&lt;P&gt;If you're working in Node, we&amp;nbsp;recommend using the official&amp;nbsp;Dropbox API v2 JavaScript SDK:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/dropbox/dropbox-sdk-js" target="_blank"&gt;https://github.com/dropbox/dropbox-sdk-js&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;There's some example code here:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/dropbox/dropbox-sdk-js/tree/master/examples/javascript" target="_blank"&gt;https://github.com/dropbox/dropbox-sdk-js/tree/master/examples/javascript&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;That includes some written specifically for Node here:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://github.com/dropbox/dropbox-sdk-js/tree/master/examples/javascript/node" target="_blank"&gt;https://github.com/dropbox/dropbox-sdk-js/tree/master/examples/javascript/node&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;If you want to use the&amp;nbsp;Dropbox Business API to connect to entire teams and also access the files and folders in the connected teams, you'll need to use the "team member file access" permission/feature:&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.dropbox.com/developers/documentation/http/teams#teams-member-file-access" target="_blank"&gt;https://www.dropbox.com/developers/documentation/http/teams#teams-member-file-access&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;For instance, that would look like:&lt;/P&gt;
&lt;PRE&gt;const myFetch = require('isomorphic-fetch');
const DropboxTeam = require('dropbox').DropboxTeam;

const ACCESSTOKEN = '&amp;lt;TEAM_MEMBER_FILES_ACCESS_ACCESS_TOKEN&amp;gt;'
const dbx = new DropboxTeam({accessToken: ACCESSTOKEN, fetch: myFetch});

var memberId = "&amp;lt;MEMBER_ID&amp;gt;"; // e.g., from `teamMembersList`/`teamMembersListContinue`
var dbxUser = dbx.actAsUser(memberId);

// start listing root:
dbxUser.filesListFolder({path: ""})
  .then(function(response) {
    console.log(response);
  })
  .catch(function(error) {
    console.log(error);
  });

// create a new shared folder:
var folderPath = "/test_348388";
dbxUser.sharingShareFolder({path: folderPath})
  .then(function(response) {
    console.log(response);
  })
  .catch(function(error) {
    console.log(error);
  });
&lt;/PRE&gt;
&lt;P&gt;Hope this helps!&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 06 Jun 2019 15:49:56 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348513#M20031</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2019-06-06T15:49:56Z</dc:date>
    </item>
    <item>
      <title>Re: Business API Node</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348673#M20033</link>
      <description>&lt;P&gt;Thank you @Greg!&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What I did&lt;/STRONG&gt; :&lt;span class="lia-inline-image-display-wrapper lia-image-align-left" image-alt="my folder.png" style="width: 200px;"&gt;&lt;img src="https://www.dropboxforum.com/t5/image/serverpage/image-id/9843iD4E6C03E9BEEDECB/image-size/small?v=v2&amp;amp;px=200" role="button" title="my folder.png" alt="my folder.png" /&gt;&lt;/span&gt;&lt;SPAN&gt;Correct me if I'm wrong, I created a Team Folder using Admin Console. Now I can see my personal dropbox in Purple with additional folders that are auto generated by your system. Which means I successfully created a team folder, in my case its name is Sapphire. Using the Dropbox JS API, I am able to list groups, list members, get Info but I can't create another folder.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What I understand&lt;/STRONG&gt;:&lt;/P&gt;&lt;P&gt;To be able to create folders and add files to folders, I need to use a member id and act as a member to be able to do these.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What I want to do&lt;/STRONG&gt;:&lt;/P&gt;&lt;P&gt;create a folder for the team, share it to a specific member so he/she can sync it to his/her computer all the files I will put on it, but the member will be restricted to add files into it, edit, delete but can download it or sync to the computer. Using the Node Business API.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Jun 2019 01:08:14 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348673#M20033</guid>
      <dc:creator>arjoriesotelo</dc:creator>
      <dc:date>2019-06-07T01:08:14Z</dc:date>
    </item>
    <item>
      <title>Re: Business API Node</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348768#M20035</link>
      <description>&lt;P&gt;From your screenshot, I see that you are a member of a Business team named "Sapphire" using &lt;A href="https://help.dropbox.com/business/team-space-overview" target="_self"&gt;the "team space" configuration&lt;/A&gt; and you're looking at the file/folder listing for your team's team space.&lt;/P&gt;
&lt;P&gt;In that team space, you have your own private member folder, as well as a number of team folders with varying levels of access control set on them.&lt;/P&gt;
&lt;P&gt;I&amp;nbsp;recommend reviewing&amp;nbsp;&lt;A href="https://www.dropbox.com/developers/reference/namespace-guide" target="_self"&gt;the Namespace Guide&lt;/A&gt; and &lt;A href="https://www.dropbox.com/developers/reference/content-access-guide" target="_self"&gt;Content Access Guide&lt;/A&gt; as they have go into more detail on how to manage these.&lt;/P&gt;
&lt;P&gt;For example, to create a new folder in the team space, you would use &lt;A href="https://dropbox.github.io/dropbox-sdk-js/Dropbox.html#Dropbox__anchor" target="_self"&gt;the 'pathRoot' option&lt;/A&gt; to set the path root to the team space, and then use &lt;A href="https://dropbox.github.io/dropbox-sdk-js/Dropbox.html#filesCreateFolder__anchor" target="_self"&gt;the&amp;nbsp;filesCreateFolder method&lt;/A&gt; to make the new folder. That would look like this:&lt;/P&gt;
&lt;PRE&gt;// get a client for a specific member, defaulting to the member folder
const dbxUser = new Dropbox({accessToken: ACCESSTOKEN, fetch: myFetch, selectUser: memberId});
dbxUser.usersGetCurrentAccount()
  .then(function(response) {

    // figure out the root
    rootNamespaceID = response.root_info.root_namespace_id;
    var teamSpaceRoot = JSON.stringify({".tag": "root", "root": rootNamespaceID});

    // get a client for a specific member, setting the root to the team space
    const dbxUserWithRoot = new Dropbox({accessToken: ACCESSTOKEN, fetch: myFetch, selectUser: memberId, pathRoot: teamSpaceRoot});

    // create a new folder:
    var folderPath = "/test_348388";
    dbxUserWithRoot.filesCreateFolder({path: folderPath})
      .then(function(response) {
        console.log(response);
      })
      .catch(function(error) {
        console.log(error);
      });

  })
  .catch(function(error) {
    console.log(error);
  });&lt;/PRE&gt;
&lt;P&gt;Note that all members of the team automatically have access to the new folder, since it's in the team space. You can change that though, like this:&lt;/P&gt;
&lt;PRE&gt;var folderPath = "/test_348388";
var sharedFolderId = null;
dbxUserWithRoot.filesGetMetadata({path: folderPath})
  .then(function(response) {
    console.log(response);
    sharedFolderId = response.shared_folder_id;

    dbxUserWithRoot.sharingSetAccessInheritance({shared_folder_id: sharedFolderId, access_inheritance: 'no_inherit'})
      .then(function(response) {
        console.log(response);
      })
      .catch(function(error) {
        console.log(error);
      });

  })
  .catch(function(error) {
    console.log(error);
  });&lt;/PRE&gt;
&lt;P&gt;And then you can add specific members with whatever access level you want, using&amp;nbsp;&lt;A href="https://dropbox.github.io/dropbox-sdk-js/Dropbox.html#sharingAddFolderMember__anchor" target="_self"&gt;sharingAddFolderMember&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Fri, 07 Jun 2019 15:31:21 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Business-API-Node/m-p/348768#M20035</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2019-06-07T15:31:21Z</dc:date>
    </item>
  </channel>
</rss>

