Issue
I see that some of my events have event.type set to error and some have event.type set to default. I want to know whether I can set this value manually.
Applies To
All SaaS Customers
Error Monitoring
Resolution
Sentry derives event.type from how you capture the event:
Events captured with
Sentry.captureException()haveevent.typeset toerror.Events captured with
Sentry.captureMessage()haveevent.typeset todefault.
Sentry assigns the default type to events, and the issues created from them, that are not exceptions or errors.
You cannot set event.type directly. Sentry derives it from the event content during ingest, so changing it in a callback such as beforeSend has no effect. The only way to control it is through the method you use to capture the event.
For details on capturing errors and messages, see the Sentry usage documentation.
