mifiel 1.1.3 → 1.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.rubocop.yml +3 -0
- data/Gemfile +1 -1
- data/README.md +4 -2
- data/lib/mifiel/document.rb +2 -0
- data/lib/mifiel/version.rb +1 -1
- data/mifiel.gemspec +6 -4
- metadata +16 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dd8499fb02568bbba061b64bcd872a149bf526cf
|
4
|
+
data.tar.gz: 2a9a5c8ce4de56badb7923eced2bf5057b122643
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce68f79d6f9d1661aa99b4ac08699d181cf7717216b77c7b960ee8619140817d057dbee888a28d4ab493647a855f799e48c57e7a1423ae1e45a894a7734b4ddc
|
7
|
+
data.tar.gz: e8b6eb2b56efab4eff1550446c88bbd1a9af2b31aac6142afb896d4915240af9330bb949d88260c75ca1283ae291d537b33bb91edbf7739fbe6aed1fbdd14872
|
data/.gitignore
CHANGED
data/.rubocop.yml
CHANGED
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -26,9 +26,11 @@ Or install it yourself as:
|
|
26
26
|
|
27
27
|
## Usage
|
28
28
|
|
29
|
-
|
29
|
+
For your convenience Mifiel offers a Sandbox environment where you can confidently test your code.
|
30
30
|
|
31
|
-
|
31
|
+
To start using the API in the Sandbox environment you need to first create an account at [sandbox.mifiel.com](https://sandbox.mifiel.com).
|
32
|
+
|
33
|
+
Once you have an account you will need an APP_ID and an APP_SECRET which you can generate in [sandbox.mifiel.com/access_tokens](https://sandbox.mifiel.com/access_tokens).
|
32
34
|
|
33
35
|
Then you can configure the gem with:
|
34
36
|
|
data/lib/mifiel/document.rb
CHANGED
@@ -1,4 +1,5 @@
|
|
1
1
|
require 'open3'
|
2
|
+
require 'api-auth'
|
2
3
|
|
3
4
|
module Mifiel
|
4
5
|
class Document < Mifiel::Base
|
@@ -24,6 +25,7 @@ module Mifiel
|
|
24
25
|
name: name
|
25
26
|
}
|
26
27
|
payload = args.merge(payload)
|
28
|
+
payload.reject! { |_k, v| v.nil? }
|
27
29
|
response = process_request('/documents', :post, payload)
|
28
30
|
Mifiel::Document.new(JSON.parse(response))
|
29
31
|
end
|
data/lib/mifiel/version.rb
CHANGED
data/mifiel.gemspec
CHANGED
@@ -21,13 +21,15 @@ Gem::Specification.new do |spec|
|
|
21
21
|
|
22
22
|
spec.add_runtime_dependency 'rest-client', '~> 1.7'
|
23
23
|
spec.add_runtime_dependency 'json', '> 0'
|
24
|
-
spec.add_runtime_dependency 'api-auth', '
|
24
|
+
spec.add_runtime_dependency 'api-auth', '~> 1.4'
|
25
|
+
# Use Gem::Version to parse the Ruby version for reliable comparison
|
26
|
+
# ActiveSupport 5+ requires Ruby 2.2.2
|
25
27
|
if Gem::Version.new(RUBY_VERSION) > Gem::Version.new('2.2.2')
|
26
28
|
spec.add_runtime_dependency 'activesupport'
|
27
29
|
else
|
28
|
-
spec.add_runtime_dependency 'activesupport', '
|
30
|
+
spec.add_runtime_dependency 'activesupport', '< 5.0.0'
|
29
31
|
end
|
30
|
-
spec.add_runtime_dependency 'flexirest'
|
32
|
+
spec.add_runtime_dependency 'flexirest', '~> 1.3.35'
|
31
33
|
|
32
34
|
spec.add_development_dependency 'bundler', '~> 1.6'
|
33
35
|
spec.add_development_dependency 'rake', '~> 10.0'
|
@@ -37,6 +39,6 @@ Gem::Specification.new do |spec|
|
|
37
39
|
spec.add_development_dependency 'bump', '~> 0.5', '>= 0.5.3'
|
38
40
|
spec.add_development_dependency 'webmock', '~> 1.22', '>= 1.22.2'
|
39
41
|
spec.add_development_dependency 'sinatra', '~> 1.4', '>= 1.4.7'
|
40
|
-
spec.add_development_dependency 'rubocop', '
|
42
|
+
spec.add_development_dependency 'rubocop', '0.47.1'
|
41
43
|
spec.add_development_dependency 'simplecov', '~> 0.11'
|
42
44
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mifiel
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Genaro Madrid
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-07-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rest-client
|
@@ -42,44 +42,44 @@ dependencies:
|
|
42
42
|
name: api-auth
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '1.4'
|
48
48
|
type: :runtime
|
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: '1.4'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: activesupport
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - "<"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: 5.0.0
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - "<"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: 5.0.0
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: flexirest
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - "
|
73
|
+
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
75
|
+
version: 1.3.35
|
76
76
|
type: :runtime
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - "
|
80
|
+
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
82
|
+
version: 1.3.35
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: bundler
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -232,16 +232,16 @@ dependencies:
|
|
232
232
|
name: rubocop
|
233
233
|
requirement: !ruby/object:Gem::Requirement
|
234
234
|
requirements:
|
235
|
-
- -
|
235
|
+
- - '='
|
236
236
|
- !ruby/object:Gem::Version
|
237
|
-
version:
|
237
|
+
version: 0.47.1
|
238
238
|
type: :development
|
239
239
|
prerelease: false
|
240
240
|
version_requirements: !ruby/object:Gem::Requirement
|
241
241
|
requirements:
|
242
|
-
- -
|
242
|
+
- - '='
|
243
243
|
- !ruby/object:Gem::Version
|
244
|
-
version:
|
244
|
+
version: 0.47.1
|
245
245
|
- !ruby/object:Gem::Dependency
|
246
246
|
name: simplecov
|
247
247
|
requirement: !ruby/object:Gem::Requirement
|