Closed viperouge closed 9 years ago
It sounds like you didn't set the marketplace_id
on the client or you set it to something not in here?
I did.. my marketplace id is:
marketplace_id: "ATVPDKIKX0DER"
in which files should I place:
require 'peddler'
client = MWS.orders parser = client.get_service_status parser.parse
and
client = MWS.orders( marketplace_id: "...", merchant_id: "...", aws_access_key_id: "...", aws_secret_access_key: "..." )
? maybe I'm doing something wrong
I added a descriptive message to the Marketplace::BadId
error. Could you point your Gemfile
to the GitHub repo and see what the error message says?
missing MarketplaceId (Peddler::Marketplace::BadId). Currently the ID is in a file called peddler.rb in config/initializers. Maybe I'm just doing something wrong?
Looks like it. You need to set the credentials each time you instantiate a client. There's no singleton configuration object that stores credentials across instances.
If you are using a single set of credentials, I recommend you set them through environment variables, as I explain in the README.
I'll keep this issue open until I get a chance to reword the README to make this more explicit.
I was trying to set up peddler and after I put my marketplace_id, merchant_id etc and start the server the following error is returned: gems/peddler-0.12.7/lib/peddler/marketplace.rb:44:in `block in find_host': Peddler::Marketplace::BadId (Peddler::Marketplace::BadId)
I'm using Ruby 2.1.3 and Rails 4.2.0
Any ideas how to fix it?