mercadopago-sdk 0.3.6 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.gitignore +2 -1
- data/.travis.yml +14 -0
- data/lib/mercadopago.rb +10 -2
- data/lib/version.rb +2 -1
- data/travis_Gemfile +4 -0
- metadata +5 -5
- data/mercadopago-sdk-0.3.2.gem +0 -0
- data/mercadopago-sdk-0.3.3.gem +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 89495678416603a35547582361f007bebb19d11d
|
4
|
+
data.tar.gz: 4ff15007633d63649cd97d86dbd6e76e2b6411fd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3ba1dca8bf70df2e3da0eef2436e8c3f14572541fd4f6b9e9cde4f533fe2f6864f80512cfba081eb4813b58a0791a596f5832fdfac5102b65381e71571d2a222
|
7
|
+
data.tar.gz: 1f04c650559dd8398b22d19272956b69af5fbd6b1b297eeca8d8acfa6a7b59269e6c796eed3c2d3f2192c564d197d4450560d166fdab4e065de124b590a557a8
|
data/.gitignore
CHANGED
data/.travis.yml
ADDED
data/lib/mercadopago.rb
CHANGED
@@ -69,7 +69,9 @@ class MercadoPago
|
|
69
69
|
end
|
70
70
|
|
71
71
|
uri_prefix = @sandbox ? "/sandbox" : ""
|
72
|
-
|
72
|
+
|
73
|
+
@rest_client.get(uri_prefix + "/v1/payments/" + id + "?access_token=" + access_token)
|
74
|
+
|
73
75
|
end
|
74
76
|
|
75
77
|
def get_payment_info(id)
|
@@ -95,8 +97,10 @@ class MercadoPago
|
|
95
97
|
return e.message
|
96
98
|
end
|
97
99
|
|
100
|
+
|
98
101
|
refund_status = {}
|
99
102
|
@rest_client.post("/v1/payments/" + id + "/refunds?access_token=" + access_token, refund_status)
|
103
|
+
|
100
104
|
end
|
101
105
|
|
102
106
|
# Cancel pending payment
|
@@ -137,7 +141,9 @@ class MercadoPago
|
|
137
141
|
filters = build_query(filters)
|
138
142
|
|
139
143
|
uri_prefix = @sandbox ? "/sandbox" : ""
|
140
|
-
|
144
|
+
|
145
|
+
@rest_client.get(uri_prefix + "/v1/payments/search?" + filters + "&access_token=" + access_token)
|
146
|
+
|
141
147
|
end
|
142
148
|
|
143
149
|
# Create a checkout preference
|
@@ -317,6 +323,8 @@ class MercadoPago
|
|
317
323
|
end
|
318
324
|
|
319
325
|
headers = {
|
326
|
+
'x-product-id' => PRODUCT_ID,
|
327
|
+
'x-tracking-id' => "platform:"+RUBY_VERSION.split('.')[0]+"|"+RUBY_VERSION+",type:SDK"+MERCADO_PAGO_VERSION+",so;",
|
320
328
|
'User-Agent' => "MercadoPago Ruby SDK v" + MERCADO_PAGO_VERSION,
|
321
329
|
'Content-type' => content_type,
|
322
330
|
'Accept' => MIME_JSON
|
data/lib/version.rb
CHANGED
@@ -1 +1,2 @@
|
|
1
|
-
MERCADO_PAGO_VERSION = '
|
1
|
+
MERCADO_PAGO_VERSION = '1.1.0' unless defined?(MERCADO_PAGO_VERSION)
|
2
|
+
PRODUCT_ID = 'bc32a7vtrpp001u8nhjg'
|
data/travis_Gemfile
ADDED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mercadopago-sdk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- maticompiano
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|
@@ -60,6 +60,7 @@ extensions: []
|
|
60
60
|
extra_rdoc_files: []
|
61
61
|
files:
|
62
62
|
- ".gitignore"
|
63
|
+
- ".travis.yml"
|
63
64
|
- Gemfile
|
64
65
|
- Gemfile.lock
|
65
66
|
- README.md
|
@@ -75,10 +76,9 @@ files:
|
|
75
76
|
- lib/mercadopago.rb
|
76
77
|
- lib/ssl_options_patch.rb
|
77
78
|
- lib/version.rb
|
78
|
-
- mercadopago-sdk-0.3.2.gem
|
79
|
-
- mercadopago-sdk-0.3.3.gem
|
80
79
|
- mercadopago.gemspec
|
81
80
|
- tests/tests.rb
|
81
|
+
- travis_Gemfile
|
82
82
|
homepage: http://github.com/mercadopago/sdk-ruby
|
83
83
|
licenses: []
|
84
84
|
metadata: {}
|
@@ -98,7 +98,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
98
98
|
version: '0'
|
99
99
|
requirements: []
|
100
100
|
rubyforge_project:
|
101
|
-
rubygems_version: 2.
|
101
|
+
rubygems_version: 2.5.2.3
|
102
102
|
signing_key:
|
103
103
|
specification_version: 4
|
104
104
|
summary: MercadoPago Ruby SDK
|
data/mercadopago-sdk-0.3.2.gem
DELETED
Binary file
|
data/mercadopago-sdk-0.3.3.gem
DELETED
Binary file
|