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 - [2026-02-25 02:44: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: 0ee8b9e0-fdf2-4897-be3c-53c8b6863600 Correlation ID: 594ef8c9-e088-4470-bc1d-f3b19c043da0 Timestamp: 2026-02-25 02:44:55Z - Correlation ID: 594ef8c9-e088-4470-bc1d-f3b19c043da0 - Trace ID: 0ee8b9e0-fdf2-4897-be3c-53c8b6863600
(node:5200) [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 - [2026-02-25 02:44: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: b3594cb6-8384-414a-9595-7ff687354800 Correlation ID: ffa3243d-b200-44dd-8874-6f2b3676d217 Timestamp: 2026-02-25 02:44:55Z - Correlation ID: ffa3243d-b200-44dd-8874-6f2b3676d217 - Trace ID: b3594cb6-8384-414a-9595-7ff687354800
Error getting the secret: invalid_client: 7000222 - [2026-02-25 02:44:56Z]: 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: 8e356169-9db2-445e-89cc-129cbc6d8400 Correlation ID: bb10f149-4d78-4486-956a-e2771d0ffb14 Timestamp: 2026-02-25 02:44:56Z - Correlation ID: bb10f149-4d78-4486-956a-e2771d0ffb14 - Trace ID: 8e356169-9db2-445e-89cc-129cbc6d8400
Error getting the secret: invalid_client: 7000222 - [2026-02-25 02:44:56Z]: 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: af1b743c-b012-46a9-a836-faef3d7e4c00 Correlation ID: a3b2ae57-f624-4be1-a1da-e3bf5d99ea57 Timestamp: 2026-02-25 02:44:56Z - Correlation ID: a3b2ae57-f624-4be1-a1da-e3bf5d99ea57 - Trace ID: af1b743c-b012-46a9-a836-faef3d7e4c00
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)