This repository has been archived by the owner on Dec 11, 2020. It is now read-only.
forked from cloudflare/raven-lua
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathpayload.json
221 lines (185 loc) · 7.94 KB
/
payload.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
{
// The API Key associated with the project. Informs Bugsnag which project
// has generated this error.
apiKey: "c9d60ae4c7e70c4b6c4ebd3e8056d2b8",
// This object describes the notifier itself. These properties are used
// within Bugsnag to track error rates from a notifier.
notifier: {
// The notifier name
name: "Bugsnag Ruby",
// The notifier's current version
version: "1.0.11",
// The URL associated with the notifier
url: "https://github.com/bugsnag/bugsnag-ruby"
},
// An array of error events that Bugsnag should be notified of. A notifier
// can choose to group notices into an array to minimize network traffic, or
// can notify Bugsnag each time an event occurs.
events: [{
// The version number of the payload. If not set to 2+, Severity will
// not be supported.
// (required, must be set to "2")
payloadVersion: "2",
// An array of exceptions that occurred during this event. Most of the
// time there will only be one exception, but some languages support
// "nested" or "caused by" exceptions. In this case, exceptions should
// be unwrapped and added to the array one at a time. The first
// exception raised should be first in this array.
exceptions: [{
// The class of error that occurred. This field is used to group the
// errors together so should not contain any contextual information
// that would prevent correct grouping. This would ordinarily be the
// Exception name when dealing with an exception.
// (searchable)
errorClass: "NoMethodError",
// The error message associated with the error. Usually this will
// contain some information about this specific instance of the
// error and is not used to group the errors (optional, default
// none). (searchable)
message: "Unable to connect to database.",
// An array of stacktrace objects. Each object represents one line
// in the exception's stacktrace. Bugsnag uses this information to
// help with error grouping, as well as displaying it to the user.
stacktrace: [{
// The file that this stack frame was executing.
// It is recommended that you strip any unnecessary or common
// information from the beginning of the path.
file: "controllers/auth/session_controller.rb",
// The line of the file that this frame of the stack was in.
lineNumber: 1234,
// The column of the file that this frame of the stack was in.
// (optional)
columnNumber: 123,
// The method that this particular stack frame is within.
method: "create",
// Is this stacktrace line is in the user's project code, set
// this to true. It is useful for developers to be able to see
// which lines of a stacktrace are within their own application,
// and which are within third party libraries. This boolean
// field allows Bugsnag to display this information in the
// stacktrace as well as use the information to help group
// errors better.
// (Optional, defaults to false).
inProject: true,
// The code in this file surrounding this line. You can include
// up to three lines on either side of the line that crashed.
// These will be displayed on the bugsnag dashboard when you expand
// that line.
// (optional)
code: {
1231: " def a",
1232: "",
1233: " if problem?",
1234: " raise 'something went wrong'",
1235: " end"
1236: "",
1237: " end"
}
}]
}],
// An array of background threads.
// This is optional but recommended for apps that rely heavily on threading.
// Threads should be in an order that makes sense for your application.
// (optional)
threads: [{
// The id of the thread in your application.
// (optional)
id: "thread_id",
// A human readable name for the thread.
// (optional)
name: "thread_name",
// An array of stacktrace objects. Each object represents one line
// in the stacktrace of the thread at the point your program crashed.
stacktrace: [{
// This object has the same format as the stacktrace object on exceptions.
}]
}],
// A string representing what was happening in the application at the
// time of the error. This string could be used for grouping purposes,
// depending on the event.
// Usually this would represent the controller and action in a server
// based project. It could represent the screen that the user was
// interacting with in a client side project.
// For example,
// * On Ruby on Rails the context could be controller#action
// * In Android, the context could be the top most Activity.
// * In iOS, the context could be the name of the top most
// UIViewController
// (optional, searchable)
context: "auth/session#create",
// All errors with the same groupingHash will be grouped together within
// the bugsnag dashboard.
// This gives a notifier more control as to how grouping should be
// performed. We recommend including the errorClass of the exception in
// here so a different class of error will be grouped separately.
// (optional)
groupingHash: "buggy_file.rb",
// The severity of the error. This can be set to:
// - "error" used when the app crashes
// - "warning" used when Bugsnag.notify is called
// - "info" can be used in manual Bugsnag.notify calls
// (optional, default "error", filtered)
severity: "error",
// Information about the user affected by the crash.
// These fields are optional but highly recommended.
user: {
// A unique identifier for a user affected by this event. This could
// be any distinct identifier that makes sense for your
// application/platform.
// (optional, searchable)
id: "19",
// The user's name, or a string you use to identify them.
// (optional, searchable)
name: "Simon Maynard",
// The user's email address.
// (optional, searchable)
email: "[email protected]"
},
// Information about the app that crashed.
// These fields are optional but highly recommended
app: {
// The version number of the application which generated the error.
// If appVersion is set and an error is resolved in the dashboard
// the error will not unresolve until a crash is seen in a newer
// version of the app.
// (optional, default none, filtered)
version: "1.1.3",
// The release stage that this error occurred in, for example
// "development", "staging" or "production".
// (optional, default "production", filtered)
releaseStage: "production",
},
// Information about the computer/device running the app
// These fields are optional but highly recommended
device: {
// The operating system version of the client that the error was
// generated on. (optional, default none)
osVersion: "2.1.1",
// The hostname of the server running your code
// (optional, default none)
hostname: "web1.internal"
}
// An object containing any further data you wish to attach to this
// error event. This should contain one or more objects, with each
// object being displayed in its own tab on the event details on the
// Bugsnag website.
// (Optional).
metaData: {
// This will displayed as the first tab after the stacktrace on the
// Bugsnag website.
someData: {
// A key value pair that will be displayed in the first tab
key: "value",
// This is shown as a section within the first tab
setOfKeys: {
key: "value",
key2: "value"
}
},
// This would be the second tab on the Bugsnag website.
someMoreData: {
...
}
}
}]
}