iisnode encountered an error when processing the request.

HRESULT: 0x2
HTTP status: 500
HTTP subStatus: 1002
HTTP reason: Internal Server Error

You are receiving this HTTP 200 response because system.webServer/iisnode/@devErrorsEnabled configuration setting is 'true'.

In addition to the log of stdout and stderr of the node.exe process, consider using debugging and ETW traces to further diagnose the problem.

The last 64k of the output generated by the node.exe process to stderr is shown below:

Error getting the secret: invalid_client: 7000222 - [2025-12-30 00:28:54Z]: AADSTS7000222: The provided client secret keys for app '1a3f705e-321b-477c-a2a9-dd6e240f8c1e' are expired. Visit the Azure portal to create new keys for your app: https://aka.ms/NewClientSecret, or consider using certificate credentials for added security: https://aka.ms/certCreds. Trace ID: 4844be45-847e-4165-8164-e42205c8a200 Correlation ID: f8b5d69a-2c4f-419a-a32a-bf342841141d Timestamp: 2025-12-30 00:28:54Z - Correlation ID: f8b5d69a-2c4f-419a-a32a-bf342841141d - Trace ID: 4844be45-847e-4165-8164-e42205c8a200
(node:2508) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
Error getting the secret: invalid_client: 7000222 - [2025-12-30 00:28:54Z]: AADSTS7000222: The provided client secret keys for app '1a3f705e-321b-477c-a2a9-dd6e240f8c1e' are expired. Visit the Azure portal to create new keys for your app: https://aka.ms/NewClientSecret, or consider using certificate credentials for added security: https://aka.ms/certCreds. Trace ID: 28db7378-f9f4-418c-9f88-942df452ca00 Correlation ID: 2aa09cdb-076d-4c56-a9fb-8a81c4932a2f Timestamp: 2025-12-30 00:28:54Z - Correlation ID: 2aa09cdb-076d-4c56-a9fb-8a81c4932a2f - Trace ID: 28db7378-f9f4-418c-9f88-942df452ca00
Error getting the secret: invalid_client: 7000222 - [2025-12-30 00:28:54Z]: AADSTS7000222: The provided client secret keys for app '1a3f705e-321b-477c-a2a9-dd6e240f8c1e' are expired. Visit the Azure portal to create new keys for your app: https://aka.ms/NewClientSecret, or consider using certificate credentials for added security: https://aka.ms/certCreds. Trace ID: d8eb767b-44a6-4a52-b19b-0d274e27db00 Correlation ID: 199107e4-14cc-4f4d-a442-ccb0f01d90e3 Timestamp: 2025-12-30 00:28:54Z - Correlation ID: 199107e4-14cc-4f4d-a442-ccb0f01d90e3 - Trace ID: d8eb767b-44a6-4a52-b19b-0d274e27db00
Error getting the secret: invalid_client: 7000222 - [2025-12-30 00:28:55Z]: AADSTS7000222: The provided client secret keys for app '1a3f705e-321b-477c-a2a9-dd6e240f8c1e' are expired. Visit the Azure portal to create new keys for your app: https://aka.ms/NewClientSecret, or consider using certificate credentials for added security: https://aka.ms/certCreds. Trace ID: 2f2c93ff-6fb7-428c-9156-a17f4e31df00 Correlation ID: ad880bbb-929f-4ec1-89d2-a5bdbe2116a2 Timestamp: 2025-12-30 00:28:55Z - Correlation ID: ad880bbb-929f-4ec1-89d2-a5bdbe2116a2 - Trace ID: 2f2c93ff-6fb7-428c-9156-a17f4e31df00
Application has thrown an uncaught exception and is terminated:
TypeError: Cannot read properties of undefined (reading 'cosdb')
    at C:\stop_order_dev\server.js:25:30
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)