Favorite to latest month auto-upload

Dear Community,

I cannot find the right search string to help me do what I want.

I am running the latest nextcloud production version.

I currently have NC android auto-upload and delete photo and video to NC server using external folder /samsung and have subfolder for year month enabled.

I have set /samsung as favorite with the star so it apears on top. now you guess is right I would like a direct link to the latest month in my root.

I would like this to be automated.

any hints on how to accomplish this.

During my search to a solution I found this in the developers manual Basic APIs — Nextcloud latest Developer Manual latest documentation

particularly https://docs.nextcloud.com/server/latest/developer_manual/client_apis/WebDAV/basic.html?highlight=api#settings-favorites

this made me create 2 files fav0 and fav1

example fav0

<?xml version="1.0" ?>
 <d:propertyupdate xmlns:d="DAV:" xmlns:oc="http://owncloud.org/ns" xmlns:nc="http://nextcloud.org/ns">

fav1 contains a 1 where there is a 0 up in oc:favorite

I am currently still testing but this is working for me
set variables


then use curl

curl ${url} -u $UP --request PROPPATCH --data “$(cat fav0)”