All submodules included from the main Shiba package needs an instanced ShibaConnection class defining your login and an identification token as parameter.
You can also tell it to deal with the sanboxed version for testing purposes.
Each method of each submodule returns a ShibaResponseObject element from the XML returned by the PriceMinister WebServices, give it a look from the section dedicated for this class.
ShibaResponseObject wraps an ObjectifiedElement from the lxml.objectify module as the main container for the retrieved data. This object is callabel through the content attribute.
You can find some documentation about it looking into the lxml documentation.
Bases: object
Accounting Management class, showing global financial operations on your account, or specific financial details about an operation
Get a specific operation details from its “compensationid” found in the get_operation request return.
Get global operations which happened on your wallet, compensationid given back from XML can be used in the get_compensation_details method below to get more detailed information about a specific operation.
Parameters: | lastoperationdate – as follows : dd/mm/yyyy-hh:mm:ss and as string or date instance. |
---|
Bases: object
This class permits you to manage your inventory, get information about your products and even import products from XML to the PriceMinister platform
Export adverts from your inventory, nexttoken pagination is available.
Parameters: | scope – PRICING is the only acceptable value for it, if not empty. |
---|
Import XML file to your PriceMinister inventory trough a POST request.
Parameters: | data – must be a object/dict (OrderedDict is better) containing your inventory wished to be imported. You must respect the XML hierarchy detailed from the WebService documentation inside the object/dict |
---|
Retrieves the report from a previous XML import, used as verification for a proper XML import
Parameters: |
|
---|
This methods retrieve product type attributes from the product type given through the “alias” parameter. Dedicated to help you making your own XML import file.
Parameters: |
|
---|
Bases: object
Marketplace informations retrieving, such as product lists and category mapping
Prints a search list result from given parameters.
Parameters: |
|
---|
Bases: object
Primary sales management class, gather all sales-related methods.
This method cancel the sale from the “itemid” item, after this one has been sold. WARNING : Cancelling a sale this way could harm your seller reputation. Use the “comment” param to specify the reason of this action to the related buyer (mandatory).
Parameters: |
|
---|
Confirms preorders from the “advertid” item announce, will confirm “stock” items as confirmed orders for buyers who has preordered from the advert.
Parameters: |
|
---|
This functionality permits to join the PriceMinister after-sales service as buyer or seller. Specify the mailparentid to reply to a previous mail exchange. Message is message content, and itemid is the item PriceMinister ID related to the claim.
Parameters: |
|
---|
Contact buyer of the “itemid” item in a regular way, sending him a message.
Parameters: |
|
---|
Calling this method gives you accounting information about a confirmed order.
Parameters: | purchaseid – is mandatory (same as found in get_new_sales report). |
---|
Calling get_current_sales method gives you a obj gathering all current sales.
Parameters: |
|
---|
This methods retrieves information from an “itemid” item, such as state, history, messages linked to it and actions available for this item. WARNING : All messages related to asked item will be tagged as “read”.
Parameters: | itemid – string for item ID |
---|
Retrieving a todo list on items, such as CLAIMS or MESSAGES from buyer or PriceMinister.
Quite similar to billing information method, but returns information about shipping for a given purchaseid Order forms are also available from this method return content.
Parameters: | purchaseid – is mandatory (same as found in get_new_sales report). |
---|
Send to buyer tracking information, such as the transporter’s name “transporter_name”, tracking number “tracking_number” and the optional tracking url “tracking_url”. Please note that giving “Autre” as transporter_name brings the tracking url as mandatory. This WebService send an email to the “itemid” customer, including a link for package tracking.
Parameters: |
|
---|
Containing the object class returned by each method of the modules above.
Bases: object
This class gathers all content from the returned XML. Separating the namespace for further usage and the actual content. The raw XML from the WebServices is also reachable from this object.
Parameters: |
|
---|
Those arguments are stored into content for the ObjectifiedElement, raw for the raw and XML and namespace for the namespace of the XML, which have been removed.
Bases: object
The main Shiba class, standing as an initialization and mandatory for each submodules instancing.
Parameters: |
|
---|
Bases: shiba.shibaexceptions.ShibaException
Shiba internal error, for code relative errors. If such an exception is raised, look at given parameters to the API methods first as this is the major exception raising point for this type of exception
Bases: shiba.shibaexceptions.ShibaException
Shiba connection error, kind of an internal error: URL can’t be reached, in case of bad URL formatting or internet connection failure (HTTP errors 404, 500...).
Bases: exceptions.Exception
Main exception class, as you can catch the whole of Shiba exceptions from it
Bases: shiba.shibaexceptions.ShibaException
Shiba login error, XML returned from the WebService told that the login informations given are incorrect.
Bases: shiba.shibaexceptions.ShibaException
Shiba parameter error, XML returned from the WebService told that one or more parameters are incorrect.
Bases: shiba.shibaexceptions.ShibaException
Shiba throtlle error, you have sumbitted too many request of a type within a certain amount of time
Bases: shiba.shibaexceptions.ShibaException
Shiba rights error, means XML returned the specified login IDs aren’t authorized to access/modify such ressource from the asked WebService
Bases: shiba.shibaexceptions.ShibaException
Shiba service error, WebService told that an error have been encountered, but may can’t precise where
Bases: shiba.shibaexceptions.ShibaException
Shiba unknown service error, WebService has caused/encoutered an error, but we can’t know why (followed by a rough print of the XML retrieved