members/add
POST https://api.dropboxapi.com/2/team/members/add
scope: members.write
Adds members to a team. Permission : Team member management A maximum of 20 members can be specified in a single call. If no Dropbox account exists with the email address specified, a new Dropbox account will be created with the given email address, and that account will be invited to the team. If a personal Dropbox account exists with the email address specified in the call, this call will create a placeholder Dropbox account for the user on the team and send an email inviting the user to migrate their existing personal account onto the team. Team member management apps are required to set an initial given_name and surname for a user to use in the team invitation and for 'Perform as team member' actions taken on the user before they become 'active'.
Request Body
{"new_members"=>[{"member_email"=>"tom.s@company.com", "member_given_name"=>"Tom", "member_surname"=>"Silverstone", "member_external_id"=>"company_id:342432", "send_welcome_email"=>true, "role"=>"member_only"}], "force_async"=>false}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string |
RESPONSES
status: OK
{".tag":"complete","complete":[{".tag":"success","profile":{"team_member_id":"dbmid:FDFSVF-DFSDF","email":"tami@seagull.com","email_verified":false,"status":{".tag":"active"},"name":{"given_name":"Franz","surname":"Ferdinand","familiar_name":"Franz","display_name":"Franz Ferdinand (Personal)","abbreviated_name":"FF"},"membership_type":{".tag":"full"},"groups":["g:e2db7665347abcd600000000001a2b3c"],"member_folder_id":"20","external_id":"244423","account_id":"dbid:AAH4f99T0taONIb-OurWxbNQ6ywGRopQngc","secondary_emails":[{"email":"grape@strawberry.com","is_verified":false},{"email":"apple@orange.com","is_verified":true}],"joined_on":"2015-05-12T15:50:38Z","profile_photo_url":"https://dl-web.dropbox.com/account_photo/get/dbaphid%3AAAHWGmIXV3sUuOmBfTz0wPsiqHUpBWvv3ZA?vers=1556069330102\u0026size=128x128"},"role":{".tag":"member_only"}}]}