Metadata-Version: 2.4
Name: oidc-auth-client
Version: 0.1.2
Summary: Add your description here
Author-email: Ole-Jakob Olsen <ole.jakob.olsen@ngi.no>
Requires-Python: >=3.13
Requires-Dist: httpx>=0.28.1
Description-Content-Type: text/markdown

# oidc-auth-client

## Installing

`pip install oidc-auth-client`

## Example usage

```py
from oidc_auth_client import Config, AuthorizationCode, OidcProvider

access_token = AuthorizationCode(
    config=Config(
        client_id="<your-client-id>",
        oidc_provider=OidcProvider(
            openid_configuration_url="<auth-provider-url>/.well-known/openid-configuration"
        ),
        token_cache=TokenCache(),
    )
).get_token()
```

To allow the user to cache the token between usages, configure with a `TokenCache`. Will store the token in plaintext on the users system.

```py
from oidc_auth_client import Config, TokenCache

config = Config(
    # ...
    token_cache=TokenCache(),
)
```

see some example usage in the [examples folder](./examples/).
