sms-uslugi-api 0.6.1 → 0.7.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.
- checksums.yaml +4 -4
- data/.rspec +1 -1
- data/Gemfile.lock +4 -1
- data/README.md +21 -2
- data/Rakefile +10 -10
- data/VERSION +1 -1
- data/lib/sms-uslugi-api.rb +11 -8
- data/sms-uslugi-api.gemspec +3 -7
- data/spec/sms_uslugi_api_spec.rb +43 -16
- metadata +32 -34
- data/fixtures/vcr_cassettes/getPhoneInfo.yml +0 -45
- data/fixtures/vcr_cassettes/info.yml +0 -43
- data/fixtures/vcr_cassettes/send.yml +0 -42
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1b3b17eee515c26c879c1cbc63a5ee49293df14
|
4
|
+
data.tar.gz: 63767ff5c4b7c92b7c8297296681b63878909893
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cc20661d9fc3044b1fd997e482ef63ca7e90f222de41a1dc4f35b6b2834f4f966eded4b4209a25589c23dbc827455cac6326eefa15e40b272e832aabedf9b9a9
|
7
|
+
data.tar.gz: ab1e2dfa6b7156cec356ff1fb245da5fa4fc03ea660ffce6e6a1684504c16bf4e4f5e6f7291f1b70f53ba9437087087c0d0dfbd55f47c2e50a84139835f15ab5
|
data/.rspec
CHANGED
@@ -1,2 +1,2 @@
|
|
1
1
|
--color
|
2
|
-
--format
|
2
|
+
--format doc
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -52,7 +52,17 @@ sms.send 'message in utf8', '81112223333' # отправка SMS получат
|
|
52
52
|
}
|
53
53
|
```
|
54
54
|
|
55
|
-
### send(txt, to,
|
55
|
+
### send(txt, to, options)
|
56
|
+
|
57
|
+
`options` может содержать следующие параметры:
|
58
|
+
|
59
|
+
* idGroup
|
60
|
+
* source
|
61
|
+
* flash
|
62
|
+
* dateTimeSend
|
63
|
+
* onlydelivery
|
64
|
+
* use_alfasource
|
65
|
+
* discountID
|
56
66
|
|
57
67
|
Отправляет SMS с текстом `txt` (должен быть в кодировке utf8) на номер `to`. Остальные параметры идентичны аналогичным из официальной документации: https://lcab.sms-uslugi.ru/send/smsApi#main/lcabApi/send
|
58
68
|
|
@@ -87,6 +97,15 @@ Pull-реквесты приветствуются. Чтобы добавить
|
|
87
97
|
|
88
98
|
PS. При смене информации для авторизации все старые тесты не пройдут, это нормальное поведение. После замены логина и пароля обратно на `demo:demo` всё станет нормально.
|
89
99
|
|
100
|
+
### Что делать, если не работает подстановка своего номера отправителя
|
101
|
+
|
102
|
+
Для того, чтобы использовать своё имя отправителя, требуется сначала зарегистрировать его в личном кабинете и дождаться подтверждения, после чего высылать СМС с использованием прямого канала:
|
103
|
+
|
104
|
+
```ruby
|
105
|
+
@sms.send("teset message", PHONE_NUMBER, source: SOURCE, use_alfasource: 1)
|
106
|
+
# важен последний параметр (1), он отвечает за использование прямого канала
|
107
|
+
```
|
108
|
+
|
90
109
|
## Copyright
|
91
110
|
|
92
|
-
Copyright (c) 2014 Alexander Maslov. See LICENSE.txt for further details.
|
111
|
+
Copyright (c) 2014-2016 Alexander Maslov, Oleg Bobok. See LICENSE.txt for further details.
|
data/Rakefile
CHANGED
@@ -6,7 +6,7 @@ begin
|
|
6
6
|
Bundler.setup(:default, :development)
|
7
7
|
rescue Bundler::BundlerError => e
|
8
8
|
$stderr.puts e.message
|
9
|
-
$stderr.puts
|
9
|
+
$stderr.puts 'Run `bundle install` to install missing gems'
|
10
10
|
exit e.status_code
|
11
11
|
end
|
12
12
|
|
@@ -18,23 +18,23 @@ RSpec::Core::RakeTask.new(:spec)
|
|
18
18
|
require 'jeweler'
|
19
19
|
Jeweler::Tasks.new do |gem|
|
20
20
|
# gem is a Gem::Specification... see http://guides.rubygems.org/specification-reference/ for more options
|
21
|
-
gem.name =
|
22
|
-
gem.homepage =
|
23
|
-
gem.license =
|
24
|
-
gem.summary =
|
25
|
-
gem.description =
|
26
|
-
gem.email =
|
27
|
-
gem.authors = [
|
21
|
+
gem.name = 'sms-uslugi-api'
|
22
|
+
gem.homepage = 'http://github.com/drakmail/sms-uslugi-api'
|
23
|
+
gem.license = 'MIT'
|
24
|
+
gem.summary = 'API for sms-uslugi service'
|
25
|
+
gem.description = 'Sms-uslugi.ru API gem'
|
26
|
+
gem.email = 'drakmail@gmail.com'
|
27
|
+
gem.authors = ['Alexander Maslov']
|
28
28
|
# dependencies defined in Gemfile
|
29
29
|
end
|
30
30
|
Jeweler::RubygemsDotOrgTasks.new
|
31
31
|
|
32
32
|
require 'rdoc/task'
|
33
33
|
Rake::RDocTask.new do |rdoc|
|
34
|
-
version = File.exist?('VERSION') ? File.read('VERSION') :
|
34
|
+
version = File.exist?('VERSION') ? File.read('VERSION') : ''
|
35
35
|
|
36
36
|
rdoc.rdoc_dir = 'rdoc'
|
37
|
-
rdoc.title =
|
37
|
+
rdoc.title = 'sms-uslugi-api #{version}'
|
38
38
|
rdoc.rdoc_files.include('README*')
|
39
39
|
rdoc.rdoc_files.include('lib/**/*.rb')
|
40
40
|
end
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.7.0
|
data/lib/sms-uslugi-api.rb
CHANGED
@@ -20,17 +20,20 @@ class SmsUslugiApi
|
|
20
20
|
|
21
21
|
# https://lcab.sms-uslugi.ru/integration/lcabApi#main/pager/send
|
22
22
|
# txt must be in UTF-8 encoding!
|
23
|
-
def send(txt, to, idGroup = nil, source = nil, flash = 0, dateTimeSend = nil, onlydelivery = 0, use_alfasource = nil, discountID = nil)
|
23
|
+
#def send(txt, to, idGroup = nil, source = nil, flash = 0, dateTimeSend = nil, onlydelivery = 0, use_alfasource = nil, discountID = nil)
|
24
|
+
def send(txt, to, options = {})
|
25
|
+
options.default = nil
|
24
26
|
api_request("sendSms.php", {
|
25
27
|
txt: txt,
|
26
28
|
to: to,
|
27
|
-
idGroup: idGroup,
|
28
|
-
source: source,
|
29
|
-
flash: flash,
|
30
|
-
dateTimeSend: dateTimeSend,
|
31
|
-
onlydelivery: onlydelivery,
|
32
|
-
use_alfasource: use_alfasource,
|
33
|
-
discountID: discountID
|
29
|
+
idGroup: options[:idGroup],
|
30
|
+
source: options[:source],
|
31
|
+
flash: options[:flash],
|
32
|
+
dateTimeSend: options[:dateTimeSend],
|
33
|
+
onlydelivery: options[:onlydelivery],
|
34
|
+
use_alfasource: options[:use_alfasource],
|
35
|
+
discountID: options[:discountID],
|
36
|
+
channel: options[:channel]
|
34
37
|
})
|
35
38
|
end
|
36
39
|
|
data/sms-uslugi-api.gemspec
CHANGED
@@ -5,13 +5,13 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "sms-uslugi-api"
|
8
|
-
s.version = "0.
|
8
|
+
s.version = "0.7.0"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Alexander Maslov"]
|
12
|
-
s.date = "
|
12
|
+
s.date = "2016-06-15"
|
13
13
|
s.description = "Simple gem for send SMS through sms-uslugi service"
|
14
|
-
s.email = "drakmail@
|
14
|
+
s.email = "drakmail@gmail.com"
|
15
15
|
s.extra_rdoc_files = [
|
16
16
|
"LICENSE.txt",
|
17
17
|
"README.md"
|
@@ -26,9 +26,6 @@ Gem::Specification.new do |s|
|
|
26
26
|
"README.md",
|
27
27
|
"Rakefile",
|
28
28
|
"VERSION",
|
29
|
-
"fixtures/vcr_cassettes/getPhoneInfo.yml",
|
30
|
-
"fixtures/vcr_cassettes/info.yml",
|
31
|
-
"fixtures/vcr_cassettes/send.yml",
|
32
29
|
"lib/sms-uslugi-api.rb",
|
33
30
|
"sms-uslugi-api.gemspec",
|
34
31
|
"spec/sms_uslugi_api_spec.rb",
|
@@ -82,4 +79,3 @@ Gem::Specification.new do |s|
|
|
82
79
|
s.add_dependency(%q<coveralls>, [">= 0"])
|
83
80
|
end
|
84
81
|
end
|
85
|
-
|
data/spec/sms_uslugi_api_spec.rb
CHANGED
@@ -1,9 +1,13 @@
|
|
1
1
|
# encoding: UTF-8
|
2
2
|
require "spec_helper"
|
3
3
|
|
4
|
+
file_path = File.join(File.expand_path(File.dirname(__FILE__)), 'settings.yml')
|
5
|
+
settings = YAML.load_file(file_path)['settings'] if File.file?(file_path)
|
6
|
+
settings ||= {}
|
7
|
+
|
4
8
|
describe SmsUslugiApi do
|
5
9
|
before do
|
6
|
-
@sms = SmsUslugiApi.new("
|
10
|
+
@sms = SmsUslugiApi.new("#{settings['login']}", "#{settings['password']}") # Changed in VCR
|
7
11
|
end
|
8
12
|
|
9
13
|
describe "minimal functionality" do
|
@@ -19,14 +23,13 @@ describe SmsUslugiApi do
|
|
19
23
|
expect(info).to include(
|
20
24
|
code: 1,
|
21
25
|
descr: "Операция завершена успешно",
|
22
|
-
account: "
|
23
|
-
ocode: "
|
24
|
-
tarif: "Аванс::
|
25
|
-
price: "0.
|
26
|
-
source: ["systemTest"
|
26
|
+
account: "30.99",
|
27
|
+
ocode: "#{settings['source']}",
|
28
|
+
tarif: "Аванс::67",
|
29
|
+
price: "0.67",
|
30
|
+
source: ["systemTest"],
|
27
31
|
receive_numbers: [
|
28
|
-
|
29
|
-
"79028888888"
|
32
|
+
|
30
33
|
]
|
31
34
|
)
|
32
35
|
end
|
@@ -34,14 +37,38 @@ describe SmsUslugiApi do
|
|
34
37
|
end
|
35
38
|
|
36
39
|
describe "sms sending" do
|
37
|
-
it "should send sms" do
|
38
|
-
VCR.use_cassette("
|
39
|
-
status = @sms.send("Тестовое сообщение", "
|
40
|
+
it "should send sms to me" do
|
41
|
+
VCR.use_cassette("send_me") do
|
42
|
+
status = @sms.send("Тестовое сообщение", "#{settings['phone_me']}", idGroup: nil, source: nil, onlydelivery: '1')
|
43
|
+
expect(status).to include(
|
44
|
+
code: 1,
|
45
|
+
descr: "Успешно обработано",
|
46
|
+
colsmsOfSending: 1,
|
47
|
+
priceOfSending: "0.67"
|
48
|
+
)
|
49
|
+
end
|
50
|
+
end
|
51
|
+
|
52
|
+
it "should send sms to nw" do
|
53
|
+
VCR.use_cassette("send_nw") do
|
54
|
+
status = @sms.send("Тестовое сообщение", "#{settings['phone_nw']}", idGroup: nil, source: nil, onlydelivery: '1')
|
55
|
+
expect(status).to include(
|
56
|
+
code: 1,
|
57
|
+
descr: "Успешно обработано",
|
58
|
+
colsmsOfSending: 1,
|
59
|
+
priceOfSending: "0.67"
|
60
|
+
)
|
61
|
+
end
|
62
|
+
end
|
63
|
+
|
64
|
+
it "should send sms to pr" do
|
65
|
+
VCR.use_cassette("send_pr") do
|
66
|
+
status = @sms.send("Тестовое сообщение", "#{settings['phone_pr']}", idGroup: nil, source: nil, onlydelivery: '1')
|
40
67
|
expect(status).to include(
|
41
68
|
code: 1,
|
42
69
|
descr: "Успешно обработано",
|
43
70
|
colsmsOfSending: 1,
|
44
|
-
priceOfSending: "0.
|
71
|
+
priceOfSending: "0.67"
|
45
72
|
)
|
46
73
|
end
|
47
74
|
end
|
@@ -50,14 +77,14 @@ describe SmsUslugiApi do
|
|
50
77
|
describe "phone number info" do
|
51
78
|
it "should reveice phone number info" do
|
52
79
|
VCR.use_cassette("getPhoneInfo") do
|
53
|
-
phone_info = @sms.get_phone_info("
|
80
|
+
phone_info = @sms.get_phone_info("#{settings['phone_me']}")
|
54
81
|
expect(phone_info).to include(
|
55
82
|
code: 1,
|
56
83
|
descr: "Операция завершена успешно",
|
57
|
-
phone: "
|
84
|
+
phone: "#{settings['phone_me']}",
|
58
85
|
country: "Россия",
|
59
|
-
district: "
|
60
|
-
opsos: "
|
86
|
+
district: "#{settings['my_region']}",
|
87
|
+
opsos: "#{settings['my_operator']} (цифровая подпись)"
|
61
88
|
)
|
62
89
|
end
|
63
90
|
end
|
metadata
CHANGED
@@ -1,189 +1,186 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sms-uslugi-api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexander Maslov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-06-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: shoulda
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rdoc
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - ~>
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '4.1'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - ~>
|
52
|
+
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '4.1'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: bundler
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - ~>
|
59
|
+
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: '1.0'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - ~>
|
66
|
+
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '1.0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: jeweler
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - ~>
|
73
|
+
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
75
|
version: 2.0.1
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - ~>
|
80
|
+
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: 2.0.1
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: simplecov
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- -
|
87
|
+
- - ">="
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: '0'
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- -
|
94
|
+
- - ">="
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: vcr
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
|
-
- -
|
101
|
+
- - ">="
|
102
102
|
- !ruby/object:Gem::Version
|
103
103
|
version: '0'
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- -
|
108
|
+
- - ">="
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: webmock
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
114
114
|
requirements:
|
115
|
-
- -
|
115
|
+
- - ">="
|
116
116
|
- !ruby/object:Gem::Version
|
117
117
|
version: '0'
|
118
118
|
type: :development
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
|
-
- -
|
122
|
+
- - ">="
|
123
123
|
- !ruby/object:Gem::Version
|
124
124
|
version: '0'
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: rake
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
128
128
|
requirements:
|
129
|
-
- -
|
129
|
+
- - ">="
|
130
130
|
- !ruby/object:Gem::Version
|
131
131
|
version: '0'
|
132
132
|
type: :development
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
|
-
- -
|
136
|
+
- - ">="
|
137
137
|
- !ruby/object:Gem::Version
|
138
138
|
version: '0'
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
140
|
name: rspec
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|
142
142
|
requirements:
|
143
|
-
- -
|
143
|
+
- - ">="
|
144
144
|
- !ruby/object:Gem::Version
|
145
145
|
version: '0'
|
146
146
|
type: :development
|
147
147
|
prerelease: false
|
148
148
|
version_requirements: !ruby/object:Gem::Requirement
|
149
149
|
requirements:
|
150
|
-
- -
|
150
|
+
- - ">="
|
151
151
|
- !ruby/object:Gem::Version
|
152
152
|
version: '0'
|
153
153
|
- !ruby/object:Gem::Dependency
|
154
154
|
name: coveralls
|
155
155
|
requirement: !ruby/object:Gem::Requirement
|
156
156
|
requirements:
|
157
|
-
- -
|
157
|
+
- - ">="
|
158
158
|
- !ruby/object:Gem::Version
|
159
159
|
version: '0'
|
160
160
|
type: :development
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
|
-
- -
|
164
|
+
- - ">="
|
165
165
|
- !ruby/object:Gem::Version
|
166
166
|
version: '0'
|
167
167
|
description: Simple gem for send SMS through sms-uslugi service
|
168
|
-
email: drakmail@
|
168
|
+
email: drakmail@gmail.com
|
169
169
|
executables: []
|
170
170
|
extensions: []
|
171
171
|
extra_rdoc_files:
|
172
172
|
- LICENSE.txt
|
173
173
|
- README.md
|
174
174
|
files:
|
175
|
-
- .document
|
176
|
-
- .rspec
|
177
|
-
- .travis.yml
|
175
|
+
- ".document"
|
176
|
+
- ".rspec"
|
177
|
+
- ".travis.yml"
|
178
178
|
- Gemfile
|
179
179
|
- Gemfile.lock
|
180
180
|
- LICENSE.txt
|
181
181
|
- README.md
|
182
182
|
- Rakefile
|
183
183
|
- VERSION
|
184
|
-
- fixtures/vcr_cassettes/getPhoneInfo.yml
|
185
|
-
- fixtures/vcr_cassettes/info.yml
|
186
|
-
- fixtures/vcr_cassettes/send.yml
|
187
184
|
- lib/sms-uslugi-api.rb
|
188
185
|
- sms-uslugi-api.gemspec
|
189
186
|
- spec/sms_uslugi_api_spec.rb
|
@@ -198,18 +195,19 @@ require_paths:
|
|
198
195
|
- lib
|
199
196
|
required_ruby_version: !ruby/object:Gem::Requirement
|
200
197
|
requirements:
|
201
|
-
- -
|
198
|
+
- - ">="
|
202
199
|
- !ruby/object:Gem::Version
|
203
200
|
version: '0'
|
204
201
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
205
202
|
requirements:
|
206
|
-
- -
|
203
|
+
- - ">="
|
207
204
|
- !ruby/object:Gem::Version
|
208
205
|
version: '0'
|
209
206
|
requirements: []
|
210
207
|
rubyforge_project:
|
211
|
-
rubygems_version: 2.
|
208
|
+
rubygems_version: 2.5.1
|
212
209
|
signing_key:
|
213
210
|
specification_version: 4
|
214
211
|
summary: API for sms-uslugi service
|
215
212
|
test_files: []
|
213
|
+
has_rdoc:
|
@@ -1,45 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: get
|
5
|
-
uri: https://lcab.sms-uslugi.ru/lcabApi/getPhoneInfo.php?login=demo&password=demo&phone=79000000000
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.8.8
|
12
|
-
Accept-Encoding:
|
13
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
14
|
-
Accept:
|
15
|
-
- '*/*'
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 200
|
19
|
-
message: OK
|
20
|
-
headers:
|
21
|
-
Server:
|
22
|
-
- nginx
|
23
|
-
Date:
|
24
|
-
- Sat, 22 Feb 2014 19:05:48 GMT
|
25
|
-
Content-Type:
|
26
|
-
- text/json; charset:utf-8;
|
27
|
-
Transfer-Encoding:
|
28
|
-
- chunked
|
29
|
-
Connection:
|
30
|
-
- keep-alive
|
31
|
-
X-Powered-By:
|
32
|
-
- PHP/5.5.9
|
33
|
-
X-Content-Type-Options:
|
34
|
-
- nosniff
|
35
|
-
X-Xss-Protection:
|
36
|
-
- 1; mode=block;
|
37
|
-
body:
|
38
|
-
encoding: UTF-8
|
39
|
-
string: '{"code":1,"descr":"\u041e\u043f\u0435\u0440\u0430\u0446\u0438\u044f
|
40
|
-
\u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0430 \u0443\u0441\u043f\u0435\u0448\u043d\u043e","phone":"79000000000","district":"\u041a\u0440\u0430\u0441\u043d\u043e\u0434\u0430\u0440\u0441\u043a\u0438\u0439
|
41
|
-
\u043a\u0440\u0430\u0439","country":"\u0420\u043e\u0441\u0441\u0438\u044f","opsos":"\u0422\u0435\u043b\u0435
|
42
|
-
2 (\u0446\u0438\u0444\u0440\u043e\u0432\u0430\u044f \u043f\u043e\u0434\u043f\u0438\u0441\u044c)"}'
|
43
|
-
http_version:
|
44
|
-
recorded_at: Sat, 22 Feb 2014 19:05:47 GMT
|
45
|
-
recorded_with: VCR 2.6.0
|
@@ -1,43 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: get
|
5
|
-
uri: https://lcab.sms-uslugi.ru/lcabApi/info.php?login=demo&password=demo
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.8.8
|
12
|
-
Accept-Encoding:
|
13
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
14
|
-
Accept:
|
15
|
-
- '*/*'
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 200
|
19
|
-
message: OK
|
20
|
-
headers:
|
21
|
-
Server:
|
22
|
-
- nginx
|
23
|
-
Date:
|
24
|
-
- Sat, 22 Feb 2014 11:06:49 GMT
|
25
|
-
Content-Type:
|
26
|
-
- text/json; charset:utf-8;
|
27
|
-
Transfer-Encoding:
|
28
|
-
- chunked
|
29
|
-
Connection:
|
30
|
-
- keep-alive
|
31
|
-
X-Powered-By:
|
32
|
-
- PHP/5.5.9
|
33
|
-
X-Content-Type-Options:
|
34
|
-
- nosniff
|
35
|
-
X-Xss-Protection:
|
36
|
-
- 1; mode=block;
|
37
|
-
body:
|
38
|
-
encoding: UTF-8
|
39
|
-
string: '{"code":1,"descr":"\u041e\u043f\u0435\u0440\u0430\u0446\u0438\u044f
|
40
|
-
\u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0430 \u0443\u0441\u043f\u0435\u0448\u043d\u043e","account":"583.12","ocode":"80009999999","tarif":"\u0410\u0432\u0430\u043d\u0441::50","price":"0.50","source":["systemTest","Ded Moroz"],"receive_numbers":["79029999999","79028888888"],"userAccess":{"canExportContacts":"1","canDeleteGroups":"1","canDeleteContacts":"1","canConfig":"1","canViewReportNums":"1","canViewNumbersInPhonebook":"1","canEditPhonebook":"1","canEditContacts":"1","canUseAllGroups":"1","canModifyContent":"1","canDealerConfig":"1","canTarifConfig":"1","canManageAllOrgs":"1","canReportsCenter":"1","canViewAllReports":"1","canTarifInfo":"1","canChangeTarif":"1","canManageInputNumbers":"1","canManageClientLoginPassword":"1","canSendSMS":"1","canDopModules":"1","canOnline":"1","canMakePayment":"1","canChangeUseAlfaSourceAll":"1","canPm":"1","canOrgList":"1","canDutyAndSkipped":"0","canUseAllSmsTemplates":"1","canPager":"1","canMyFinReports":"1","canDoc":"1"}}'
|
41
|
-
http_version:
|
42
|
-
recorded_at: Sat, 22 Feb 2014 11:06:49 GMT
|
43
|
-
recorded_with: VCR 2.6.0
|
@@ -1,42 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: get
|
5
|
-
uri: https://lcab.sms-uslugi.ru/lcabApi/sendSms.php?dateTimeSend&discountID&flash=0&idGroup&login=demo&onlydelivery=0&password=demo&source=79021111111&to=81111111111&txt=%D0%A2%D0%B5%D1%81%D1%82%D0%BE%D0%B2%D0%BE%D0%B5%20%D1%81%D0%BE%D0%BE%D0%B1%D1%89%D0%B5%D0%BD%D0%B8%D0%B5&use_alfasource
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.8.8
|
12
|
-
Accept-Encoding:
|
13
|
-
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
14
|
-
Accept:
|
15
|
-
- '*/*'
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 200
|
19
|
-
message: OK
|
20
|
-
headers:
|
21
|
-
Server:
|
22
|
-
- nginx
|
23
|
-
Date:
|
24
|
-
- Sat, 22 Feb 2014 11:37:20 GMT
|
25
|
-
Content-Type:
|
26
|
-
- text/json; charset:utf-8;
|
27
|
-
Transfer-Encoding:
|
28
|
-
- chunked
|
29
|
-
Connection:
|
30
|
-
- keep-alive
|
31
|
-
X-Powered-By:
|
32
|
-
- PHP/5.5.9
|
33
|
-
X-Content-Type-Options:
|
34
|
-
- nosniff
|
35
|
-
X-Xss-Protection:
|
36
|
-
- 1; mode=block;
|
37
|
-
body:
|
38
|
-
encoding: UTF-8
|
39
|
-
string: '{"code":1,"descr":"\u0423\u0441\u043f\u0435\u0448\u043d\u043e \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u0430\u043d\u043e","smsid":"0d46ec94e6ed10c91c66737dbf12e910","colsmsOfSending":1,"priceOfSending":"0.50","colAbonentSend":1}'
|
40
|
-
http_version:
|
41
|
-
recorded_at: Sat, 22 Feb 2014 11:37:20 GMT
|
42
|
-
recorded_with: VCR 2.6.0
|