messente_api 1.3.1 → 2.1.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.
Files changed (150) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +33 -30
  3. data/docs/BlacklistApi.md +105 -37
  4. data/docs/BulkMessagingApi.md +76 -0
  5. data/docs/BulkOmniMessageCreateSuccessResponse.md +18 -0
  6. data/docs/BulkOmniMessageCreateSuccessResponseMessagesInner.md +49 -0
  7. data/docs/BulkOmnimessage.md +18 -0
  8. data/docs/Channel.md +4 -5
  9. data/docs/ContactEnvelope.md +8 -7
  10. data/docs/ContactFields.md +26 -25
  11. data/docs/ContactListEnvelope.md +8 -7
  12. data/docs/ContactResponseFields.md +28 -27
  13. data/docs/ContactUpdateFields.md +24 -23
  14. data/docs/ContactsApi.md +221 -86
  15. data/docs/DeliveryReportApi.md +29 -13
  16. data/docs/DeliveryReportResponse.md +12 -11
  17. data/docs/DeliveryResult.md +22 -17
  18. data/docs/ErrorCodeOmnichannel.md +4 -5
  19. data/docs/ErrorCodeOmnichannelMachine.md +4 -5
  20. data/docs/ErrorCodePhonebook.md +4 -5
  21. data/docs/ErrorCodeStatistics.md +4 -5
  22. data/docs/ErrorItemNumberLookup.md +8 -7
  23. data/docs/ErrorItemNumberLookupError.md +10 -9
  24. data/docs/ErrorItemOmnichannel.md +14 -13
  25. data/docs/ErrorItemPhonebook.md +12 -11
  26. data/docs/ErrorItemStatistics.md +12 -11
  27. data/docs/ErrorNumberLookup.md +8 -7
  28. data/docs/ErrorOmnichannel.md +8 -7
  29. data/docs/ErrorPhonebook.md +8 -7
  30. data/docs/ErrorStatistics.md +8 -7
  31. data/docs/ErrorTitleOmnichannel.md +4 -5
  32. data/docs/ErrorTitlePhonebook.md +4 -5
  33. data/docs/FetchBlacklistSuccess.md +8 -7
  34. data/docs/GroupEnvelope.md +8 -7
  35. data/docs/GroupListEnvelope.md +8 -7
  36. data/docs/GroupName.md +8 -7
  37. data/docs/GroupResponseFields.md +14 -13
  38. data/docs/GroupsApi.md +136 -51
  39. data/docs/MessageResult.md +12 -11
  40. data/docs/MobileNetwork.md +16 -15
  41. data/docs/NumberLookupApi.md +30 -14
  42. data/docs/NumberToBlacklist.md +8 -7
  43. data/docs/NumbersToInvestigate.md +8 -7
  44. data/docs/OmniMessageCreateSuccessResponse.md +12 -11
  45. data/docs/Omnimessage.md +18 -15
  46. data/docs/OmnimessageApi.md +56 -23
  47. data/docs/OmnimessageMessagesInner.md +53 -0
  48. data/docs/PriceInfo.md +22 -0
  49. data/docs/Priority.md +15 -0
  50. data/docs/SMS.md +20 -17
  51. data/docs/StatisticsApi.md +30 -14
  52. data/docs/StatisticsReport.md +12 -11
  53. data/docs/StatisticsReportSettings.md +12 -11
  54. data/docs/StatisticsReportSuccess.md +8 -7
  55. data/docs/Status.md +4 -5
  56. data/docs/SyncNumberLookupResult.md +24 -23
  57. data/docs/SyncNumberLookupSuccess.md +10 -9
  58. data/docs/Telegram.md +20 -19
  59. data/docs/TextStore.md +4 -5
  60. data/docs/Viber.md +22 -19
  61. data/docs/WhatsApp.md +16 -19
  62. data/docs/WhatsAppComponent.md +24 -0
  63. data/docs/WhatsAppCurrency.md +22 -0
  64. data/docs/WhatsAppDatetime.md +18 -0
  65. data/docs/WhatsAppLanguage.md +20 -0
  66. data/docs/WhatsAppMedia.md +24 -0
  67. data/docs/WhatsAppParameter.md +30 -0
  68. data/docs/WhatsAppTemplate.md +22 -0
  69. data/git_push.sh +3 -4
  70. data/lib/messente_api/api/blacklist_api.rb +22 -15
  71. data/lib/messente_api/api/bulk_messaging_api.rb +88 -0
  72. data/lib/messente_api/api/contacts_api.rb +42 -28
  73. data/lib/messente_api/api/delivery_report_api.rb +6 -5
  74. data/lib/messente_api/api/groups_api.rb +30 -19
  75. data/lib/messente_api/api/number_lookup_api.rb +10 -6
  76. data/lib/messente_api/api/omnimessage_api.rb +14 -9
  77. data/lib/messente_api/api/statistics_api.rb +10 -6
  78. data/lib/messente_api/api_client.rb +72 -66
  79. data/lib/messente_api/api_error.rb +3 -2
  80. data/lib/messente_api/configuration.rb +64 -14
  81. data/lib/messente_api/models/{whats_app_audio.rb → bulk_omni_message_create_success_response.rb} +50 -38
  82. data/lib/messente_api/models/bulk_omni_message_create_success_response_messages_inner.rb +105 -0
  83. data/lib/messente_api/models/{whats_app_text.rb → bulk_omnimessage.rb} +49 -49
  84. data/lib/messente_api/models/channel.rb +9 -5
  85. data/lib/messente_api/models/contact_envelope.rb +31 -23
  86. data/lib/messente_api/models/contact_fields.rb +33 -23
  87. data/lib/messente_api/models/contact_list_envelope.rb +41 -23
  88. data/lib/messente_api/models/contact_response_fields.rb +31 -23
  89. data/lib/messente_api/models/contact_update_fields.rb +31 -23
  90. data/lib/messente_api/models/delivery_report_response.rb +37 -23
  91. data/lib/messente_api/models/delivery_result.rb +77 -27
  92. data/lib/messente_api/models/error_code_omnichannel.rb +9 -5
  93. data/lib/messente_api/models/error_code_omnichannel_machine.rb +9 -5
  94. data/lib/messente_api/models/error_code_phonebook.rb +9 -5
  95. data/lib/messente_api/models/error_code_statistics.rb +9 -5
  96. data/lib/messente_api/models/error_item_number_lookup.rb +33 -23
  97. data/lib/messente_api/models/error_item_number_lookup_error.rb +35 -23
  98. data/lib/messente_api/models/error_item_omnichannel.rb +61 -23
  99. data/lib/messente_api/models/error_item_phonebook.rb +59 -23
  100. data/lib/messente_api/models/error_item_statistics.rb +59 -23
  101. data/lib/messente_api/models/error_number_lookup.rb +33 -23
  102. data/lib/messente_api/models/error_omnichannel.rb +33 -23
  103. data/lib/messente_api/models/error_phonebook.rb +33 -23
  104. data/lib/messente_api/models/error_statistics.rb +33 -23
  105. data/lib/messente_api/models/error_title_omnichannel.rb +9 -5
  106. data/lib/messente_api/models/error_title_phonebook.rb +9 -5
  107. data/lib/messente_api/models/fetch_blacklist_success.rb +41 -23
  108. data/lib/messente_api/models/group_envelope.rb +31 -23
  109. data/lib/messente_api/models/group_list_envelope.rb +41 -23
  110. data/lib/messente_api/models/group_name.rb +33 -23
  111. data/lib/messente_api/models/group_response_fields.rb +37 -23
  112. data/lib/messente_api/models/message_result.rb +59 -23
  113. data/lib/messente_api/models/mobile_network.rb +31 -23
  114. data/lib/messente_api/models/number_to_blacklist.rb +33 -23
  115. data/lib/messente_api/models/numbers_to_investigate.rb +62 -24
  116. data/lib/messente_api/models/omni_message_create_success_response.rb +37 -23
  117. data/lib/messente_api/models/omnimessage.rb +71 -28
  118. data/lib/messente_api/models/omnimessage_messages_inner.rb +107 -0
  119. data/lib/messente_api/models/price_info.rb +257 -0
  120. data/lib/messente_api/models/priority.rb +41 -0
  121. data/lib/messente_api/models/sms.rb +45 -25
  122. data/lib/messente_api/models/statistics_report.rb +37 -23
  123. data/lib/messente_api/models/statistics_report_settings.rb +35 -23
  124. data/lib/messente_api/models/statistics_report_success.rb +33 -23
  125. data/lib/messente_api/models/status.rb +9 -5
  126. data/lib/messente_api/models/sync_number_lookup_result.rb +35 -24
  127. data/lib/messente_api/models/sync_number_lookup_success.rb +35 -23
  128. data/lib/messente_api/models/telegram.rb +31 -23
  129. data/lib/messente_api/models/text_store.rb +9 -5
  130. data/lib/messente_api/models/viber.rb +43 -25
  131. data/lib/messente_api/models/whats_app.rb +45 -54
  132. data/lib/messente_api/models/whats_app_component.rb +255 -0
  133. data/lib/messente_api/models/whats_app_currency.rb +257 -0
  134. data/lib/messente_api/models/{whats_app_document.rb → whats_app_datetime.rb} +48 -48
  135. data/lib/messente_api/models/{whats_app_image.rb → whats_app_language.rb} +55 -45
  136. data/lib/messente_api/models/whats_app_media.rb +246 -0
  137. data/lib/messente_api/models/whats_app_parameter.rb +278 -0
  138. data/lib/messente_api/models/whats_app_template.rb +251 -0
  139. data/lib/messente_api/version.rb +3 -3
  140. data/lib/messente_api.rb +16 -6
  141. data/messente_api.gemspec +5 -5
  142. data/spec/spec_helper.rb +2 -2
  143. metadata +35 -40
  144. data/docs/WhatsAppAudio.md +0 -17
  145. data/docs/WhatsAppDocument.md +0 -19
  146. data/docs/WhatsAppImage.md +0 -19
  147. data/docs/WhatsAppText.md +0 -19
  148. data/messente_api-1.3.0.gem +0 -0
  149. data/spec/api_client_spec.rb +0 -226
  150. data/spec/configuration_spec.rb +0 -42
data/docs/Viber.md CHANGED
@@ -2,28 +2,31 @@
2
2
 
3
3
  ## Properties
4
4
 
5
- Name | Type | Description | Notes
6
- ------------ | ------------- | ------------- | -------------
7
- **sender** | **String** | Phone number or alphanumeric sender name | [optional]
8
- **validity** | **Integer** | After how many minutes this channel is considered as failed and the next channel is attempted | [optional]
9
- **text** | **String** | Plaintext content for Viber | [optional]
10
- **image_url** | **String** | URL for the embedded image Valid combinations: 1) image_url, 2) text, image_url, button_url, button_text | [optional]
11
- **button_url** | **String** | URL of the button, must be specified along with ''text'', ''button_text'' and ''image_url'' (optional) | [optional]
12
- **button_text** | **String** | Must be specified along with ''text'', ''button_url'', ''button_text'', ''image_url'' (optional) | [optional]
13
- **channel** | **String** | The channel used to deliver the message | [optional] [default to 'viber']
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **sender** | **String** | Phone number or alphanumeric sender name | [optional] |
8
+ | **validity** | **Integer** | After how many minutes this channel is considered as failed and the next channel is attempted. Only one of \"ttl\" and \"validity\" can be used. | [optional] |
9
+ | **ttl** | **Integer** | After how many seconds this channel is considered as failed and the next channel is attempted. Only one of \"ttl\" and \"validity\" can be used. | [optional] |
10
+ | **text** | **String** | Plaintext content for Viber | [optional] |
11
+ | **image_url** | **String** | URL for the embedded image Valid combinations: 1) image_url, 2) text, image_url, button_url, button_text | [optional] |
12
+ | **button_url** | **String** | URL of the button, must be specified along with ''text'', ''button_text'' and ''image_url'' (optional) | [optional] |
13
+ | **button_text** | **String** | Must be specified along with ''text'', ''button_url'', ''button_text'', ''image_url'' (optional) | [optional] |
14
+ | **channel** | **String** | The channel used to deliver the message | [optional][default to 'viber'] |
14
15
 
15
- ## Code Sample
16
+ ## Example
16
17
 
17
18
  ```ruby
18
- require 'MessenteApi'
19
+ require 'messente_api'
19
20
 
20
- instance = MessenteApi::Viber.new(sender: null,
21
- validity: 360,
22
- text: null,
23
- image_url: null,
24
- button_url: null,
25
- button_text: null,
26
- channel: null)
21
+ instance = MessenteApi::Viber.new(
22
+ sender: null,
23
+ validity: 360,
24
+ ttl: 21600,
25
+ text: null,
26
+ image_url: null,
27
+ button_url: null,
28
+ button_text: null,
29
+ channel: null
30
+ )
27
31
  ```
28
32
 
29
-
data/docs/WhatsApp.md CHANGED
@@ -2,28 +2,25 @@
2
2
 
3
3
  ## Properties
4
4
 
5
- Name | Type | Description | Notes
6
- ------------ | ------------- | ------------- | -------------
7
- **sender** | **String** | Phone number or alphanumeric sender name | [optional]
8
- **validity** | **Integer** | After how many minutes this channel is considered as failed and the next channel is attempted | [optional]
9
- **text** | [**WhatsAppText**](WhatsAppText.md) | | [optional]
10
- **image** | [**WhatsAppImage**](WhatsAppImage.md) | | [optional]
11
- **document** | [**WhatsAppDocument**](WhatsAppDocument.md) | | [optional]
12
- **audio** | [**WhatsAppAudio**](WhatsAppAudio.md) | | [optional]
13
- **channel** | **String** | The channel used to deliver the message | [optional] [default to 'whatsapp']
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **sender** | **String** | Phone number or alphanumeric sender name | [optional] |
8
+ | **validity** | **Integer** | After how many minutes this channel is considered as failed and the next channel is attempted | [optional] |
9
+ | **ttl** | **Integer** | After how many seconds this channel is considered as failed and the next channel is attempted. Only one of \"ttl\" and \"validity\" can be used. | [optional] |
10
+ | **template** | [**WhatsAppTemplate**](WhatsAppTemplate.md) | | [optional] |
11
+ | **channel** | **String** | The channel used to deliver the message | [optional][default to 'whatsapp'] |
14
12
 
15
- ## Code Sample
13
+ ## Example
16
14
 
17
15
  ```ruby
18
- require 'MessenteApi'
16
+ require 'messente_api'
19
17
 
20
- instance = MessenteApi::WhatsApp.new(sender: null,
21
- validity: 360,
22
- text: null,
23
- image: null,
24
- document: null,
25
- audio: null,
26
- channel: null)
18
+ instance = MessenteApi::WhatsApp.new(
19
+ sender: null,
20
+ validity: 360,
21
+ ttl: 21600,
22
+ template: null,
23
+ channel: null
24
+ )
27
25
  ```
28
26
 
29
-
@@ -0,0 +1,24 @@
1
+ # MessenteApi::WhatsAppComponent
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **type** | **String** | Type of the component | |
8
+ | **sub_type** | **String** | Sub-type of the component | [optional] |
9
+ | **index** | **Integer** | index used to position buttons | [optional] |
10
+ | **parameters** | [**Array<WhatsAppParameter>**](WhatsAppParameter.md) | List of parameters for the component | [optional] |
11
+
12
+ ## Example
13
+
14
+ ```ruby
15
+ require 'messente_api'
16
+
17
+ instance = MessenteApi::WhatsAppComponent.new(
18
+ type: null,
19
+ sub_type: null,
20
+ index: null,
21
+ parameters: null
22
+ )
23
+ ```
24
+
@@ -0,0 +1,22 @@
1
+ # MessenteApi::WhatsAppCurrency
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **fallback_value** | **String** | Default text if localization fails. | |
8
+ | **code** | **String** | Currency code as defined in ISO 4217. | |
9
+ | **amount_1000** | **String** | Amount multiplied by 1000. | |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'messente_api'
15
+
16
+ instance = MessenteApi::WhatsAppCurrency.new(
17
+ fallback_value: null,
18
+ code: null,
19
+ amount_1000: null
20
+ )
21
+ ```
22
+
@@ -0,0 +1,18 @@
1
+ # MessenteApi::WhatsAppDatetime
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **fallback_value** | **String** | Default text. | |
8
+
9
+ ## Example
10
+
11
+ ```ruby
12
+ require 'messente_api'
13
+
14
+ instance = MessenteApi::WhatsAppDatetime.new(
15
+ fallback_value: null
16
+ )
17
+ ```
18
+
@@ -0,0 +1,20 @@
1
+ # MessenteApi::WhatsAppLanguage
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **code** | **String** | Language code | |
8
+ | **policy** | **String** | Language policy | [optional] |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'messente_api'
14
+
15
+ instance = MessenteApi::WhatsAppLanguage.new(
16
+ code: null,
17
+ policy: null
18
+ )
19
+ ```
20
+
@@ -0,0 +1,24 @@
1
+ # MessenteApi::WhatsAppMedia
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **id** | **String** | The media object ID. Do not use this field when message type is set to text. | [optional] |
8
+ | **link** | **String** | The protocol and URL of the media to be sent. Use only with HTTP/HTTPS URLs. Do not use this field when message type is set to text. | [optional] |
9
+ | **caption** | **String** | Media asset caption. Do not use with audio or sticker media. | [optional] |
10
+ | **filename** | **String** | Describes the filename for the specific document. Use only with document media. | [optional] |
11
+
12
+ ## Example
13
+
14
+ ```ruby
15
+ require 'messente_api'
16
+
17
+ instance = MessenteApi::WhatsAppMedia.new(
18
+ id: null,
19
+ link: null,
20
+ caption: null,
21
+ filename: null
22
+ )
23
+ ```
24
+
@@ -0,0 +1,30 @@
1
+ # MessenteApi::WhatsAppParameter
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **type** | **String** | Type of the parameter. | |
8
+ | **text** | **String** | A text. | [optional] |
9
+ | **currency** | [**WhatsAppCurrency**](WhatsAppCurrency.md) | | [optional] |
10
+ | **date_time** | [**WhatsAppDatetime**](WhatsAppDatetime.md) | | [optional] |
11
+ | **image** | [**WhatsAppMedia**](WhatsAppMedia.md) | | [optional] |
12
+ | **document** | [**WhatsAppMedia**](WhatsAppMedia.md) | | [optional] |
13
+ | **video** | [**WhatsAppMedia**](WhatsAppMedia.md) | | [optional] |
14
+
15
+ ## Example
16
+
17
+ ```ruby
18
+ require 'messente_api'
19
+
20
+ instance = MessenteApi::WhatsAppParameter.new(
21
+ type: null,
22
+ text: null,
23
+ currency: null,
24
+ date_time: null,
25
+ image: null,
26
+ document: null,
27
+ video: null
28
+ )
29
+ ```
30
+
@@ -0,0 +1,22 @@
1
+ # MessenteApi::WhatsAppTemplate
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **name** | **String** | Name of the template | |
8
+ | **language** | [**WhatsAppLanguage**](WhatsAppLanguage.md) | | |
9
+ | **components** | [**Array<WhatsAppComponent>**](WhatsAppComponent.md) | List of template components | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'messente_api'
15
+
16
+ instance = MessenteApi::WhatsAppTemplate.new(
17
+ name: null,
18
+ language: null,
19
+ components: null
20
+ )
21
+ ```
22
+
data/git_push.sh CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/bin/sh
2
2
  # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
3
3
  #
4
- # Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com"
4
+ # Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com"
5
5
 
6
6
  git_user_id=$1
7
7
  git_repo_id=$2
@@ -38,14 +38,14 @@ git add .
38
38
  git commit -m "$release_note"
39
39
 
40
40
  # Sets the new remote
41
- git_remote=`git remote`
41
+ git_remote=$(git remote)
42
42
  if [ "$git_remote" = "" ]; then # git remote not defined
43
43
 
44
44
  if [ "$GIT_TOKEN" = "" ]; then
45
45
  echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
46
46
  git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
47
47
  else
48
- git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git
48
+ git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git
49
49
  fi
50
50
 
51
51
  fi
@@ -55,4 +55,3 @@ git pull origin master
55
55
  # Pushes (Forces) the changes in the local repository up to the remote repository
56
56
  echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
57
57
  git push origin master 2>&1 | grep -v 'To https'
58
-
@@ -3,10 +3,10 @@
3
3
 
4
4
  #[Messente](https://messente.com) is a global provider of messaging and user verification services. * Send and receive SMS, Viber, WhatsApp and Telegram messages. * Manage contacts and groups. * Fetch detailed info about phone numbers. * Blacklist phone numbers to make sure you're not sending any unwanted messages. Messente builds [tools](https://messente.com/documentation) to help organizations connect their services to people anywhere in the world.
5
5
 
6
- The version of the OpenAPI document: 1.3.0
6
+ The version of the OpenAPI document: 2.0.0
7
7
  Contact: messente@messente.com
8
8
  Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 4.3.1
9
+ Generator version: 7.6.0
10
10
 
11
11
  =end
12
12
 
@@ -51,21 +51,25 @@ module MessenteApi
51
51
  # HTTP header 'Accept' (if needed)
52
52
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
53
53
  # HTTP header 'Content-Type'
54
- header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
54
+ content_type = @api_client.select_header_content_type(['application/json'])
55
+ if !content_type.nil?
56
+ header_params['Content-Type'] = content_type
57
+ end
55
58
 
56
59
  # form parameters
57
60
  form_params = opts[:form_params] || {}
58
61
 
59
62
  # http body (model)
60
- post_body = opts[:body] || @api_client.object_to_http_body(number_to_blacklist)
63
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(number_to_blacklist)
61
64
 
62
65
  # return_type
63
- return_type = opts[:return_type]
66
+ return_type = opts[:debug_return_type]
64
67
 
65
68
  # auth_names
66
- auth_names = opts[:auth_names] || ['basicAuth']
69
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
67
70
 
68
71
  new_options = opts.merge(
72
+ :operation => :"BlacklistApi.add_to_blacklist",
69
73
  :header_params => header_params,
70
74
  :query_params => query_params,
71
75
  :form_params => form_params,
@@ -117,15 +121,16 @@ module MessenteApi
117
121
  form_params = opts[:form_params] || {}
118
122
 
119
123
  # http body (model)
120
- post_body = opts[:body]
124
+ post_body = opts[:debug_body]
121
125
 
122
126
  # return_type
123
- return_type = opts[:return_type]
127
+ return_type = opts[:debug_return_type]
124
128
 
125
129
  # auth_names
126
- auth_names = opts[:auth_names] || ['basicAuth']
130
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
127
131
 
128
132
  new_options = opts.merge(
133
+ :operation => :"BlacklistApi.delete_from_blacklist",
129
134
  :header_params => header_params,
130
135
  :query_params => query_params,
131
136
  :form_params => form_params,
@@ -171,15 +176,16 @@ module MessenteApi
171
176
  form_params = opts[:form_params] || {}
172
177
 
173
178
  # http body (model)
174
- post_body = opts[:body]
179
+ post_body = opts[:debug_body]
175
180
 
176
181
  # return_type
177
- return_type = opts[:return_type] || 'FetchBlacklistSuccess'
182
+ return_type = opts[:debug_return_type] || 'FetchBlacklistSuccess'
178
183
 
179
184
  # auth_names
180
- auth_names = opts[:auth_names] || ['basicAuth']
185
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
181
186
 
182
187
  new_options = opts.merge(
188
+ :operation => :"BlacklistApi.fetch_blacklist",
183
189
  :header_params => header_params,
184
190
  :query_params => query_params,
185
191
  :form_params => form_params,
@@ -231,15 +237,16 @@ module MessenteApi
231
237
  form_params = opts[:form_params] || {}
232
238
 
233
239
  # http body (model)
234
- post_body = opts[:body]
240
+ post_body = opts[:debug_body]
235
241
 
236
242
  # return_type
237
- return_type = opts[:return_type]
243
+ return_type = opts[:debug_return_type]
238
244
 
239
245
  # auth_names
240
- auth_names = opts[:auth_names] || ['basicAuth']
246
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
241
247
 
242
248
  new_options = opts.merge(
249
+ :operation => :"BlacklistApi.is_blacklisted",
243
250
  :header_params => header_params,
244
251
  :query_params => query_params,
245
252
  :form_params => form_params,
@@ -0,0 +1,88 @@
1
+ =begin
2
+ #Messente API
3
+
4
+ #[Messente](https://messente.com) is a global provider of messaging and user verification services. * Send and receive SMS, Viber, WhatsApp and Telegram messages. * Manage contacts and groups. * Fetch detailed info about phone numbers. * Blacklist phone numbers to make sure you're not sending any unwanted messages. Messente builds [tools](https://messente.com/documentation) to help organizations connect their services to people anywhere in the world.
5
+
6
+ The version of the OpenAPI document: 2.0.0
7
+ Contact: messente@messente.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.6.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module MessenteApi
16
+ class BulkMessagingApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # Sends a bulk Omnimessage
23
+ # @param bulk_omnimessage [BulkOmnimessage] Bulk Omnimessage to be sent
24
+ # @param [Hash] opts the optional parameters
25
+ # @return [BulkOmniMessageCreateSuccessResponse]
26
+ def send_bulk_omnimessage(bulk_omnimessage, opts = {})
27
+ data, _status_code, _headers = send_bulk_omnimessage_with_http_info(bulk_omnimessage, opts)
28
+ data
29
+ end
30
+
31
+ # Sends a bulk Omnimessage
32
+ # @param bulk_omnimessage [BulkOmnimessage] Bulk Omnimessage to be sent
33
+ # @param [Hash] opts the optional parameters
34
+ # @return [Array<(BulkOmniMessageCreateSuccessResponse, Integer, Hash)>] BulkOmniMessageCreateSuccessResponse data, response status code and response headers
35
+ def send_bulk_omnimessage_with_http_info(bulk_omnimessage, opts = {})
36
+ if @api_client.config.debugging
37
+ @api_client.config.logger.debug 'Calling API: BulkMessagingApi.send_bulk_omnimessage ...'
38
+ end
39
+ # verify the required parameter 'bulk_omnimessage' is set
40
+ if @api_client.config.client_side_validation && bulk_omnimessage.nil?
41
+ fail ArgumentError, "Missing the required parameter 'bulk_omnimessage' when calling BulkMessagingApi.send_bulk_omnimessage"
42
+ end
43
+ # resource path
44
+ local_var_path = '/omnimessages'
45
+
46
+ # query parameters
47
+ query_params = opts[:query_params] || {}
48
+
49
+ # header parameters
50
+ header_params = opts[:header_params] || {}
51
+ # HTTP header 'Accept' (if needed)
52
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
53
+ # HTTP header 'Content-Type'
54
+ content_type = @api_client.select_header_content_type(['application/json'])
55
+ if !content_type.nil?
56
+ header_params['Content-Type'] = content_type
57
+ end
58
+
59
+ # form parameters
60
+ form_params = opts[:form_params] || {}
61
+
62
+ # http body (model)
63
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(bulk_omnimessage)
64
+
65
+ # return_type
66
+ return_type = opts[:debug_return_type] || 'BulkOmniMessageCreateSuccessResponse'
67
+
68
+ # auth_names
69
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
70
+
71
+ new_options = opts.merge(
72
+ :operation => :"BulkMessagingApi.send_bulk_omnimessage",
73
+ :header_params => header_params,
74
+ :query_params => query_params,
75
+ :form_params => form_params,
76
+ :body => post_body,
77
+ :auth_names => auth_names,
78
+ :return_type => return_type
79
+ )
80
+
81
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
82
+ if @api_client.config.debugging
83
+ @api_client.config.logger.debug "API called: BulkMessagingApi#send_bulk_omnimessage\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
84
+ end
85
+ return data, status_code, headers
86
+ end
87
+ end
88
+ end