mercadolibre 0.14.1 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (93) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +4 -0
  3. data/lib/mercadolibre.rb +4 -80
  4. data/lib/mercadolibre/api.rb +56 -20
  5. data/lib/mercadolibre/core/auth.rb +8 -12
  6. data/lib/mercadolibre/core/categories_and_listings.rb +8 -24
  7. data/lib/mercadolibre/core/collections.rb +10 -0
  8. data/lib/mercadolibre/core/items_and_searches.rb +25 -60
  9. data/lib/mercadolibre/core/locations_and_currencies.rb +8 -29
  10. data/lib/mercadolibre/core/order_management.rb +77 -47
  11. data/lib/mercadolibre/core/questions.rb +10 -27
  12. data/lib/mercadolibre/core/shippings.rb +2 -4
  13. data/lib/mercadolibre/core/users.rb +5 -13
  14. data/lib/mercadolibre/version.rb +1 -1
  15. data/lib/mercadopago/api.rb +55 -20
  16. data/lib/mercadopago/core/auth.rb +12 -18
  17. data/lib/mercadopago/core/payments.rb +3 -12
  18. metadata +3 -77
  19. data/lib/mercadolibre/entity/address.rb +0 -40
  20. data/lib/mercadolibre/entity/address_agency.rb +0 -21
  21. data/lib/mercadolibre/entity/answer.rb +0 -25
  22. data/lib/mercadolibre/entity/atm_transfer_reference.rb +0 -21
  23. data/lib/mercadolibre/entity/auth.rb +0 -21
  24. data/lib/mercadolibre/entity/billing_info.rb +0 -21
  25. data/lib/mercadolibre/entity/card_configuration.rb +0 -23
  26. data/lib/mercadolibre/entity/card_issuer.rb +0 -21
  27. data/lib/mercadolibre/entity/category.rb +0 -28
  28. data/lib/mercadolibre/entity/category_settings.rb +0 -26
  29. data/lib/mercadolibre/entity/city.rb +0 -27
  30. data/lib/mercadolibre/entity/collector.rb +0 -21
  31. data/lib/mercadolibre/entity/cost_components.rb +0 -21
  32. data/lib/mercadolibre/entity/country.rb +0 -26
  33. data/lib/mercadolibre/entity/currency.rb +0 -21
  34. data/lib/mercadolibre/entity/currency_conversion_ratio.rb +0 -21
  35. data/lib/mercadolibre/entity/featured_item.rb +0 -28
  36. data/lib/mercadolibre/entity/feedback.rb +0 -35
  37. data/lib/mercadolibre/entity/feedback_reply.rb +0 -25
  38. data/lib/mercadolibre/entity/geolocation.rb +0 -21
  39. data/lib/mercadolibre/entity/gtin.rb +0 -21
  40. data/lib/mercadolibre/entity/item.rb +0 -55
  41. data/lib/mercadolibre/entity/item_attribute.rb +0 -21
  42. data/lib/mercadolibre/entity/item_description.rb +0 -27
  43. data/lib/mercadolibre/entity/item_payment_method.rb +0 -21
  44. data/lib/mercadolibre/entity/item_picture.rb +0 -21
  45. data/lib/mercadolibre/entity/item_shipping.rb +0 -22
  46. data/lib/mercadolibre/entity/listing_exposure.rb +0 -21
  47. data/lib/mercadolibre/entity/listing_price.rb +0 -26
  48. data/lib/mercadolibre/entity/listing_type.rb +0 -21
  49. data/lib/mercadolibre/entity/mediation.rb +0 -25
  50. data/lib/mercadolibre/entity/mediation_interaction.rb +0 -21
  51. data/lib/mercadolibre/entity/municipality.rb +0 -21
  52. data/lib/mercadolibre/entity/neighborhood.rb +0 -21
  53. data/lib/mercadolibre/entity/order.rb +0 -44
  54. data/lib/mercadolibre/entity/order_coupon.rb +0 -21
  55. data/lib/mercadolibre/entity/order_feedback.rb +0 -25
  56. data/lib/mercadolibre/entity/order_item.rb +0 -25
  57. data/lib/mercadolibre/entity/order_note.rb +0 -25
  58. data/lib/mercadolibre/entity/order_shipping.rb +0 -33
  59. data/lib/mercadolibre/entity/payment.rb +0 -35
  60. data/lib/mercadolibre/entity/payment_method.rb +0 -33
  61. data/lib/mercadolibre/entity/payment_plan.rb +0 -21
  62. data/lib/mercadolibre/entity/payment_promotion.rb +0 -28
  63. data/lib/mercadolibre/entity/phone.rb +0 -21
  64. data/lib/mercadolibre/entity/product_identifier.rb +0 -25
  65. data/lib/mercadolibre/entity/question.rb +0 -30
  66. data/lib/mercadolibre/entity/search_location.rb +0 -27
  67. data/lib/mercadolibre/entity/shipment.rb +0 -41
  68. data/lib/mercadolibre/entity/shipment_status_history.rb +0 -24
  69. data/lib/mercadolibre/entity/shipping_delivery.rb +0 -25
  70. data/lib/mercadolibre/entity/shipping_item.rb +0 -21
  71. data/lib/mercadolibre/entity/shipping_option.rb +0 -28
  72. data/lib/mercadolibre/entity/shipping_speed.rb +0 -21
  73. data/lib/mercadolibre/entity/site.rb +0 -28
  74. data/lib/mercadolibre/entity/site_domain.rb +0 -21
  75. data/lib/mercadolibre/entity/site_trend.rb +0 -21
  76. data/lib/mercadolibre/entity/state.rb +0 -27
  77. data/lib/mercadolibre/entity/user.rb +0 -34
  78. data/lib/mercadolibre/entity/zip_code.rb +0 -29
  79. data/lib/mercadopago/entity/additional_info.rb +0 -27
  80. data/lib/mercadopago/entity/address.rb +0 -21
  81. data/lib/mercadopago/entity/auth.rb +0 -21
  82. data/lib/mercadopago/entity/collector.rb +0 -29
  83. data/lib/mercadopago/entity/fee_detail.rb +0 -21
  84. data/lib/mercadopago/entity/identification.rb +0 -21
  85. data/lib/mercadopago/entity/money_request.rb +0 -32
  86. data/lib/mercadopago/entity/order.rb +0 -21
  87. data/lib/mercadopago/entity/payer.rb +0 -27
  88. data/lib/mercadopago/entity/payment.rb +0 -83
  89. data/lib/mercadopago/entity/phone.rb +0 -21
  90. data/lib/mercadopago/entity/refund.rb +0 -25
  91. data/lib/mercadopago/entity/shipments.rb +0 -21
  92. data/lib/mercadopago/entity/source.rb +0 -21
  93. data/lib/mercadopago/entity/transaction_details.rb +0 -28
@@ -1,25 +0,0 @@
1
- module Mercadopago
2
- module Entity
3
- class Refund
4
- def self.attr_list
5
- [:id, :amount, :source, :reason, :date_created, :payment_id, :metadata, :unique_sequence_number]
6
- end
7
-
8
- attr_reader *attr_list
9
-
10
- def initialize(attributes={})
11
- attributes.each do |k, v|
12
- if k.to_s == 'source'
13
- self.source = Source.new(v) unless v.nil?
14
- else
15
- self.send("#{k}=", v) if self.respond_to?(k)
16
- end
17
- end
18
- end
19
-
20
- private
21
-
22
- attr_writer *attr_list
23
- end
24
- end
25
- end
@@ -1,21 +0,0 @@
1
- module Mercadopago
2
- module Entity
3
- class Shipments
4
- def self.attr_list
5
- [:receiver_address]
6
- end
7
-
8
- attr_reader *attr_list
9
-
10
- def initialize(attributes={})
11
- attributes.each do |k, v|
12
- self.send("#{k}=", v) if self.respond_to?(k)
13
- end
14
- end
15
-
16
- private
17
-
18
- attr_writer *attr_list
19
- end
20
- end
21
- end
@@ -1,21 +0,0 @@
1
- module Mercadopago
2
- module Entity
3
- class Source
4
- def self.attr_list
5
- [:id, :name, :type]
6
- end
7
-
8
- attr_reader *attr_list
9
-
10
- def initialize(attributes={})
11
- attributes.each do |k, v|
12
- self.send("#{k}=", v) if self.respond_to?(k)
13
- end
14
- end
15
-
16
- private
17
-
18
- attr_writer *attr_list
19
- end
20
- end
21
- end
@@ -1,28 +0,0 @@
1
- module Mercadopago
2
- module Entity
3
- class TransactionDetails
4
- def self.attr_list
5
- [:net_received_amount,
6
- :total_paid_amount,
7
- :overpaid_amount,
8
- :external_resource_url,
9
- :installment_amount,
10
- :financial_institution,
11
- :financial_institution_description,
12
- :payment_method_reference_id]
13
- end
14
-
15
- attr_reader *attr_list
16
-
17
- def initialize(attributes={})
18
- attributes.each do |k, v|
19
- self.send("#{k}=", v) if self.respond_to?(k)
20
- end
21
- end
22
-
23
- private
24
-
25
- attr_writer *attr_list
26
- end
27
- end
28
- end