# BoB Metadata Keys and URLs
This repository contains a Python module with the current [BoB](https://bob.samtrafiken.se/) Metadata keys and URLs. Inspired by [certifi](https://github.com/certifi/python-certifi).
## Installation
`bobifi` is available on PyPI. Simply install it with ``pip``:
$ pip install bobifi
## Usage
`bobifi` includes test and production keys and metadata URLs from Swedish Samtrafiken. Usage examples below.
>>> from bobifi.samtrafiken import trusted_jwks, metadata_url, where
>>> metadata_url(env="test")
'https://bobmetadata-pp.samtrafiken.se/api/v2/participantMetadata'
>>> where(env="test")
'/home/bob/bobifi/data/samtrafiken-test.json'
>>> import pprint
>>> pprint.pprint(trusted_jwks(env="test"))
{'keys': [{'crv': 'P-256',
'kid': '16:samtrafiken_one',
'kty': 'EC',
'x': 'f83OJ3D2xF1Bg8vub9tLe1gHMzV76e8Tus9uPHvRVEU',
'y': 'x_FEzRu9m36HLN_tue659LNpXW6pCyStikYjKIWI5a0'},
{'e': 'AQAB',
'kid': '16:samtrafiken_fallback_2023',
'kty': 'RSA',
'n': 't5ITeoklTnhR8XNDLYKx5WsUxkJZkBSqT-5dfc-W_1cByD0ZKf-2DkwArXWwK4bYPQ2RlDuot-m8U2GSjnQ9wNxrA1oIUzJZYw1ryqbq-Lh1hrbYWbW2OlcIIce2dzEnSdbphTthoYFDu1xS8n5hi1xC-LGlmfmQfTCjCZR5CFnRbar97rAjfrRfvlwG15XJTC6BiDtYZMF5KmpgKCqP39ELCqV0LHXfeJ50v263a9enlD0RogNAbwM0OTDZ-ek8WF5YePEuE1p0-Pbe14O-pSkT_DPwl5pF6uk6QN3whr90oTgDkUoI4xb88jhscWb1yf4PfjsF3F4JUgYn9V1w28-N7ZIkGe6-PznWmvjsgJj9u6sg9f2-AU5k2ZsZCuO1-bVSubjJU0j2J7DyvP3wpxt1ybrOjA1X8K2s6bMBan0u3CsHDsikGHsgKlDkWJvD5fBpb1Ize3YfbAJvbGNtT2ae6Ft0cB__xVGDvJqEl6UHZgU4gBm01DiX20RJcGgWbX5nsz47mC2zXG_thtpPd8lAsyevGBKTsMpPEomAwRfL_VDWvjcXGPTD7Lm-igzzWLHrK9xRmhBOHs_oxK2o6gUtu4LcqSh1PHCIzBznzdacHVSPrLy5pPTuwxm4DYrhycOvlb8PPL9qX7qscJTwp5jcNYAYvmF2Ezns32HhIXM'}]}
For Samtrafiken, the `test` and `prod` environments are currently defined. The `prod` environment is used as default.
Raw data
{
"_id": null,
"home_page": "https://github.com/bobcat-ticketing/python-bobifi'",
"name": "bobifi",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.9",
"maintainer_email": null,
"keywords": null,
"author": "Jakob Schlyter",
"author_email": "jakob@kirei.se",
"download_url": "https://files.pythonhosted.org/packages/e4/32/a2733e95b5ffed55f0808a538ecf4e20e7ebe646758858f81004f7a3bd6b/bobifi-2024.11.25.tar.gz",
"platform": null,
"description": "# BoB Metadata Keys and URLs\n\nThis repository contains a Python module with the current [BoB](https://bob.samtrafiken.se/) Metadata keys and URLs. Inspired by [certifi](https://github.com/certifi/python-certifi).\n\n\n## Installation\n\n`bobifi` is available on PyPI. Simply install it with ``pip``:\n\n $ pip install bobifi\n\n\n## Usage\n\n`bobifi` includes test and production keys and metadata URLs from Swedish Samtrafiken. Usage examples below.\n\n >>> from bobifi.samtrafiken import trusted_jwks, metadata_url, where\n\n >>> metadata_url(env=\"test\")\n 'https://bobmetadata-pp.samtrafiken.se/api/v2/participantMetadata'\n\n >>> where(env=\"test\")\n '/home/bob/bobifi/data/samtrafiken-test.json'\n\n >>> import pprint\n >>> pprint.pprint(trusted_jwks(env=\"test\"))\n {'keys': [{'crv': 'P-256',\n 'kid': '16:samtrafiken_one',\n 'kty': 'EC',\n 'x': 'f83OJ3D2xF1Bg8vub9tLe1gHMzV76e8Tus9uPHvRVEU',\n 'y': 'x_FEzRu9m36HLN_tue659LNpXW6pCyStikYjKIWI5a0'},\n {'e': 'AQAB',\n 'kid': '16:samtrafiken_fallback_2023',\n 'kty': 'RSA',\n 'n': 't5ITeoklTnhR8XNDLYKx5WsUxkJZkBSqT-5dfc-W_1cByD0ZKf-2DkwArXWwK4bYPQ2RlDuot-m8U2GSjnQ9wNxrA1oIUzJZYw1ryqbq-Lh1hrbYWbW2OlcIIce2dzEnSdbphTthoYFDu1xS8n5hi1xC-LGlmfmQfTCjCZR5CFnRbar97rAjfrRfvlwG15XJTC6BiDtYZMF5KmpgKCqP39ELCqV0LHXfeJ50v263a9enlD0RogNAbwM0OTDZ-ek8WF5YePEuE1p0-Pbe14O-pSkT_DPwl5pF6uk6QN3whr90oTgDkUoI4xb88jhscWb1yf4PfjsF3F4JUgYn9V1w28-N7ZIkGe6-PznWmvjsgJj9u6sg9f2-AU5k2ZsZCuO1-bVSubjJU0j2J7DyvP3wpxt1ybrOjA1X8K2s6bMBan0u3CsHDsikGHsgKlDkWJvD5fBpb1Ize3YfbAJvbGNtT2ae6Ft0cB__xVGDvJqEl6UHZgU4gBm01DiX20RJcGgWbX5nsz47mC2zXG_thtpPd8lAsyevGBKTsMpPEomAwRfL_VDWvjcXGPTD7Lm-igzzWLHrK9xRmhBOHs_oxK2o6gUtu4LcqSh1PHCIzBznzdacHVSPrLy5pPTuwxm4DYrhycOvlb8PPL9qX7qscJTwp5jcNYAYvmF2Ezns32HhIXM'}]}\n\n\nFor Samtrafiken, the `test` and `prod` environments are currently defined. The `prod` environment is used as default.\n\n\n",
"bugtrack_url": null,
"license": "BSD-2-Clause",
"summary": "BoB Metadata Keys and URLs",
"version": "2024.11.25",
"project_urls": {
"Homepage": "https://github.com/bobcat-ticketing/python-bobifi'",
"Repository": "https://github.com/bobcat-ticketing/python-bobifi'"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "c5ffb3b091aa41f3bc04c992b7dcdefb8de88b9d6ebb7c52ba542af34c702ee7",
"md5": "639ae63c8261440744d74e86ba7a8411",
"sha256": "8e5d5d411a31e782d4e4e3eb70f84c8049405a2589171d6f06d1ed6dc51e4946"
},
"downloads": -1,
"filename": "bobifi-2024.11.25-py3-none-any.whl",
"has_sig": false,
"md5_digest": "639ae63c8261440744d74e86ba7a8411",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.9",
"size": 5958,
"upload_time": "2024-11-25T09:07:48",
"upload_time_iso_8601": "2024-11-25T09:07:48.104331Z",
"url": "https://files.pythonhosted.org/packages/c5/ff/b3b091aa41f3bc04c992b7dcdefb8de88b9d6ebb7c52ba542af34c702ee7/bobifi-2024.11.25-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "e432a2733e95b5ffed55f0808a538ecf4e20e7ebe646758858f81004f7a3bd6b",
"md5": "d93cf2aa50ba64c18e19b43a7eef6d74",
"sha256": "471254e052621321bc8cc53bec99e394217ffb44e37ebf2a914ddd02d1636f30"
},
"downloads": -1,
"filename": "bobifi-2024.11.25.tar.gz",
"has_sig": false,
"md5_digest": "d93cf2aa50ba64c18e19b43a7eef6d74",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.9",
"size": 4343,
"upload_time": "2024-11-25T09:07:49",
"upload_time_iso_8601": "2024-11-25T09:07:49.539925Z",
"url": "https://files.pythonhosted.org/packages/e4/32/a2733e95b5ffed55f0808a538ecf4e20e7ebe646758858f81004f7a3bd6b/bobifi-2024.11.25.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-25 09:07:49",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "bobcat-ticketing",
"github_project": "python-bobifi'",
"github_not_found": true,
"lcname": "bobifi"
}