A Web Extension that generates a compact eBay purchase history report
The eBay purchase history doesn't look friendly when you have tons of purchases and you are interested to see a compact grouped list of what you have purchased, how much it costed, how many shipped or not, etc. Such a list can be easily generated by traversing the page's DOM and collecting these info and eventually printing out a report at the browser's console.
This project provides a Firefox|Chrome|Opera Web Extension (add-on) that aids in generating such a report. The report is generated in a new tab as a HTML document.
Tested on Linux with Firefox 45+, Chrome 55+, Opera 36+. It should work also on Windows or MacOS. Not built/tested on Microsoft Edge, Android or iPhone but who knows, it might just work :-)
Some functions of this add-on uses certain APIs, thus would require certain permissions for installation. Below is a list of those permissions and the reason for them:
Normally you don't bother with this when you install an add-on, don't you? In case you do now you know it :-)
The user
way:
If you want to install/test a certain version then go to the dist folder and download and install the version which is right for you:
Extension
|Add-ons
menu
Search add-on
input) there is a tools
drop-down button. Click that button and choose Install Add-on From File
. Choose the file downloaded at step (1)Extension
list. It will automatically suggest you to Drop to install
The developer
way:
How to use it
.Purchase history
menuQuick Report
button on the Orders group box:
Quick Report
button. A new tab will open containing a compact HTML report of your eBay purchase history:
Please note that the report will include only visible items. For instance, if you chose to see only 25 Orders per page
then the report will include only these orders. To include the whole history make sure you choose the largest Orders per page
option available (eg. 100).
By default the report would include the following columns:
Order date
informationItem price
valueEstimated delivery
date, if availableBy default the report would generate a group footer subtotal for each date/currency value. This group footer shows the item count within group, their total amount, how many are shipped/not-shipped and the average price per item. The report will print also a grand total for the entire report.
Starting with v1.0.7 it will also show the item's thumbnail picture while moving the mouse over the item :-)
The report is generated by default using the natural order of the purchased items. If you want to sort the report by a given column then click the arrow icon that is shown near the column name. It works both ascendent and descendent.
The report allows you to export its dataset to tab-delimited, JSON and XML format. Just use the link shown on the report document.
eBay Purchase History
page.If you want to fork this project then you might be interested in building automatically the .zip|.crx|.xpi bundles, right? Ok, the simplest way to do this is via the Mozilla's web-ext command line tool or, in case of Chrome|Opera via the Chrome's crxmake command line tool.
The building commands can be encapsulated within a Bourne shell script (that would normally work on Unix-like systems):
#!/bin/bash
EXT_NAME=ebay_purchase_report_history
EXT_PATH=${0%/*} # ;-)
EXT_SRC=$EXT_PATH/src/extension
EXT_DIST=$EXT_PATH/dist
EXT_VER=$(cat $EXT_SRC/manifest.json |grep '"version"'|grep -Eow "[0-9.]+")
web-ext -s $EXT_SRC -a $EXT_DIST --api-key=<your-addons.mozilla.org-api-key> --api-secret=<your-addons.mozilla.org-api-secret> --id=<your-addons.mozilla.org-api-UUID> sign
crxmake --pack-extension=$EXT_SRC --extension-output=$EXT_DIST/$EXT_NAME-$EXT_VER.crx --key-output=$EXT_DIST/$EXT_NAME-$EXT_VER.pem
Please note that in case of Firefox you should:
--api-key
and --api-secret
)UUID
and use it on the above script.Read more on AMO and/or on Google.
The JavaScript source files are annotated according to JSDoc specification and thus the source documentation can be produced on the fly by using the {@link http://usejsdoc.org/|JSDoc} tool.
In order to generate the JSDoc documentation you should follow the steps below. In case you want to use the JSDoc default template skip the step (1) below.
npm install {@link https://www.npmjs.com/package/interledger-jsdoc-template|minami}
)opts.template
property with the path to the installed JSDoc template in project's conf.json
filejsdoc -c path-to-conf.json
jsdoc
folder that will contain the auto-generated JSDoc documentation for the JavaScript source filesUnpaid items
, Canceled items
, Canceled invoices
and Returns and canceled orders
purchase history lists.