Class: Zernio::WhatsAppFlowsApi

Inherits:
Object
  • Object
show all
Defined in:
lib/zernio-sdk/api/whats_app_flows_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ WhatsAppFlowsApi

Returns a new instance of WhatsAppFlowsApi.



19
20
21
# File 'lib/zernio-sdk/api/whats_app_flows_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/zernio-sdk/api/whats_app_flows_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#create_whats_app_flow(create_whats_app_flow_request, opts = {}) ⇒ CreateWhatsAppFlow200Response

Create flow Create a new WhatsApp Flow in DRAFT status. Optionally clone an existing flow. After creating, upload a Flow JSON definition, then publish to make it sendable.

Parameters:

Returns:



27
28
29
30
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 27

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

#create_whats_app_flow_with_http_info(create_whats_app_flow_request, opts = {}) ⇒ Array<(CreateWhatsAppFlow200Response, Integer, Hash)>

Create flow Create a new WhatsApp Flow in DRAFT status. Optionally clone an existing flow. After creating, upload a Flow JSON definition, then publish to make it sendable.

Parameters:

Returns:



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
87
88
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 37

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

  # 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(create_whats_app_flow_request)

  # return_type
  return_type = opts[:debug_return_type] || 'CreateWhatsAppFlow200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.create_whats_app_flow",
    :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: WhatsAppFlowsApi#create_whats_app_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_whats_app_flow(flow_id, account_id, opts = {}) ⇒ UpdateYoutubeDefaultPlaylist200Response

Delete flow Delete a DRAFT flow. This is irreversible. Only flows in DRAFT status can be deleted.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



96
97
98
99
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 96

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

#delete_whats_app_flow_with_http_info(flow_id, account_id, opts = {}) ⇒ Array<(UpdateYoutubeDefaultPlaylist200Response, Integer, Hash)>

Delete flow Delete a DRAFT flow. This is irreversible. Only flows in DRAFT status can be deleted.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



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
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 107

def delete_whats_app_flow_with_http_info(flow_id, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.delete_whats_app_flow ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.delete_whats_app_flow"
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling WhatsAppFlowsApi.delete_whats_app_flow"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}'.sub('{' + 'flowId' + '}', CGI.escape(flow_id.to_s))

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

  # 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] || 'UpdateYoutubeDefaultPlaylist200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.delete_whats_app_flow",
    :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: WhatsAppFlowsApi#delete_whats_app_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#deprecate_whats_app_flow(flow_id, delete_whatsapp_business_username_request, opts = {}) ⇒ UpdateYoutubeDefaultPlaylist200Response

Deprecate flow Deprecate a PUBLISHED flow. This is irreversible. Deprecated flows cannot be sent or opened, but existing active sessions may continue until they complete.

Parameters:

Returns:



166
167
168
169
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 166

def deprecate_whats_app_flow(flow_id, delete_whatsapp_business_username_request, opts = {})
  data, _status_code, _headers = deprecate_whats_app_flow_with_http_info(flow_id, delete_whatsapp_business_username_request, opts)
  data
end

#deprecate_whats_app_flow_with_http_info(flow_id, delete_whatsapp_business_username_request, opts = {}) ⇒ Array<(UpdateYoutubeDefaultPlaylist200Response, Integer, Hash)>

Deprecate flow Deprecate a PUBLISHED flow. This is irreversible. Deprecated flows cannot be sent or opened, but existing active sessions may continue until they complete.

Parameters:

Returns:



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
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 177

def deprecate_whats_app_flow_with_http_info(flow_id, delete_whatsapp_business_username_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.deprecate_whats_app_flow ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.deprecate_whats_app_flow"
  end
  # verify the required parameter 'delete_whatsapp_business_username_request' is set
  if @api_client.config.client_side_validation && delete_whatsapp_business_username_request.nil?
    fail ArgumentError, "Missing the required parameter 'delete_whatsapp_business_username_request' when calling WhatsAppFlowsApi.deprecate_whats_app_flow"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}/deprecate'.sub('{' + 'flowId' + '}', CGI.escape(flow_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(delete_whatsapp_business_username_request)

  # return_type
  return_type = opts[:debug_return_type] || 'UpdateYoutubeDefaultPlaylist200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.deprecate_whats_app_flow",
    :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: WhatsAppFlowsApi#deprecate_whats_app_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_whats_app_flow(flow_id, account_id, opts = {}) ⇒ GetWhatsAppFlow200Response

Get flow Get details for a specific flow, including status, categories, validation errors, and preview URL.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Options Hash (opts):

  • :fields (String)

    Comma-separated fields to return (default: id,name,status,categories,validation_errors,json_version,preview,data_api_version,endpoint_uri)

Returns:



241
242
243
244
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 241

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

#get_whats_app_flow_json(flow_id, account_id, opts = {}) ⇒ GetWhatsAppFlowJson200Response

Get flow JSON asset Get the flow JSON asset metadata, including a temporary download URL for the Flow JSON file.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



313
314
315
316
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 313

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

#get_whats_app_flow_json_with_http_info(flow_id, account_id, opts = {}) ⇒ Array<(GetWhatsAppFlowJson200Response, Integer, Hash)>

Get flow JSON asset Get the flow JSON asset metadata, including a temporary download URL for the Flow JSON file.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



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
368
369
370
371
372
373
374
375
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 324

def get_whats_app_flow_json_with_http_info(flow_id, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.get_whats_app_flow_json ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.get_whats_app_flow_json"
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling WhatsAppFlowsApi.get_whats_app_flow_json"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}/json'.sub('{' + 'flowId' + '}', CGI.escape(flow_id.to_s))

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

  # 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] || 'GetWhatsAppFlowJson200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.get_whats_app_flow_json",
    :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: WhatsAppFlowsApi#get_whats_app_flow_json\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_whats_app_flow_preview(flow_id, account_id, opts = {}) ⇒ GetWhatsAppFlowPreview200Response

Get flow preview URL Get Meta's public web-preview URL for a flow (drafts included), embeddable as an interactive iframe. The link is reused across calls (valid ~30 days); pass invalidate=true to mint a fresh one (the previous link stops working).

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Options Hash (opts):

  • :invalidate (Boolean)

    Mint a fresh preview link (default false)

Returns:



384
385
386
387
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 384

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

#get_whats_app_flow_preview_with_http_info(flow_id, account_id, opts = {}) ⇒ Array<(GetWhatsAppFlowPreview200Response, Integer, Hash)>

Get flow preview URL Get Meta's public web-preview URL for a flow (drafts included), embeddable as an interactive iframe. The link is reused across calls (valid ~30 days); pass invalidate=true to mint a fresh one (the previous link stops working).

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Options Hash (opts):

  • :invalidate (Boolean)

    Mint a fresh preview link (default false)

Returns:



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
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 396

def get_whats_app_flow_preview_with_http_info(flow_id, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.get_whats_app_flow_preview ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.get_whats_app_flow_preview"
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling WhatsAppFlowsApi.get_whats_app_flow_preview"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}/preview'.sub('{' + 'flowId' + '}', CGI.escape(flow_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'accountId'] = 
  query_params[:'invalidate'] = opts[:'invalidate'] if !opts[:'invalidate'].nil?

  # 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] || 'GetWhatsAppFlowPreview200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.get_whats_app_flow_preview",
    :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: WhatsAppFlowsApi#get_whats_app_flow_preview\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_whats_app_flow_with_http_info(flow_id, account_id, opts = {}) ⇒ Array<(GetWhatsAppFlow200Response, Integer, Hash)>

Get flow Get details for a specific flow, including status, categories, validation errors, and preview URL.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Options Hash (opts):

  • :fields (String)

    Comma-separated fields to return (default: id,name,status,categories,validation_errors,json_version,preview,data_api_version,endpoint_uri)

Returns:

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

    GetWhatsAppFlow200Response data, response status code and response headers



253
254
255
256
257
258
259
260
261
262
263
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
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 253

def get_whats_app_flow_with_http_info(flow_id, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.get_whats_app_flow ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.get_whats_app_flow"
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling WhatsAppFlowsApi.get_whats_app_flow"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}'.sub('{' + 'flowId' + '}', CGI.escape(flow_id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'accountId'] = 
  query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil?

  # 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] || 'GetWhatsAppFlow200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.get_whats_app_flow",
    :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: WhatsAppFlowsApi#get_whats_app_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_whats_app_flow_responses(account_id, opts = {}) ⇒ ListWhatsAppFlowResponses200Response

List flow responses List the responses customers submitted when completing a flow (parsed from the nfm_reply messages received via webhook), newest first. Scope to a single flow with flowId — this matches responses whose flow_token carries the <flowId>: prefix that Zernio stamps on auto-generated tokens at send time. Responses sent with a custom integrator-supplied flow_token are not attributed to a flow.

Parameters:

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Options Hash (opts):

  • :flow_id (String)

    Scope to responses for this flow

  • :limit (Integer)

    Max responses to return (default to 50)

Returns:



457
458
459
460
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 457

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

#list_whats_app_flow_responses_with_http_info(account_id, opts = {}) ⇒ Array<(ListWhatsAppFlowResponses200Response, Integer, Hash)>

List flow responses List the responses customers submitted when completing a flow (parsed from the nfm_reply messages received via webhook), newest first. Scope to a single flow with `flowId` — this matches responses whose flow_token carries the `<flowId>:` prefix that Zernio stamps on auto-generated tokens at send time. Responses sent with a custom integrator-supplied flow_token are not attributed to a flow.

Parameters:

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Options Hash (opts):

  • :flow_id (String)

    Scope to responses for this flow

  • :limit (Integer)

    Max responses to return (default to 50)

Returns:



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
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 469

def list_whats_app_flow_responses_with_http_info(, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.list_whats_app_flow_responses ...'
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling WhatsAppFlowsApi.list_whats_app_flow_responses"
  end
  if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 200
    fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling WhatsAppFlowsApi.list_whats_app_flow_responses, must be smaller than or equal to 200.'
  end

  # resource path
  local_var_path = '/v1/whatsapp/flow-responses'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'accountId'] = 
  query_params[:'flowId'] = opts[:'flow_id'] if !opts[:'flow_id'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?

  # 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] || 'ListWhatsAppFlowResponses200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.list_whats_app_flow_responses",
    :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: WhatsAppFlowsApi#list_whats_app_flow_responses\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_whats_app_flow_versions(flow_id, account_id, opts = {}) ⇒ ListWhatsAppFlowVersions200Response

List flow versions List the flow's version history (the clone lineage Zernio tracks, since Meta has no native versioning), newest version first. Each entry is enriched with the version's live name and status from Meta. A flow with no lineage returns just itself as version 1.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



530
531
532
533
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 530

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

#list_whats_app_flow_versions_with_http_info(flow_id, account_id, opts = {}) ⇒ Array<(ListWhatsAppFlowVersions200Response, Integer, Hash)>

List flow versions List the flow's version history (the clone lineage Zernio tracks, since Meta has no native versioning), newest version first. Each entry is enriched with the version's live name and status from Meta. A flow with no lineage returns just itself as version 1.

Parameters:

  • flow_id (String)

    Flow ID

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 541

def list_whats_app_flow_versions_with_http_info(flow_id, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.list_whats_app_flow_versions ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.list_whats_app_flow_versions"
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling WhatsAppFlowsApi.list_whats_app_flow_versions"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}/versions'.sub('{' + 'flowId' + '}', CGI.escape(flow_id.to_s))

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

  # 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] || 'ListWhatsAppFlowVersions200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.list_whats_app_flow_versions",
    :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: WhatsAppFlowsApi#list_whats_app_flow_versions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#list_whats_app_flows(account_id, opts = {}) ⇒ ListWhatsAppFlows200Response

List flows List all WhatsApp Flows for the Business Account (WABA) associated with the given account.

Parameters:

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



599
600
601
602
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 599

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

#list_whats_app_flows_with_http_info(account_id, opts = {}) ⇒ Array<(ListWhatsAppFlows200Response, Integer, Hash)>

List flows List all WhatsApp Flows for the Business Account (WABA) associated with the given account.

Parameters:

  • account_id (String)

    WhatsApp social account ID

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

    the optional parameters

Returns:



609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 609

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

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

  # 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] || 'ListWhatsAppFlows200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.list_whats_app_flows",
    :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: WhatsAppFlowsApi#list_whats_app_flows\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#publish_whats_app_flow(flow_id, delete_whatsapp_business_username_request, opts = {}) ⇒ UpdateYoutubeDefaultPlaylist200Response

Publish flow Publish a DRAFT flow. This is irreversible. Once published, the flow and its JSON become immutable and the flow can be sent to users. To update a published flow, create a new flow (optionally cloning this one via cloneFlowId).

Parameters:

Returns:



664
665
666
667
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 664

def publish_whats_app_flow(flow_id, delete_whatsapp_business_username_request, opts = {})
  data, _status_code, _headers = publish_whats_app_flow_with_http_info(flow_id, delete_whatsapp_business_username_request, opts)
  data
end

#publish_whats_app_flow_with_http_info(flow_id, delete_whatsapp_business_username_request, opts = {}) ⇒ Array<(UpdateYoutubeDefaultPlaylist200Response, Integer, Hash)>

Publish flow Publish a DRAFT flow. This is irreversible. Once published, the flow and its JSON become immutable and the flow can be sent to users. To update a published flow, create a new flow (optionally cloning this one via cloneFlowId).

Parameters:

Returns:



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
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 675

def publish_whats_app_flow_with_http_info(flow_id, delete_whatsapp_business_username_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.publish_whats_app_flow ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.publish_whats_app_flow"
  end
  # verify the required parameter 'delete_whatsapp_business_username_request' is set
  if @api_client.config.client_side_validation && delete_whatsapp_business_username_request.nil?
    fail ArgumentError, "Missing the required parameter 'delete_whatsapp_business_username_request' when calling WhatsAppFlowsApi.publish_whats_app_flow"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}/publish'.sub('{' + 'flowId' + '}', CGI.escape(flow_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(delete_whatsapp_business_username_request)

  # return_type
  return_type = opts[:debug_return_type] || 'UpdateYoutubeDefaultPlaylist200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.publish_whats_app_flow",
    :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: WhatsAppFlowsApi#publish_whats_app_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#send_whats_app_flow_message(send_whats_app_flow_message_request, opts = {}) ⇒ SendWhatsAppFlowMessage200Response

Send flow message Send a published flow as an interactive message with a CTA button. When the recipient taps the button, the flow opens natively in WhatsApp. Flow responses are received via webhooks.

Parameters:

Returns:



737
738
739
740
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 737

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

#send_whats_app_flow_message_with_http_info(send_whats_app_flow_message_request, opts = {}) ⇒ Array<(SendWhatsAppFlowMessage200Response, Integer, Hash)>

Send flow message Send a published flow as an interactive message with a CTA button. When the recipient taps the button, the flow opens natively in WhatsApp. Flow responses are received via webhooks.

Parameters:

Returns:



747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 747

def send_whats_app_flow_message_with_http_info(send_whats_app_flow_message_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.send_whats_app_flow_message ...'
  end
  # verify the required parameter 'send_whats_app_flow_message_request' is set
  if @api_client.config.client_side_validation && send_whats_app_flow_message_request.nil?
    fail ArgumentError, "Missing the required parameter 'send_whats_app_flow_message_request' when calling WhatsAppFlowsApi.send_whats_app_flow_message"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/send'

  # 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(send_whats_app_flow_message_request)

  # return_type
  return_type = opts[:debug_return_type] || 'SendWhatsAppFlowMessage200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.send_whats_app_flow_message",
    :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: WhatsAppFlowsApi#send_whats_app_flow_message\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#update_whats_app_flow(flow_id, update_whats_app_flow_request, opts = {}) ⇒ UpdateYoutubeDefaultPlaylist200Response

Update flow Update metadata (name, categories) of a DRAFT flow. Published flows are immutable.

Parameters:

  • flow_id (String)

    Flow ID

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

    the optional parameters

Returns:



806
807
808
809
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 806

def update_whats_app_flow(flow_id, update_whats_app_flow_request, opts = {})
  data, _status_code, _headers = update_whats_app_flow_with_http_info(flow_id, update_whats_app_flow_request, opts)
  data
end

#update_whats_app_flow_with_http_info(flow_id, update_whats_app_flow_request, opts = {}) ⇒ Array<(UpdateYoutubeDefaultPlaylist200Response, Integer, Hash)>

Update flow Update metadata (name, categories) of a DRAFT flow. Published flows are immutable.

Parameters:

  • flow_id (String)

    Flow ID

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

    the optional parameters

Returns:



817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 817

def update_whats_app_flow_with_http_info(flow_id, update_whats_app_flow_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.update_whats_app_flow ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.update_whats_app_flow"
  end
  # verify the required parameter 'update_whats_app_flow_request' is set
  if @api_client.config.client_side_validation && update_whats_app_flow_request.nil?
    fail ArgumentError, "Missing the required parameter 'update_whats_app_flow_request' when calling WhatsAppFlowsApi.update_whats_app_flow"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}'.sub('{' + 'flowId' + '}', CGI.escape(flow_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(update_whats_app_flow_request)

  # return_type
  return_type = opts[:debug_return_type] || 'UpdateYoutubeDefaultPlaylist200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.update_whats_app_flow",
    :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(:PATCH, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: WhatsAppFlowsApi#update_whats_app_flow\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#upload_whats_app_flow_json(flow_id, upload_whats_app_flow_json_request, opts = {}) ⇒ UploadWhatsAppFlowJson200Response

Upload flow JSON Upload or update the Flow JSON for a DRAFT flow. The Flow JSON defines all screens, components (text inputs, dropdowns, date pickers, etc.), and navigation. Meta validates the JSON on upload and returns any validation errors. See: https://developers.facebook.com/docs/whatsapp/flows/reference/flowjson

Parameters:

  • flow_id (String)

    Flow ID

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

    the optional parameters

Returns:



880
881
882
883
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 880

def upload_whats_app_flow_json(flow_id, upload_whats_app_flow_json_request, opts = {})
  data, _status_code, _headers = upload_whats_app_flow_json_with_http_info(flow_id, upload_whats_app_flow_json_request, opts)
  data
end

#upload_whats_app_flow_json_with_http_info(flow_id, upload_whats_app_flow_json_request, opts = {}) ⇒ Array<(UploadWhatsAppFlowJson200Response, Integer, Hash)>

Upload flow JSON Upload or update the Flow JSON for a DRAFT flow. The Flow JSON defines all screens, components (text inputs, dropdowns, date pickers, etc.), and navigation. Meta validates the JSON on upload and returns any validation errors. See: https://developers.facebook.com/docs/whatsapp/flows/reference/flowjson

Parameters:

  • flow_id (String)

    Flow ID

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

    the optional parameters

Returns:



891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
# File 'lib/zernio-sdk/api/whats_app_flows_api.rb', line 891

def upload_whats_app_flow_json_with_http_info(flow_id, upload_whats_app_flow_json_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: WhatsAppFlowsApi.upload_whats_app_flow_json ...'
  end
  # verify the required parameter 'flow_id' is set
  if @api_client.config.client_side_validation && flow_id.nil?
    fail ArgumentError, "Missing the required parameter 'flow_id' when calling WhatsAppFlowsApi.upload_whats_app_flow_json"
  end
  # verify the required parameter 'upload_whats_app_flow_json_request' is set
  if @api_client.config.client_side_validation && upload_whats_app_flow_json_request.nil?
    fail ArgumentError, "Missing the required parameter 'upload_whats_app_flow_json_request' when calling WhatsAppFlowsApi.upload_whats_app_flow_json"
  end
  # resource path
  local_var_path = '/v1/whatsapp/flows/{flowId}/json'.sub('{' + 'flowId' + '}', CGI.escape(flow_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(upload_whats_app_flow_json_request)

  # return_type
  return_type = opts[:debug_return_type] || 'UploadWhatsAppFlowJson200Response'

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

  new_options = opts.merge(
    :operation => :"WhatsAppFlowsApi.upload_whats_app_flow_json",
    :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: WhatsAppFlowsApi#upload_whats_app_flow_json\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end