Class: DatadogAPIClient::V1::SyntheticsTestRequest

Inherits:
Object
  • Object
show all
Defined in:
lib/datadog_api_client/v1/models/synthetics_test_request.rb

Overview

Object describing the Synthetic test request.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ SyntheticsTestRequest

Initializes the object

Parameters:

  • attributes (Hash) (defaults to: {})

    attributes Model attributes in the form of hash



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
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 151

def initialize(attributes = {})
  if (!attributes.is_a?(Hash))
    fail ArgumentError, "The input argument (attributes) must be a hash in `DatadogAPIClient::V1::SyntheticsTestRequest` initialize method"
  end

  # check to see if the attribute exists and convert string to symbol for hash key
  attributes = attributes.each_with_object({}) { |(k, v), h|
    if (!self.class.attribute_map.key?(k.to_sym))
      fail ArgumentError, "`#{k}` is not a valid attribute in `DatadogAPIClient::V1::SyntheticsTestRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
    end
    h[k.to_sym] = v
  }

  if attributes.key?(:'allow_insecure')
    self.allow_insecure = attributes[:'allow_insecure']
  end

  if attributes.key?(:'basic_auth')
    self.basic_auth = attributes[:'basic_auth']
  end

  if attributes.key?(:'body')
    self.body = attributes[:'body']
  end

  if attributes.key?(:'certificate')
    self.certificate = attributes[:'certificate']
  end

  if attributes.key?(:'dns_server')
    self.dns_server = attributes[:'dns_server']
  end

  if attributes.key?(:'dns_server_port')
    self.dns_server_port = attributes[:'dns_server_port']
  end

  if attributes.key?(:'follow_redirects')
    self.follow_redirects = attributes[:'follow_redirects']
  end

  if attributes.key?(:'headers')
    if (value = attributes[:'headers']).is_a?(Hash)
      self.headers = value
    end
  end

  if attributes.key?(:'host')
    self.host = attributes[:'host']
  end

  if attributes.key?(:'message')
    self.message = attributes[:'message']
  end

  if attributes.key?(:'method')
    self.method = attributes[:'method']
  end

  if attributes.key?(:'no_saving_response_body')
    self.no_saving_response_body = attributes[:'no_saving_response_body']
  end

  if attributes.key?(:'number_of_packets')
    self.number_of_packets = attributes[:'number_of_packets']
  end

  if attributes.key?(:'port')
    self.port = attributes[:'port']
  end

  if attributes.key?(:'proxy')
    self.proxy = attributes[:'proxy']
  end

  if attributes.key?(:'query')
    self.query = attributes[:'query']
  end

  if attributes.key?(:'servername')
    self.servername = attributes[:'servername']
  end

  if attributes.key?(:'should_track_hops')
    self.should_track_hops = attributes[:'should_track_hops']
  end

  if attributes.key?(:'timeout')
    self.timeout = attributes[:'timeout']
  end

  if attributes.key?(:'url')
    self.url = attributes[:'url']
  end
end

Instance Attribute Details

#allow_insecureObject

Allows loading insecure content for an HTTP request in a multistep test step.



27
28
29
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 27

def allow_insecure
  @allow_insecure
end

#basic_authObject

Returns the value of attribute basic_auth.



29
30
31
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 29

def basic_auth
  @basic_auth
end

#bodyObject

Body to include in the test.



32
33
34
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 32

def body
  @body
end

#certificateObject

Returns the value of attribute certificate.



34
35
36
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 34

def certificate
  @certificate
end

#dns_serverObject

DNS server to use for DNS tests.



37
38
39
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 37

def dns_server
  @dns_server
end

#dns_server_portObject

DNS server port to use for DNS tests.



40
41
42
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 40

def dns_server_port
  @dns_server_port
end

#follow_redirectsObject

Specifies whether or not the request follows redirects.



43
44
45
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 43

def follow_redirects
  @follow_redirects
end

#headersObject

Headers to include when performing the test.



46
47
48
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 46

def headers
  @headers
end

#hostObject

Host name to perform the test with.



49
50
51
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 49

def host
  @host
end

#messageObject

Message to send for UDP or WebSocket tests.



52
53
54
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 52

def message
  @message
end

#methodObject

Returns the value of attribute method.



54
55
56
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 54

def method
  @method
end

#no_saving_response_bodyObject

Determines whether or not to save the response body.



57
58
59
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 57

def no_saving_response_body
  @no_saving_response_body
end

#number_of_packetsObject

Number of pings to use per test.



60
61
62
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 60

def number_of_packets
  @number_of_packets
end

#portObject

Port to use when performing the test.



63
64
65
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 63

def port
  @port
end

#proxyObject

Returns the value of attribute proxy.



65
66
67
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 65

def proxy
  @proxy
end

#queryObject

Query to use for the test.



68
69
70
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 68

def query
  @query
end

#servernameObject

For SSL tests, it specifies on which server you want to initiate the TLS handshake, allowing the server to present one of multiple possible certificates on the same IP address and TCP port number.



71
72
73
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 71

def servername
  @servername
end

#should_track_hopsObject

Turns on a traceroute probe to discover all gateways along the path to the host destination.



74
75
76
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 74

def should_track_hops
  @should_track_hops
end

#timeoutObject

Timeout in seconds for the test.



77
78
79
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 77

def timeout
  @timeout
end

#urlObject

URL to perform the test with.



80
81
82
# File 'lib/datadog_api_client/v1/models/synthetics_test_request.rb', line 80

def url
  @url
end