iFixit REST API Interface
Project description
fixitPy
Python iFixit API interface.
Currently, you can retrieve guides and their prerequisite guides
Installation
pip install fixitpy
Usage
Guide retrieval
import fixitpy
# Call 'retrieve_guide' returns the guide's dictionary
found_guide = fixitpy.retrieve_guide(123)
# As any regular dictionary, you can retrieve specific values from it
print(f"Title: {found_guide.get("title")}")
print(f"Difficulty: {found_guide.get("difficulty")}")
print(f"Conclusion: {found_guide.get("conclusion")}")
# The dictionary returned from 'retrieve_guide' contains a list refered to as 'steps'
# Each list item contains a dictionary with the properties 'title', which is self explanatory and 'text', the process itself.
for step in found_guide.get("steps"):
print(step.get("title"))
print(step.get("text"))
Media retrieval
import fixitpy
# Call 'retrieve_media', returns the media's dictionary
found_guide = fixitpy.retrieve_media(123)
# As any regular dictionary, you can retrieve specific values from it
print(found_guide.get("width"))
print(found_guide.get("height"))
# The dictionary returned from 'retrieve_media' contains a sub-dictionary under 'sizes'
# Which contains all the sizes of the media and their corresponding URLs.
sizes = found_guide.get("sizes")
# 'thumbnail' is a very common size for iFixit Media
print(sizes.get("thumbnail"))
License
MIT License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
fixitpy-0.2.19.tar.gz
(4.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fixitpy-0.2.19.tar.gz.
File metadata
- Download URL: fixitpy-0.2.19.tar.gz
- Upload date:
- Size: 4.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3391cca138dcc2149cdaf94c8654eff306caf3d1d19dfb6cfed227ef5dfe26a1
|
|
| MD5 |
8d0281533f8ca929ff1afd592b53a474
|
|
| BLAKE2b-256 |
d9932d2e8a9d28d374fa74e1339ecd9f8379931e46dfd5282daf7d22b36a8f3b
|
File details
Details for the file fixitpy-0.2.19-py3-none-any.whl.
File metadata
- Download URL: fixitpy-0.2.19-py3-none-any.whl
- Upload date:
- Size: 4.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2e65f97b9dc448ebd706eb4a710313f61b807ba49f97d1dfd2808457db189cd7
|
|
| MD5 |
84b1b33db69a514806c0c602181ec405
|
|
| BLAKE2b-256 |
a630ce5d3dc543eaf793ccfb66d6e85833ed4b710c7e733c2b6d3c0f988c2c22
|