Python chron job as Azure Function to delete entries in Azure Storage and Azure Cosmos DB -- 2

Job ID: 32625416

Budget: €30 – €250 EUR

A chron job should be done as a Azure Function in Python 3.7.

The chron job should do:
A) In an Azure Storage (Storage (general purpose v1) in a certain folder all files which are older than x days shall be deleted. Empty folders should be deleted, too. A log should be written to the storage which files and directories were deleted.
B) In an Azure Cosmos DB in a certain table all entries should be deleted when the "id" is smaller than a certain date/time given as yyyy-mm-dd_hh-mm-ss with a prefix "m", e.g.: "m2021-01-18_23-34-06" and the partition key has a certain value (e.g. partition key is "devicename" and the value has to be "Dev001").

Access to an empty test Azure DB and an empty test Azure Storage can be given during development process.

Task
1) Develop a chron job with the above features A) and B). The settings login for Azure Storage and Azure Cosmos DB should be variables which can be changed easily. As well the name of the table, the name of the partition key, the date/time, the value of the partition key (Azure Cosmos DB) and the root directory (Azure Storage).
2) Explain how to set up the chron job in Azure portal

Payment is only done when the whole task is fulfilled and working. Source code has to be delivered.
Related categories: Python Azure Microsoft Azure