kognic-auth


Namekognic-auth JSON
Version 3.5.1 PyPI version JSON
download
home_pageNone
SummaryKognic Authentication
upload_time2024-10-23 08:44:47
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseMIT
keywords kognic api
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Kognic Authentication

Python 3 library providing foundations for Kognic Authentication
on top of the `requests` or `httpx` libraries.

Install with `pip install kognic-auth[requests]` or `pip install kognic-auth[httpx]` 

Builds on the standard OAuth 2.0 Client Credentials flow. There are a few ways to provide auth credentials to our api
 clients. Kognic Python clients such as in `kognic-io` accept an `auth` parameter that
  can be set explicitly or you can omit it and use environment variables. 

There are a few ways to set your credentials in `auth`. 
1. Set the environment variable `KOGNIC_CREDENTIALS` to point to your Api Credentials file. 
The credentials will contain the Client Id and Client Secret.
2. Set to the credentials file path like `auth="~/.config/kognic/credentials.json"` 
3. Set environment variables `KOGNIC_CLIENT_ID` and`KOGNIC_CLIENT_SECRET`
4. Set to credentials tuple `auth=(client_id, client_secret)` 

API clients such as the `InputApiClient` accept this `auth` parameter.

Under the hood, they commonly use the AuthSession class which is implements a `requests` session with automatic token
 refresh. An `httpx` implementation is also available. 
```python
from kognic.auth.requests.auth_session import RequestsAuthSession

sess = RequestsAuthSession()

# make call to some Kognic service with your token. Use default requests 
sess.get("https://api.app.kognic.com")
```

## Changelog
See Github releases from v3.1.0, historic changelog is available in CHANGELOG.md

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "kognic-auth",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "Kognic, API",
    "author": null,
    "author_email": "Kognic <michel.edkrantz@kognic.com>",
    "download_url": "https://files.pythonhosted.org/packages/e4/8c/8e531506864da88a4e9eaf9d4660861fcdcbe60e3d48551f6549b25ca9cb/kognic_auth-3.5.1.tar.gz",
    "platform": null,
    "description": "# Kognic Authentication\n\nPython 3 library providing foundations for Kognic Authentication\non top of the `requests` or `httpx` libraries.\n\nInstall with `pip install kognic-auth[requests]` or `pip install kognic-auth[httpx]` \n\nBuilds on the standard OAuth 2.0 Client Credentials flow. There are a few ways to provide auth credentials to our api\n clients. Kognic Python clients such as in `kognic-io` accept an `auth` parameter that\n  can be set explicitly or you can omit it and use environment variables. \n\nThere are a few ways to set your credentials in `auth`. \n1. Set the environment variable `KOGNIC_CREDENTIALS` to point to your Api Credentials file. \nThe credentials will contain the Client Id and Client Secret.\n2. Set to the credentials file path like `auth=\"~/.config/kognic/credentials.json\"` \n3. Set environment variables `KOGNIC_CLIENT_ID` and`KOGNIC_CLIENT_SECRET`\n4. Set to credentials tuple `auth=(client_id, client_secret)` \n\nAPI clients such as the `InputApiClient` accept this `auth` parameter.\n\nUnder the hood, they commonly use the AuthSession class which is implements a `requests` session with automatic token\n refresh. An `httpx` implementation is also available. \n```python\nfrom kognic.auth.requests.auth_session import RequestsAuthSession\n\nsess = RequestsAuthSession()\n\n# make call to some Kognic service with your token. Use default requests \nsess.get(\"https://api.app.kognic.com\")\n```\n\n## Changelog\nSee Github releases from v3.1.0, historic changelog is available in CHANGELOG.md\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Kognic Authentication",
    "version": "3.5.1",
    "project_urls": {
        "homepage": "https://github.com/annotell/kognic-auth-python"
    },
    "split_keywords": [
        "kognic",
        " api"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "ab3c5d2a9ace5fc966758e1b7dffc5f4e6d1a8a5fe0c39a2cb4a54a6f6c3bc3d",
                "md5": "800d2ee14f6381ec48e91612ef98cdbc",
                "sha256": "aca41756fd29520337fa736ce019076d5b09abd7616e213169b5163bb8295430"
            },
            "downloads": -1,
            "filename": "kognic_auth-3.5.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "800d2ee14f6381ec48e91612ef98cdbc",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 7262,
            "upload_time": "2024-10-23T08:44:46",
            "upload_time_iso_8601": "2024-10-23T08:44:46.360405Z",
            "url": "https://files.pythonhosted.org/packages/ab/3c/5d2a9ace5fc966758e1b7dffc5f4e6d1a8a5fe0c39a2cb4a54a6f6c3bc3d/kognic_auth-3.5.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "e48c8e531506864da88a4e9eaf9d4660861fcdcbe60e3d48551f6549b25ca9cb",
                "md5": "d2727a267a322bd7b5720b9ea6438fcf",
                "sha256": "ff8e8c9285467ae1ba8777dc62e98f32f7a9854504c7ff480c1ca40cb86f415a"
            },
            "downloads": -1,
            "filename": "kognic_auth-3.5.1.tar.gz",
            "has_sig": false,
            "md5_digest": "d2727a267a322bd7b5720b9ea6438fcf",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 8766,
            "upload_time": "2024-10-23T08:44:47",
            "upload_time_iso_8601": "2024-10-23T08:44:47.596545Z",
            "url": "https://files.pythonhosted.org/packages/e4/8c/8e531506864da88a4e9eaf9d4660861fcdcbe60e3d48551f6549b25ca9cb/kognic_auth-3.5.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-23 08:44:47",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "annotell",
    "github_project": "kognic-auth-python",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "kognic-auth"
}
        
Elapsed time: 1.05071s