chand


Namechand JSON
Version 0.0.2 PyPI version JSON
download
home_pagehttps://github.com/armanyazdi/chand
SummaryA Python library for converting currencies to Iranian Rial and Toman.
upload_time2022-12-03 05:03:12
maintainer
docs_urlNone
authorArman Yazdi
requires_python>= 3.6
licenseMIT
keywords currency converter crypto converter iranian rial iranian toman
VCS
bugtrack_url
requirements requests bs4
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # chand چند؟

[![PyPI](https://img.shields.io/pypi/v/chand?style=for-the-badge)](https://pypi.org/project/chand)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/chand?style=for-the-badge)](https://pypi.org/project/chand)
[![GitHub](https://img.shields.io/github/license/armanyazdi/chand?style=for-the-badge)](https://pypi.org/project/chand)

A Python library for converting currencies to Iranian Rial and Toman.

Note: This package shows the right real time price of Iranian Rial.

## Installation

Install from [PyPI](https://pypi.org/project/chand) with pip by typing in your favorite terminal.

This will also install `requests` and `bs4`.

`pip install chand`

## Usage

Let's take a look at what an example test case would look like using `chand`.

### Exchange Rates in Rial and Toman:

```python
import chand

chand.toman('usd') # or 'USD'
chand.toman('gbp') # or 'GBP'
chand.rial('eur')  # or 'EUR'
chand.rial('try')  # or 'TRY'
```

### Currency Converter:

It can convert the currency of **136 codes (ISO 4217)**.

```python
import chand

chand.convert('eur', 'usd', 500) # 500 Euro to US Dollar
chand.convert('usd', 'eur', 500) # 500 US Dollar to Euro
chand.convert('eur', 'try', 100) # 100 Euro to Turkish Lira
```

### Crypto Price in USD:

It supports more than **3700 Crypto Currencies**.

```python
import chand

chand.crypto('bitcoin')  # or 'btc'
chand.crypto('ethereum') # or 'eth'
chand.crypto('cardano')  # or 'ada'
```

### Crypto Converter:

```python
import chand

chand.convert('btc', 'eth')     # Bitcoin to Ethereum
chand.convert('eth', 'btc', 10) # 10 Ethereum to Bitcoin
chand.convert('btc', 'eur', 5)  # 5 Bitcoin to Euro
chand.convert('eth', 'gbp', 20) # 20 Bitcoin to Pound
```

### Color Formats Converter:

HEX to RGB, CMYK, HSV/HSB

```python
import chand

chand.convert('hex', 'rgb', 'ff4f5e')  # (255, 79, 94)
chand.convert('hex', 'cmyk', 'ff4f5e') # (0%, 69%, 63%, 0%)
chand.convert('hex', 'hsv', 'ff4f5e')  # (355°, 69%, 100%)
```

### BMI, BMR, RMR Calculator:

```python
import chand

chand.bmi(180, 75) # or chand.bmi('180', '75')
# Height(cm), Weight(kg)

chand.bmr(168, 55, 22, 'female')
# Height(cm), Weight(kg), Age, Sex

chand.rmr(180, 75, 29, 'male')
# Height(cm), Weight(kg), Age, Sex
```


            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/armanyazdi/chand",
    "name": "chand",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">= 3.6",
    "maintainer_email": "",
    "keywords": "currency converter,crypto converter,iranian rial,iranian toman",
    "author": "Arman Yazdi",
    "author_email": "",
    "download_url": "https://files.pythonhosted.org/packages/d7/4d/62fef0e910c13c016f86609015b6e23b2590ba7668fa1c172bba7a1cd6fd/chand-0.0.2.tar.gz",
    "platform": null,
    "description": "# chand \u0686\u0646\u062f\u061f\n\n[![PyPI](https://img.shields.io/pypi/v/chand?style=for-the-badge)](https://pypi.org/project/chand)\n[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/chand?style=for-the-badge)](https://pypi.org/project/chand)\n[![GitHub](https://img.shields.io/github/license/armanyazdi/chand?style=for-the-badge)](https://pypi.org/project/chand)\n\nA Python library for converting currencies to Iranian Rial and Toman.\n\nNote: This package shows the right real time price of Iranian Rial.\n\n## Installation\n\nInstall from [PyPI](https://pypi.org/project/chand) with pip by typing in your favorite terminal.\n\nThis will also install `requests` and `bs4`.\n\n`pip install chand`\n\n## Usage\n\nLet's take a look at what an example test case would look like using `chand`.\n\n### Exchange Rates in Rial and Toman:\n\n```python\nimport chand\n\nchand.toman('usd') # or 'USD'\nchand.toman('gbp') # or 'GBP'\nchand.rial('eur')  # or 'EUR'\nchand.rial('try')  # or 'TRY'\n```\n\n### Currency Converter:\n\nIt can convert the currency of **136 codes (ISO 4217)**.\n\n```python\nimport chand\n\nchand.convert('eur', 'usd', 500) # 500 Euro to US Dollar\nchand.convert('usd', 'eur', 500) # 500 US Dollar to Euro\nchand.convert('eur', 'try', 100) # 100 Euro to Turkish Lira\n```\n\n### Crypto Price in USD:\n\nIt supports more than **3700 Crypto Currencies**.\n\n```python\nimport chand\n\nchand.crypto('bitcoin')  # or 'btc'\nchand.crypto('ethereum') # or 'eth'\nchand.crypto('cardano')  # or 'ada'\n```\n\n### Crypto Converter:\n\n```python\nimport chand\n\nchand.convert('btc', 'eth')     # Bitcoin to Ethereum\nchand.convert('eth', 'btc', 10) # 10 Ethereum to Bitcoin\nchand.convert('btc', 'eur', 5)  # 5 Bitcoin to Euro\nchand.convert('eth', 'gbp', 20) # 20 Bitcoin to Pound\n```\n\n### Color Formats Converter:\n\nHEX to RGB, CMYK, HSV/HSB\n\n```python\nimport chand\n\nchand.convert('hex', 'rgb', 'ff4f5e')  # (255, 79, 94)\nchand.convert('hex', 'cmyk', 'ff4f5e') # (0%, 69%, 63%, 0%)\nchand.convert('hex', 'hsv', 'ff4f5e')  # (355\u00b0, 69%, 100%)\n```\n\n### BMI, BMR, RMR Calculator:\n\n```python\nimport chand\n\nchand.bmi(180, 75) # or chand.bmi('180', '75')\n# Height(cm), Weight(kg)\n\nchand.bmr(168, 55, 22, 'female')\n# Height(cm), Weight(kg), Age, Sex\n\nchand.rmr(180, 75, 29, 'male')\n# Height(cm), Weight(kg), Age, Sex\n```\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A Python library for converting currencies to Iranian Rial and Toman.",
    "version": "0.0.2",
    "split_keywords": [
        "currency converter",
        "crypto converter",
        "iranian rial",
        "iranian toman"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "9cb91ec304901e4695a6490797fc77e8",
                "sha256": "67dc1f8140b3bc84a66990ce1b05e977fa2087daa55560b2724ddea8f5dad728"
            },
            "downloads": -1,
            "filename": "chand-0.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "9cb91ec304901e4695a6490797fc77e8",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">= 3.6",
            "size": 35717,
            "upload_time": "2022-12-03T05:03:08",
            "upload_time_iso_8601": "2022-12-03T05:03:08.859350Z",
            "url": "https://files.pythonhosted.org/packages/a5/4c/24632155f30c8823f31c9dbea26881fe2f6a9954ca2fd1b4b808b9fa1e10/chand-0.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "ae19695466415fe69522f0565692f0fa",
                "sha256": "7bb461e5ebd5357b659797e53b48cdab8a79799ca24695aac904bb5e82ce6ab4"
            },
            "downloads": -1,
            "filename": "chand-0.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "ae19695466415fe69522f0565692f0fa",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">= 3.6",
            "size": 34143,
            "upload_time": "2022-12-03T05:03:12",
            "upload_time_iso_8601": "2022-12-03T05:03:12.047112Z",
            "url": "https://files.pythonhosted.org/packages/d7/4d/62fef0e910c13c016f86609015b6e23b2590ba7668fa1c172bba7a1cd6fd/chand-0.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-12-03 05:03:12",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "armanyazdi",
    "github_project": "chand",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "requirements": [
        {
            "name": "requests",
            "specs": []
        },
        {
            "name": "bs4",
            "specs": []
        }
    ],
    "lcname": "chand"
}
        
Elapsed time: 0.04666s