@@ -376,13 +376,17 @@ This section describes the main objects used for managing collaboration shares.
376376 alice_rcpt = core_types.Collaborator.local_user(alice).expire_in(30 ).read_only()
377377 engineers_rcpt = core_types.Collaborator.local_group(engineers).read_write()
378378
379+ # Share with a local user with read-only access, expiring in 30 days
380+ # Share with a local group with read-write access and the default expiration date
379381 user.files.share(' Codebase' , [alice_rcpt, engineers_rcpt])
380382
381383 .. code-block :: python
382384
385+ # Share with an external user with view-only access, expiring in 10 days
383386 jsmith = core_types.Collaborator.external(' jsmith@hotmail.com' ).expire_in(10 ).preview_only()
384387 user.files.share(' My Files/Projects/2020/ProjectX' , [jsmith])
385388
389+ # Share with an external user with read-only access, expiring in 5 days
386390 jsmith = core_types.Collaborator.external(' jsmith@hotmail.com' , True ).expire_in(5 ).read_only()
387391 user.files.share(' My Files/Projects/2020/ProjectX' , [jsmith])
388392
@@ -394,13 +398,21 @@ This section describes the main objects used for managing collaboration shares.
394398 albany_rcpt = core_types.Collaborator.domain_group(albany_group).read_write()
395399 cleveland_rcpt = core_types.Collaborator.domain_group(cleveland_group).read_only()
396400
401+ # Share with two domain groups, with the default expiration date
397402 user.files.share(' Cloud/Albany' , [albany_rcpt, cleveland_rcpt])
398403
404+ .. code-block :: python
405+
406+ # Share with an external user with upload-only access, expiring in 15 days
407+ jsmith = core_types.Collaborator.external(' jsmith@hotmail.com' ).expire_in(15 ).upload_only()
408+ user.files.share(' My Files/Projects/2020/ProjectX' , [jsmith])
409+
399410 .. automethod :: cterasdk.core.files.browser.CloudDrive.add_share_recipients
400411 :noindex:
401412
402413.. code-block :: python
403414
415+ # Add a read-write local group share recepient
404416 engineering = core_types.GroupAccount(' Engineering' )
405417 engineering_rcpt = core_types.Collaborator.local_group(engineering).read_write()
406418 user.files.add_share_recipients(' My Files/Projects/2020/ProjectX' , [engineering_rcpt])
@@ -410,6 +422,7 @@ This section describes the main objects used for managing collaboration shares.
410422
411423.. code-block :: python
412424
425+ # Remove a local user and group from a share
413426 alice = core_types.UserAccount(' alice' )
414427 engineering = core_types.GroupAccount(' Engineering' )
415428 user.files.remove_share_recipients(' My Files/Projects/2020/ProjectX' , [alice, engineering])
@@ -419,9 +432,7 @@ This section describes the main objects used for managing collaboration shares.
419432
420433.. code-block :: python
421434
422- user.files.unshare(' Codebase' )
423435 user.files.unshare(' My Files/Projects/2020/ProjectX' )
424- user.files.unshare(' Cloud/Albany' )
425436
426437 Managing S3 Credentials
427438-----------------------
0 commit comments