@samet-digital/open-id-client
v1.0.1
Published
OpenID client
Readme
Samet Digital : OpenID Client [Client]
▗▄▖ ▗▄▄▖ ▗▄▄▄▖▗▖ ▗▖ ▗▄▄▄▖▗▄▄▄ ▗▄▄▖▗▖ ▗▄▄▄▖▗▄▄▄▖▗▖ ▗▖▗▄▄▄▖
▐▌ ▐▌▐▌ ▐▌▐▌ ▐▛▚▖▐▌ █ ▐▌ █ ▐▌ ▐▌ █ ▐▌ ▐▛▚▖▐▌ █
▐▌ ▐▌▐▛▀▘ ▐▛▀▀▘▐▌ ▝▜▌ █ ▐▌ █ ▐▌ ▐▌ █ ▐▛▀▀▘▐▌ ▝▜▌ █
▝▚▄▞▘▐▌ ▐▙▄▄▖▐▌ ▐▌ ▗▄█▄▖▐▙▄▄▀ ▝▚▄▄▖▐▙▄▄▖▗▄█▄▖▐▙▄▄▖▐▌ ▐▌ █ EN: You can use it to connect Samet's Open ID service to generate or validate tokensTR: Samet'in login sistemine bağlanmak ve token üretmek yada gelen token'a doğrulamak için kullanınız
Usage
EN: How to add into your project?TR: Projene nasıl eklersin?
npm i @samet-digital/open-id-clientEnvironments
@see Config
| Name | Type | Default | Notes |
|--------------------------|----------|---------------------------|-------------------------------|
| SMT_OIDC_CLIENT_ID | string | none | SECRET |
| SMT_OIDC_CLIENT_SECRET | string | none | SECRET |
| SMT_OIDC_CLIENT_SCOPE | string | | default |
| SMT_OIDC_GRANT_TYPE | integer | client_credentials | default |
| SMT_OIDC_TEST_TOKENS | string[] | | Only experimental |
| SMT_OIDC_URL | string | http://localhost/openid | SMT_GNL_GATEWAY: |
Contents
- OidcService - OIDC Service
Dependency Injection - OidcModule - OIDC Module
Dependency Injection - openidClientConfig - OIDC configuration
- TokenMiddleware - token validating middleware
Dependency Injection
Development
You can start to develop on it
Step 1
EN: Go to your project folderTR: Bilgisayarında proje klasörüne git
# Windows
cd C:\\projects\samet-digital# Mac
cd /Users/{user}/projects/samet-digitalStep 2
EN: Clone the projectTR: Projeyi bilgisiyarına çek
git clone https://github.com/samet-digital/open-id-client.git -b developmentDependencies
- base-common -
samet-digital - api-common -
samet-digitalcontext and error usage - client-common -
samet-digitalhttp client usage
Commands
# Collects all dependencies
npm i
# Builds project dist (TS -> JS, src -> dist)
npm run build
# Publishes component on http://npmjs.com/
npm run publish:public
# Clears `dist` and `coverage` folders
npm run clear
# Clear `node_modules` folder
npm run clear:nm
# Validates lint for only errors @see (./eslint.config.mjs) for rules
npm run lint
# Validates lint with warnings
npm run lint:verbose
# Runs test cases
npm run test
# Exports coverage report, @see (./coverage/lcov-report/index.html)
npm run coverage
# Finds outdated/legacy dependencies
npm outdatedStandards
+ language: TS
+ lint: eslint
+ inspections: intelli-j code inspections
+ ddd: domain driven development
+ edd: exception driven development
! tdd: test driven development
+ ldd: log driven development
+ ddd: document driven developmentHistory
| Date | Developer | Info | Ticket | |------------|----------------|--------------|----------------| | 2025-04-15 | Mustafa Yelmer | Created | ~~none~~ | | 2025-08-09 | Mustafa Yelmer | Refactored | ~~none~~ | | 2025-08-14 | Mustafa Yelmer | Documented | ~~none~~ |
