smooch-api 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (121) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +7 -0
  3. data/README.md +181 -0
  4. data/Rakefile +8 -0
  5. data/docs/Action.md +16 -0
  6. data/docs/App.md +10 -0
  7. data/docs/AppApi.md +609 -0
  8. data/docs/AppCreate.md +8 -0
  9. data/docs/AppResponse.md +8 -0
  10. data/docs/AppUser.md +18 -0
  11. data/docs/AppUserApi.md +561 -0
  12. data/docs/AppUserLink.md +9 -0
  13. data/docs/AppUserPreCreate.md +14 -0
  14. data/docs/AppUserResponse.md +8 -0
  15. data/docs/AppUserUpdate.md +12 -0
  16. data/docs/Client.md +14 -0
  17. data/docs/ClientInfo.md +15 -0
  18. data/docs/Conversation.md +9 -0
  19. data/docs/ConversationApi.md +282 -0
  20. data/docs/Destination.md +9 -0
  21. data/docs/DeviceInit.md +12 -0
  22. data/docs/DeviceResponse.md +8 -0
  23. data/docs/DeviceUpdate.md +10 -0
  24. data/docs/DisplaySettings.md +8 -0
  25. data/docs/Event.md +8 -0
  26. data/docs/GetMessagesResponse.md +10 -0
  27. data/docs/Init.md +9 -0
  28. data/docs/InitApi.md +61 -0
  29. data/docs/InitResponse.md +9 -0
  30. data/docs/Integration.md +24 -0
  31. data/docs/IntegrationApi.md +121 -0
  32. data/docs/IntegrationCreate.md +23 -0
  33. data/docs/IntegrationResponse.md +8 -0
  34. data/docs/JwtResponse.md +8 -0
  35. data/docs/ListAppsResponse.md +10 -0
  36. data/docs/ListIntegrationsResponse.md +8 -0
  37. data/docs/ListSecretKeysResponse.md +8 -0
  38. data/docs/ListWebhooksResponse.md +8 -0
  39. data/docs/Menu.md +9 -0
  40. data/docs/MenuApi.md +155 -0
  41. data/docs/MenuItem.md +11 -0
  42. data/docs/MenuResponse.md +8 -0
  43. data/docs/Message.md +23 -0
  44. data/docs/MessageItem.md +13 -0
  45. data/docs/MessagePost.md +20 -0
  46. data/docs/MessageResponse.md +9 -0
  47. data/docs/PostMessagesResponse.md +9 -0
  48. data/docs/SecretKey.md +10 -0
  49. data/docs/SecretKeyCreate.md +8 -0
  50. data/docs/SecretKeyResponse.md +8 -0
  51. data/docs/TrackEventResponse.md +8 -0
  52. data/docs/TypingActivityTrigger.md +11 -0
  53. data/docs/Webhook.md +11 -0
  54. data/docs/WebhookApi.md +287 -0
  55. data/docs/WebhookCreate.md +9 -0
  56. data/docs/WebhookResponse.md +8 -0
  57. data/docs/WebhookUpdate.md +9 -0
  58. data/git_push.sh +55 -0
  59. data/lib/smooch-api.rb +91 -0
  60. data/lib/smooch-api/api/app_api.rb +628 -0
  61. data/lib/smooch-api/api/app_user_api.rb +585 -0
  62. data/lib/smooch-api/api/conversation_api.rb +298 -0
  63. data/lib/smooch-api/api/init_api.rb +75 -0
  64. data/lib/smooch-api/api/integration_api.rb +135 -0
  65. data/lib/smooch-api/api/menu_api.rb +173 -0
  66. data/lib/smooch-api/api/webhook_api.rb +306 -0
  67. data/lib/smooch-api/api_client.rb +376 -0
  68. data/lib/smooch-api/api_error.rb +37 -0
  69. data/lib/smooch-api/configuration.rb +202 -0
  70. data/lib/smooch-api/models/action.rb +311 -0
  71. data/lib/smooch-api/models/app.rb +223 -0
  72. data/lib/smooch-api/models/app_create.rb +193 -0
  73. data/lib/smooch-api/models/app_response.rb +188 -0
  74. data/lib/smooch-api/models/app_user.rb +307 -0
  75. data/lib/smooch-api/models/app_user_link.rb +236 -0
  76. data/lib/smooch-api/models/app_user_pre_create.rb +253 -0
  77. data/lib/smooch-api/models/app_user_response.rb +193 -0
  78. data/lib/smooch-api/models/app_user_update.rb +228 -0
  79. data/lib/smooch-api/models/client.rb +290 -0
  80. data/lib/smooch-api/models/client_info.rb +258 -0
  81. data/lib/smooch-api/models/conversation.rb +208 -0
  82. data/lib/smooch-api/models/destination.rb +208 -0
  83. data/lib/smooch-api/models/device_init.rb +270 -0
  84. data/lib/smooch-api/models/device_response.rb +188 -0
  85. data/lib/smooch-api/models/device_update.rb +207 -0
  86. data/lib/smooch-api/models/display_settings.rb +188 -0
  87. data/lib/smooch-api/models/event.rb +193 -0
  88. data/lib/smooch-api/models/get_messages_response.rb +210 -0
  89. data/lib/smooch-api/models/init.rb +202 -0
  90. data/lib/smooch-api/models/init_response.rb +208 -0
  91. data/lib/smooch-api/models/integration.rb +358 -0
  92. data/lib/smooch-api/models/integration_create.rb +343 -0
  93. data/lib/smooch-api/models/integration_response.rb +188 -0
  94. data/lib/smooch-api/models/jwt_response.rb +188 -0
  95. data/lib/smooch-api/models/list_apps_response.rb +210 -0
  96. data/lib/smooch-api/models/list_integrations_response.rb +190 -0
  97. data/lib/smooch-api/models/list_secret_keys_response.rb +190 -0
  98. data/lib/smooch-api/models/list_webhooks_response.rb +195 -0
  99. data/lib/smooch-api/models/menu.rb +205 -0
  100. data/lib/smooch-api/models/menu_item.rb +228 -0
  101. data/lib/smooch-api/models/menu_response.rb +193 -0
  102. data/lib/smooch-api/models/message.rb +415 -0
  103. data/lib/smooch-api/models/message_item.rb +250 -0
  104. data/lib/smooch-api/models/message_post.rb +355 -0
  105. data/lib/smooch-api/models/message_response.rb +208 -0
  106. data/lib/smooch-api/models/post_messages_response.rb +200 -0
  107. data/lib/smooch-api/models/secret_key.rb +223 -0
  108. data/lib/smooch-api/models/secret_key_create.rb +193 -0
  109. data/lib/smooch-api/models/secret_key_response.rb +188 -0
  110. data/lib/smooch-api/models/track_event_response.rb +188 -0
  111. data/lib/smooch-api/models/typing_activity_trigger.rb +228 -0
  112. data/lib/smooch-api/models/webhook.rb +261 -0
  113. data/lib/smooch-api/models/webhook_create.rb +226 -0
  114. data/lib/smooch-api/models/webhook_response.rb +193 -0
  115. data/lib/smooch-api/models/webhook_update.rb +221 -0
  116. data/lib/smooch-api/version.rb +14 -0
  117. data/smooch-api.gemspec +44 -0
  118. data/spec/api_client_spec.rb +225 -0
  119. data/spec/configuration_spec.rb +41 -0
  120. data/spec/spec_helper.rb +110 -0
  121. metadata +349 -0
@@ -0,0 +1,14 @@
1
+ =begin
2
+ #Smooch
3
+
4
+ #The Smooch API is a unified interface for powering messaging in your customer experiences across every channel. Our API speeds access to new markets, reduces time to ship, eliminates complexity, and helps you build the best experiences for your customers. For more information, visit our [official documentation](https://docs.smooch.io).
5
+
6
+ OpenAPI spec version: 1
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+
10
+ =end
11
+
12
+ module SmoochApi
13
+ VERSION = "1.0.0"
14
+ end
@@ -0,0 +1,44 @@
1
+ # -*- encoding: utf-8 -*-
2
+ #
3
+ =begin
4
+ #Smooch
5
+
6
+ #The Smooch API is a unified interface for powering messaging in your customer experiences across every channel. Our API speeds access to new markets, reduces time to ship, eliminates complexity, and helps you build the best experiences for your customers. For more information, visit our [official documentation](https://docs.smooch.io).
7
+
8
+ OpenAPI spec version: 1
9
+
10
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
11
+
12
+ =end
13
+
14
+ $:.push File.expand_path("../lib", __FILE__)
15
+ require "smooch-api/version"
16
+
17
+ Gem::Specification.new do |s|
18
+ s.name = "smooch-api"
19
+ s.version = SmoochApi::VERSION
20
+ s.platform = Gem::Platform::RUBY
21
+ s.authors = ["Smooch"]
22
+ s.email = [""]
23
+ s.homepage = "https://github.com/smooch/smooch-ruby"
24
+ s.summary = "Smooch Ruby Gem"
25
+ s.description = "The Smooch API is a unified interface for powering messaging in your customer experiences across every channel. Our API speeds access to new markets, reduces time to ship, eliminates complexity, and helps you build the best experiences for your customers. For more information, visit our [official documentation](https://docs.smooch.io)."
26
+ s.license = "https://smooch.io/terms/"
27
+ s.required_ruby_version = ">= 1.9"
28
+
29
+ s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
30
+ s.add_runtime_dependency 'json', '~> 1.8', '>= 1.8.3'
31
+
32
+ s.add_development_dependency 'rspec', '~> 3.4', '>= 3.4.0'
33
+ s.add_development_dependency 'vcr', '~> 3.0', '>= 3.0.1'
34
+ s.add_development_dependency 'webmock', '~> 1.24', '>= 1.24.3'
35
+ s.add_development_dependency 'autotest', '~> 4.4', '>= 4.4.6'
36
+ s.add_development_dependency 'autotest-rails-pure', '~> 4.1', '>= 4.1.2'
37
+ s.add_development_dependency 'autotest-growl', '~> 0.2', '>= 0.2.16'
38
+ s.add_development_dependency 'autotest-fsevent', '~> 0.2', '>= 0.2.11'
39
+
40
+ s.files = `find *`.split("\n").uniq.sort.select{|f| !f.empty? }
41
+ s.test_files = `find spec/*`.split("\n")
42
+ s.executables = []
43
+ s.require_paths = ["lib"]
44
+ end
@@ -0,0 +1,225 @@
1
+ =begin
2
+ #Smooch
3
+
4
+ #The Smooch API is a unified interface for powering messaging in your customer experiences across every channel. Our API speeds access to new markets, reduces time to ship, eliminates complexity, and helps you build the best experiences for your customers. For more information, visit our [official documentation](https://docs.smooch.io).
5
+
6
+ OpenAPI spec version: 1
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+
10
+ =end
11
+
12
+ require 'spec_helper'
13
+
14
+ describe SmoochApi::ApiClient do
15
+ context 'initialization' do
16
+ context 'URL stuff' do
17
+ context 'host' do
18
+ it 'removes http from host' do
19
+ SmoochApi.configure { |c| c.host = 'http://example.com' }
20
+ expect(SmoochApi::Configuration.default.host).to eq('example.com')
21
+ end
22
+
23
+ it 'removes https from host' do
24
+ SmoochApi.configure { |c| c.host = 'https://wookiee.com' }
25
+ expect(SmoochApi::ApiClient.default.config.host).to eq('wookiee.com')
26
+ end
27
+
28
+ it 'removes trailing path from host' do
29
+ SmoochApi.configure { |c| c.host = 'hobo.com/v4' }
30
+ expect(SmoochApi::Configuration.default.host).to eq('hobo.com')
31
+ end
32
+ end
33
+
34
+ context 'base_path' do
35
+ it "prepends a slash to base_path" do
36
+ SmoochApi.configure { |c| c.base_path = 'v4/dog' }
37
+ expect(SmoochApi::Configuration.default.base_path).to eq('/v4/dog')
38
+ end
39
+
40
+ it "doesn't prepend a slash if one is already there" do
41
+ SmoochApi.configure { |c| c.base_path = '/v4/dog' }
42
+ expect(SmoochApi::Configuration.default.base_path).to eq('/v4/dog')
43
+ end
44
+
45
+ it "ends up as a blank string if nil" do
46
+ SmoochApi.configure { |c| c.base_path = nil }
47
+ expect(SmoochApi::Configuration.default.base_path).to eq('')
48
+ end
49
+ end
50
+ end
51
+ end
52
+
53
+ describe "params_encoding in #build_request" do
54
+ let(:config) { SmoochApi::Configuration.new }
55
+ let(:api_client) { SmoochApi::ApiClient.new(config) }
56
+
57
+ it "defaults to nil" do
58
+ expect(SmoochApi::Configuration.default.params_encoding).to eq(nil)
59
+ expect(config.params_encoding).to eq(nil)
60
+
61
+ request = api_client.build_request(:get, '/test')
62
+ expect(request.options[:params_encoding]).to eq(nil)
63
+ end
64
+
65
+ it "can be customized" do
66
+ config.params_encoding = :multi
67
+ request = api_client.build_request(:get, '/test')
68
+ expect(request.options[:params_encoding]).to eq(:multi)
69
+ end
70
+ end
71
+
72
+ describe "timeout in #build_request" do
73
+ let(:config) { SmoochApi::Configuration.new }
74
+ let(:api_client) { SmoochApi::ApiClient.new(config) }
75
+
76
+ it "defaults to 0" do
77
+ expect(SmoochApi::Configuration.default.timeout).to eq(0)
78
+ expect(config.timeout).to eq(0)
79
+
80
+ request = api_client.build_request(:get, '/test')
81
+ expect(request.options[:timeout]).to eq(0)
82
+ end
83
+
84
+ it "can be customized" do
85
+ config.timeout = 100
86
+ request = api_client.build_request(:get, '/test')
87
+ expect(request.options[:timeout]).to eq(100)
88
+ end
89
+ end
90
+
91
+ describe "#deserialize" do
92
+ it "handles Array<Integer>" do
93
+ api_client = SmoochApi::ApiClient.new
94
+ headers = {'Content-Type' => 'application/json'}
95
+ response = double('response', headers: headers, body: '[12, 34]')
96
+ data = api_client.deserialize(response, 'Array<Integer>')
97
+ expect(data).to be_instance_of(Array)
98
+ expect(data).to eq([12, 34])
99
+ end
100
+
101
+ it "handles Array<Array<Integer>>" do
102
+ api_client = SmoochApi::ApiClient.new
103
+ headers = {'Content-Type' => 'application/json'}
104
+ response = double('response', headers: headers, body: '[[12, 34], [56]]')
105
+ data = api_client.deserialize(response, 'Array<Array<Integer>>')
106
+ expect(data).to be_instance_of(Array)
107
+ expect(data).to eq([[12, 34], [56]])
108
+ end
109
+
110
+ it "handles Hash<String, String>" do
111
+ api_client = SmoochApi::ApiClient.new
112
+ headers = {'Content-Type' => 'application/json'}
113
+ response = double('response', headers: headers, body: '{"message": "Hello"}')
114
+ data = api_client.deserialize(response, 'Hash<String, String>')
115
+ expect(data).to be_instance_of(Hash)
116
+ expect(data).to eq({:message => 'Hello'})
117
+ end
118
+ end
119
+
120
+ describe "#object_to_hash" do
121
+ it "ignores nils and includes empty arrays" do
122
+ # uncomment below to test object_to_hash for model
123
+ #api_client = SmoochApi::ApiClient.new
124
+ #_model = SmoochApi::ModelName.new
125
+ # update the model attribute below
126
+ #_model.id = 1
127
+ # update the expected value (hash) below
128
+ #expected = {id: 1, name: '', tags: []}
129
+ #expect(api_client.object_to_hash(_model)).to eq(expected)
130
+ end
131
+ end
132
+
133
+ describe "#build_collection_param" do
134
+ let(:param) { ['aa', 'bb', 'cc'] }
135
+ let(:api_client) { SmoochApi::ApiClient.new }
136
+
137
+ it "works for csv" do
138
+ expect(api_client.build_collection_param(param, :csv)).to eq('aa,bb,cc')
139
+ end
140
+
141
+ it "works for ssv" do
142
+ expect(api_client.build_collection_param(param, :ssv)).to eq('aa bb cc')
143
+ end
144
+
145
+ it "works for tsv" do
146
+ expect(api_client.build_collection_param(param, :tsv)).to eq("aa\tbb\tcc")
147
+ end
148
+
149
+ it "works for pipes" do
150
+ expect(api_client.build_collection_param(param, :pipes)).to eq('aa|bb|cc')
151
+ end
152
+
153
+ it "works for multi" do
154
+ expect(api_client.build_collection_param(param, :multi)).to eq(['aa', 'bb', 'cc'])
155
+ end
156
+
157
+ it "fails for invalid collection format" do
158
+ expect(proc { api_client.build_collection_param(param, :INVALID) }).to raise_error(RuntimeError, 'unknown collection format: :INVALID')
159
+ end
160
+ end
161
+
162
+ describe "#json_mime?" do
163
+ let(:api_client) { SmoochApi::ApiClient.new }
164
+
165
+ it "works" do
166
+ expect(api_client.json_mime?(nil)).to eq false
167
+ expect(api_client.json_mime?('')).to eq false
168
+
169
+ expect(api_client.json_mime?('application/json')).to eq true
170
+ expect(api_client.json_mime?('application/json; charset=UTF8')).to eq true
171
+ expect(api_client.json_mime?('APPLICATION/JSON')).to eq true
172
+
173
+ expect(api_client.json_mime?('application/xml')).to eq false
174
+ expect(api_client.json_mime?('text/plain')).to eq false
175
+ expect(api_client.json_mime?('application/jsonp')).to eq false
176
+ end
177
+ end
178
+
179
+ describe "#select_header_accept" do
180
+ let(:api_client) { SmoochApi::ApiClient.new }
181
+
182
+ it "works" do
183
+ expect(api_client.select_header_accept(nil)).to be_nil
184
+ expect(api_client.select_header_accept([])).to be_nil
185
+
186
+ expect(api_client.select_header_accept(['application/json'])).to eq('application/json')
187
+ expect(api_client.select_header_accept(['application/xml', 'application/json; charset=UTF8'])).to eq('application/json; charset=UTF8')
188
+ expect(api_client.select_header_accept(['APPLICATION/JSON', 'text/html'])).to eq('APPLICATION/JSON')
189
+
190
+ expect(api_client.select_header_accept(['application/xml'])).to eq('application/xml')
191
+ expect(api_client.select_header_accept(['text/html', 'application/xml'])).to eq('text/html,application/xml')
192
+ end
193
+ end
194
+
195
+ describe "#select_header_content_type" do
196
+ let(:api_client) { SmoochApi::ApiClient.new }
197
+
198
+ it "works" do
199
+ expect(api_client.select_header_content_type(nil)).to eq('application/json')
200
+ expect(api_client.select_header_content_type([])).to eq('application/json')
201
+
202
+ expect(api_client.select_header_content_type(['application/json'])).to eq('application/json')
203
+ expect(api_client.select_header_content_type(['application/xml', 'application/json; charset=UTF8'])).to eq('application/json; charset=UTF8')
204
+ expect(api_client.select_header_content_type(['APPLICATION/JSON', 'text/html'])).to eq('APPLICATION/JSON')
205
+ expect(api_client.select_header_content_type(['application/xml'])).to eq('application/xml')
206
+ expect(api_client.select_header_content_type(['text/plain', 'application/xml'])).to eq('text/plain')
207
+ end
208
+ end
209
+
210
+ describe "#sanitize_filename" do
211
+ let(:api_client) { SmoochApi::ApiClient.new }
212
+
213
+ it "works" do
214
+ expect(api_client.sanitize_filename('sun')).to eq('sun')
215
+ expect(api_client.sanitize_filename('sun.gif')).to eq('sun.gif')
216
+ expect(api_client.sanitize_filename('../sun.gif')).to eq('sun.gif')
217
+ expect(api_client.sanitize_filename('/var/tmp/sun.gif')).to eq('sun.gif')
218
+ expect(api_client.sanitize_filename('./sun.gif')).to eq('sun.gif')
219
+ expect(api_client.sanitize_filename('..\sun.gif')).to eq('sun.gif')
220
+ expect(api_client.sanitize_filename('\var\tmp\sun.gif')).to eq('sun.gif')
221
+ expect(api_client.sanitize_filename('c:\var\tmp\sun.gif')).to eq('sun.gif')
222
+ expect(api_client.sanitize_filename('.\sun.gif')).to eq('sun.gif')
223
+ end
224
+ end
225
+ end
@@ -0,0 +1,41 @@
1
+ =begin
2
+ #Smooch
3
+
4
+ #The Smooch API is a unified interface for powering messaging in your customer experiences across every channel. Our API speeds access to new markets, reduces time to ship, eliminates complexity, and helps you build the best experiences for your customers. For more information, visit our [official documentation](https://docs.smooch.io).
5
+
6
+ OpenAPI spec version: 1
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+
10
+ =end
11
+
12
+ require 'spec_helper'
13
+
14
+ describe SmoochApi::Configuration do
15
+ let(:config) { SmoochApi::Configuration.default }
16
+
17
+ before(:each) do
18
+ # uncomment below to setup host and base_path
19
+ #require 'URI'
20
+ #uri = URI.parse("https://api.smooch.io/v1")
21
+ #SmoochApi.configure do |c|
22
+ # c.host = uri.host
23
+ # c.base_path = uri.path
24
+ #end
25
+ end
26
+
27
+ describe '#base_url' do
28
+ it 'should have the default value' do
29
+ # uncomment below to test default value of the base path
30
+ #expect(config.base_url).to eq("https://api.smooch.io/v1")
31
+ end
32
+
33
+ it 'should remove trailing slashes' do
34
+ [nil, '', '/', '//'].each do |base_path|
35
+ config.base_path = base_path
36
+ # uncomment below to test trailing slashes
37
+ #expect(config.base_url).to eq("https://api.smooch.io/v1")
38
+ end
39
+ end
40
+ end
41
+ end
@@ -0,0 +1,110 @@
1
+ =begin
2
+ #Smooch
3
+
4
+ #The Smooch API is a unified interface for powering messaging in your customer experiences across every channel. Our API speeds access to new markets, reduces time to ship, eliminates complexity, and helps you build the best experiences for your customers. For more information, visit our [official documentation](https://docs.smooch.io).
5
+
6
+ OpenAPI spec version: 1
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+
10
+ =end
11
+
12
+ # load the gem
13
+ require 'smooch-api'
14
+
15
+ # The following was generated by the `rspec --init` command. Conventionally, all
16
+ # specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
17
+ # The generated `.rspec` file contains `--require spec_helper` which will cause
18
+ # this file to always be loaded, without a need to explicitly require it in any
19
+ # files.
20
+ #
21
+ # Given that it is always loaded, you are encouraged to keep this file as
22
+ # light-weight as possible. Requiring heavyweight dependencies from this file
23
+ # will add to the boot time of your test suite on EVERY test run, even for an
24
+ # individual file that may not need all of that loaded. Instead, consider making
25
+ # a separate helper file that requires the additional dependencies and performs
26
+ # the additional setup, and require it from the spec files that actually need
27
+ # it.
28
+ #
29
+ # The `.rspec` file also contains a few flags that are not defaults but that
30
+ # users commonly want.
31
+ #
32
+ # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
33
+ RSpec.configure do |config|
34
+ # rspec-expectations config goes here. You can use an alternate
35
+ # assertion/expectation library such as wrong or the stdlib/minitest
36
+ # assertions if you prefer.
37
+ config.expect_with :rspec do |expectations|
38
+ # This option will default to `true` in RSpec 4. It makes the `description`
39
+ # and `failure_message` of custom matchers include text for helper methods
40
+ # defined using `chain`, e.g.:
41
+ # be_bigger_than(2).and_smaller_than(4).description
42
+ # # => "be bigger than 2 and smaller than 4"
43
+ # ...rather than:
44
+ # # => "be bigger than 2"
45
+ expectations.include_chain_clauses_in_custom_matcher_descriptions = true
46
+ end
47
+
48
+ # rspec-mocks config goes here. You can use an alternate test double
49
+ # library (such as bogus or mocha) by changing the `mock_with` option here.
50
+ config.mock_with :rspec do |mocks|
51
+ # Prevents you from mocking or stubbing a method that does not exist on
52
+ # a real object. This is generally recommended, and will default to
53
+ # `true` in RSpec 4.
54
+ mocks.verify_partial_doubles = true
55
+ end
56
+
57
+ # The settings below are suggested to provide a good initial experience
58
+ # with RSpec, but feel free to customize to your heart's content.
59
+ =begin
60
+ # These two settings work together to allow you to limit a spec run
61
+ # to individual examples or groups you care about by tagging them with
62
+ # `:focus` metadata. When nothing is tagged with `:focus`, all examples
63
+ # get run.
64
+ config.filter_run :focus
65
+ config.run_all_when_everything_filtered = true
66
+
67
+ # Allows RSpec to persist some state between runs in order to support
68
+ # the `--only-failures` and `--next-failure` CLI options. We recommend
69
+ # you configure your source control system to ignore this file.
70
+ config.example_status_persistence_file_path = "spec/examples.txt"
71
+
72
+ # Limits the available syntax to the non-monkey patched syntax that is
73
+ # recommended. For more details, see:
74
+ # - http://rspec.info/blog/2012/06/rspecs-new-expectation-syntax/
75
+ # - http://www.teaisaweso.me/blog/2013/05/27/rspecs-new-message-expectation-syntax/
76
+ # - http://rspec.info/blog/2014/05/notable-changes-in-rspec-3/#zero-monkey-patching-mode
77
+ config.disable_monkey_patching!
78
+
79
+ # This setting enables warnings. It's recommended, but in some cases may
80
+ # be too noisy due to issues in dependencies.
81
+ config.warnings = true
82
+
83
+ # Many RSpec users commonly either run the entire suite or an individual
84
+ # file, and it's useful to allow more verbose output when running an
85
+ # individual spec file.
86
+ if config.files_to_run.one?
87
+ # Use the documentation formatter for detailed output,
88
+ # unless a formatter has already been configured
89
+ # (e.g. via a command-line flag).
90
+ config.default_formatter = 'doc'
91
+ end
92
+
93
+ # Print the 10 slowest examples and example groups at the
94
+ # end of the spec run, to help surface which specs are running
95
+ # particularly slow.
96
+ config.profile_examples = 10
97
+
98
+ # Run specs in random order to surface order dependencies. If you find an
99
+ # order dependency and want to debug it, you can fix the order by providing
100
+ # the seed, which is printed after each run.
101
+ # --seed 1234
102
+ config.order = :random
103
+
104
+ # Seed global randomization in this process using the `--seed` CLI option.
105
+ # Setting this allows you to use `--seed` to deterministically reproduce
106
+ # test failures related to randomization by passing the same `--seed` value
107
+ # as the one that triggered the failure.
108
+ Kernel.srand config.seed
109
+ =end
110
+ end
metadata ADDED
@@ -0,0 +1,349 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: smooch-api
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Smooch
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2017-03-21 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: typhoeus
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.0'
20
+ - - ">="
21
+ - !ruby/object:Gem::Version
22
+ version: 1.0.1
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '1.0'
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: 1.0.1
33
+ - !ruby/object:Gem::Dependency
34
+ name: json
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '1.8'
40
+ - - ">="
41
+ - !ruby/object:Gem::Version
42
+ version: 1.8.3
43
+ type: :runtime
44
+ prerelease: false
45
+ version_requirements: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - "~>"
48
+ - !ruby/object:Gem::Version
49
+ version: '1.8'
50
+ - - ">="
51
+ - !ruby/object:Gem::Version
52
+ version: 1.8.3
53
+ - !ruby/object:Gem::Dependency
54
+ name: rspec
55
+ requirement: !ruby/object:Gem::Requirement
56
+ requirements:
57
+ - - "~>"
58
+ - !ruby/object:Gem::Version
59
+ version: '3.4'
60
+ - - ">="
61
+ - !ruby/object:Gem::Version
62
+ version: 3.4.0
63
+ type: :development
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - "~>"
68
+ - !ruby/object:Gem::Version
69
+ version: '3.4'
70
+ - - ">="
71
+ - !ruby/object:Gem::Version
72
+ version: 3.4.0
73
+ - !ruby/object:Gem::Dependency
74
+ name: vcr
75
+ requirement: !ruby/object:Gem::Requirement
76
+ requirements:
77
+ - - "~>"
78
+ - !ruby/object:Gem::Version
79
+ version: '3.0'
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: 3.0.1
83
+ type: :development
84
+ prerelease: false
85
+ version_requirements: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '3.0'
90
+ - - ">="
91
+ - !ruby/object:Gem::Version
92
+ version: 3.0.1
93
+ - !ruby/object:Gem::Dependency
94
+ name: webmock
95
+ requirement: !ruby/object:Gem::Requirement
96
+ requirements:
97
+ - - "~>"
98
+ - !ruby/object:Gem::Version
99
+ version: '1.24'
100
+ - - ">="
101
+ - !ruby/object:Gem::Version
102
+ version: 1.24.3
103
+ type: :development
104
+ prerelease: false
105
+ version_requirements: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: '1.24'
110
+ - - ">="
111
+ - !ruby/object:Gem::Version
112
+ version: 1.24.3
113
+ - !ruby/object:Gem::Dependency
114
+ name: autotest
115
+ requirement: !ruby/object:Gem::Requirement
116
+ requirements:
117
+ - - "~>"
118
+ - !ruby/object:Gem::Version
119
+ version: '4.4'
120
+ - - ">="
121
+ - !ruby/object:Gem::Version
122
+ version: 4.4.6
123
+ type: :development
124
+ prerelease: false
125
+ version_requirements: !ruby/object:Gem::Requirement
126
+ requirements:
127
+ - - "~>"
128
+ - !ruby/object:Gem::Version
129
+ version: '4.4'
130
+ - - ">="
131
+ - !ruby/object:Gem::Version
132
+ version: 4.4.6
133
+ - !ruby/object:Gem::Dependency
134
+ name: autotest-rails-pure
135
+ requirement: !ruby/object:Gem::Requirement
136
+ requirements:
137
+ - - "~>"
138
+ - !ruby/object:Gem::Version
139
+ version: '4.1'
140
+ - - ">="
141
+ - !ruby/object:Gem::Version
142
+ version: 4.1.2
143
+ type: :development
144
+ prerelease: false
145
+ version_requirements: !ruby/object:Gem::Requirement
146
+ requirements:
147
+ - - "~>"
148
+ - !ruby/object:Gem::Version
149
+ version: '4.1'
150
+ - - ">="
151
+ - !ruby/object:Gem::Version
152
+ version: 4.1.2
153
+ - !ruby/object:Gem::Dependency
154
+ name: autotest-growl
155
+ requirement: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - "~>"
158
+ - !ruby/object:Gem::Version
159
+ version: '0.2'
160
+ - - ">="
161
+ - !ruby/object:Gem::Version
162
+ version: 0.2.16
163
+ type: :development
164
+ prerelease: false
165
+ version_requirements: !ruby/object:Gem::Requirement
166
+ requirements:
167
+ - - "~>"
168
+ - !ruby/object:Gem::Version
169
+ version: '0.2'
170
+ - - ">="
171
+ - !ruby/object:Gem::Version
172
+ version: 0.2.16
173
+ - !ruby/object:Gem::Dependency
174
+ name: autotest-fsevent
175
+ requirement: !ruby/object:Gem::Requirement
176
+ requirements:
177
+ - - "~>"
178
+ - !ruby/object:Gem::Version
179
+ version: '0.2'
180
+ - - ">="
181
+ - !ruby/object:Gem::Version
182
+ version: 0.2.11
183
+ type: :development
184
+ prerelease: false
185
+ version_requirements: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - "~>"
188
+ - !ruby/object:Gem::Version
189
+ version: '0.2'
190
+ - - ">="
191
+ - !ruby/object:Gem::Version
192
+ version: 0.2.11
193
+ description: The Smooch API is a unified interface for powering messaging in your
194
+ customer experiences across every channel. Our API speeds access to new markets,
195
+ reduces time to ship, eliminates complexity, and helps you build the best experiences
196
+ for your customers. For more information, visit our [official documentation](https://docs.smooch.io).
197
+ email:
198
+ - ''
199
+ executables: []
200
+ extensions: []
201
+ extra_rdoc_files: []
202
+ files:
203
+ - Gemfile
204
+ - README.md
205
+ - Rakefile
206
+ - docs/Action.md
207
+ - docs/App.md
208
+ - docs/AppApi.md
209
+ - docs/AppCreate.md
210
+ - docs/AppResponse.md
211
+ - docs/AppUser.md
212
+ - docs/AppUserApi.md
213
+ - docs/AppUserLink.md
214
+ - docs/AppUserPreCreate.md
215
+ - docs/AppUserResponse.md
216
+ - docs/AppUserUpdate.md
217
+ - docs/Client.md
218
+ - docs/ClientInfo.md
219
+ - docs/Conversation.md
220
+ - docs/ConversationApi.md
221
+ - docs/Destination.md
222
+ - docs/DeviceInit.md
223
+ - docs/DeviceResponse.md
224
+ - docs/DeviceUpdate.md
225
+ - docs/DisplaySettings.md
226
+ - docs/Event.md
227
+ - docs/GetMessagesResponse.md
228
+ - docs/Init.md
229
+ - docs/InitApi.md
230
+ - docs/InitResponse.md
231
+ - docs/Integration.md
232
+ - docs/IntegrationApi.md
233
+ - docs/IntegrationCreate.md
234
+ - docs/IntegrationResponse.md
235
+ - docs/JwtResponse.md
236
+ - docs/ListAppsResponse.md
237
+ - docs/ListIntegrationsResponse.md
238
+ - docs/ListSecretKeysResponse.md
239
+ - docs/ListWebhooksResponse.md
240
+ - docs/Menu.md
241
+ - docs/MenuApi.md
242
+ - docs/MenuItem.md
243
+ - docs/MenuResponse.md
244
+ - docs/Message.md
245
+ - docs/MessageItem.md
246
+ - docs/MessagePost.md
247
+ - docs/MessageResponse.md
248
+ - docs/PostMessagesResponse.md
249
+ - docs/SecretKey.md
250
+ - docs/SecretKeyCreate.md
251
+ - docs/SecretKeyResponse.md
252
+ - docs/TrackEventResponse.md
253
+ - docs/TypingActivityTrigger.md
254
+ - docs/Webhook.md
255
+ - docs/WebhookApi.md
256
+ - docs/WebhookCreate.md
257
+ - docs/WebhookResponse.md
258
+ - docs/WebhookUpdate.md
259
+ - git_push.sh
260
+ - lib/smooch-api.rb
261
+ - lib/smooch-api/api/app_api.rb
262
+ - lib/smooch-api/api/app_user_api.rb
263
+ - lib/smooch-api/api/conversation_api.rb
264
+ - lib/smooch-api/api/init_api.rb
265
+ - lib/smooch-api/api/integration_api.rb
266
+ - lib/smooch-api/api/menu_api.rb
267
+ - lib/smooch-api/api/webhook_api.rb
268
+ - lib/smooch-api/api_client.rb
269
+ - lib/smooch-api/api_error.rb
270
+ - lib/smooch-api/configuration.rb
271
+ - lib/smooch-api/models/action.rb
272
+ - lib/smooch-api/models/app.rb
273
+ - lib/smooch-api/models/app_create.rb
274
+ - lib/smooch-api/models/app_response.rb
275
+ - lib/smooch-api/models/app_user.rb
276
+ - lib/smooch-api/models/app_user_link.rb
277
+ - lib/smooch-api/models/app_user_pre_create.rb
278
+ - lib/smooch-api/models/app_user_response.rb
279
+ - lib/smooch-api/models/app_user_update.rb
280
+ - lib/smooch-api/models/client.rb
281
+ - lib/smooch-api/models/client_info.rb
282
+ - lib/smooch-api/models/conversation.rb
283
+ - lib/smooch-api/models/destination.rb
284
+ - lib/smooch-api/models/device_init.rb
285
+ - lib/smooch-api/models/device_response.rb
286
+ - lib/smooch-api/models/device_update.rb
287
+ - lib/smooch-api/models/display_settings.rb
288
+ - lib/smooch-api/models/event.rb
289
+ - lib/smooch-api/models/get_messages_response.rb
290
+ - lib/smooch-api/models/init.rb
291
+ - lib/smooch-api/models/init_response.rb
292
+ - lib/smooch-api/models/integration.rb
293
+ - lib/smooch-api/models/integration_create.rb
294
+ - lib/smooch-api/models/integration_response.rb
295
+ - lib/smooch-api/models/jwt_response.rb
296
+ - lib/smooch-api/models/list_apps_response.rb
297
+ - lib/smooch-api/models/list_integrations_response.rb
298
+ - lib/smooch-api/models/list_secret_keys_response.rb
299
+ - lib/smooch-api/models/list_webhooks_response.rb
300
+ - lib/smooch-api/models/menu.rb
301
+ - lib/smooch-api/models/menu_item.rb
302
+ - lib/smooch-api/models/menu_response.rb
303
+ - lib/smooch-api/models/message.rb
304
+ - lib/smooch-api/models/message_item.rb
305
+ - lib/smooch-api/models/message_post.rb
306
+ - lib/smooch-api/models/message_response.rb
307
+ - lib/smooch-api/models/post_messages_response.rb
308
+ - lib/smooch-api/models/secret_key.rb
309
+ - lib/smooch-api/models/secret_key_create.rb
310
+ - lib/smooch-api/models/secret_key_response.rb
311
+ - lib/smooch-api/models/track_event_response.rb
312
+ - lib/smooch-api/models/typing_activity_trigger.rb
313
+ - lib/smooch-api/models/webhook.rb
314
+ - lib/smooch-api/models/webhook_create.rb
315
+ - lib/smooch-api/models/webhook_response.rb
316
+ - lib/smooch-api/models/webhook_update.rb
317
+ - lib/smooch-api/version.rb
318
+ - smooch-api.gemspec
319
+ - spec/api_client_spec.rb
320
+ - spec/configuration_spec.rb
321
+ - spec/spec_helper.rb
322
+ homepage: https://github.com/smooch/smooch-ruby
323
+ licenses:
324
+ - https://smooch.io/terms/
325
+ metadata: {}
326
+ post_install_message:
327
+ rdoc_options: []
328
+ require_paths:
329
+ - lib
330
+ required_ruby_version: !ruby/object:Gem::Requirement
331
+ requirements:
332
+ - - ">="
333
+ - !ruby/object:Gem::Version
334
+ version: '1.9'
335
+ required_rubygems_version: !ruby/object:Gem::Requirement
336
+ requirements:
337
+ - - ">="
338
+ - !ruby/object:Gem::Version
339
+ version: '0'
340
+ requirements: []
341
+ rubyforge_project:
342
+ rubygems_version: 2.4.5.2
343
+ signing_key:
344
+ specification_version: 4
345
+ summary: Smooch Ruby Gem
346
+ test_files:
347
+ - spec/api_client_spec.rb
348
+ - spec/configuration_spec.rb
349
+ - spec/spec_helper.rb