Class: Spatio::SettingsApi

Inherits:
Object
  • Object
show all
Defined in:
lib/spatio-sdk/api/settings_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ SettingsApi

Returns a new instance of SettingsApi.



19
20
21
# File 'lib/spatio-sdk/api/settings_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/spatio-sdk/api/settings_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#bulk_update_settings(request_body, opts = {}) ⇒ Hash<String, Object>

Bulk-update multiple settings rows in one round-trip.

Parameters:

  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Hash<String, Object>)


26
27
28
29
# File 'lib/spatio-sdk/api/settings_api.rb', line 26

def bulk_update_settings(request_body, opts = {})
  data, _status_code, _headers = bulk_update_settings_with_http_info(request_body, opts)
  data
end

#bulk_update_settings_with_http_info(request_body, opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Bulk-update multiple settings rows in one round-trip.

Parameters:

  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



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
# File 'lib/spatio-sdk/api/settings_api.rb', line 35

def bulk_update_settings_with_http_info(request_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.bulk_update_settings ...'
  end
  # verify the required parameter 'request_body' is set
  if @api_client.config.client_side_validation && request_body.nil?
    fail ArgumentError, "Missing the required parameter 'request_body' when calling SettingsApi.bulk_update_settings"
  end
  # resource path
  local_var_path = '/v1/settings/bulk-update'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(['application/json'])
  if !content_type.nil?
      header_params['Content-Type'] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.bulk_update_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#bulk_update_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_current_user_settings(opts = {}) ⇒ nil

Reset the caller’s user-level settings.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


91
92
93
94
# File 'lib/spatio-sdk/api/settings_api.rb', line 91

def (opts = {})
  (opts)
  nil
end

#delete_current_user_settings_with_http_info(opts = {}) ⇒ Array<(nil, Integer, Hash)>

Reset the caller&#39;s user-level settings.

Parameters:

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

    the optional parameters

Returns:

  • (Array<(nil, Integer, Hash)>)

    nil, response status code and response headers



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
# File 'lib/spatio-sdk/api/settings_api.rb', line 99

def (opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.delete_current_user_settings ...'
  end
  # resource path
  local_var_path = '/v1/settings'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type]

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.delete_current_user_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#delete_current_user_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_current_user_settings(opts = {}) ⇒ Hash<String, Object>

Fetch the caller’s user-level settings.

Parameters:

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

    the optional parameters

Returns:

  • (Hash<String, Object>)


146
147
148
149
# File 'lib/spatio-sdk/api/settings_api.rb', line 146

def (opts = {})
  data, _status_code, _headers = (opts)
  data
end

#get_current_user_settings_with_http_info(opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Fetch the caller&#39;s user-level settings.

Parameters:

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

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



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
# File 'lib/spatio-sdk/api/settings_api.rb', line 154

def (opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.get_current_user_settings ...'
  end
  # resource path
  local_var_path = '/v1/settings'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.get_current_user_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#get_current_user_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_mail_read_receipts_pref(opts = {}) ⇒ Hash<String, Object>

Read the caller’s mail-read-receipts preference.

Parameters:

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

    the optional parameters

Returns:

  • (Hash<String, Object>)


201
202
203
204
# File 'lib/spatio-sdk/api/settings_api.rb', line 201

def get_mail_read_receipts_pref(opts = {})
  data, _status_code, _headers = get_mail_read_receipts_pref_with_http_info(opts)
  data
end

#get_mail_read_receipts_pref_with_http_info(opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Read the caller&#39;s mail-read-receipts preference.

Parameters:

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

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



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
246
247
248
249
250
251
# File 'lib/spatio-sdk/api/settings_api.rb', line 209

def get_mail_read_receipts_pref_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.get_mail_read_receipts_pref ...'
  end
  # resource path
  local_var_path = '/v1/me/preferences/mail-read-receipts'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.get_mail_read_receipts_pref",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#get_mail_read_receipts_pref\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_settings_permissions(opts = {}) ⇒ Hash<String, Object>

Read the caller’s settings-write permissions matrix.

Parameters:

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

    the optional parameters

Returns:

  • (Hash<String, Object>)


256
257
258
259
# File 'lib/spatio-sdk/api/settings_api.rb', line 256

def get_settings_permissions(opts = {})
  data, _status_code, _headers = get_settings_permissions_with_http_info(opts)
  data
end

#get_settings_permissions_with_http_info(opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Read the caller&#39;s settings-write permissions matrix.

Parameters:

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

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
# File 'lib/spatio-sdk/api/settings_api.rb', line 264

def get_settings_permissions_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.get_settings_permissions ...'
  end
  # resource path
  local_var_path = '/v1/settings/permissions'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.get_settings_permissions",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#get_settings_permissions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_user_settings(user_id, opts = {}) ⇒ Hash<String, Object>

Fetch a specific user’s settings (admin / self only).

Parameters:

  • user_id (String)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Hash<String, Object>)


312
313
314
315
# File 'lib/spatio-sdk/api/settings_api.rb', line 312

def (user_id, opts = {})
  data, _status_code, _headers = (user_id, opts)
  data
end

#get_user_settings_with_http_info(user_id, opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Fetch a specific user&#39;s settings (admin / self only).

Parameters:

  • user_id (String)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
# File 'lib/spatio-sdk/api/settings_api.rb', line 321

def (user_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.get_user_settings ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling SettingsApi.get_user_settings"
  end
  # resource path
  local_var_path = '/v1/settings/user/{userId}'.sub('{userId}', CGI.escape(user_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.get_user_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#get_user_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_workspace_settings(workspace_id, opts = {}) ⇒ Hash<String, Object>

Fetch workspace-level settings.

Parameters:

  • workspace_id (String)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Hash<String, Object>)


373
374
375
376
# File 'lib/spatio-sdk/api/settings_api.rb', line 373

def get_workspace_settings(workspace_id, opts = {})
  data, _status_code, _headers = get_workspace_settings_with_http_info(workspace_id, opts)
  data
end

#get_workspace_settings_with_http_info(workspace_id, opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Fetch workspace-level settings.

Parameters:

  • workspace_id (String)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
# File 'lib/spatio-sdk/api/settings_api.rb', line 382

def get_workspace_settings_with_http_info(workspace_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.get_workspace_settings ...'
  end
  # verify the required parameter 'workspace_id' is set
  if @api_client.config.client_side_validation && workspace_id.nil?
    fail ArgumentError, "Missing the required parameter 'workspace_id' when calling SettingsApi.get_workspace_settings"
  end
  # resource path
  local_var_path = '/v1/settings/workspace/{workspaceId}'.sub('{workspaceId}', CGI.escape(workspace_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.get_workspace_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#get_workspace_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_current_user_settings(request_body, opts = {}) ⇒ Hash<String, Object>

Replace the caller’s user-level settings.

Parameters:

  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Hash<String, Object>)


434
435
436
437
# File 'lib/spatio-sdk/api/settings_api.rb', line 434

def (request_body, opts = {})
  data, _status_code, _headers = (request_body, opts)
  data
end

#put_current_user_settings_with_http_info(request_body, opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Replace the caller&#39;s user-level settings.

Parameters:

  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
# File 'lib/spatio-sdk/api/settings_api.rb', line 443

def (request_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.put_current_user_settings ...'
  end
  # verify the required parameter 'request_body' is set
  if @api_client.config.client_side_validation && request_body.nil?
    fail ArgumentError, "Missing the required parameter 'request_body' when calling SettingsApi.put_current_user_settings"
  end
  # resource path
  local_var_path = '/v1/settings'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(['application/json'])
  if !content_type.nil?
      header_params['Content-Type'] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.put_current_user_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#put_current_user_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_mail_read_receipts_pref(request_body, opts = {}) ⇒ nil

Update the caller’s mail-read-receipts preference.

Parameters:

  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (nil)


500
501
502
503
# File 'lib/spatio-sdk/api/settings_api.rb', line 500

def put_mail_read_receipts_pref(request_body, opts = {})
  put_mail_read_receipts_pref_with_http_info(request_body, opts)
  nil
end

#put_mail_read_receipts_pref_with_http_info(request_body, opts = {}) ⇒ Array<(nil, Integer, Hash)>

Update the caller&#39;s mail-read-receipts preference.

Parameters:

  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(nil, Integer, Hash)>)

    nil, response status code and response headers



509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
# File 'lib/spatio-sdk/api/settings_api.rb', line 509

def put_mail_read_receipts_pref_with_http_info(request_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.put_mail_read_receipts_pref ...'
  end
  # verify the required parameter 'request_body' is set
  if @api_client.config.client_side_validation && request_body.nil?
    fail ArgumentError, "Missing the required parameter 'request_body' when calling SettingsApi.put_mail_read_receipts_pref"
  end
  # resource path
  local_var_path = '/v1/me/preferences/mail-read-receipts'

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(['application/json'])
  if !content_type.nil?
      header_params['Content-Type'] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)

  # return_type
  return_type = opts[:debug_return_type]

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.put_mail_read_receipts_pref",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#put_mail_read_receipts_pref\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_user_settings(user_id, request_body, opts = {}) ⇒ Hash<String, Object>

Replace a specific user’s settings.

Parameters:

  • user_id (String)
  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Hash<String, Object>)


567
568
569
570
# File 'lib/spatio-sdk/api/settings_api.rb', line 567

def (user_id, request_body, opts = {})
  data, _status_code, _headers = (user_id, request_body, opts)
  data
end

#put_user_settings_with_http_info(user_id, request_body, opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Replace a specific user&#39;s settings.

Parameters:

  • user_id (String)
  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
# File 'lib/spatio-sdk/api/settings_api.rb', line 577

def (user_id, request_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.put_user_settings ...'
  end
  # verify the required parameter 'user_id' is set
  if @api_client.config.client_side_validation && user_id.nil?
    fail ArgumentError, "Missing the required parameter 'user_id' when calling SettingsApi.put_user_settings"
  end
  # verify the required parameter 'request_body' is set
  if @api_client.config.client_side_validation && request_body.nil?
    fail ArgumentError, "Missing the required parameter 'request_body' when calling SettingsApi.put_user_settings"
  end
  # resource path
  local_var_path = '/v1/settings/user/{userId}'.sub('{userId}', CGI.escape(user_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(['application/json'])
  if !content_type.nil?
      header_params['Content-Type'] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.put_user_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#put_user_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_workspace_settings(workspace_id, request_body, opts = {}) ⇒ Hash<String, Object>

Replace workspace-level settings.

Parameters:

  • workspace_id (String)
  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Hash<String, Object>)


639
640
641
642
# File 'lib/spatio-sdk/api/settings_api.rb', line 639

def put_workspace_settings(workspace_id, request_body, opts = {})
  data, _status_code, _headers = put_workspace_settings_with_http_info(workspace_id, request_body, opts)
  data
end

#put_workspace_settings_with_http_info(workspace_id, request_body, opts = {}) ⇒ Array<(Hash<String, Object>, Integer, Hash)>

Replace workspace-level settings.

Parameters:

  • workspace_id (String)
  • request_body (Hash<String, Object>)
  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Hash<String, Object>, Integer, Hash)>)

    Hash<String, Object> data, response status code and response headers



649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
# File 'lib/spatio-sdk/api/settings_api.rb', line 649

def put_workspace_settings_with_http_info(workspace_id, request_body, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: SettingsApi.put_workspace_settings ...'
  end
  # verify the required parameter 'workspace_id' is set
  if @api_client.config.client_side_validation && workspace_id.nil?
    fail ArgumentError, "Missing the required parameter 'workspace_id' when calling SettingsApi.put_workspace_settings"
  end
  # verify the required parameter 'request_body' is set
  if @api_client.config.client_side_validation && request_body.nil?
    fail ArgumentError, "Missing the required parameter 'request_body' when calling SettingsApi.put_workspace_settings"
  end
  # resource path
  local_var_path = '/v1/settings/workspace/{workspaceId}'.sub('{workspaceId}', CGI.escape(workspace_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(['application/json'])
  if !content_type.nil?
      header_params['Content-Type'] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(request_body)

  # return_type
  return_type = opts[:debug_return_type] || 'Hash<String, Object>'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['bearerAuth']

  new_options = opts.merge(
    :operation => :"SettingsApi.put_workspace_settings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: SettingsApi#put_workspace_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end