{ "info": { "author": "Arnav Borborah", "author_email": "arnavborborah11@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Natural Language :: English", "Operating System :: OS Independent", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Games/Entertainment", "Topic :: Software Development :: Libraries" ], "description": "

\n \n

\n\n[![Travis Build Status](https://travis-ci.org/arnavb/pypokedex.svg?branch=master)](https://travis-ci.org/arnavb/pypokedex)\n[![Appveyor Build status](https://ci.appveyor.com/api/projects/status/wpbab6ojfvoe1eg2/branch/master?svg=true)](https://ci.appveyor.com/project/arnavb/pypokedex/branch/master)\n[![Codecov](https://img.shields.io/codecov/c/github/arnavb/pypokedex.svg)](https://codecov.io/gh/arnavb/pypokedex)\n[![PyPI](https://img.shields.io/pypi/v/pypokedex.svg)](https://pypi.org/project/pypokedex/)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/pypokedex.svg)\n[![License](https://img.shields.io/github/license/arnavb/pypokedex.svg)](https://github.com/arnavb/pypokedex/blob/master/LICENSE)\n\nPyPokedex is a minimal pokedex library for Python that uses [PokeAPI](https://pokeapi.co/) internally to get Pokemon data. A simple example:\n\n

\n \n

\n\n## Requirements\n\n- Python 3.6+\n\n## Installing\n\nUse:\n\n```bash\n$ pip install pypokedex\n```\n\nto get the latest stable release, or:\n\n```bash\n$ pip install git+https://github.com/arnavb/pypokedex.git@master\n```\n\nto get the latest commit on master.\n\n## Documentation\n\nThis package (`pypokedex`) only provides one function through the\npublic API\u2014`get`. It can be used as follows:\n\n```python\nimport pypokedex\n\npokemon = pypokedex.get(dex=DEX) # DEX must be a valid _national_ pokedex\n # number\npokemon2 = pypokedex.get(name=NAME) # NAME must be a valid name of a pokemon\n```\n\n### Possible Exceptions\n\n- A `TypeError` will be raised if the wrong number of arguments or the wrong\n type of arguments are passed.\n- A `PyPokedexHTTPError` will be raised with an HTTP code of 404 if the Pokemon\n requested is not found. **Note**: The `name` parameter to `get` is _case-insensitive_.\n- A `PyPokedexHTTPError` will be raised with the proper HTTP code if another type\n of HTTP error occurs.\n- A `PyPokedexError` will be raised if a [requests exception](http://docs.python-requests.org/en/master/_modules/requests/exceptions/)\n occurs (with the exception of `requests.exceptions.HTTPError`, handled in the\n previous two bullet points).\n- A `PyPokedexError` will be raised if data is missing when parsing the returned\n JSON from PokeAPI (usually this indicates an API change).\n\nOnce a valid `pypokedex.pokemon.Pokemon` object is returned, the following\nmembers are provided for its consumption:\n\n### Member Variables\n\n- `dex` (`int`): Contains the _national_ Pokedex number of the current Pokemon.\n- `name` (`str`): Contains the name of the current Pokemon.\n- `height` (`int`): Contains the height of the current Pokemon in decimeters (see [veekun/pokedex#249](https://github.com/veekun/pokedex/issues/249)).\n- `weight` (`int`): Contains the weight of the current Pokemon in hectograms (see [veekun/pokedex#249](https://github.com/veekun/pokedex/issues/249)).\n- `base_experience` (`intt`): Contains the base experience yield of the current Pokemon.\n- `types` (`List[str]`): Contains a list of strings with the name of the current\n Pokemon's types.\n- `abilities` (`List[Ability]`): Contains a list of named tuples called `Ability`.\n Each `Ability` has the following members:\n - `name` (`str`): The name of the current ability.\n - `is_hidden` (`bool`): Whether the current ability is a hidden ability or not.\n- `base_stats` (`BaseStats`): Contains a named tuple with the current\n Pokemon's base stats stored as follows (all `int`s):\n - `hp`: The base HP of the current Pokemon.\n - `atk`: The base attack of the current Pokemon.\n - `def`: The base defense of the current Pokemon.\n - `sp_atk`: The base special attack of the current Pokemon.\n - `sp_def`: The base special defense of the current Pokemon.\n - `speed`: The base speed of the current Pokemon.\n- `moves` (`DefaultDict[str, List[Move]]`): Contains a dictionary of game names\n (according to PokeAPI) to a list of named tuples called `Move` representing the\n moves the current Pokemon learns in the respective game. The `Move` named tuple\n contains the following members:\n - `name` (`str`): The name of the current move.\n - `learn_method` (`str`): The method the current Pokemon uses to learn the\n current move (according to PokeAPI).\n - `level` (`int`): The level the current Pokemon learns the current move if\n `learn_method` is `level-up`, `None` otherwise.\n\n### Member Functions\n\n- `def exists_in(self, game: str) -> bool`: Method to check whether the current\n Pokemon exists in a specific game.\n- `def learns(self, move_name: str, game: str) -> bool`: Method to check\n whether the current Pokemon learns a specific move in a specific game.\n- `def __str__(self) -> str`: Method to get a string represenation of the\n current Pokemon. This string is of the form: `Pokemon(dex={self.dex}, name='{self.name}')`.\n- `__eq__, __lt__, __gt__, __le__, __ge__`: Methods that implement various\n comparison operators for Pokemon objects in terms of their Pokedex number.\n\n#### Possible Exceptions\n\n- `learns` will raise a `PyPokedexError` if the current Pokemon does not exist\n in the game specified.\n\n## License\n\nThis library is licensed under the [MIT License](https://github.com/arnavb/pypokedex/blob/master/LICENSE).\n\n### Dependency Licenses\n\nThis library depends on [requests](https://github.com/requests/requests), which is licensed under the [Apache 2.0 License](https://github.com/requests/requests/blob/master/LICENSE).\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/arnavb/pypokedex", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "pypokedex", "package_url": "https://pypi.org/project/pypokedex/", "platform": "", "project_url": "https://pypi.org/project/pypokedex/", "project_urls": { "Homepage": "https://github.com/arnavb/pypokedex" }, "release_url": "https://pypi.org/project/pypokedex/1.2.0/", "requires_dist": [ "requests (>=2.21.0)" ], "requires_python": ">=3.6", "summary": "A minimal pokedex library", "version": "1.2.0" }, "last_serial": 5936171, "releases": { "1.0.0": [ { "comment_text": "", "digests": { "md5": "a54b4ca7bee5bc5aeffab3a3b30237f2", "sha256": "12cd6f817496cd553b2921156b8732c8b2eed1884763d9a7b526c09155bc2ae3" }, "downloads": -1, "filename": "pypokedex-1.0.0-py36-none-any.whl", "has_sig": false, "md5_digest": "a54b4ca7bee5bc5aeffab3a3b30237f2", "packagetype": "bdist_wheel", "python_version": "py36", "requires_python": ">=3.6", "size": 4654, "upload_time": "2018-10-01T20:33:10", "url": "https://files.pythonhosted.org/packages/07/3d/f4f15fd9de7613eaf64584b4d9ce08589f309386f9021c4550a766b38d99/pypokedex-1.0.0-py36-none-any.whl" }, { "comment_text": "", "digests": { "md5": "8783535a45d200c8510ca5dd06c177a6", "sha256": "64563f11757e6d18a2fe72f9db8cb90e3c84efd341f7dc50a15ebb6c8f05ea03" }, "downloads": -1, "filename": "pypokedex-1.0.0.tar.gz", "has_sig": false, "md5_digest": "8783535a45d200c8510ca5dd06c177a6", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 223643, "upload_time": "2018-10-01T20:33:11", "url": "https://files.pythonhosted.org/packages/1f/0f/e04098ea506df292dc7aa9f9ea32db0e0c0dd02d3762fefb60466101560a/pypokedex-1.0.0.tar.gz" } ], "1.1.0": [ { "comment_text": "", "digests": { "md5": "982ca12448170cc955e6fa8a0f2859e9", "sha256": "3d3b2b36eb4958587c476e3fcc43e587557c65a3d58d5dfef0884388be65393a" }, "downloads": -1, "filename": "pypokedex-1.1.0-py36-none-any.whl", "has_sig": false, "md5_digest": "982ca12448170cc955e6fa8a0f2859e9", "packagetype": "bdist_wheel", "python_version": "py36", "requires_python": ">=3.6", "size": 6541, "upload_time": "2018-10-07T18:58:22", "url": "https://files.pythonhosted.org/packages/2d/f1/30ad3e0c646539e4026e0427241b0bbb690a50308554efc79f1b8263bfb9/pypokedex-1.1.0-py36-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ac59cf5b87638f6b18380058171437c9", "sha256": "07479c89f90ea2a878c81ddbf1555f3f861d071ec0d5236ccb3be968330dd74a" }, "downloads": -1, "filename": "pypokedex-1.1.0.tar.gz", "has_sig": false, "md5_digest": "ac59cf5b87638f6b18380058171437c9", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 227355, "upload_time": "2018-10-07T18:58:24", "url": "https://files.pythonhosted.org/packages/fa/95/fff6b96827e861f89af37d1d002ee81c7e0d8ef60dc1071793b76f142354/pypokedex-1.1.0.tar.gz" } ], "1.1.1": [ { "comment_text": "", "digests": { "md5": "ccb8b49ff265cfc2a02cdcc4610c415f", "sha256": "42576690f7d9b4b8ab55fe73cbc70c2ea9274e7c4ab427319708becb009d896c" }, "downloads": -1, "filename": "pypokedex-1.1.1-py36-none-any.whl", "has_sig": false, "md5_digest": "ccb8b49ff265cfc2a02cdcc4610c415f", "packagetype": "bdist_wheel", "python_version": "py36", "requires_python": ">=3.6", "size": 6585, "upload_time": "2018-12-02T16:17:39", "url": "https://files.pythonhosted.org/packages/19/7e/0e953abeb5e025896287355396a55e7415af7adda73b4397bcacdd46d2e0/pypokedex-1.1.1-py36-none-any.whl" }, { "comment_text": "", "digests": { "md5": "b7c21e7c669a06bc18b37f00d3d174d3", "sha256": "6d0750155bf7d7e4ab78e698b094ad929ef12d5ed16f3f96657ba17611d5e767" }, "downloads": -1, "filename": "pypokedex-1.1.1.tar.gz", "has_sig": false, "md5_digest": "b7c21e7c669a06bc18b37f00d3d174d3", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 228122, "upload_time": "2018-12-02T16:17:41", "url": "https://files.pythonhosted.org/packages/fc/e4/e963ebdf61d29b1e3c3ae6de2c3c6bc02cd5694096ee7f20f73706972d89/pypokedex-1.1.1.tar.gz" } ], "1.1.2": [ { "comment_text": "", "digests": { "md5": "ab5906e13b2725fea2df83db43bff877", "sha256": "863a5185dc09d94f69d2c040c41750b0c3e7d6e83a6385de892ad561405373b9" }, "downloads": -1, "filename": "pypokedex-1.1.2-py36-none-any.whl", "has_sig": false, "md5_digest": "ab5906e13b2725fea2df83db43bff877", "packagetype": "bdist_wheel", "python_version": "py36", "requires_python": ">=3.6", "size": 6626, "upload_time": "2019-05-04T00:09:10", "url": "https://files.pythonhosted.org/packages/e6/76/e0c90ac1402e4fe41d2f4a735b44bea6b7b8595e02cb1ec86041e166ceb9/pypokedex-1.1.2-py36-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ef0d10c0b33169fc06c0dd3fbeca30b0", "sha256": "5f91d26bd663f2599e09b152a00ec8c26b5a7022b9e43956c3cdb530989cf8a1" }, "downloads": -1, "filename": "pypokedex-1.1.2.tar.gz", "has_sig": false, "md5_digest": "ef0d10c0b33169fc06c0dd3fbeca30b0", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 228064, "upload_time": "2019-05-04T00:09:11", "url": "https://files.pythonhosted.org/packages/ec/eb/b5c18a862e9fd0edddaa954fec2f862763505d0e4d8c2f6ed6698b511a72/pypokedex-1.1.2.tar.gz" } ], "1.2.0": [ { "comment_text": "", "digests": { "md5": "829b502d43ede8cc40dbd34527f11df8", "sha256": "15a75dc214ff735852484f4d4cead539d14565f7fd8cac13c55ebb9cb4e42888" }, "downloads": -1, "filename": "pypokedex-1.2.0-py36-none-any.whl", "has_sig": false, "md5_digest": "829b502d43ede8cc40dbd34527f11df8", "packagetype": "bdist_wheel", "python_version": "py36", "requires_python": ">=3.6", "size": 6655, "upload_time": "2019-10-06T22:05:59", "url": "https://files.pythonhosted.org/packages/95/01/7bb011523f798f1d9d896c16d128602637f0ee07b9da833e82acf448e582/pypokedex-1.2.0-py36-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0e7e485e7745cb354c2cf3f880a56c4d", "sha256": "0d7d611a158af71d1d092aea54c6e4573c81c393188946f08efef9ba22d07157" }, "downloads": -1, "filename": "pypokedex-1.2.0.tar.gz", "has_sig": false, "md5_digest": "0e7e485e7745cb354c2cf3f880a56c4d", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 225738, "upload_time": "2019-10-06T22:06:01", "url": "https://files.pythonhosted.org/packages/59/ec/c21cf04b5df93fd2368170af581ba3f9de2138024fa97430b75a5d7e510c/pypokedex-1.2.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "829b502d43ede8cc40dbd34527f11df8", "sha256": "15a75dc214ff735852484f4d4cead539d14565f7fd8cac13c55ebb9cb4e42888" }, "downloads": -1, "filename": "pypokedex-1.2.0-py36-none-any.whl", "has_sig": false, "md5_digest": "829b502d43ede8cc40dbd34527f11df8", "packagetype": "bdist_wheel", "python_version": "py36", "requires_python": ">=3.6", "size": 6655, "upload_time": "2019-10-06T22:05:59", "url": "https://files.pythonhosted.org/packages/95/01/7bb011523f798f1d9d896c16d128602637f0ee07b9da833e82acf448e582/pypokedex-1.2.0-py36-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0e7e485e7745cb354c2cf3f880a56c4d", "sha256": "0d7d611a158af71d1d092aea54c6e4573c81c393188946f08efef9ba22d07157" }, "downloads": -1, "filename": "pypokedex-1.2.0.tar.gz", "has_sig": false, "md5_digest": "0e7e485e7745cb354c2cf3f880a56c4d", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 225738, "upload_time": "2019-10-06T22:06:01", "url": "https://files.pythonhosted.org/packages/59/ec/c21cf04b5df93fd2368170af581ba3f9de2138024fa97430b75a5d7e510c/pypokedex-1.2.0.tar.gz" } ] }