Script to export BrickOwl orders to Rebrickable parts list (csv file)

I wanted to export my BrickOwl orders to individual Rebrickable parts lists so I wrote a script which works so far for the 3 orders I have made on BrickOwl. I couldn't find any way out there to do this, so I wrote a script. Here it is on Github:

https://github.com/dgrant/brickowl2rebrickable

There are lots of features I'd like to add, like:
-Fetching list of all BrickOwl order id numbers automatically
-Option to create one big CSV file instead of one for each file
-Caching the color convesion data I grab from here: http://rebrickable.com/colors

Let me know if this is useful for you as well and if there are any features you'd like to see added. I can't promise you that I can add it, but if not, you're welcome to submit a pull request on github.

Comments

  • 7 Comments sorted by Votes Date Added
  • You can export all of your orders placed, including detail using the API.
  • Maybe I should have been more specific in my original post. When I said "I couldn't find any way out there to do this", by "this" I meant, how to get the BrickOwl data into Rebrickable format. BrickOwl order data is in json with their own color id and color name and that's the easy part. Rebrickable only takes the following formats:

    Rebrickable Parts file (CSV)
    Peeron Loose Parts file (TSV)
    Basebrick Loose Parts file (TSV)
    BrickStore Parts (BSX)
    BrickLink Orders/Inv (XML)

    So my script takes the BrickOwl order data (from the BrickOwl API) and converts it into a "Rebrickable parts file (CSV)"
  • Good news, it looks like Rebrickable might add support for importing from BrickOwl: http://rebrickable.com/forum/index.php/topic/208-brickowl-integration/

    I'll keep improving my script though (I'm going to add support for determining which part id is better to use, the design_id or the ldraw_id, depending on which one is in more sets in Rebrickable) until the Rebrickable support is there and it at least the same or better than my script.
  • I've made some update to the brickowl2rebrickable script (https://github.com/dgrant/brickowl2rebrickable):

    * It now looks at the design_id, ldraw_id, and peeron_id from BrickOwl and then looks for parts in Rebrickable that match. Chooses whichever one has more parts in Rebrickable.
    * New script called combine_rebrickable_csv.py that combines multiple Rebrickable.csv files into one.

    So far it's working well for me. I've imported 4 BrickOwl orders into Rebrickable as well as a list of loose parts obtained separately from BrickOwl and I am using it to find MOCs and sets to build on Rebrickable based on these parts.
Sign In or Register to comment.