ddvk / rmfakecloud

host your own cloud for the remarkable
GNU Affero General Public License v3.0
788 stars 68 forks source link

New routes for v3.10 compatibility #297

Closed nemunaire closed 8 months ago

nemunaire commented 8 months ago

In order to see the archive function to work, we need to implement the /sync/v3/check-files route.

Here is the input:

{
    "filename": "a7be6e0ea961-453b-5d54-b76e-b939beb9",
    "files": [
        "a7be6e0ea9618b3421b3131f1453b3f6e8453b5b01453bdccc7bf123b4bebeb9",
        "84eae55a21242bc1b8da64209161ed97ea2927a24ec434732d363453ab3ad9d4",
        "3d4b122055d556f2cd0e936e4dd264817e17196cb828e886cc7ae6d298268b45",
        "ebaef2a30e1d43068726d14c31b4ce763585c1f942be7cd2f8843d55f99fe6f8",
        "ba023d47bd42294fd3f64869507a96cea932b8157d14f1c315c84bba87d6e9a4"
    ],
    "reason": "Archive"
}

I also see a reason "Logout" when we try to unpair the device from cloud.

The current implementation doesn't return anything and it works. (As we didn't delete any file, the archived file can be retrieved as always.)

nemunaire commented 8 months ago

There is another route GET /sync/v3/missing returning {"hashes":[]}.

The route POST /sync/v3/check-files returns {"missingFiles":[]} filled with eventual missing blob id.