codeflash-internal/js/cf-api/instrument.ts

91 lines
2.6 KiB
TypeScript
Raw Normal View History

import * as Sentry from "@sentry/node"
fix sentry & inline suggestions (#1546) ### **PR Type** Enhancement ___ ### **Description** - Introduce Sentry test endpoint for error capture - Integrate Sentry profiling into instrumentation - Update package dependencies for Sentry enhancements - Simplify optimization endpoints routing ___ ### **Changes walkthrough** 📝 <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table> <tr> <td> <details> <summary><strong>sentry-test.ts</strong><dd><code>New Sentry test error endpoint added</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/endpoints/sentry-test.ts <li>Added a new endpoint that triggers a test error<br> <li> Captures and logs the error via Sentry </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-a1734472696f2996ba47e868f2d5bf56fa74c8010195afe7731898e6dd7325b9">+15/-0</a>&nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>index.ts</strong><dd><code>Integrated Sentry test router and endpoint adjustments</code>&nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/index.ts <li>Imported and applied the new Sentry test router<br> <li> Refined optimization endpoints list </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-c3e60be1461b6e80f9181080342927fd9df095197e8784ae0ff51daaec8d71d5">+3/-5</a>&nbsp; &nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>instrument.ts</strong><dd><code>Improved Sentry instrumentation configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/instrument.ts <li>Enabled Sentry profiling integration<br> <li> Updated sampling rates and cleaned commentary </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-8f041330c6187cfe1b7aaa4598b1a8522d25226f0fe79c30ededa0c3bf95fa8a">+11/-9</a>&nbsp; &nbsp; </td> </tr> </table></td></tr><tr><td><strong>Dependencies</strong></td><td><table> <tr> <td> <details> <summary><strong>package.json</strong><dd><code>Updated package dependencies for Sentry improvements</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/package.json <li>Upgraded Sentry related packages to version 9<br> <li> Added OpenTelemetry packages for tracing integration </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-53ddfb1f8a02f1231d3d15a2e694ffe1407d2cc01d3e685de5653b67fec571c7">+5/-2</a>&nbsp; &nbsp; &nbsp; </td> </tr> </table></td></tr></tr></tbody></table> ___ > <details> <summary> Need help?</summary><li>Type <code>/help how to ...</code> in the comments thread for any questions about PR-Agent usage.</li><li>Check out the <a href="https://qodo-merge-docs.qodo.ai/usage-guide/">documentation</a> for more information.</li></details>
2025-04-02 01:19:57 +00:00
import { nodeProfilingIntegration } from "@sentry/profiling-node"
import { prismaIntegration } from "@sentry/node"
2025-06-05 21:00:31 +00:00
const isProduction = process.env.NODE_ENV === "production"
const environment = process.env.AZURE_ENVIRONMENT || process.env.NODE_ENV || "development"
Sentry.init({
2025-06-05 21:00:31 +00:00
dsn: isProduction
? "https://7a83ac92f85c298f31bae97b97cabfe2@o4506833230561280.ingest.sentry.io/4506833372643328"
: undefined,
environment,
fix sentry & inline suggestions (#1546) ### **PR Type** Enhancement ___ ### **Description** - Introduce Sentry test endpoint for error capture - Integrate Sentry profiling into instrumentation - Update package dependencies for Sentry enhancements - Simplify optimization endpoints routing ___ ### **Changes walkthrough** 📝 <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table> <tr> <td> <details> <summary><strong>sentry-test.ts</strong><dd><code>New Sentry test error endpoint added</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/endpoints/sentry-test.ts <li>Added a new endpoint that triggers a test error<br> <li> Captures and logs the error via Sentry </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-a1734472696f2996ba47e868f2d5bf56fa74c8010195afe7731898e6dd7325b9">+15/-0</a>&nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>index.ts</strong><dd><code>Integrated Sentry test router and endpoint adjustments</code>&nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/index.ts <li>Imported and applied the new Sentry test router<br> <li> Refined optimization endpoints list </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-c3e60be1461b6e80f9181080342927fd9df095197e8784ae0ff51daaec8d71d5">+3/-5</a>&nbsp; &nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>instrument.ts</strong><dd><code>Improved Sentry instrumentation configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/instrument.ts <li>Enabled Sentry profiling integration<br> <li> Updated sampling rates and cleaned commentary </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-8f041330c6187cfe1b7aaa4598b1a8522d25226f0fe79c30ededa0c3bf95fa8a">+11/-9</a>&nbsp; &nbsp; </td> </tr> </table></td></tr><tr><td><strong>Dependencies</strong></td><td><table> <tr> <td> <details> <summary><strong>package.json</strong><dd><code>Updated package dependencies for Sentry improvements</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/package.json <li>Upgraded Sentry related packages to version 9<br> <li> Added OpenTelemetry packages for tracing integration </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-53ddfb1f8a02f1231d3d15a2e694ffe1407d2cc01d3e685de5653b67fec571c7">+5/-2</a>&nbsp; &nbsp; &nbsp; </td> </tr> </table></td></tr></tr></tbody></table> ___ > <details> <summary> Need help?</summary><li>Type <code>/help how to ...</code> in the comments thread for any questions about PR-Agent usage.</li><li>Check out the <a href="https://qodo-merge-docs.qodo.ai/usage-guide/">documentation</a> for more information.</li></details>
2025-04-02 01:19:57 +00:00
integrations: [
nodeProfilingIntegration(),
prismaIntegration(), // Better database error tracking
fix sentry & inline suggestions (#1546) ### **PR Type** Enhancement ___ ### **Description** - Introduce Sentry test endpoint for error capture - Integrate Sentry profiling into instrumentation - Update package dependencies for Sentry enhancements - Simplify optimization endpoints routing ___ ### **Changes walkthrough** 📝 <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table> <tr> <td> <details> <summary><strong>sentry-test.ts</strong><dd><code>New Sentry test error endpoint added</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/endpoints/sentry-test.ts <li>Added a new endpoint that triggers a test error<br> <li> Captures and logs the error via Sentry </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-a1734472696f2996ba47e868f2d5bf56fa74c8010195afe7731898e6dd7325b9">+15/-0</a>&nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>index.ts</strong><dd><code>Integrated Sentry test router and endpoint adjustments</code>&nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/index.ts <li>Imported and applied the new Sentry test router<br> <li> Refined optimization endpoints list </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-c3e60be1461b6e80f9181080342927fd9df095197e8784ae0ff51daaec8d71d5">+3/-5</a>&nbsp; &nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>instrument.ts</strong><dd><code>Improved Sentry instrumentation configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/instrument.ts <li>Enabled Sentry profiling integration<br> <li> Updated sampling rates and cleaned commentary </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-8f041330c6187cfe1b7aaa4598b1a8522d25226f0fe79c30ededa0c3bf95fa8a">+11/-9</a>&nbsp; &nbsp; </td> </tr> </table></td></tr><tr><td><strong>Dependencies</strong></td><td><table> <tr> <td> <details> <summary><strong>package.json</strong><dd><code>Updated package dependencies for Sentry improvements</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/package.json <li>Upgraded Sentry related packages to version 9<br> <li> Added OpenTelemetry packages for tracing integration </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-53ddfb1f8a02f1231d3d15a2e694ffe1407d2cc01d3e685de5653b67fec571c7">+5/-2</a>&nbsp; &nbsp; &nbsp; </td> </tr> </table></td></tr></tr></tbody></table> ___ > <details> <summary> Need help?</summary><li>Type <code>/help how to ...</code> in the comments thread for any questions about PR-Agent usage.</li><li>Check out the <a href="https://qodo-merge-docs.qodo.ai/usage-guide/">documentation</a> for more information.</li></details>
2025-04-02 01:19:57 +00:00
],
fix sentry & inline suggestions (#1546) ### **PR Type** Enhancement ___ ### **Description** - Introduce Sentry test endpoint for error capture - Integrate Sentry profiling into instrumentation - Update package dependencies for Sentry enhancements - Simplify optimization endpoints routing ___ ### **Changes walkthrough** 📝 <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table> <tr> <td> <details> <summary><strong>sentry-test.ts</strong><dd><code>New Sentry test error endpoint added</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/endpoints/sentry-test.ts <li>Added a new endpoint that triggers a test error<br> <li> Captures and logs the error via Sentry </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-a1734472696f2996ba47e868f2d5bf56fa74c8010195afe7731898e6dd7325b9">+15/-0</a>&nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>index.ts</strong><dd><code>Integrated Sentry test router and endpoint adjustments</code>&nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/index.ts <li>Imported and applied the new Sentry test router<br> <li> Refined optimization endpoints list </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-c3e60be1461b6e80f9181080342927fd9df095197e8784ae0ff51daaec8d71d5">+3/-5</a>&nbsp; &nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>instrument.ts</strong><dd><code>Improved Sentry instrumentation configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/instrument.ts <li>Enabled Sentry profiling integration<br> <li> Updated sampling rates and cleaned commentary </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-8f041330c6187cfe1b7aaa4598b1a8522d25226f0fe79c30ededa0c3bf95fa8a">+11/-9</a>&nbsp; &nbsp; </td> </tr> </table></td></tr><tr><td><strong>Dependencies</strong></td><td><table> <tr> <td> <details> <summary><strong>package.json</strong><dd><code>Updated package dependencies for Sentry improvements</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/package.json <li>Upgraded Sentry related packages to version 9<br> <li> Added OpenTelemetry packages for tracing integration </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-53ddfb1f8a02f1231d3d15a2e694ffe1407d2cc01d3e685de5653b67fec571c7">+5/-2</a>&nbsp; &nbsp; &nbsp; </td> </tr> </table></td></tr></tr></tbody></table> ___ > <details> <summary> Need help?</summary><li>Type <code>/help how to ...</code> in the comments thread for any questions about PR-Agent usage.</li><li>Check out the <a href="https://qodo-merge-docs.qodo.ai/usage-guide/">documentation</a> for more information.</li></details>
2025-04-02 01:19:57 +00:00
// Performance Monitoring sampling rate
// In production, sample 20% of transactions to reduce noise
tracesSampleRate: isProduction ? 0.2 : 1.0,
fix sentry & inline suggestions (#1546) ### **PR Type** Enhancement ___ ### **Description** - Introduce Sentry test endpoint for error capture - Integrate Sentry profiling into instrumentation - Update package dependencies for Sentry enhancements - Simplify optimization endpoints routing ___ ### **Changes walkthrough** 📝 <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table> <tr> <td> <details> <summary><strong>sentry-test.ts</strong><dd><code>New Sentry test error endpoint added</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/endpoints/sentry-test.ts <li>Added a new endpoint that triggers a test error<br> <li> Captures and logs the error via Sentry </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-a1734472696f2996ba47e868f2d5bf56fa74c8010195afe7731898e6dd7325b9">+15/-0</a>&nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>index.ts</strong><dd><code>Integrated Sentry test router and endpoint adjustments</code>&nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/index.ts <li>Imported and applied the new Sentry test router<br> <li> Refined optimization endpoints list </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-c3e60be1461b6e80f9181080342927fd9df095197e8784ae0ff51daaec8d71d5">+3/-5</a>&nbsp; &nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>instrument.ts</strong><dd><code>Improved Sentry instrumentation configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/instrument.ts <li>Enabled Sentry profiling integration<br> <li> Updated sampling rates and cleaned commentary </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-8f041330c6187cfe1b7aaa4598b1a8522d25226f0fe79c30ededa0c3bf95fa8a">+11/-9</a>&nbsp; &nbsp; </td> </tr> </table></td></tr><tr><td><strong>Dependencies</strong></td><td><table> <tr> <td> <details> <summary><strong>package.json</strong><dd><code>Updated package dependencies for Sentry improvements</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/package.json <li>Upgraded Sentry related packages to version 9<br> <li> Added OpenTelemetry packages for tracing integration </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-53ddfb1f8a02f1231d3d15a2e694ffe1407d2cc01d3e685de5653b67fec571c7">+5/-2</a>&nbsp; &nbsp; &nbsp; </td> </tr> </table></td></tr></tr></tbody></table> ___ > <details> <summary> Need help?</summary><li>Type <code>/help how to ...</code> in the comments thread for any questions about PR-Agent usage.</li><li>Check out the <a href="https://qodo-merge-docs.qodo.ai/usage-guide/">documentation</a> for more information.</li></details>
2025-04-02 01:19:57 +00:00
// Profiling sampling rate
// In production, sample 10% of transactions
profilesSampleRate: isProduction ? 0.1 : 1.0,
fix sentry & inline suggestions (#1546) ### **PR Type** Enhancement ___ ### **Description** - Introduce Sentry test endpoint for error capture - Integrate Sentry profiling into instrumentation - Update package dependencies for Sentry enhancements - Simplify optimization endpoints routing ___ ### **Changes walkthrough** 📝 <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table> <tr> <td> <details> <summary><strong>sentry-test.ts</strong><dd><code>New Sentry test error endpoint added</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/endpoints/sentry-test.ts <li>Added a new endpoint that triggers a test error<br> <li> Captures and logs the error via Sentry </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-a1734472696f2996ba47e868f2d5bf56fa74c8010195afe7731898e6dd7325b9">+15/-0</a>&nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>index.ts</strong><dd><code>Integrated Sentry test router and endpoint adjustments</code>&nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/index.ts <li>Imported and applied the new Sentry test router<br> <li> Refined optimization endpoints list </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-c3e60be1461b6e80f9181080342927fd9df095197e8784ae0ff51daaec8d71d5">+3/-5</a>&nbsp; &nbsp; &nbsp; </td> </tr> <tr> <td> <details> <summary><strong>instrument.ts</strong><dd><code>Improved Sentry instrumentation configuration</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/instrument.ts <li>Enabled Sentry profiling integration<br> <li> Updated sampling rates and cleaned commentary </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-8f041330c6187cfe1b7aaa4598b1a8522d25226f0fe79c30ededa0c3bf95fa8a">+11/-9</a>&nbsp; &nbsp; </td> </tr> </table></td></tr><tr><td><strong>Dependencies</strong></td><td><table> <tr> <td> <details> <summary><strong>package.json</strong><dd><code>Updated package dependencies for Sentry improvements</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary> <hr> js/cf-api/package.json <li>Upgraded Sentry related packages to version 9<br> <li> Added OpenTelemetry packages for tracing integration </details> </td> <td><a href="https://github.com/codeflash-ai/codeflash-internal/pull/1546/files#diff-53ddfb1f8a02f1231d3d15a2e694ffe1407d2cc01d3e685de5653b67fec571c7">+5/-2</a>&nbsp; &nbsp; &nbsp; </td> </tr> </table></td></tr></tr></tbody></table> ___ > <details> <summary> Need help?</summary><li>Type <code>/help how to ...</code> in the comments thread for any questions about PR-Agent usage.</li><li>Check out the <a href="https://qodo-merge-docs.qodo.ai/usage-guide/">documentation</a> for more information.</li></details>
2025-04-02 01:19:57 +00:00
// Debug mode for local testing
2025-06-05 21:00:31 +00:00
debug: !isProduction,
// Capture more context for errors
maxBreadcrumbs: 50,
// Attach stack traces to messages
attachStacktrace: true,
// Add release information if available
release: process.env.RELEASE_VERSION || process.env.npm_package_version,
// Filter out sensitive data
beforeSend(event, hint) {
// Remove sensitive headers
if (event.request?.headers) {
delete event.request.headers.authorization
delete event.request.headers.cookie
delete event.request.headers["x-api-key"]
}
// Remove sensitive environment variables
if (event.contexts?.runtime?.env) {
const sensitiveKeys = ["DATABASE_URL", "STRIPE_SECRET", "JWT_SECRET", "GITHUB_PRIVATE_KEY"]
sensitiveKeys.forEach(key => {
if (event.contexts?.runtime?.env) {
delete event.contexts.runtime.env[key]
}
})
}
return event
},
// Ignore certain errors
ignoreErrors: [
// Browser extensions
"top.GLOBALS",
// Random plugins/extensions
"originalCreateNotification",
"canvas.contentDocument",
"MyApp_RemoveAllHighlights",
// Common benign errors
"Non-Error promise rejection captured",
"ResizeObserver loop limit exceeded",
// Network errors that are user-side issues
"Network request failed",
"NetworkError",
],
// Add server name for identification
serverName: process.env.WEBSITE_INSTANCE_ID || process.env.HOSTNAME || "unknown",
// Tag with Azure-specific metadata if available
initialScope: {
tags: {
service: "cf-api",
azure_instance: process.env.WEBSITE_INSTANCE_ID || "unknown",
azure_site_name: process.env.WEBSITE_SITE_NAME || "unknown",
node_version: process.version,
},
},
})