{"id":18651243,"url":"https://github.com/fallendeity/pokelance","last_synced_at":"2025-04-11T15:31:11.547Z","repository":{"id":64662976,"uuid":"576518848","full_name":"FallenDeity/PokeLance","owner":"FallenDeity","description":"An asynchronous api wrapper wrapping around pokeapi with auto data and image caching.","archived":false,"fork":false,"pushed_at":"2024-03-25T13:15:54.000Z","size":2762,"stargazers_count":7,"open_issues_count":4,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-04-23T21:18:21.922Z","etag":null,"topics":["asyncio","pokeapi","pokedex","pokemon","pokemon-api","python3"],"latest_commit_sha":null,"homepage":"https://fallendeity.github.io/PokeLance/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FallenDeity.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-12-10T04:59:18.000Z","updated_at":"2024-02-26T08:05:12.000Z","dependencies_parsed_at":"2023-12-23T18:21:29.395Z","dependency_job_id":"2ef8a118-5e72-4f1d-93e0-1f526f141f80","html_url":"https://github.com/FallenDeity/PokeLance","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FallenDeity%2FPokeLance","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FallenDeity%2FPokeLance/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FallenDeity%2FPokeLance/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FallenDeity%2FPokeLance/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FallenDeity","download_url":"https://codeload.github.com/FallenDeity/PokeLance/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248431368,"owners_count":21102189,"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":["asyncio","pokeapi","pokedex","pokemon","pokemon-api","python3"],"created_at":"2024-11-07T06:49:04.600Z","updated_at":"2025-04-11T15:31:06.536Z","avatar_url":"https://github.com/FallenDeity.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\u003cb\u003ePokeLance\u003c/b\u003e\u003c/h1\u003e\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/FallenDeity/PokeLance/master/docs/assets/pokelance.png\" width=450 alt=\"logo\"\u003e\u003cbr\u003e\u003cbr\u003e\n\u003cimg src=\"https://img.shields.io/github/license/FallenDeity/PokeLance?style=flat-square\" alt=\"license\"\u003e\n\u003cimg src=\"https://img.shields.io/badge/code%20style-black-000000.svg?style=flat-square\" alt=\"black\"\u003e\n\u003cimg src=\"https://img.shields.io/badge/%20type_checker-mypy-%231674b1?style=flat-square\" alt=\"mypy\"\u003e\n\u003cimg src=\"https://img.shields.io/badge/%20linter-ruff-%231674b1?style=flat-square\" alt=\"ruff\"\u003e\n\u003cimg src=\"https://img.shields.io/github/stars/FallenDeity/PokeLance?style=flat-square\" alt=\"stars\"\u003e\n\u003cimg src=\"https://img.shields.io/pypi/dm/pokelance.svg\" alt=\"downloads\"\u003e\n\u003cimg src=\"https://img.shields.io/github/last-commit/FallenDeity/PokeLance?style=flat-square\" alt=\"commits\"\u003e\n\u003cimg src=\"https://img.shields.io/pypi/pyversions/PokeLance?style=flat-square\" alt=\"py\"\u003e\n\u003cimg src=\"https://img.shields.io/pypi/v/PokeLance?style=flat-square\" alt=\"versions\"\u003e\n\u003cbr\u003e\u003cbr\u003e\nA flexible, statically typed and easy to use pokeapi wrapper for python 🚀\n\u003c/p\u003e\n\n---\n\n\nFeatures:\n- Modern and pythonic API asynchronously built on top of aiohttp\n- Flexible and easy to use\n- Statically typed with mypy\n- Linted with ruff\n- Well documented\n- Optimized for speed and performance\n- Automatically caches data for faster access\n- Caches endpoints for user convenience\n\n---\n\n## Installation\n\n```bash\n$ python -m pip install PokeLance\n```\n\n---\n\n## Usage\n\n```python\nimport asyncio\n\nfrom pokelance import PokeLance\n\nclient = PokeLance()  # Create a client instance\n\n\nasync def main() -\u003e None:\n    print(await client.ping())  # Ping the pokeapi\n    print(await client.berry.fetch_berry(\"cheri\"))  # Fetch a berry from the pokeapi\n    print(await client.berry.fetch_berry_flavor(\"spicy\"))\n    print(await client.berry.fetch_berry_firmness(\"very-soft\"))\n    print(client.berry.get_berry(\"cheri\"))  # Get a cached berry it will return None if it doesn't exist\n    print(client.berry.get_berry_flavor(\"spicy\"))\n    print(client.berry.get_berry_firmness(\"very-soft\"))\n    await client.close()  # Close the client\n    return None\n\n\nasyncio.run(main())\n```\n\n## With Async Context Manager\n\n```python\nimport asyncio\n\nimport aiohttp\nfrom pokelance import PokeLance\n\n\nasync def main() -\u003e None:\n    # Use an async context manager to create a client instance\n    async with aiohttp.ClientSession() as session, PokeLance(session=session) as client:\n        print(await client.ping())  # Ping the pokeapi\n        print(await client.berry.fetch_berry(\"cheri\"))  # Fetch a berry from the pokeapi\n        print(await client.berry.fetch_berry_flavor(\"spicy\"))\n        print(await client.berry.fetch_berry_firmness(\"very-soft\"))\n        print(client.berry.get_berry(\"cheri\"))  # Get a cached berry it will return None if it doesn't exist\n        print(client.berry.get_berry_flavor(\"spicy\"))\n        print(client.berry.get_berry_firmness(\"very-soft\"))\n        # The client will be closed automatically when the async context manager exits\n    return None\n\nasyncio.run(main())\n```\n\n# Examples\n\n[Examples](https://fallendeity.github.io/PokeLance/guide/basic_usage/)\n\nFollowing examples are available open an issue if you want more examples or more details on certain examples.\n- Basic Usage\n- Advanced cache usage\n- Discord bot example\n- FastAPI example\n\n\n## Important Links\n\n\n- [PokeAPI](https://pokeapi.co/)\n- [PokeAPI Documentation](https://pokeapi.co/docs/v2)\n- [PokeLance Documentation](https://FallenDeity.github.io/PokeLance/)\n- [PokeLance ReadTheDocs](https://pokelance.readthedocs.io/en/latest/)\n- [PokeLance GitHub](https://github.com/FallenDeity/PokeLance)\n- [PokeLance PyPI](https://pypi.org/project/PokeLance/)\n- [PokeLance Discord](https://discord.gg/yeyEvT5V2J)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffallendeity%2Fpokelance","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffallendeity%2Fpokelance","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffallendeity%2Fpokelance/lists"}