mirror of
https://github.com/narrrl/proton-sdk-rs.git
synced 2026-11-03 16:41:26 +01:00
get_public_link recovers the custom password along with the URL fragment, so a caller can keep it while update_public_link changes the role or the expiry. Debug for PublicLink and Bookmark redacts the URL and the custom password.
3.6 KiB
3.6 KiB
Changelog
Notable changes to proton-sdk and proton-drive-rs. The format follows
Keep a Changelog; versions follow semver,
and both crates are released together under the workspace version. Upstream
commits a change ports are recorded in UPSTREAM_SYNC.md.
This file starts after 0.9.2; earlier changes are in the git history.
[Unreleased]
Added
- Server-side copy.
ProtonDriveClient::copy_node(uid, new_parent, name)copies a file, or a folder with everything in it, without downloading and uploading it. The copy may get a new name and may land on another volume; the returned uid is on the target volume. Ported from the TypeScript SDK (copyNode). - Folder size.
ProtonDriveClient::get_folder_size(uid)returns aFolderSizewith the total size and the number of descendants, trashed nodes included. Folders count as descendants, and the size is in encrypted bytes. Ported from the TypeScript SDK (getFolderSize). - Changing a public link.
ProtonDriveClient::update_public_link(uid, role, custom_password, expiration_time)sets the role, the custom password and the expiry of the link on a node. The URL does not change.Noneremoves a custom password or an expiry. A legacy link cannot be updated. Ported from the TypeScript SDK (updateSharedLink). - A public link's custom password.
PublicLink::custom_passwordholds the custom password of a link, recovered from the stored link password, so a caller can keep it whileupdate_public_linkchanges the role or the expiry. - Walking a public link.
ProtonDrivePublicLinkClient::enumerate_subtreeandenumerate_subtree_reportingreturn every node below a shared folder, breadth first, listing several folders of a level at once. - Bookmark names.
list_bookmarksnow decrypts the bookmarked item's name intoBookmark::node_name, and returns the link's custom password in the newBookmark::custom_passwordfield. - Album capabilities from the C# SDK (
a36cc423):ProtonPhotosClient::set_album_cover;ProtonPhotosClient::delete_album_saving_photos, which onAlbumContainsPhotosNotInTimeline(code 200302) saves the photos that are only in the album to the timeline and deletes the album again;add_photos_to_albumadds photos from another volume by copying them in, instead of refusing them;- a photo group the server reports as incomplete is retried once with the missing related photos.
ResponseCode::AlbumContainsPhotosNotInTimeline.ApiHttpClient::post_query, a POST that only reads and may be sent again.
Changed
- A read is sent again when its connection drops. A GET, a block download or
a
post_querythat loses its connection mid-request or while reading the body is retried under the client's retry policy. A write still is not: it may have been applied. Read-only POSTs inproton-drive-rs(link details, thumbnails, photo duplicates,checkAvailableHashes) now usepost_query. DebugforPublicLinkandBookmarkno longer prints the URL or the custom password; it shows<redacted>instead.remove_photos_from_albumrefuses a photo on another volume per photo, in the input order, without sending it.
Fixed
- A bookmark's URL fragment is now only the generated password, as in the URL the web client shows. It used to include the custom password as well.
Breaking
BookmarkandPublicLinkhave a new public field,custom_password. Code that builds either with a struct literal must set it.ResponseCodehas a new variant. An exhaustivematchon it needs an arm.