module Bugsnag::Api::Client::EventFields
Methods for the Project Event Fields API
@see docs.bugsnagapiv2.apiary.io/#reference/projects/event-fields
Public Instance Methods
Create a custom Event Field
@option reindex [Boolean] Whether to reindex historical events @option pivot_options [Object] Configuration
for how this field will appear in pivots @return [Sawyer::Resource] New Event Field @see docs.bugsnagapiv2.apiary.io/#reference/projects/event-fields/create-a-custom-event-field
# File lib/bugsnag/api/client/eventfields.rb, line 24 def create_event_field(project_id, display_id, path, filter_options, options = {}) post "projects/#{project_id}/event_fields", options.merge({:display_id => display_id, :path => path, :filter_options => filter_options}) end
Delete a custom Event Field
@return @see docs.bugsnagapiv2.apiary.io/#reference/projects/event-fields/delete-a-custom-event-field
# File lib/bugsnag/api/client/eventfields.rb, line 43 def delete_event_field(project_id, display_id, options = {}) boolean_from_resposne :delete, "project/#{project_id}/event_fields/#{display_id}", options end
List the Event Fields for a Project
@option per_page []Number] Number of results required per page @return [Array<Sawyer::Resource>] List of event fields @see docs.bugsnagapiv2.apiary.io/#reference/projects/event-fields/list-the-event-fields-for-a-project
# File lib/bugsnag/api/client/eventfields.rb, line 14 def event_fields(project_id, options = {}) paginate "projects/#{project_id}/event_fields", options end
Update a custom Event Field
@option reindex [Boolean] Whether to reindex historical events @option filter_options [Object] Configuration
for how the field will appear in the Filter Bar @option pivot_options [Object] Configuration
for how this field will appear in pivots @return [Sawyer::Resource] Updated Event Field @see docs.bugsnagapiv2.apiary.io/#reference/projects/event-fields/update-a-custom-event-field
# File lib/bugsnag/api/client/eventfields.rb, line 35 def update_event_field(project_id, display_id, path, options = {}) patch "projects/#{id}/event_fields/#{display_id}", options.merge({:display_id => display_id, :path => path}) end