{"componentChunkName":"component---src-templates-platform-tsx","path":"/platforms/node/guides/koa/hints/","result":{"data":{"file":{"id":"e5c4f2c8-55d8-5c6b-89e7-945ac079acb8","relativePath":"node/common/hints.mdx","sourceInstanceName":"platforms","childMarkdownRemark":null,"childMdx":{"body":"function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\n\nfunction _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\n/* @jsx mdx */\nvar _frontmatter = {\n  \"title\": \"Hints\",\n  \"sidebar_order\": 900\n};\nvar layoutProps = {\n  _frontmatter: _frontmatter\n};\nvar MDXLayout = \"wrapper\";\nreturn function MDXContent(_ref) {\n  var components = _ref.components,\n      props = _objectWithoutProperties(_ref, [\"components\"]);\n\n  return mdx(MDXLayout, _extends({}, layoutProps, props, {\n    components: components,\n    mdxType: \"MDXLayout\"\n  }), mdx(\"p\", null, \"Event and Breadcrumb \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"hints\"), \" are objects containing various information used to put together an event or a breadcrumb. For events, those are things like \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"event_id\"), \", \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"originalException\"), \", \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"syntheticException\"), \" (used internally to generate a cleaner stack trace), and any other arbitrary \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"data\"), \" that a user attaches. For breadcrumbs, it's all implementation dependent. For XHR requests, hint contains the xhr object itself. For user interactions, it contains the DOM element and event name, etc.\"), mdx(\"p\", null, \"They're available in two places: \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"beforeSend\"), \"/\", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"beforeBreadcrumb\"), \" and \", mdx(\"inlineCode\", {\n    parentName: \"p\"\n  }, \"eventProcessors\"), \". Those are the two ways we'll allow users to modify what we put together.\"), mdx(\"h3\", {\n    \"id\": \"hints-for-events\",\n    \"style\": {\n      \"position\": \"relative\"\n    }\n  }, mdx(\"a\", _extends({\n    parentName: \"h3\"\n  }, {\n    \"href\": \"#hints-for-events\",\n    \"aria-label\": \"hints for events permalink\",\n    \"className\": \"anchor before\"\n  }), mdx(\"svg\", _extends({\n    parentName: \"a\"\n  }, {\n    \"viewBox\": \"0 0 24 24\",\n    \"xmlns\": \"http://www.w3.org/2000/svg\"\n  }), mdx(\"path\", _extends({\n    parentName: \"svg\"\n  }, {\n    \"d\": \"M10.879 6.05L15 1.93A5.001 5.001 0 0 1 22.071 9l-4.121 4.121a1 1 0 0 1-1.414-1.414l4.12-4.121a3 3 0 1 0-4.242-4.243l-4.121 4.121a1 1 0 1 1-1.414-1.414zm2.242 11.9L9 22.07A5 5 0 1 1 1.929 15l4.121-4.121a1 1 0 0 1 1.414 1.414l-4.12 4.121a3 3 0 1 0 4.242 4.243l4.121-4.121a1 1 0 1 1 1.414 1.414zm-8.364-.122l13.071-13.07a1 1 0 0 1 1.415 1.414L6.172 19.242a1 1 0 1 1-1.415-1.414z\",\n    \"fill\": \"currentColor\"\n  })))), \"Hints for Events\"), mdx(\"p\", null, mdx(\"dl\", {\n    parentName: \"p\"\n  }, mdx(\"dt\", {\n    parentName: \"dl\"\n  }, mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"originalException\")), mdx(\"dd\", {\n    parentName: \"dl\"\n  }, \"The original exception that created the event. This is useful for changing how events are grouped, or to extract additional information.\"))), mdx(\"p\", null, mdx(\"dl\", {\n    parentName: \"p\"\n  }, mdx(\"dt\", {\n    parentName: \"dl\"\n  }, mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"syntheticException\")), mdx(\"dd\", {\n    parentName: \"dl\"\n  }, \"When a string or a non-error object is raised, Sentry creates a synthetic exception so you can get a basic stack trace. This exception is stored here for further data extraction.\"))), mdx(\"h3\", {\n    \"id\": \"hints-for-breadcrumbs\",\n    \"style\": {\n      \"position\": \"relative\"\n    }\n  }, mdx(\"a\", _extends({\n    parentName: \"h3\"\n  }, {\n    \"href\": \"#hints-for-breadcrumbs\",\n    \"aria-label\": \"hints for breadcrumbs permalink\",\n    \"className\": \"anchor before\"\n  }), mdx(\"svg\", _extends({\n    parentName: \"a\"\n  }, {\n    \"viewBox\": \"0 0 24 24\",\n    \"xmlns\": \"http://www.w3.org/2000/svg\"\n  }), mdx(\"path\", _extends({\n    parentName: \"svg\"\n  }, {\n    \"d\": \"M10.879 6.05L15 1.93A5.001 5.001 0 0 1 22.071 9l-4.121 4.121a1 1 0 0 1-1.414-1.414l4.12-4.121a3 3 0 1 0-4.242-4.243l-4.121 4.121a1 1 0 1 1-1.414-1.414zm2.242 11.9L9 22.07A5 5 0 1 1 1.929 15l4.121-4.121a1 1 0 0 1 1.414 1.414l-4.12 4.121a3 3 0 1 0 4.242 4.243l4.121-4.121a1 1 0 1 1 1.414 1.414zm-8.364-.122l13.071-13.07a1 1 0 0 1 1.415 1.414L6.172 19.242a1 1 0 1 1-1.415-1.414z\",\n    \"fill\": \"currentColor\"\n  })))), \"Hints for Breadcrumbs\"), mdx(\"p\", null, mdx(\"dl\", {\n    parentName: \"p\"\n  }, mdx(\"dt\", {\n    parentName: \"dl\"\n  }, mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"level\"), \" / \", mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"input\")), mdx(\"dd\", {\n    parentName: \"dl\"\n  }, \"For breadcrumbs created from console log interceptions, this holds the original console log level and the original input data to the log function.\"))), mdx(\"p\", null, mdx(\"dl\", {\n    parentName: \"p\"\n  }, mdx(\"dt\", {\n    parentName: \"dl\"\n  }, mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"request\"), \" / \", mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"response\"), \" / \", mdx(\"inlineCode\", {\n    parentName: \"dt\"\n  }, \"event\")), mdx(\"dd\", {\n    parentName: \"dl\"\n  }, \"For breadcrumbs created from HTTP requests, this holds the request and response object\\n(from the node HTTP API) as well as the node event (\", mdx(\"inlineCode\", {\n    parentName: \"dd\"\n  }, \"response\"), \" or \", mdx(\"inlineCode\", {\n    parentName: \"dd\"\n  }, \"error\"), \").\"))));\n}\n;\nMDXContent.isMDXComponent = true;","tableOfContents":{"items":[{"url":"#hints-for-events","title":"Hints for Events"},{"url":"#hints-for-breadcrumbs","title":"Hints for Breadcrumbs"}]},"internal":{"type":"Mdx"}}}},"pageContext":{"excerpt":"Event and Breadcrumb  hints  are objects containing various information used to put together an event or a breadcrumb. For events, those are things like  event_id ,  originalException ,  syntheticException  (used internally to generate a cleaner stack trace), and any other arbitrary  data  that a user attaches. For breadcrumbs, it's all implementation dependent. For XHR requests, hint contains the xhr object itself. For user interactions, it contains the DOM element and event name, etc. They're available in two places:  beforeSend / beforeBreadcrumb  and  eventProcessors . Those are the two ways we'll allow users to modify what we put together. Hints for Events originalException : The original exception that created the event. This is useful for changing how events are grouped, or to extract additional information. syntheticException : When a string or a non-error object is raised, Sentry creates a synthetic exception so you can get a basic stack trace. This exception is stored here for further data extraction. Hints for Breadcrumbs level  /  input : For breadcrumbs created from console log interceptions, this holds the original console log level and the original input data to the log function. request  /  response  /  event : For breadcrumbs created from HTTP requests, this holds the request and response object\n(from the node HTTP API) as well as the node event ( response  or  error ).","title":"Hints","sidebar_order":900,"platform":{"name":"node","title":"Node.js"},"guide":{"name":"koa","title":"Koa"},"noindex":true,"notoc":true,"redirect_from":[],"id":"e5c4f2c8-55d8-5c6b-89e7-945ac079acb8"}},"staticQueryHashes":["1218203755","1222113826","1222113826","1766336459","2158593473","2404336828","2472290386","2764967025","3818502851","4015007367","4192517163","4264099332","518019976"]}