# Nigerian Zip Codes (zipcode-ng)
The `zipcode-ng` library provides information about states, local government areas (LGAs) towns and zip codes in Nigeria.
## Installation
You can install the package via pip:
```bash
pip install zipcode-ng
```
## Usage
### Importing
```python
from zipcode_ng import (
get_state_data,
get_all_state_data
)
# Retrieve data for a specific state
lagos_state_data = get_state_data("Lagos")
print("Lagos State Data:", lagos_state_data)
# Retrieve data for all states
all_states_data = get_all_state_data()
print("All States Data:", all_states_data)
```
### Functions
- `get_state_data(identifier: Union[str, StateName]) -> StateInfo`: Returns information about a specific state based on its name or postal code.
- `get_all_state_data() -> List[StateInfo]`: Returns information about all states in Nigeria.
### Type Definitions
- `StateInfo`: Represents the data structure for information about a state, including its name, language, tribe, description, region, etc.
- `StateName`: Literal type representing the names of Nigerian states.
### JSON Data
The state information returned by the library is sourced from a JSON file included with the package. The JSON file contains details about each state, including local government areas and towns within them.
## Contributing
Contributions are welcome! If you'd like to contribute to this project, please fork the repository and submit a pull request with your changes.
## GitHub Repository
You can find the source code and contribute to this project on GitHub: [Nigerian Zip Codes on GitHub](https://github.com/awesomegoodman/zipcode-ng)
Raw data
{
"_id": null,
"home_page": "https://github.com/awesomegoodman/zipcode-ng/tree/main/pypi",
"name": "zipcode-ng",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "Nigerian Zip Codes,Nigerian LGAs,Nigerian Local Government Areas,Nigerian States,Nigerian Postal Codes",
"author": "Awesome Goodman",
"author_email": "goodman.awesome@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/a0/c1/cb613409ed3382baf2c37c48e29ad322bffc2958cbfedbff82817757ecde/zipcode_ng-0.0.1.tar.gz",
"platform": null,
"description": "# Nigerian Zip Codes (zipcode-ng)\r\n\r\nThe `zipcode-ng` library provides information about states, local government areas (LGAs) towns and zip codes in Nigeria.\r\n\r\n## Installation\r\n\r\nYou can install the package via pip:\r\n\r\n```bash\r\npip install zipcode-ng\r\n```\r\n\r\n## Usage\r\n\r\n### Importing\r\n\r\n```python\r\nfrom zipcode_ng import (\r\n get_state_data,\r\n get_all_state_data\r\n)\r\n\r\n# Retrieve data for a specific state\r\nlagos_state_data = get_state_data(\"Lagos\")\r\nprint(\"Lagos State Data:\", lagos_state_data)\r\n\r\n# Retrieve data for all states\r\nall_states_data = get_all_state_data()\r\nprint(\"All States Data:\", all_states_data)\r\n```\r\n\r\n### Functions\r\n\r\n- `get_state_data(identifier: Union[str, StateName]) -> StateInfo`: Returns information about a specific state based on its name or postal code.\r\n\r\n- `get_all_state_data() -> List[StateInfo]`: Returns information about all states in Nigeria.\r\n\r\n### Type Definitions\r\n\r\n- `StateInfo`: Represents the data structure for information about a state, including its name, language, tribe, description, region, etc.\r\n\r\n- `StateName`: Literal type representing the names of Nigerian states.\r\n\r\n### JSON Data\r\n\r\nThe state information returned by the library is sourced from a JSON file included with the package. The JSON file contains details about each state, including local government areas and towns within them.\r\n\r\n## Contributing\r\n\r\nContributions are welcome! If you'd like to contribute to this project, please fork the repository and submit a pull request with your changes.\r\n\r\n## GitHub Repository\r\n\r\nYou can find the source code and contribute to this project on GitHub: [Nigerian Zip Codes on GitHub](https://github.com/awesomegoodman/zipcode-ng)\r\n",
"bugtrack_url": null,
"license": "",
"summary": "information about states, local government areas (LGAs) towns and zip codes in Nigeria.",
"version": "0.0.1",
"project_urls": {
"Homepage": "https://github.com/awesomegoodman/zipcode-ng/tree/main/pypi"
},
"split_keywords": [
"nigerian zip codes",
"nigerian lgas",
"nigerian local government areas",
"nigerian states",
"nigerian postal codes"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "1253ecd98c354a9e2158ccd4aab0d0a12cbba8ef58f69d8a129ae13c5bf0bb36",
"md5": "fbaa9dc5947b39f0522828e3c22ceb72",
"sha256": "d0ea439380c465e9298ab2b1b1dcc29fe8d37dc0ca9f1782778b10652690ff72"
},
"downloads": -1,
"filename": "zipcode_ng-0.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "fbaa9dc5947b39f0522828e3c22ceb72",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 9166,
"upload_time": "2024-03-05T01:30:14",
"upload_time_iso_8601": "2024-03-05T01:30:14.896582Z",
"url": "https://files.pythonhosted.org/packages/12/53/ecd98c354a9e2158ccd4aab0d0a12cbba8ef58f69d8a129ae13c5bf0bb36/zipcode_ng-0.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "a0c1cb613409ed3382baf2c37c48e29ad322bffc2958cbfedbff82817757ecde",
"md5": "2bc96b23d7c8b302b57a36e09bad0582",
"sha256": "6ce50b966ac00423f1e9607080460b8365eb9dcf363c45ef79fb05ae828bd486"
},
"downloads": -1,
"filename": "zipcode_ng-0.0.1.tar.gz",
"has_sig": false,
"md5_digest": "2bc96b23d7c8b302b57a36e09bad0582",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 9907,
"upload_time": "2024-03-05T01:30:18",
"upload_time_iso_8601": "2024-03-05T01:30:18.400708Z",
"url": "https://files.pythonhosted.org/packages/a0/c1/cb613409ed3382baf2c37c48e29ad322bffc2958cbfedbff82817757ecde/zipcode_ng-0.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-03-05 01:30:18",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "awesomegoodman",
"github_project": "zipcode-ng",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "zipcode-ng"
}