Dropbox API Invitar a un miembro a una carpeta compartida a través de jQuery en JavaScript


Ejemplo

$.ajax({
    url: 'https://api.dropboxapi.com/2/sharing/add_folder_member',
    type: 'POST',
    processData: false,
    data: JSON.stringify({"shared_folder_id": "84528192421","members": [{"member": {".tag": "email","email": "justin@example.com"},"access_level": {".tag": "editor"}},{"member": {".tag": "dropbox_id","dropbox_id": "dbid:AAEufNrMPSPe0dMQijRP0N_aZtBJRm26W4Q"},"access_level": {".tag": "viewer"}}],"quiet": false,"custom_message": "Documentation for launch day"}),
    contentType: 'application/json',
    headers: {
        "Authorization": "Bearer <ACCESS_TOKEN>"
    },
    success: function(data) {
        console.log(data);
    },
    error: function(data) {
        console.error(data);
    }
})

<ACCESS_TOKEN> debe reemplazarse con el token de acceso OAuth 2.