Skip to content

POST request handled as GET in nextjs route handlers #13908

Closed

Description

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/nextjs

SDK Version

8.33.1

Framework Version

No response

Link to Sentry event

https://dev-curumas.sentry.io/issues/5968125190/?project=5591101&query=is%3Aunresolved%20issue.priority%3A%5Bhigh%2C%20medium%5D&referrer=issue-stream&statsPeriod=7d&stream_index=0

Reproduction Example/SDK Setup

No response

Steps to Reproduce

Repro: next-test-sentry-main.zip
Follow the steps in the readme:

  1. npm install
  2. update DSN in the sentry config files
  3. npm run dev
  4. send a POST request to http://localhost:3000/api/test

Expected Result

The event in sentry has the POST request information including body.

Actual Result

The request in the Sentry event is treated as a GET request, even though the event is associated with the transaction POST /api/test (http.server)

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

Package: nextjsIssues related to the Sentry Nextjs SDK

Type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions