amazon-mws 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (116) hide show
  1. data/.gitignore +1 -0
  2. data/README.markdown +31 -0
  3. data/Rakefile +14 -0
  4. data/VERSION +1 -0
  5. data/amazon-mws.gemspec +164 -0
  6. data/examples/xml/cancel_feed_submissions.xml +16 -0
  7. data/examples/xml/cancel_report_requests.xml +18 -0
  8. data/examples/xml/error.xml +10 -0
  9. data/examples/xml/get_feed_submission_count.xml +10 -0
  10. data/examples/xml/get_feed_submission_list.xml +16 -0
  11. data/examples/xml/get_feed_submission_list_by_next_token.xml +16 -0
  12. data/examples/xml/get_feed_submission_result.xml +30 -0
  13. data/examples/xml/get_report_count.xml +9 -0
  14. data/examples/xml/get_report_list.xml +17 -0
  15. data/examples/xml/get_report_request_count.xml +8 -0
  16. data/examples/xml/get_report_request_list.xml +120 -0
  17. data/examples/xml/get_report_request_list_by_next_token.xml +20 -0
  18. data/examples/xml/get_report_schedule_count.xml +10 -0
  19. data/examples/xml/get_report_schedule_list.xml +15 -0
  20. data/examples/xml/get_report_schedule_list_by_next_token.xml +15 -0
  21. data/examples/xml/manage_report_schedule.xml +14 -0
  22. data/examples/xml/request_report.xml +17 -0
  23. data/examples/xml/submit_feed.xml +14 -0
  24. data/examples/xml/update_report_acknowledgements.xml +18 -0
  25. data/examples/xsd/Inventory.xsd +49 -0
  26. data/examples/xsd/Item.xsd +285 -0
  27. data/examples/xsd/Listings.xsd +32 -0
  28. data/examples/xsd/OrderAcknowledgement.xsd +55 -0
  29. data/examples/xsd/OrderAdjustment.xsd +94 -0
  30. data/examples/xsd/OrderFulfillment.xsd +57 -0
  31. data/examples/xsd/Override.xsd +48 -0
  32. data/examples/xsd/Price.xsd +59 -0
  33. data/examples/xsd/ProcessingReport.xsd +87 -0
  34. data/examples/xsd/Product.xsd +220 -0
  35. data/examples/xsd/Product/AutoAccessory.xsd +807 -0
  36. data/examples/xsd/Product/Beauty.xsd +114 -0
  37. data/examples/xsd/Product/CE.xsd +544 -0
  38. data/examples/xsd/Product/CameraPhoto.xsd +2410 -0
  39. data/examples/xsd/Product/FoodAndBeverages.xsd +270 -0
  40. data/examples/xsd/Product/Gourmet.xsd +85 -0
  41. data/examples/xsd/Product/Health.xsd +189 -0
  42. data/examples/xsd/Product/Home.xsd +654 -0
  43. data/examples/xsd/Product/Jewelry.xsd +603 -0
  44. data/examples/xsd/Product/Miscellaneous.xsd +157 -0
  45. data/examples/xsd/Product/MusicalInstruments.xsd +853 -0
  46. data/examples/xsd/Product/Office.xsd +550 -0
  47. data/examples/xsd/Product/PetSupplies.xsd +40 -0
  48. data/examples/xsd/Product/ProductClothing.xsd +197 -0
  49. data/examples/xsd/Product/SWVG.xsd +238 -0
  50. data/examples/xsd/Product/Sports.xsd +308 -0
  51. data/examples/xsd/Product/TiresAndWheels.xsd +159 -0
  52. data/examples/xsd/Product/Tools.xsd +66 -0
  53. data/examples/xsd/Product/ToysBaby.xsd +241 -0
  54. data/examples/xsd/Product/Wireless.xsd +77 -0
  55. data/examples/xsd/ProductImage.xsd +39 -0
  56. data/examples/xsd/Relationship.xsd +47 -0
  57. data/examples/xsd/SettlementReport.xsd +158 -0
  58. data/examples/xsd/amzn-base.xsd +1601 -0
  59. data/examples/xsd/amzn-envelope.xsd +98 -0
  60. data/examples/xsd/amzn-header.xsd +45 -0
  61. data/lib/amazon/mws.rb +86 -0
  62. data/lib/amazon/mws/authentication.rb +9 -0
  63. data/lib/amazon/mws/authentication/query_string.rb +28 -0
  64. data/lib/amazon/mws/authentication/signature.rb +43 -0
  65. data/lib/amazon/mws/base.rb +61 -0
  66. data/lib/amazon/mws/connection.rb +99 -0
  67. data/lib/amazon/mws/connection/management.rb +94 -0
  68. data/lib/amazon/mws/connection/request_builder.rb +67 -0
  69. data/lib/amazon/mws/exceptions.rb +80 -0
  70. data/lib/amazon/mws/feed.rb +223 -0
  71. data/lib/amazon/mws/feed_builder.rb +67 -0
  72. data/lib/amazon/mws/feed_enumerations.rb +46 -0
  73. data/lib/amazon/mws/feed_submission.rb +14 -0
  74. data/lib/amazon/mws/lib/extensions.rb +162 -0
  75. data/lib/amazon/mws/lib/memoizable.rb +10 -0
  76. data/lib/amazon/mws/orders.rb +9 -0
  77. data/lib/amazon/mws/report.rb +310 -0
  78. data/lib/amazon/mws/report_enumerations.rb +44 -0
  79. data/lib/amazon/mws/report_info.rb +16 -0
  80. data/lib/amazon/mws/report_request.rb +19 -0
  81. data/lib/amazon/mws/report_schedule.rb +13 -0
  82. data/lib/amazon/mws/response.rb +32 -0
  83. data/lib/amazon/mws/response/cancel_feed_submissions_response.rb +14 -0
  84. data/lib/amazon/mws/response/cancel_report_requests_response.rb +14 -0
  85. data/lib/amazon/mws/response/get_feed_submission_count_response.rb +13 -0
  86. data/lib/amazon/mws/response/get_feed_submission_list_by_next_token_response.rb +15 -0
  87. data/lib/amazon/mws/response/get_feed_submission_list_response.rb +15 -0
  88. data/lib/amazon/mws/response/get_feed_submission_result_response.rb +54 -0
  89. data/lib/amazon/mws/response/get_report_count_response.rb +13 -0
  90. data/lib/amazon/mws/response/get_report_list_response.rb +15 -0
  91. data/lib/amazon/mws/response/get_report_request_count_response.rb +13 -0
  92. data/lib/amazon/mws/response/get_report_request_list_by_next_token_response.rb +15 -0
  93. data/lib/amazon/mws/response/get_report_request_list_response.rb +15 -0
  94. data/lib/amazon/mws/response/get_report_schedule_count_response.rb +13 -0
  95. data/lib/amazon/mws/response/get_report_schedule_list_by_next_token_response.rb +15 -0
  96. data/lib/amazon/mws/response/get_report_schedule_list_response.rb +15 -0
  97. data/lib/amazon/mws/response/manage_report_schedule_response.rb +14 -0
  98. data/lib/amazon/mws/response/request_report_response.rb +14 -0
  99. data/lib/amazon/mws/response/response_error.rb +15 -0
  100. data/lib/amazon/mws/response/submit_feed_response.rb +13 -0
  101. data/lib/amazon/mws/response/update_reports_acknowledgements_response.rb +14 -0
  102. data/lib/amazon/mws/version.rb +12 -0
  103. data/pkg/amazon-mws-0.1.0.gem +0 -0
  104. data/test/authentication_test.rb +15 -0
  105. data/test/connection_test.rb +5 -0
  106. data/test/feed_builder_test.rb +15 -0
  107. data/test/feed_submission_test.rb +32 -0
  108. data/test/feed_test.rb +64 -0
  109. data/test/query_string_test.rb +21 -0
  110. data/test/report_test.rb +29 -0
  111. data/test/request_test.rb +18 -0
  112. data/test/response_test.rb +197 -0
  113. data/test/signature_test.rb +30 -0
  114. data/test/test_config.yml +5 -0
  115. data/test/test_helper.rb +22 -0
  116. metadata +179 -0
@@ -0,0 +1,5 @@
1
+ # Sony Music Entertainment Store
2
+ access_key: ACCESS_KEY
3
+ secret_access_key: SECRET_ACCESS_KEY
4
+ merchant_id: MERCHANT_ID
5
+ marketplace_id: MARKETPLACE_ID
@@ -0,0 +1,22 @@
1
+ require 'test/unit'
2
+ require 'rubygems'
3
+
4
+ require 'yaml'
5
+ #require 'fakeweb'
6
+
7
+ require File.join(File.dirname(__FILE__), '..', 'lib', 'amazon', 'mws')
8
+
9
+ def xml_for(name)
10
+ Pathname.new(File.dirname(__FILE__)).expand_path.dirname.join("examples/xml/#{name}.xml")
11
+ end
12
+
13
+ def mock_response(code, options={})
14
+ body = options[:body]
15
+ content_type = options[:content_type]
16
+
17
+ response = Net::HTTPResponse.send(:response_class, code.to_s).new("1.0", code.to_s, "message")
18
+ response.instance_variable_set(:@body, body)
19
+ response.instance_variable_set(:@read, true)
20
+ response.content_type = content_type
21
+ return response
22
+ end
metadata ADDED
@@ -0,0 +1,179 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: amazon-mws
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - David Michael
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+
12
+ date: 2009-10-30 00:00:00 -04:00
13
+ default_executable:
14
+ dependencies: []
15
+
16
+ description: A Ruby Wrapper for the Amazon MWS API
17
+ email: david.michael@sonymusic.com
18
+ executables: []
19
+
20
+ extensions: []
21
+
22
+ extra_rdoc_files:
23
+ - README.markdown
24
+ files:
25
+ - .gitignore
26
+ - README.markdown
27
+ - Rakefile
28
+ - VERSION
29
+ - amazon-mws.gemspec
30
+ - examples/xml/cancel_feed_submissions.xml
31
+ - examples/xml/cancel_report_requests.xml
32
+ - examples/xml/error.xml
33
+ - examples/xml/get_feed_submission_count.xml
34
+ - examples/xml/get_feed_submission_list.xml
35
+ - examples/xml/get_feed_submission_list_by_next_token.xml
36
+ - examples/xml/get_feed_submission_result.xml
37
+ - examples/xml/get_report_count.xml
38
+ - examples/xml/get_report_list.xml
39
+ - examples/xml/get_report_request_count.xml
40
+ - examples/xml/get_report_request_list.xml
41
+ - examples/xml/get_report_request_list_by_next_token.xml
42
+ - examples/xml/get_report_schedule_count.xml
43
+ - examples/xml/get_report_schedule_list.xml
44
+ - examples/xml/get_report_schedule_list_by_next_token.xml
45
+ - examples/xml/manage_report_schedule.xml
46
+ - examples/xml/request_report.xml
47
+ - examples/xml/submit_feed.xml
48
+ - examples/xml/update_report_acknowledgements.xml
49
+ - examples/xsd/Inventory.xsd
50
+ - examples/xsd/Item.xsd
51
+ - examples/xsd/Listings.xsd
52
+ - examples/xsd/OrderAcknowledgement.xsd
53
+ - examples/xsd/OrderAdjustment.xsd
54
+ - examples/xsd/OrderFulfillment.xsd
55
+ - examples/xsd/Override.xsd
56
+ - examples/xsd/Price.xsd
57
+ - examples/xsd/ProcessingReport.xsd
58
+ - examples/xsd/Product.xsd
59
+ - examples/xsd/Product/AutoAccessory.xsd
60
+ - examples/xsd/Product/Beauty.xsd
61
+ - examples/xsd/Product/CE.xsd
62
+ - examples/xsd/Product/CameraPhoto.xsd
63
+ - examples/xsd/Product/FoodAndBeverages.xsd
64
+ - examples/xsd/Product/Gourmet.xsd
65
+ - examples/xsd/Product/Health.xsd
66
+ - examples/xsd/Product/Home.xsd
67
+ - examples/xsd/Product/Jewelry.xsd
68
+ - examples/xsd/Product/Miscellaneous.xsd
69
+ - examples/xsd/Product/MusicalInstruments.xsd
70
+ - examples/xsd/Product/Office.xsd
71
+ - examples/xsd/Product/PetSupplies.xsd
72
+ - examples/xsd/Product/ProductClothing.xsd
73
+ - examples/xsd/Product/SWVG.xsd
74
+ - examples/xsd/Product/Sports.xsd
75
+ - examples/xsd/Product/TiresAndWheels.xsd
76
+ - examples/xsd/Product/Tools.xsd
77
+ - examples/xsd/Product/ToysBaby.xsd
78
+ - examples/xsd/Product/Wireless.xsd
79
+ - examples/xsd/ProductImage.xsd
80
+ - examples/xsd/Relationship.xsd
81
+ - examples/xsd/SettlementReport.xsd
82
+ - examples/xsd/amzn-base.xsd
83
+ - examples/xsd/amzn-envelope.xsd
84
+ - examples/xsd/amzn-header.xsd
85
+ - lib/amazon/mws.rb
86
+ - lib/amazon/mws/authentication.rb
87
+ - lib/amazon/mws/authentication/query_string.rb
88
+ - lib/amazon/mws/authentication/signature.rb
89
+ - lib/amazon/mws/base.rb
90
+ - lib/amazon/mws/connection.rb
91
+ - lib/amazon/mws/connection/management.rb
92
+ - lib/amazon/mws/connection/request_builder.rb
93
+ - lib/amazon/mws/exceptions.rb
94
+ - lib/amazon/mws/feed.rb
95
+ - lib/amazon/mws/feed_builder.rb
96
+ - lib/amazon/mws/feed_enumerations.rb
97
+ - lib/amazon/mws/feed_submission.rb
98
+ - lib/amazon/mws/lib/extensions.rb
99
+ - lib/amazon/mws/lib/memoizable.rb
100
+ - lib/amazon/mws/orders.rb
101
+ - lib/amazon/mws/report.rb
102
+ - lib/amazon/mws/report_enumerations.rb
103
+ - lib/amazon/mws/report_info.rb
104
+ - lib/amazon/mws/report_request.rb
105
+ - lib/amazon/mws/report_schedule.rb
106
+ - lib/amazon/mws/response.rb
107
+ - lib/amazon/mws/response/cancel_feed_submissions_response.rb
108
+ - lib/amazon/mws/response/cancel_report_requests_response.rb
109
+ - lib/amazon/mws/response/get_feed_submission_count_response.rb
110
+ - lib/amazon/mws/response/get_feed_submission_list_by_next_token_response.rb
111
+ - lib/amazon/mws/response/get_feed_submission_list_response.rb
112
+ - lib/amazon/mws/response/get_feed_submission_result_response.rb
113
+ - lib/amazon/mws/response/get_report_count_response.rb
114
+ - lib/amazon/mws/response/get_report_list_response.rb
115
+ - lib/amazon/mws/response/get_report_request_count_response.rb
116
+ - lib/amazon/mws/response/get_report_request_list_by_next_token_response.rb
117
+ - lib/amazon/mws/response/get_report_request_list_response.rb
118
+ - lib/amazon/mws/response/get_report_schedule_count_response.rb
119
+ - lib/amazon/mws/response/get_report_schedule_list_by_next_token_response.rb
120
+ - lib/amazon/mws/response/get_report_schedule_list_response.rb
121
+ - lib/amazon/mws/response/manage_report_schedule_response.rb
122
+ - lib/amazon/mws/response/request_report_response.rb
123
+ - lib/amazon/mws/response/response_error.rb
124
+ - lib/amazon/mws/response/submit_feed_response.rb
125
+ - lib/amazon/mws/response/update_reports_acknowledgements_response.rb
126
+ - lib/amazon/mws/version.rb
127
+ - pkg/amazon-mws-0.1.0.gem
128
+ - test/authentication_test.rb
129
+ - test/connection_test.rb
130
+ - test/feed_builder_test.rb
131
+ - test/feed_submission_test.rb
132
+ - test/feed_test.rb
133
+ - test/query_string_test.rb
134
+ - test/report_test.rb
135
+ - test/request_test.rb
136
+ - test/response_test.rb
137
+ - test/signature_test.rb
138
+ - test/test_config.yml
139
+ - test/test_helper.rb
140
+ has_rdoc: true
141
+ homepage: http://github.com/dmichael/amazon-mws
142
+ licenses: []
143
+
144
+ post_install_message:
145
+ rdoc_options:
146
+ - --charset=UTF-8
147
+ require_paths:
148
+ - lib
149
+ required_ruby_version: !ruby/object:Gem::Requirement
150
+ requirements:
151
+ - - ">="
152
+ - !ruby/object:Gem::Version
153
+ version: "0"
154
+ version:
155
+ required_rubygems_version: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - ">="
158
+ - !ruby/object:Gem::Version
159
+ version: "0"
160
+ version:
161
+ requirements: []
162
+
163
+ rubyforge_project:
164
+ rubygems_version: 1.3.5
165
+ signing_key:
166
+ specification_version: 3
167
+ summary: A Ruby Wrapper for the Amazon MWS API
168
+ test_files:
169
+ - test/authentication_test.rb
170
+ - test/connection_test.rb
171
+ - test/feed_builder_test.rb
172
+ - test/feed_submission_test.rb
173
+ - test/feed_test.rb
174
+ - test/query_string_test.rb
175
+ - test/report_test.rb
176
+ - test/request_test.rb
177
+ - test/response_test.rb
178
+ - test/signature_test.rb
179
+ - test/test_helper.rb