DigiKala
Create session and work with Digikala API
Installation:
Install the DgiKala library from PyPI or GitHub.
pip install DigiKala
or
git clone https://github.com/NuoQTe/DigiKala.git
Crate session
import asyncio
from DigiKala import Client
async def main()
app = Client("NuoQTe")
await app.login()
await app.close()
asyncio.run(main())
or
import asyncio
from DigiKala import Client
async def main()
async with Client('NuoQTe',do_login=True) as app:
pass
asyncio.run(main())
Examples:
import asyncio
from DigiKala import Client , SearchFilter
async def main():
async with Client('NuoQTe',do_login=True) as app:
# Search in DigiKala
result = await app.search(SearchFilter(
query="Laptop",
classification="notebook-netbook-ultrabook",
has_selling_stock=True,
price_range=(50000000 , 80000000),
sort_code=4
))
product = await result.products[3].get_product()
product = product.product
print(product.variants)
# add product in my cart
await product.add_cart()
asyncio.run(main())
Capabilities
- login phone number or email with sent code or password
- logout
- crate session file
- search with all filters
- search wuth product ID
- get product comments
- get account information
- get cart information
- add product to cart
- remove product from the cart
License
This project is licensed under the MIT License. See the LICENSE file for details.
Developer
- Telegram: t.me/NuoQTe
Release files for DigiKala 1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| digikala-1.0.tar.gz | 12.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| DigiKala-1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 29.6 kB
Release files / digikala-1.0.tar.gz
| Download URL | digikala-1.0.tar.gz |
|---|---|
| Size | 12.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3e419accc69c018c46caa56740f41cf286b2eec97e1fb5f373d74d79b5957b1a
|
|
BLAKE2b-256 checksum How to use checksums |
ab011345846104964f3e4b53f42a9ad8866c9a160be1ae265f51321c3fd7f8da
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.10.12
|
Release files / DigiKala-1.0-py3-none-any.whl
| Download URL | DigiKala-1.0-py3-none-any.whl |
|---|---|
| Size | 17.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9b58c5fbca0338ba4e882d3e14eba64cc0e31cccbdd5c9281bf0cdac54d72af5
|
|
BLAKE2b-256 checksum How to use checksums |
cba2b61b012aeb3e1c9b84a19d1ec4f6c63bde855d51a060bec80bb30914b251
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.10.12
|