deeprails 0.7.0 → 0.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/CHANGELOG.md +9 -0
 - data/README.md +1 -1
 - data/lib/deeprails/internal/transport/pooled_net_requester.rb +30 -24
 - data/lib/deeprails/models/defend_create_workflow_params.rb +4 -4
 - data/lib/deeprails/models/defend_response.rb +4 -4
 - data/lib/deeprails/models/defend_submit_event_params.rb +4 -4
 - data/lib/deeprails/models/evaluate_create_params.rb +2 -2
 - data/lib/deeprails/models/evaluation.rb +2 -2
 - data/lib/deeprails/models/monitor_detail_response.rb +150 -0
 - data/lib/deeprails/models/monitor_event_response.rb +41 -0
 - data/lib/deeprails/models/monitor_response.rb +83 -0
 - data/lib/deeprails/models/monitor_submit_event_params.rb +2 -2
 - data/lib/deeprails/models.rb +6 -2
 - data/lib/deeprails/resources/defend.rb +2 -2
 - data/lib/deeprails/resources/monitor.rb +8 -8
 - data/lib/deeprails/version.rb +1 -1
 - data/lib/deeprails.rb +3 -3
 - data/rbi/deeprails/models/defend_create_workflow_params.rbi +6 -6
 - data/rbi/deeprails/models/defend_response.rbi +6 -6
 - data/rbi/deeprails/models/defend_submit_event_params.rbi +5 -5
 - data/rbi/deeprails/models/evaluate_create_params.rbi +3 -3
 - data/rbi/deeprails/models/evaluation.rbi +3 -3
 - data/rbi/deeprails/models/monitor_detail_response.rbi +251 -0
 - data/rbi/deeprails/models/monitor_event_response.rbi +64 -0
 - data/rbi/deeprails/models/monitor_response.rbi +142 -0
 - data/rbi/deeprails/models/monitor_submit_event_params.rbi +3 -3
 - data/rbi/deeprails/models.rbi +6 -2
 - data/rbi/deeprails/resources/defend.rbi +3 -3
 - data/rbi/deeprails/resources/evaluate.rbi +1 -1
 - data/rbi/deeprails/resources/monitor.rbi +5 -5
 - data/sig/deeprails/models/defend_create_workflow_params.rbs +5 -5
 - data/sig/deeprails/models/defend_response.rbs +5 -5
 - data/sig/deeprails/models/monitor_detail_response.rbs +134 -0
 - data/sig/deeprails/models/monitor_event_response.rbs +37 -0
 - data/sig/deeprails/models/monitor_response.rbs +73 -0
 - data/sig/deeprails/models.rbs +6 -2
 - data/sig/deeprails/resources/defend.rbs +1 -1
 - data/sig/deeprails/resources/monitor.rbs +4 -4
 - metadata +11 -11
 - data/lib/deeprails/models/api_response.rb +0 -116
 - data/lib/deeprails/models/monitor_retrieve_response.rb +0 -183
 - data/lib/deeprails/models/monitor_submit_event_response.rb +0 -74
 - data/rbi/deeprails/models/api_response.rbi +0 -201
 - data/rbi/deeprails/models/monitor_retrieve_response.rbi +0 -333
 - data/rbi/deeprails/models/monitor_submit_event_response.rbi +0 -131
 - data/sig/deeprails/models/api_response.rbs +0 -100
 - data/sig/deeprails/models/monitor_retrieve_response.rbs +0 -167
 - data/sig/deeprails/models/monitor_submit_event_response.rbs +0 -70
 
| 
         @@ -1,183 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            # frozen_string_literal: true
         
     | 
| 
       2 
     | 
    
         
            -
             
     | 
| 
       3 
     | 
    
         
            -
            module Deeprails
         
     | 
| 
       4 
     | 
    
         
            -
              module Models
         
     | 
| 
       5 
     | 
    
         
            -
                # @see Deeprails::Resources::Monitor#retrieve
         
     | 
| 
       6 
     | 
    
         
            -
                class MonitorRetrieveResponse < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       7 
     | 
    
         
            -
                  # @!attribute success
         
     | 
| 
       8 
     | 
    
         
            -
                  #   Represents whether the request was completed successfully.
         
     | 
| 
       9 
     | 
    
         
            -
                  #
         
     | 
| 
       10 
     | 
    
         
            -
                  #   @return [Boolean]
         
     | 
| 
       11 
     | 
    
         
            -
                  required :success, Deeprails::Internal::Type::Boolean
         
     | 
| 
       12 
     | 
    
         
            -
             
     | 
| 
       13 
     | 
    
         
            -
                  # @!attribute data
         
     | 
| 
       14 
     | 
    
         
            -
                  #
         
     | 
| 
       15 
     | 
    
         
            -
                  #   @return [Deeprails::Models::MonitorRetrieveResponse::Data, nil]
         
     | 
| 
       16 
     | 
    
         
            -
                  optional :data, -> { Deeprails::Models::MonitorRetrieveResponse::Data }
         
     | 
| 
       17 
     | 
    
         
            -
             
     | 
| 
       18 
     | 
    
         
            -
                  # @!attribute message
         
     | 
| 
       19 
     | 
    
         
            -
                  #   The accompanying message for the request. Includes error details when
         
     | 
| 
       20 
     | 
    
         
            -
                  #   applicable.
         
     | 
| 
       21 
     | 
    
         
            -
                  #
         
     | 
| 
       22 
     | 
    
         
            -
                  #   @return [String, nil]
         
     | 
| 
       23 
     | 
    
         
            -
                  optional :message, String
         
     | 
| 
       24 
     | 
    
         
            -
             
     | 
| 
       25 
     | 
    
         
            -
                  # @!method initialize(success:, data: nil, message: nil)
         
     | 
| 
       26 
     | 
    
         
            -
                  #   Some parameter documentations has been truncated, see
         
     | 
| 
       27 
     | 
    
         
            -
                  #   {Deeprails::Models::MonitorRetrieveResponse} for more details.
         
     | 
| 
       28 
     | 
    
         
            -
                  #
         
     | 
| 
       29 
     | 
    
         
            -
                  #   Response wrapper for operations returning a MonitorDetailResponse.
         
     | 
| 
       30 
     | 
    
         
            -
                  #
         
     | 
| 
       31 
     | 
    
         
            -
                  #   @param success [Boolean] Represents whether the request was completed successfully.
         
     | 
| 
       32 
     | 
    
         
            -
                  #
         
     | 
| 
       33 
     | 
    
         
            -
                  #   @param data [Deeprails::Models::MonitorRetrieveResponse::Data]
         
     | 
| 
       34 
     | 
    
         
            -
                  #
         
     | 
| 
       35 
     | 
    
         
            -
                  #   @param message [String] The accompanying message for the request. Includes error details when applicable
         
     | 
| 
       36 
     | 
    
         
            -
             
     | 
| 
       37 
     | 
    
         
            -
                  # @see Deeprails::Models::MonitorRetrieveResponse#data
         
     | 
| 
       38 
     | 
    
         
            -
                  class Data < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       39 
     | 
    
         
            -
                    # @!attribute monitor_id
         
     | 
| 
       40 
     | 
    
         
            -
                    #   A unique monitor ID.
         
     | 
| 
       41 
     | 
    
         
            -
                    #
         
     | 
| 
       42 
     | 
    
         
            -
                    #   @return [String]
         
     | 
| 
       43 
     | 
    
         
            -
                    required :monitor_id, String
         
     | 
| 
       44 
     | 
    
         
            -
             
     | 
| 
       45 
     | 
    
         
            -
                    # @!attribute monitor_status
         
     | 
| 
       46 
     | 
    
         
            -
                    #   Status of the monitor. Can be `active` or `inactive`. Inactive monitors no
         
     | 
| 
       47 
     | 
    
         
            -
                    #   longer record and evaluate events.
         
     | 
| 
       48 
     | 
    
         
            -
                    #
         
     | 
| 
       49 
     | 
    
         
            -
                    #   @return [Symbol, Deeprails::Models::MonitorRetrieveResponse::Data::MonitorStatus]
         
     | 
| 
       50 
     | 
    
         
            -
                    required :monitor_status, enum: -> { Deeprails::Models::MonitorRetrieveResponse::Data::MonitorStatus }
         
     | 
| 
       51 
     | 
    
         
            -
             
     | 
| 
       52 
     | 
    
         
            -
                    # @!attribute name
         
     | 
| 
       53 
     | 
    
         
            -
                    #   Name of this monitor.
         
     | 
| 
       54 
     | 
    
         
            -
                    #
         
     | 
| 
       55 
     | 
    
         
            -
                    #   @return [String]
         
     | 
| 
       56 
     | 
    
         
            -
                    required :name, String
         
     | 
| 
       57 
     | 
    
         
            -
             
     | 
| 
       58 
     | 
    
         
            -
                    # @!attribute created_at
         
     | 
| 
       59 
     | 
    
         
            -
                    #   The time the monitor was created in UTC.
         
     | 
| 
       60 
     | 
    
         
            -
                    #
         
     | 
| 
       61 
     | 
    
         
            -
                    #   @return [Time, nil]
         
     | 
| 
       62 
     | 
    
         
            -
                    optional :created_at, Time
         
     | 
| 
       63 
     | 
    
         
            -
             
     | 
| 
       64 
     | 
    
         
            -
                    # @!attribute description
         
     | 
| 
       65 
     | 
    
         
            -
                    #   Description of this monitor.
         
     | 
| 
       66 
     | 
    
         
            -
                    #
         
     | 
| 
       67 
     | 
    
         
            -
                    #   @return [String, nil]
         
     | 
| 
       68 
     | 
    
         
            -
                    optional :description, String
         
     | 
| 
       69 
     | 
    
         
            -
             
     | 
| 
       70 
     | 
    
         
            -
                    # @!attribute evaluations
         
     | 
| 
       71 
     | 
    
         
            -
                    #   An array of all evaluations performed by this monitor. Each one corresponds to a
         
     | 
| 
       72 
     | 
    
         
            -
                    #   separate monitor event.
         
     | 
| 
       73 
     | 
    
         
            -
                    #
         
     | 
| 
       74 
     | 
    
         
            -
                    #   @return [Array<Deeprails::Models::Evaluation>, nil]
         
     | 
| 
       75 
     | 
    
         
            -
                    optional :evaluations, -> { Deeprails::Internal::Type::ArrayOf[Deeprails::Evaluation] }
         
     | 
| 
       76 
     | 
    
         
            -
             
     | 
| 
       77 
     | 
    
         
            -
                    # @!attribute stats
         
     | 
| 
       78 
     | 
    
         
            -
                    #   Contains five fields used for stats of this monitor: total evaluations,
         
     | 
| 
       79 
     | 
    
         
            -
                    #   completed evaluations, failed evaluations, queued evaluations, and in progress
         
     | 
| 
       80 
     | 
    
         
            -
                    #   evaluations.
         
     | 
| 
       81 
     | 
    
         
            -
                    #
         
     | 
| 
       82 
     | 
    
         
            -
                    #   @return [Deeprails::Models::MonitorRetrieveResponse::Data::Stats, nil]
         
     | 
| 
       83 
     | 
    
         
            -
                    optional :stats, -> { Deeprails::Models::MonitorRetrieveResponse::Data::Stats }
         
     | 
| 
       84 
     | 
    
         
            -
             
     | 
| 
       85 
     | 
    
         
            -
                    # @!attribute updated_at
         
     | 
| 
       86 
     | 
    
         
            -
                    #   The most recent time the monitor was modified in UTC.
         
     | 
| 
       87 
     | 
    
         
            -
                    #
         
     | 
| 
       88 
     | 
    
         
            -
                    #   @return [Time, nil]
         
     | 
| 
       89 
     | 
    
         
            -
                    optional :updated_at, Time
         
     | 
| 
       90 
     | 
    
         
            -
             
     | 
| 
       91 
     | 
    
         
            -
                    # @!attribute user_id
         
     | 
| 
       92 
     | 
    
         
            -
                    #   User ID of the user who created the monitor.
         
     | 
| 
       93 
     | 
    
         
            -
                    #
         
     | 
| 
       94 
     | 
    
         
            -
                    #   @return [String, nil]
         
     | 
| 
       95 
     | 
    
         
            -
                    optional :user_id, String
         
     | 
| 
       96 
     | 
    
         
            -
             
     | 
| 
       97 
     | 
    
         
            -
                    # @!method initialize(monitor_id:, monitor_status:, name:, created_at: nil, description: nil, evaluations: nil, stats: nil, updated_at: nil, user_id: nil)
         
     | 
| 
       98 
     | 
    
         
            -
                    #   Some parameter documentations has been truncated, see
         
     | 
| 
       99 
     | 
    
         
            -
                    #   {Deeprails::Models::MonitorRetrieveResponse::Data} for more details.
         
     | 
| 
       100 
     | 
    
         
            -
                    #
         
     | 
| 
       101 
     | 
    
         
            -
                    #   @param monitor_id [String] A unique monitor ID.
         
     | 
| 
       102 
     | 
    
         
            -
                    #
         
     | 
| 
       103 
     | 
    
         
            -
                    #   @param monitor_status [Symbol, Deeprails::Models::MonitorRetrieveResponse::Data::MonitorStatus] Status of the monitor. Can be `active` or `inactive`. Inactive monitors no lon
         
     | 
| 
       104 
     | 
    
         
            -
                    #
         
     | 
| 
       105 
     | 
    
         
            -
                    #   @param name [String] Name of this monitor.
         
     | 
| 
       106 
     | 
    
         
            -
                    #
         
     | 
| 
       107 
     | 
    
         
            -
                    #   @param created_at [Time] The time the monitor was created in UTC.
         
     | 
| 
       108 
     | 
    
         
            -
                    #
         
     | 
| 
       109 
     | 
    
         
            -
                    #   @param description [String] Description of this monitor.
         
     | 
| 
       110 
     | 
    
         
            -
                    #
         
     | 
| 
       111 
     | 
    
         
            -
                    #   @param evaluations [Array<Deeprails::Models::Evaluation>] An array of all evaluations performed by this monitor. Each one corresponds to
         
     | 
| 
       112 
     | 
    
         
            -
                    #
         
     | 
| 
       113 
     | 
    
         
            -
                    #   @param stats [Deeprails::Models::MonitorRetrieveResponse::Data::Stats] Contains five fields used for stats of this monitor: total evaluations, complete
         
     | 
| 
       114 
     | 
    
         
            -
                    #
         
     | 
| 
       115 
     | 
    
         
            -
                    #   @param updated_at [Time] The most recent time the monitor was modified in UTC.
         
     | 
| 
       116 
     | 
    
         
            -
                    #
         
     | 
| 
       117 
     | 
    
         
            -
                    #   @param user_id [String] User ID of the user who created the monitor.
         
     | 
| 
       118 
     | 
    
         
            -
             
     | 
| 
       119 
     | 
    
         
            -
                    # Status of the monitor. Can be `active` or `inactive`. Inactive monitors no
         
     | 
| 
       120 
     | 
    
         
            -
                    # longer record and evaluate events.
         
     | 
| 
       121 
     | 
    
         
            -
                    #
         
     | 
| 
       122 
     | 
    
         
            -
                    # @see Deeprails::Models::MonitorRetrieveResponse::Data#monitor_status
         
     | 
| 
       123 
     | 
    
         
            -
                    module MonitorStatus
         
     | 
| 
       124 
     | 
    
         
            -
                      extend Deeprails::Internal::Type::Enum
         
     | 
| 
       125 
     | 
    
         
            -
             
     | 
| 
       126 
     | 
    
         
            -
                      ACTIVE = :active
         
     | 
| 
       127 
     | 
    
         
            -
                      INACTIVE = :inactive
         
     | 
| 
       128 
     | 
    
         
            -
             
     | 
| 
       129 
     | 
    
         
            -
                      # @!method self.values
         
     | 
| 
       130 
     | 
    
         
            -
                      #   @return [Array<Symbol>]
         
     | 
| 
       131 
     | 
    
         
            -
                    end
         
     | 
| 
       132 
     | 
    
         
            -
             
     | 
| 
       133 
     | 
    
         
            -
                    # @see Deeprails::Models::MonitorRetrieveResponse::Data#stats
         
     | 
| 
       134 
     | 
    
         
            -
                    class Stats < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       135 
     | 
    
         
            -
                      # @!attribute completed_evaluations
         
     | 
| 
       136 
     | 
    
         
            -
                      #   Number of evaluations that completed successfully.
         
     | 
| 
       137 
     | 
    
         
            -
                      #
         
     | 
| 
       138 
     | 
    
         
            -
                      #   @return [Integer, nil]
         
     | 
| 
       139 
     | 
    
         
            -
                      optional :completed_evaluations, Integer
         
     | 
| 
       140 
     | 
    
         
            -
             
     | 
| 
       141 
     | 
    
         
            -
                      # @!attribute failed_evaluations
         
     | 
| 
       142 
     | 
    
         
            -
                      #   Number of evaluations that failed.
         
     | 
| 
       143 
     | 
    
         
            -
                      #
         
     | 
| 
       144 
     | 
    
         
            -
                      #   @return [Integer, nil]
         
     | 
| 
       145 
     | 
    
         
            -
                      optional :failed_evaluations, Integer
         
     | 
| 
       146 
     | 
    
         
            -
             
     | 
| 
       147 
     | 
    
         
            -
                      # @!attribute in_progress_evaluations
         
     | 
| 
       148 
     | 
    
         
            -
                      #   Number of evaluations currently in progress.
         
     | 
| 
       149 
     | 
    
         
            -
                      #
         
     | 
| 
       150 
     | 
    
         
            -
                      #   @return [Integer, nil]
         
     | 
| 
       151 
     | 
    
         
            -
                      optional :in_progress_evaluations, Integer
         
     | 
| 
       152 
     | 
    
         
            -
             
     | 
| 
       153 
     | 
    
         
            -
                      # @!attribute queued_evaluations
         
     | 
| 
       154 
     | 
    
         
            -
                      #   Number of evaluations currently queued.
         
     | 
| 
       155 
     | 
    
         
            -
                      #
         
     | 
| 
       156 
     | 
    
         
            -
                      #   @return [Integer, nil]
         
     | 
| 
       157 
     | 
    
         
            -
                      optional :queued_evaluations, Integer
         
     | 
| 
       158 
     | 
    
         
            -
             
     | 
| 
       159 
     | 
    
         
            -
                      # @!attribute total_evaluations
         
     | 
| 
       160 
     | 
    
         
            -
                      #   Total number of evaluations performed by this monitor.
         
     | 
| 
       161 
     | 
    
         
            -
                      #
         
     | 
| 
       162 
     | 
    
         
            -
                      #   @return [Integer, nil]
         
     | 
| 
       163 
     | 
    
         
            -
                      optional :total_evaluations, Integer
         
     | 
| 
       164 
     | 
    
         
            -
             
     | 
| 
       165 
     | 
    
         
            -
                      # @!method initialize(completed_evaluations: nil, failed_evaluations: nil, in_progress_evaluations: nil, queued_evaluations: nil, total_evaluations: nil)
         
     | 
| 
       166 
     | 
    
         
            -
                      #   Contains five fields used for stats of this monitor: total evaluations,
         
     | 
| 
       167 
     | 
    
         
            -
                      #   completed evaluations, failed evaluations, queued evaluations, and in progress
         
     | 
| 
       168 
     | 
    
         
            -
                      #   evaluations.
         
     | 
| 
       169 
     | 
    
         
            -
                      #
         
     | 
| 
       170 
     | 
    
         
            -
                      #   @param completed_evaluations [Integer] Number of evaluations that completed successfully.
         
     | 
| 
       171 
     | 
    
         
            -
                      #
         
     | 
| 
       172 
     | 
    
         
            -
                      #   @param failed_evaluations [Integer] Number of evaluations that failed.
         
     | 
| 
       173 
     | 
    
         
            -
                      #
         
     | 
| 
       174 
     | 
    
         
            -
                      #   @param in_progress_evaluations [Integer] Number of evaluations currently in progress.
         
     | 
| 
       175 
     | 
    
         
            -
                      #
         
     | 
| 
       176 
     | 
    
         
            -
                      #   @param queued_evaluations [Integer] Number of evaluations currently queued.
         
     | 
| 
       177 
     | 
    
         
            -
                      #
         
     | 
| 
       178 
     | 
    
         
            -
                      #   @param total_evaluations [Integer] Total number of evaluations performed by this monitor.
         
     | 
| 
       179 
     | 
    
         
            -
                    end
         
     | 
| 
       180 
     | 
    
         
            -
                  end
         
     | 
| 
       181 
     | 
    
         
            -
                end
         
     | 
| 
       182 
     | 
    
         
            -
              end
         
     | 
| 
       183 
     | 
    
         
            -
            end
         
     | 
| 
         @@ -1,74 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            # frozen_string_literal: true
         
     | 
| 
       2 
     | 
    
         
            -
             
     | 
| 
       3 
     | 
    
         
            -
            module Deeprails
         
     | 
| 
       4 
     | 
    
         
            -
              module Models
         
     | 
| 
       5 
     | 
    
         
            -
                # @see Deeprails::Resources::Monitor#submit_event
         
     | 
| 
       6 
     | 
    
         
            -
                class MonitorSubmitEventResponse < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       7 
     | 
    
         
            -
                  # @!attribute success
         
     | 
| 
       8 
     | 
    
         
            -
                  #   Represents whether the request was completed successfully.
         
     | 
| 
       9 
     | 
    
         
            -
                  #
         
     | 
| 
       10 
     | 
    
         
            -
                  #   @return [Boolean]
         
     | 
| 
       11 
     | 
    
         
            -
                  required :success, Deeprails::Internal::Type::Boolean
         
     | 
| 
       12 
     | 
    
         
            -
             
     | 
| 
       13 
     | 
    
         
            -
                  # @!attribute data
         
     | 
| 
       14 
     | 
    
         
            -
                  #
         
     | 
| 
       15 
     | 
    
         
            -
                  #   @return [Deeprails::Models::MonitorSubmitEventResponse::Data, nil]
         
     | 
| 
       16 
     | 
    
         
            -
                  optional :data, -> { Deeprails::Models::MonitorSubmitEventResponse::Data }
         
     | 
| 
       17 
     | 
    
         
            -
             
     | 
| 
       18 
     | 
    
         
            -
                  # @!attribute message
         
     | 
| 
       19 
     | 
    
         
            -
                  #   The accompanying message for the request. Includes error details when
         
     | 
| 
       20 
     | 
    
         
            -
                  #   applicable.
         
     | 
| 
       21 
     | 
    
         
            -
                  #
         
     | 
| 
       22 
     | 
    
         
            -
                  #   @return [String, nil]
         
     | 
| 
       23 
     | 
    
         
            -
                  optional :message, String
         
     | 
| 
       24 
     | 
    
         
            -
             
     | 
| 
       25 
     | 
    
         
            -
                  # @!method initialize(success:, data: nil, message: nil)
         
     | 
| 
       26 
     | 
    
         
            -
                  #   Some parameter documentations has been truncated, see
         
     | 
| 
       27 
     | 
    
         
            -
                  #   {Deeprails::Models::MonitorSubmitEventResponse} for more details.
         
     | 
| 
       28 
     | 
    
         
            -
                  #
         
     | 
| 
       29 
     | 
    
         
            -
                  #   Response wrapper for operations returning a MonitorEventResponse.
         
     | 
| 
       30 
     | 
    
         
            -
                  #
         
     | 
| 
       31 
     | 
    
         
            -
                  #   @param success [Boolean] Represents whether the request was completed successfully.
         
     | 
| 
       32 
     | 
    
         
            -
                  #
         
     | 
| 
       33 
     | 
    
         
            -
                  #   @param data [Deeprails::Models::MonitorSubmitEventResponse::Data]
         
     | 
| 
       34 
     | 
    
         
            -
                  #
         
     | 
| 
       35 
     | 
    
         
            -
                  #   @param message [String] The accompanying message for the request. Includes error details when applicable
         
     | 
| 
       36 
     | 
    
         
            -
             
     | 
| 
       37 
     | 
    
         
            -
                  # @see Deeprails::Models::MonitorSubmitEventResponse#data
         
     | 
| 
       38 
     | 
    
         
            -
                  class Data < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       39 
     | 
    
         
            -
                    # @!attribute evaluation_id
         
     | 
| 
       40 
     | 
    
         
            -
                    #   A unique evaluation ID associated with this event.
         
     | 
| 
       41 
     | 
    
         
            -
                    #
         
     | 
| 
       42 
     | 
    
         
            -
                    #   @return [String]
         
     | 
| 
       43 
     | 
    
         
            -
                    required :evaluation_id, String
         
     | 
| 
       44 
     | 
    
         
            -
             
     | 
| 
       45 
     | 
    
         
            -
                    # @!attribute event_id
         
     | 
| 
       46 
     | 
    
         
            -
                    #   A unique monitor event ID.
         
     | 
| 
       47 
     | 
    
         
            -
                    #
         
     | 
| 
       48 
     | 
    
         
            -
                    #   @return [String]
         
     | 
| 
       49 
     | 
    
         
            -
                    required :event_id, String
         
     | 
| 
       50 
     | 
    
         
            -
             
     | 
| 
       51 
     | 
    
         
            -
                    # @!attribute monitor_id
         
     | 
| 
       52 
     | 
    
         
            -
                    #   Monitor ID associated with this event.
         
     | 
| 
       53 
     | 
    
         
            -
                    #
         
     | 
| 
       54 
     | 
    
         
            -
                    #   @return [String]
         
     | 
| 
       55 
     | 
    
         
            -
                    required :monitor_id, String
         
     | 
| 
       56 
     | 
    
         
            -
             
     | 
| 
       57 
     | 
    
         
            -
                    # @!attribute created_at
         
     | 
| 
       58 
     | 
    
         
            -
                    #   The time the monitor event was created in UTC.
         
     | 
| 
       59 
     | 
    
         
            -
                    #
         
     | 
| 
       60 
     | 
    
         
            -
                    #   @return [Time, nil]
         
     | 
| 
       61 
     | 
    
         
            -
                    optional :created_at, Time
         
     | 
| 
       62 
     | 
    
         
            -
             
     | 
| 
       63 
     | 
    
         
            -
                    # @!method initialize(evaluation_id:, event_id:, monitor_id:, created_at: nil)
         
     | 
| 
       64 
     | 
    
         
            -
                    #   @param evaluation_id [String] A unique evaluation ID associated with this event.
         
     | 
| 
       65 
     | 
    
         
            -
                    #
         
     | 
| 
       66 
     | 
    
         
            -
                    #   @param event_id [String] A unique monitor event ID.
         
     | 
| 
       67 
     | 
    
         
            -
                    #
         
     | 
| 
       68 
     | 
    
         
            -
                    #   @param monitor_id [String] Monitor ID associated with this event.
         
     | 
| 
       69 
     | 
    
         
            -
                    #
         
     | 
| 
       70 
     | 
    
         
            -
                    #   @param created_at [Time] The time the monitor event was created in UTC.
         
     | 
| 
       71 
     | 
    
         
            -
                  end
         
     | 
| 
       72 
     | 
    
         
            -
                end
         
     | 
| 
       73 
     | 
    
         
            -
              end
         
     | 
| 
       74 
     | 
    
         
            -
            end
         
     | 
| 
         @@ -1,201 +0,0 @@ 
     | 
|
| 
       1 
     | 
    
         
            -
            # typed: strong
         
     | 
| 
       2 
     | 
    
         
            -
             
     | 
| 
       3 
     | 
    
         
            -
            module Deeprails
         
     | 
| 
       4 
     | 
    
         
            -
              module Models
         
     | 
| 
       5 
     | 
    
         
            -
                class APIResponse < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       6 
     | 
    
         
            -
                  OrHash =
         
     | 
| 
       7 
     | 
    
         
            -
                    T.type_alias do
         
     | 
| 
       8 
     | 
    
         
            -
                      T.any(Deeprails::APIResponse, Deeprails::Internal::AnyHash)
         
     | 
| 
       9 
     | 
    
         
            -
                    end
         
     | 
| 
       10 
     | 
    
         
            -
             
     | 
| 
       11 
     | 
    
         
            -
                  # Represents whether the request was completed successfully.
         
     | 
| 
       12 
     | 
    
         
            -
                  sig { returns(T::Boolean) }
         
     | 
| 
       13 
     | 
    
         
            -
                  attr_accessor :success
         
     | 
| 
       14 
     | 
    
         
            -
             
     | 
| 
       15 
     | 
    
         
            -
                  sig { returns(T.nilable(Deeprails::APIResponse::Data)) }
         
     | 
| 
       16 
     | 
    
         
            -
                  attr_reader :data
         
     | 
| 
       17 
     | 
    
         
            -
             
     | 
| 
       18 
     | 
    
         
            -
                  sig { params(data: Deeprails::APIResponse::Data::OrHash).void }
         
     | 
| 
       19 
     | 
    
         
            -
                  attr_writer :data
         
     | 
| 
       20 
     | 
    
         
            -
             
     | 
| 
       21 
     | 
    
         
            -
                  # The accompanying message for the request. Includes error details when
         
     | 
| 
       22 
     | 
    
         
            -
                  # applicable.
         
     | 
| 
       23 
     | 
    
         
            -
                  sig { returns(T.nilable(String)) }
         
     | 
| 
       24 
     | 
    
         
            -
                  attr_reader :message
         
     | 
| 
       25 
     | 
    
         
            -
             
     | 
| 
       26 
     | 
    
         
            -
                  sig { params(message: String).void }
         
     | 
| 
       27 
     | 
    
         
            -
                  attr_writer :message
         
     | 
| 
       28 
     | 
    
         
            -
             
     | 
| 
       29 
     | 
    
         
            -
                  # Response wrapper for operations returning a MonitorResponse.
         
     | 
| 
       30 
     | 
    
         
            -
                  sig do
         
     | 
| 
       31 
     | 
    
         
            -
                    params(
         
     | 
| 
       32 
     | 
    
         
            -
                      success: T::Boolean,
         
     | 
| 
       33 
     | 
    
         
            -
                      data: Deeprails::APIResponse::Data::OrHash,
         
     | 
| 
       34 
     | 
    
         
            -
                      message: String
         
     | 
| 
       35 
     | 
    
         
            -
                    ).returns(T.attached_class)
         
     | 
| 
       36 
     | 
    
         
            -
                  end
         
     | 
| 
       37 
     | 
    
         
            -
                  def self.new(
         
     | 
| 
       38 
     | 
    
         
            -
                    # Represents whether the request was completed successfully.
         
     | 
| 
       39 
     | 
    
         
            -
                    success:,
         
     | 
| 
       40 
     | 
    
         
            -
                    data: nil,
         
     | 
| 
       41 
     | 
    
         
            -
                    # The accompanying message for the request. Includes error details when
         
     | 
| 
       42 
     | 
    
         
            -
                    # applicable.
         
     | 
| 
       43 
     | 
    
         
            -
                    message: nil
         
     | 
| 
       44 
     | 
    
         
            -
                  )
         
     | 
| 
       45 
     | 
    
         
            -
                  end
         
     | 
| 
       46 
     | 
    
         
            -
             
     | 
| 
       47 
     | 
    
         
            -
                  sig do
         
     | 
| 
       48 
     | 
    
         
            -
                    override.returns(
         
     | 
| 
       49 
     | 
    
         
            -
                      {
         
     | 
| 
       50 
     | 
    
         
            -
                        success: T::Boolean,
         
     | 
| 
       51 
     | 
    
         
            -
                        data: Deeprails::APIResponse::Data,
         
     | 
| 
       52 
     | 
    
         
            -
                        message: String
         
     | 
| 
       53 
     | 
    
         
            -
                      }
         
     | 
| 
       54 
     | 
    
         
            -
                    )
         
     | 
| 
       55 
     | 
    
         
            -
                  end
         
     | 
| 
       56 
     | 
    
         
            -
                  def to_hash
         
     | 
| 
       57 
     | 
    
         
            -
                  end
         
     | 
| 
       58 
     | 
    
         
            -
             
     | 
| 
       59 
     | 
    
         
            -
                  class Data < Deeprails::Internal::Type::BaseModel
         
     | 
| 
       60 
     | 
    
         
            -
                    OrHash =
         
     | 
| 
       61 
     | 
    
         
            -
                      T.type_alias do
         
     | 
| 
       62 
     | 
    
         
            -
                        T.any(Deeprails::APIResponse::Data, Deeprails::Internal::AnyHash)
         
     | 
| 
       63 
     | 
    
         
            -
                      end
         
     | 
| 
       64 
     | 
    
         
            -
             
     | 
| 
       65 
     | 
    
         
            -
                    # A unique monitor ID.
         
     | 
| 
       66 
     | 
    
         
            -
                    sig { returns(String) }
         
     | 
| 
       67 
     | 
    
         
            -
                    attr_accessor :monitor_id
         
     | 
| 
       68 
     | 
    
         
            -
             
     | 
| 
       69 
     | 
    
         
            -
                    # Name of the monitor.
         
     | 
| 
       70 
     | 
    
         
            -
                    sig { returns(String) }
         
     | 
| 
       71 
     | 
    
         
            -
                    attr_accessor :name
         
     | 
| 
       72 
     | 
    
         
            -
             
     | 
| 
       73 
     | 
    
         
            -
                    # The time the monitor was created in UTC.
         
     | 
| 
       74 
     | 
    
         
            -
                    sig { returns(T.nilable(Time)) }
         
     | 
| 
       75 
     | 
    
         
            -
                    attr_reader :created_at
         
     | 
| 
       76 
     | 
    
         
            -
             
     | 
| 
       77 
     | 
    
         
            -
                    sig { params(created_at: Time).void }
         
     | 
| 
       78 
     | 
    
         
            -
                    attr_writer :created_at
         
     | 
| 
       79 
     | 
    
         
            -
             
     | 
| 
       80 
     | 
    
         
            -
                    # Description of the monitor.
         
     | 
| 
       81 
     | 
    
         
            -
                    sig { returns(T.nilable(String)) }
         
     | 
| 
       82 
     | 
    
         
            -
                    attr_reader :description
         
     | 
| 
       83 
     | 
    
         
            -
             
     | 
| 
       84 
     | 
    
         
            -
                    sig { params(description: String).void }
         
     | 
| 
       85 
     | 
    
         
            -
                    attr_writer :description
         
     | 
| 
       86 
     | 
    
         
            -
             
     | 
| 
       87 
     | 
    
         
            -
                    # Status of the monitor. Can be `active` or `inactive`. Inactive monitors no
         
     | 
| 
       88 
     | 
    
         
            -
                    # longer record and evaluate events.
         
     | 
| 
       89 
     | 
    
         
            -
                    sig do
         
     | 
| 
       90 
     | 
    
         
            -
                      returns(
         
     | 
| 
       91 
     | 
    
         
            -
                        T.nilable(Deeprails::APIResponse::Data::MonitorStatus::TaggedSymbol)
         
     | 
| 
       92 
     | 
    
         
            -
                      )
         
     | 
| 
       93 
     | 
    
         
            -
                    end
         
     | 
| 
       94 
     | 
    
         
            -
                    attr_reader :monitor_status
         
     | 
| 
       95 
     | 
    
         
            -
             
     | 
| 
       96 
     | 
    
         
            -
                    sig do
         
     | 
| 
       97 
     | 
    
         
            -
                      params(
         
     | 
| 
       98 
     | 
    
         
            -
                        monitor_status:
         
     | 
| 
       99 
     | 
    
         
            -
                          Deeprails::APIResponse::Data::MonitorStatus::OrSymbol
         
     | 
| 
       100 
     | 
    
         
            -
                      ).void
         
     | 
| 
       101 
     | 
    
         
            -
                    end
         
     | 
| 
       102 
     | 
    
         
            -
                    attr_writer :monitor_status
         
     | 
| 
       103 
     | 
    
         
            -
             
     | 
| 
       104 
     | 
    
         
            -
                    # The most recent time the monitor was modified in UTC.
         
     | 
| 
       105 
     | 
    
         
            -
                    sig { returns(T.nilable(Time)) }
         
     | 
| 
       106 
     | 
    
         
            -
                    attr_reader :updated_at
         
     | 
| 
       107 
     | 
    
         
            -
             
     | 
| 
       108 
     | 
    
         
            -
                    sig { params(updated_at: Time).void }
         
     | 
| 
       109 
     | 
    
         
            -
                    attr_writer :updated_at
         
     | 
| 
       110 
     | 
    
         
            -
             
     | 
| 
       111 
     | 
    
         
            -
                    # User ID of the user who created the monitor.
         
     | 
| 
       112 
     | 
    
         
            -
                    sig { returns(T.nilable(String)) }
         
     | 
| 
       113 
     | 
    
         
            -
                    attr_reader :user_id
         
     | 
| 
       114 
     | 
    
         
            -
             
     | 
| 
       115 
     | 
    
         
            -
                    sig { params(user_id: String).void }
         
     | 
| 
       116 
     | 
    
         
            -
                    attr_writer :user_id
         
     | 
| 
       117 
     | 
    
         
            -
             
     | 
| 
       118 
     | 
    
         
            -
                    sig do
         
     | 
| 
       119 
     | 
    
         
            -
                      params(
         
     | 
| 
       120 
     | 
    
         
            -
                        monitor_id: String,
         
     | 
| 
       121 
     | 
    
         
            -
                        name: String,
         
     | 
| 
       122 
     | 
    
         
            -
                        created_at: Time,
         
     | 
| 
       123 
     | 
    
         
            -
                        description: String,
         
     | 
| 
       124 
     | 
    
         
            -
                        monitor_status:
         
     | 
| 
       125 
     | 
    
         
            -
                          Deeprails::APIResponse::Data::MonitorStatus::OrSymbol,
         
     | 
| 
       126 
     | 
    
         
            -
                        updated_at: Time,
         
     | 
| 
       127 
     | 
    
         
            -
                        user_id: String
         
     | 
| 
       128 
     | 
    
         
            -
                      ).returns(T.attached_class)
         
     | 
| 
       129 
     | 
    
         
            -
                    end
         
     | 
| 
       130 
     | 
    
         
            -
                    def self.new(
         
     | 
| 
       131 
     | 
    
         
            -
                      # A unique monitor ID.
         
     | 
| 
       132 
     | 
    
         
            -
                      monitor_id:,
         
     | 
| 
       133 
     | 
    
         
            -
                      # Name of the monitor.
         
     | 
| 
       134 
     | 
    
         
            -
                      name:,
         
     | 
| 
       135 
     | 
    
         
            -
                      # The time the monitor was created in UTC.
         
     | 
| 
       136 
     | 
    
         
            -
                      created_at: nil,
         
     | 
| 
       137 
     | 
    
         
            -
                      # Description of the monitor.
         
     | 
| 
       138 
     | 
    
         
            -
                      description: nil,
         
     | 
| 
       139 
     | 
    
         
            -
                      # Status of the monitor. Can be `active` or `inactive`. Inactive monitors no
         
     | 
| 
       140 
     | 
    
         
            -
                      # longer record and evaluate events.
         
     | 
| 
       141 
     | 
    
         
            -
                      monitor_status: nil,
         
     | 
| 
       142 
     | 
    
         
            -
                      # The most recent time the monitor was modified in UTC.
         
     | 
| 
       143 
     | 
    
         
            -
                      updated_at: nil,
         
     | 
| 
       144 
     | 
    
         
            -
                      # User ID of the user who created the monitor.
         
     | 
| 
       145 
     | 
    
         
            -
                      user_id: nil
         
     | 
| 
       146 
     | 
    
         
            -
                    )
         
     | 
| 
       147 
     | 
    
         
            -
                    end
         
     | 
| 
       148 
     | 
    
         
            -
             
     | 
| 
       149 
     | 
    
         
            -
                    sig do
         
     | 
| 
       150 
     | 
    
         
            -
                      override.returns(
         
     | 
| 
       151 
     | 
    
         
            -
                        {
         
     | 
| 
       152 
     | 
    
         
            -
                          monitor_id: String,
         
     | 
| 
       153 
     | 
    
         
            -
                          name: String,
         
     | 
| 
       154 
     | 
    
         
            -
                          created_at: Time,
         
     | 
| 
       155 
     | 
    
         
            -
                          description: String,
         
     | 
| 
       156 
     | 
    
         
            -
                          monitor_status:
         
     | 
| 
       157 
     | 
    
         
            -
                            Deeprails::APIResponse::Data::MonitorStatus::TaggedSymbol,
         
     | 
| 
       158 
     | 
    
         
            -
                          updated_at: Time,
         
     | 
| 
       159 
     | 
    
         
            -
                          user_id: String
         
     | 
| 
       160 
     | 
    
         
            -
                        }
         
     | 
| 
       161 
     | 
    
         
            -
                      )
         
     | 
| 
       162 
     | 
    
         
            -
                    end
         
     | 
| 
       163 
     | 
    
         
            -
                    def to_hash
         
     | 
| 
       164 
     | 
    
         
            -
                    end
         
     | 
| 
       165 
     | 
    
         
            -
             
     | 
| 
       166 
     | 
    
         
            -
                    # Status of the monitor. Can be `active` or `inactive`. Inactive monitors no
         
     | 
| 
       167 
     | 
    
         
            -
                    # longer record and evaluate events.
         
     | 
| 
       168 
     | 
    
         
            -
                    module MonitorStatus
         
     | 
| 
       169 
     | 
    
         
            -
                      extend Deeprails::Internal::Type::Enum
         
     | 
| 
       170 
     | 
    
         
            -
             
     | 
| 
       171 
     | 
    
         
            -
                      TaggedSymbol =
         
     | 
| 
       172 
     | 
    
         
            -
                        T.type_alias do
         
     | 
| 
       173 
     | 
    
         
            -
                          T.all(Symbol, Deeprails::APIResponse::Data::MonitorStatus)
         
     | 
| 
       174 
     | 
    
         
            -
                        end
         
     | 
| 
       175 
     | 
    
         
            -
                      OrSymbol = T.type_alias { T.any(Symbol, String) }
         
     | 
| 
       176 
     | 
    
         
            -
             
     | 
| 
       177 
     | 
    
         
            -
                      ACTIVE =
         
     | 
| 
       178 
     | 
    
         
            -
                        T.let(
         
     | 
| 
       179 
     | 
    
         
            -
                          :active,
         
     | 
| 
       180 
     | 
    
         
            -
                          Deeprails::APIResponse::Data::MonitorStatus::TaggedSymbol
         
     | 
| 
       181 
     | 
    
         
            -
                        )
         
     | 
| 
       182 
     | 
    
         
            -
                      INACTIVE =
         
     | 
| 
       183 
     | 
    
         
            -
                        T.let(
         
     | 
| 
       184 
     | 
    
         
            -
                          :inactive,
         
     | 
| 
       185 
     | 
    
         
            -
                          Deeprails::APIResponse::Data::MonitorStatus::TaggedSymbol
         
     | 
| 
       186 
     | 
    
         
            -
                        )
         
     | 
| 
       187 
     | 
    
         
            -
             
     | 
| 
       188 
     | 
    
         
            -
                      sig do
         
     | 
| 
       189 
     | 
    
         
            -
                        override.returns(
         
     | 
| 
       190 
     | 
    
         
            -
                          T::Array[
         
     | 
| 
       191 
     | 
    
         
            -
                            Deeprails::APIResponse::Data::MonitorStatus::TaggedSymbol
         
     | 
| 
       192 
     | 
    
         
            -
                          ]
         
     | 
| 
       193 
     | 
    
         
            -
                        )
         
     | 
| 
       194 
     | 
    
         
            -
                      end
         
     | 
| 
       195 
     | 
    
         
            -
                      def self.values
         
     | 
| 
       196 
     | 
    
         
            -
                      end
         
     | 
| 
       197 
     | 
    
         
            -
                    end
         
     | 
| 
       198 
     | 
    
         
            -
                  end
         
     | 
| 
       199 
     | 
    
         
            -
                end
         
     | 
| 
       200 
     | 
    
         
            -
              end
         
     | 
| 
       201 
     | 
    
         
            -
            end
         
     |