Internal module for managing access tokens
Reason this release was yanked:
wrong
Project description
@affinidi-tdk/auth-provider
Affinidi TDK Internal module for managing access tokens.
Javascript
Install
npm install @affinidi-tdk/auth-provider
Usage
import { AuthProvider } from '@affinidi-tdk/auth-provider'
const authProvider = new AuthProvider({
apiGatewayUrl,
keyId,
tokenId,
passphrase,
privateKey,
projectId,
tokenEndpoint,
})
const projectScopedToken = await authProvider.fetchProjectScopedToken()
Python
Build JSII python package
This is step is required, as python package is not published to pypi.org yet
git clone git@github.com:affinidi/affinidi-tdk.git
cd packages/auth-provider/
npm i --prefix .
npm run build
npm run package
Install Python package
After Build Step, run inside python virtual env
pip install dist/python/affinidi_tdk_auth_provider-0.1.4-py3-none-any.whl
Python package usage
import affinidi_tdk_auth_provider
stats = {
apiGatewayUrl,
keyId,
tokenId,
passphrase,
privateKey,
projectId,
tokenEndpoint,
}
authProvider = affinidi_tdk_auth_provider.AuthProvider(stats)
projectScopedToken = authProvider.fetch_project_scoped_token()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file affinidi_tdk_auth_provider-0.0.1.tar.gz
.
File metadata
- Download URL: affinidi_tdk_auth_provider-0.0.1.tar.gz
- Upload date:
- Size: 46.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f21db24fa415d1f7be66e200dd25b23ea0aa952663d4b6ca9a620d424d0e900b |
|
MD5 | 6a0bead97e795f7983b598719410ab0c |
|
BLAKE2b-256 | 8eb448796c1d7e9270aa39e988c8bebb6e8bca49a15bbe3b432ed0f2778cfd87 |
File details
Details for the file affinidi_tdk_auth_provider-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: affinidi_tdk_auth_provider-0.0.1-py3-none-any.whl
- Upload date:
- Size: 44.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 701480c04bbf8bac8258f4399d575cc8707a720b1358be11e1f9dadf3a93d949 |
|
MD5 | f9d61aa1034c94b2cc85865b10972d29 |
|
BLAKE2b-256 | eb275ad6f01b3723c5a6a80e712224f45a762d57d7c22e9da3fcd16886c877ca |