Skip to content

docs(js): Add Express to the Cloudflare quick start - #20929

Merged
JPeer264 merged 2 commits into
masterfrom
jp/express-cloudflare
Nov 23, 2026
Merged

JPeer264 merged 2 commits into
masterfrom
jp/express-cloudflare

Conversation

@JPeer264

@JPeer264 JPeer264 commented Nov 20, 2026 •

Copy link
Copy Markdown
Member

DESCRIBE YOUR PR

Tell us what you're changing and why. If your PR resolves an issue, please link it so it closes automatically.

follow up to getsentry/sentry-javascript#24845

This adds Express to the framework selector of the Cloudflare quick start. With Express selected, the page shows the httpServerHandler Worker entry and the Express verify snippet, as the Bun and Deno quick starts do. The Express guide now links Cloudflare Workers next to Node.js, Bun and Deno.

Why

Since @sentry/cloudflare 11.15.0, the Vite plugin names Express requests after their route and captures route errors on Workers (getsentry/sentry-javascript#26559, getsentry/sentry-javascript#26560). With getsentry/sentry-javascript#26729, routes of mounted routers also keep their mount path with router 2.3.0. The docs had no Express setup for Cloudflare.

Known issues

  • On Cloudflare, a mount path with parameters (app.use("/orgs/:orgId", router)) gives only GET with Express 4, and with Express 5 on router older than 2.3.0. The Express block shows this as a warning.

IS YOUR CHANGE URGENT?

Help us prioritize incoming PRs by letting us know when the change needs to go live.
Select exactly one option. For deadlines, replace YYYY-MM-DD with the due date. You can update this information later by editing the PR description.

  • Urgent deadline (GA date, etc.): YYYY-MM-DD
  • Other deadline: YYYY-MM-DD
  • No deadline: Not urgent, can wait up to 1 week+

SLA

  • Teamwork makes the dream work, so please add a reviewer to your PRs.
  • Please give the docs team up to 1 week to review your PR unless you've supplied a deadline.

Thanks in advance for your help!

PRE-MERGE CHECKLIST

Make sure you've checked the following before merging your changes:

  • Checked Vercel preview for correctness, including links
  • PR was reviewed and approved by any necessary SMEs (subject matter experts)
  • PR was reviewed and approved by a member of the Sentry docs team

LEGAL BOILERPLATE

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

EXTRA RESOURCES

The Cloudflare quick start gets Express in its framework selector. With
Express selected, it shows the `httpServerHandler` Worker entry and the
Express verify snippet, as the Bun and Deno quick starts do. The Express
guide links Cloudflare Workers next to Node.js, Bun and Deno.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
sentry-docs Ready Ready Preview Nov 23, 2026 12:57pm UTC
1 Skipped Deployment
Project Deployment Actions Updated
develop-docs Ignored Ignored Preview Nov 23, 2026 12:57pm UTC

Request Review

@github-actions github-actions Bot added the Priority: Needs Triage The PR description is missing valid priority information label Nov 20, 2026
@github-actions github-actions Bot added Priority: Normal Docs review has no urgent deadline and removed Priority: Needs Triage The PR description is missing valid priority information labels Nov 22, 2026
@JPeer264
JPeer264 marked this pull request as ready for review November 23, 2026 10:20
@JPeer264 JPeer264 self-assigned this Nov 23, 2026
@cursor

cursor Bot commented Nov 23, 2026

Copy link
Copy Markdown
Contributor

Getting ready to monitor this change · Rollout details

Status Service Environment
⏳ Getting ready to monitor this change

@@ -0,0 +1,24 @@
Your Express app runs on Workers with `httpServerHandler` from `cloudflare:node`, as in [Cloudflare's Express guide](https://developers.cloudflare.com/workers/tutorials/deploy-an-express-app/). You don't change your Worker entry: the plugin wraps its `httpServerHandler` export and instruments Express. Each request is named after its route, for example `GET /users/:id`, and errors from your routes and middleware are captured.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Your Express app runs on Workers with `httpServerHandler` from `cloudflare:node`, as in [Cloudflare's Express guide](https://developers.cloudflare.com/workers/tutorials/deploy-an-express-app/). You don't change your Worker entry: the plugin wraps its `httpServerHandler` export and instruments Express. Each request is named after its route, for example `GET /users/:id`, and errors from your routes and middleware are captured.
Your Express app runs on Workers with `httpServerHandler` from `cloudflare:node`, as in [Cloudflare's Express guide](https://developers.cloudflare.com/workers/tutorials/deploy-an-express-app/). You don't need to change your Worker entry: the plugin wraps its `httpServerHandler` export and instruments Express. Each request is named after its route, for example `GET /users/:id`, and errors from your routes and middleware are captured.

missing words?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think both works but yours is better.

@JPeer264
JPeer264 merged commit 092889d into master Nov 23, 2026
30 checks passed
@JPeer264
JPeer264 deleted the jp/express-cloudflare branch November 23, 2026 13:24

This branch was successfully deployed

2 active (1 outdated) deployments
Preview – sentry-docs — 0de94521 Deployed Nov 23, 2026 by vercel[bot]
Preview – develop-docs — 10ca6393 Deployed Nov 20, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Priority: Normal Docs review has no urgent deadline

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants