{"id":14956294,"url":"https://github.com/lighthouse-web3/lighthouse-python-sdk","last_synced_at":"2025-09-30T10:32:17.189Z","repository":{"id":62593039,"uuid":"539850333","full_name":"lighthouse-web3/lighthouse-python-sdk","owner":"lighthouse-web3","description":"Python SDK for interacting with Lighthouse to store on IPFS, Filecoin","archived":false,"fork":false,"pushed_at":"2023-07-21T07:50:05.000Z","size":89,"stargazers_count":7,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-10-29T14:19:30.666Z","etag":null,"topics":["filecoin","ipfs","ipfs-protocol","lighthouse","lighthouse-storage","lighthouse-web3","web3","web3py"],"latest_commit_sha":null,"homepage":"https://www.lighthouse.storage/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lighthouse-web3.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2022-09-22T07:19:32.000Z","updated_at":"2024-09-19T10:24:34.000Z","dependencies_parsed_at":"2022-11-03T23:10:22.480Z","dependency_job_id":"75974116-856c-4128-829c-d78164d5c61c","html_url":"https://github.com/lighthouse-web3/lighthouse-python-sdk","commit_stats":{"total_commits":51,"total_committers":4,"mean_commits":12.75,"dds":0.5686274509803921,"last_synced_commit":"678e49e4ede875a1e970463fb07bb9d9fde06472"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lighthouse-web3%2Flighthouse-python-sdk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lighthouse-web3%2Flighthouse-python-sdk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lighthouse-web3%2Flighthouse-python-sdk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lighthouse-web3%2Flighthouse-python-sdk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lighthouse-web3","download_url":"https://codeload.github.com/lighthouse-web3/lighthouse-python-sdk/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":234727998,"owners_count":18877706,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["filecoin","ipfs","ipfs-protocol","lighthouse","lighthouse-storage","lighthouse-web3","web3","web3py"],"created_at":"2024-09-24T13:12:39.833Z","updated_at":"2025-09-30T10:32:11.750Z","avatar_url":"https://github.com/lighthouse-web3.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Lighthouse Python SDK\n\nLighthouse is a permanent decentralized file storage protocol that allows the ability to pay once and store forever. While traditionally, users need to repeatedly keep track and pay for their storage after every fixed amount of time, Lighthouse manages this for them and makes sure that user files are stored forever. The aim is to move users from a rent-based cost model where they are renting their own files on cloud storage to a permanent ownership model. It is built on top of IPFS, Filecoin, and Polygon. It uses the existing miner network and storage capacity of the filecoin network.\n\n# Installation\n\n```\npip install lighthouseweb3\n```\n\n# Usage\n\n### Instantiate the client\n\n```python\nfrom lighthouseweb3 import Lighthouse\n\n# use token from env variable LIGHTHOUSE_TOKEN\nlh = Lighthouse()\n\n# or you can pass token as parameter\nlh = Lighthouse(token=\"your_token\")\n```\n\n### Uploading a file\n\n```python\nfrom lighthouseweb3 import Lighthouse\nlh = Lighthouse()\nresponse = lh.upload(\"path/to/file\")\nprint(response) # prints a dict containing the cid of the file\n```\n\n### Uploading a directory\n\n```python\nfrom lighthouseweb3 import Lighthouse\nlh = Lighthouse(\"my-lightouse-token\")\nresponse = lh.upload(\"path/to/directory\")\nprint(response) # prints a dict containing the root cid of the directory\n```\n\n# Testing\n\nThe tests are written with inheritance from the unittest module. To run the tests, run the following command:\n\n```\npip install -r requirements.txt \u0026\u0026 python -m unittest discover\n```\n\nor using nose2\n\n```\npip install -r requirements.txt \u0026\u0026 python -m nose2\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flighthouse-web3%2Flighthouse-python-sdk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flighthouse-web3%2Flighthouse-python-sdk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flighthouse-web3%2Flighthouse-python-sdk/lists"}