Troubleshot the issue offline and found that 500 error was coming from function app as there was Null exception with the one of the parameter communicating to the storage account. Review the code and provided a suggestion to fix it.
Please 'Accept as answer' if it helped so that it can help others in the community looking for help on similar topics.