Skip to main content

Python access to Rebrickable API.

Project description


The rebrick library provides a collection of utilities to retrieve various data from bricks repository. It can be used either as a simple tool, which reads requested data and converts them into easy-access custom classes or by using the API directly to allow handling the HTTPResponse in whatever way you want.

Please see the examples folder or in-code documentation of classes and functions to learn more about the rebrick library capabilities as well as the original documentation of the Rebrickable API.

Tool Example

import rebrick

# init Rebrick tool
rb = rebrick.Rebrick("your_API_KEY_here", "your_USER_TOKEN_here", silent=True)

# get set info
data = rb.get_set(6608)

# if user token is not provided on init you can get it later to access user data
rb.login("your_username_here", "your_password_here")

# get user partlists
data = rb.get_users_partlists()

API Example

import rebrick
import json

# init rebrick module for general reading

# get set info
response =

# init rebrick module including user reading
rebrick.init("your_API_KEY_here", "your_USER_TOKEN_here")

# if you don't know the user token you can use your login credentials
rebrick.init("your_API_KEY_here", "your_username_here", "your_password_here")

# get user partlists
response = rebrick.users.get_partlists()


The rebrick library is fully implemented in Python. No additional compiler is necessary. After downloading the source code just run the following command from the rebrick folder:

$ python install

or simply by using pip

$ pip install rebrick


This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rebrick-0.3.0.tar.gz (15.4 kB view hashes)

Uploaded source

Built Distribution

rebrick-0.3.0-py3-none-any.whl (16.0 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page