Skip to main content

🍰 remove-bg-api - remove.bg Python API Wrapper 🍰


📄Description:

This library is used to interact with the remove.bg API to remove the background from the image.
This library implements 100% API of this service.


🧷Dependencies:

requests


🔖Setup:

🏷 Simple install using pip:

pip3 install remove-bg-api

🏷 Install from source:

  • Clone this repository.
  • Install all the dependencies from requirements.txt: pip3 install -r requirements.txt
  • Install python3 setup.py install

📙Documentation


🧰Examples:

  • Remove background from image:
    from remove_bg_api import RemoveBg
    # Initialize api wrapper
    removebg = RemoveBg(API_TOKEN)  
    # Send and save the finished image
    image = removebg.remove_bg_file(input_path="imgs/a.jpg", out_path="./a.png", size="preview", raw=False)  
    # Print path
    print("Image was saved along the path: {}".format(image))
    
  • Show account total balance:
    from remove_bg_api import RemoveBg
    removebg = RemoveBg("API_TOKEN")  # Initialize api wrapper
    print("Account total balance: ", removebg.account.balance())
    

See other examples in the examples folder.


⏳ TODO:

1) Add asyncio support. (0% done)

Release files for remove-bg-api 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for remove-bg-api 0.2.1
File Size Uploaded
remove_bg_api-0.2.1.tar.gz 4.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for remove-bg-api 0.2.1
File Interpreter ABI Platform
remove_bg_api-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 9.8 kB

Release files / remove_bg_api-0.2.1.tar.gz

Download URL remove_bg_api-0.2.1.tar.gz
Size 4.4 kB
Tags Source
SHA-256 checksum
How to use checksums
18318ca480e40f8001ece29ce84b21f6483d32a08b74328c3345bbbf8f361040
BLAKE2b-256 checksum
How to use checksums
40dc7639390faec3dbd2f9e2a6e59c32ecb68f7deba11f1cb126ba917e344638
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.3

Release files / remove_bg_api-0.2.1-py3-none-any.whl

Download URL remove_bg_api-0.2.1-py3-none-any.whl
Size 5.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b5e5621f1e834d0114d376ded0a681a046850db2b66df6fd47f04e284e15504e
BLAKE2b-256 checksum
How to use checksums
3872e6b86d8aa6d0399f354b4ea7070d49ed32c67baf6d9121b342ae4af8a6a2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.3

Release history Release notifications | RSS feed

This release

0.2.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page