lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb in twilio-ruby-5.38.0 vs lib/twilio-ruby/rest/taskrouter/v1/workspace/event.rb in twilio-ruby-5.39.0

- old
+ new

@@ -34,15 +34,17 @@ # date-time. # @param [String] event_type The type of Events to read. Returns only Events of # the type specified. # @param [String] minutes The period of events to read in minutes. Returns only # Events that occurred since this many minutes in the past. The default is `15` - # minutes. + # minutes. Task Attributes for Events occuring more 43,200 minutes ago will be + # redacted. # @param [String] reservation_sid The SID of the Reservation with the Events to # read. Returns only Events that pertain to the specified Reservation. # @param [Time] start_date Only include Events from on or after this date and # time, specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format. + # Task Attributes for Events older than 30 days will be redacted. # @param [String] task_queue_sid The SID of the TaskQueue with the Events to read. # Returns only the Events that pertain to the specified TaskQueue. # @param [String] task_sid The SID of the Task with the Events to read. Returns # only the Events that pertain to the specified Task. # @param [String] worker_sid The SID of the Worker with the Events to read. @@ -86,15 +88,17 @@ # date-time. # @param [String] event_type The type of Events to read. Returns only Events of # the type specified. # @param [String] minutes The period of events to read in minutes. Returns only # Events that occurred since this many minutes in the past. The default is `15` - # minutes. + # minutes. Task Attributes for Events occuring more 43,200 minutes ago will be + # redacted. # @param [String] reservation_sid The SID of the Reservation with the Events to # read. Returns only Events that pertain to the specified Reservation. # @param [Time] start_date Only include Events from on or after this date and # time, specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format. + # Task Attributes for Events older than 30 days will be redacted. # @param [String] task_queue_sid The SID of the TaskQueue with the Events to read. # Returns only the Events that pertain to the specified TaskQueue. # @param [String] task_sid The SID of the Task with the Events to read. Returns # only the Events that pertain to the specified Task. # @param [String] worker_sid The SID of the Worker with the Events to read. @@ -154,15 +158,17 @@ # date-time. # @param [String] event_type The type of Events to read. Returns only Events of # the type specified. # @param [String] minutes The period of events to read in minutes. Returns only # Events that occurred since this many minutes in the past. The default is `15` - # minutes. + # minutes. Task Attributes for Events occuring more 43,200 minutes ago will be + # redacted. # @param [String] reservation_sid The SID of the Reservation with the Events to # read. Returns only Events that pertain to the specified Reservation. # @param [Time] start_date Only include Events from on or after this date and # time, specified in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format. + # Task Attributes for Events older than 30 days will be redacted. # @param [String] task_queue_sid The SID of the TaskQueue with the Events to read. # Returns only the Events that pertain to the specified TaskQueue. # @param [String] task_sid The SID of the Task with the Events to read. Returns # only the Events that pertain to the specified Task. # @param [String] worker_sid The SID of the Worker with the Events to read. @@ -191,15 +197,13 @@ 'Sid' => sid, 'PageToken' => page_token, 'Page' => page_number, 'PageSize' => page_size, }) - response = @version.page( - 'GET', - @uri, - params - ) + + response = @version.page('GET', @uri, params) + EventPage.new(@version, response, @solution) end ## # Retrieve a single page of EventInstance records from the API. @@ -264,21 +268,15 @@ @solution = {workspace_sid: workspace_sid, sid: sid, } @uri = "/Workspaces/#{@solution[:workspace_sid]}/Events/#{@solution[:sid]}" end ## - # Fetch a EventInstance + # Fetch the EventInstance # @return [EventInstance] Fetched EventInstance def fetch - params = Twilio::Values.of({}) + payload = @version.fetch('GET', @uri) - payload = @version.fetch( - 'GET', - @uri, - params, - ) - EventInstance.new(@version, payload, workspace_sid: @solution[:workspace_sid], sid: @solution[:sid], ) end ## # Provide a user friendly representation @@ -444,10 +442,10 @@ def workspace_sid @properties['workspace_sid'] end ## - # Fetch a EventInstance + # Fetch the EventInstance # @return [EventInstance] Fetched EventInstance def fetch context.fetch end \ No newline at end of file