Feeds

class pymazonian.Feeds(access_key, secret_key, account_id, region='US', domain='', uri='', version='', auth_token='')

Amazon MWS Feeds API

cancel_feed_submissions(feed_ids=None, feed_types=None, from_date=None, to_date=None)
Parameters:
  • feed_ids (list of str) – A structured list of FeedSubmmissionId values. If you pass in FeedSubmmissionId values in a request, other query conditions are ignored.
  • feed_types (list of str) – A structured list of one or more FeedType values by which to filter the list of feed submissions.
  • from_date – The earliest submission date that you are looking for, in ISO8601 date format.
  • to_date – The latest submission date that you are looking for, in ISO8601 date format.
Returns:

DictWrapper

get_feed_submission_count(feed_types=None, processing_statuses=None, from_date=None, to_date=None)
Parameters:
  • feed_types (list of str) – A structured list of one or more FeedType values by which to filter the list of feed submissions, processing_statuses: A structured list of one or more feed processing statuses by which to filter the list of feed submissions.
  • processing_statuses
  • from_date – The earliest submission date that you are looking for, in ISO8601 date format.
  • to_date – The latest submission date that you are looking for, in ISO8601 date format.
Returns:

DictWrapper

get_feed_submission_list(feed_ids=None, max_count=None, feed_types=None, processing_statuses=None, from_date=None, to_date=None)

Returns a list of all feed submissions submitted in the previous 90 days.

Parameters:
  • feed_ids (list of str) – A structured list of no more than 100 FeedSubmmissionId values. If you pass in FeedSubmmissionId values in a request, other query conditions are ignored.
  • max_count (int) – A non-negative integer that indicates the maximum number of feed submissions to return in the list. If you specify a number greater than 100, the request is rejected.
  • feed_types (list of str) – A structured list of one or more FeedType values by which to filter the list of feed submissions.
  • processing_statuses (list of str) – A structured list of one or more feed processing statuses by which to filter the list of feed submissions.
  • from_date – The earliest submission date that you are looking for, in ISO8601 date format.
  • to_date – The latest submission date that you are looking for, in ISO8601 date format.
Returns:

DictWrapper

get_feed_submission_result(feed_id)

Returns the feed processing report and the Content-MD5 header.

Parameters:feed_id (list of str) – The identifier of the feed submission you are requesting a feed processing report for. You can get the FeedSubmissionId for a feed using the GetFeedSubmissionList operation.
Returns:DictWrapper
get_submission_list_by_next_token(token)
Parameters:token (str) – A string token returned by a previous request to either GetFeedSubmissionList or GetFeedSubmission ListByNextToken where the value of HasNext was true.
Returns:DictWrapper
submit_feed(feed, feed_type, marketplace_ids=None, content_type='text/xml', purge='false')

Uploads a feed ( xml or .tsv ) to the seller’s inventory. Can be used for creating/updating products on Amazon.

Parameters:
  • feed (HTTP-BODY) – The actual content of the feed itself, in XML or flat file format. You must include the FeedContent in the body of the HTTP request
  • feed_type (FeedType) – A FeedType value indicating how the data should be processed. Second line of description should be indented.
  • marketplace_ids (str) – A list of one or more marketplace IDs (of marketplaces you are registered to sell in) that you want the feed to be applied to. The feed will be applied to all the marketplaces you specify.
  • content_type (str) – Your feeds must be in a valid encoding based on your marketplace and file type, and that encoding must be specified as an HTTP Content-Type header. The following table shows the HTTP Content-Type header you should use for flat files and XML files for each marketplace
  • purge (str) – A Boolean value that enables the purge and replace functionality. Set to true to purge and replace the existing data; otherwise false. This value only applies to product-related flat file feed types, which do not have a mechanism for specifying purge and replace in the feed body. Use this parameter only in exceptional cases. Usage is throttled to allow only one purge and replace within a 24-hour period.
Returns:

DictWrapper