Configuring YSoft SafeQ Job Service to support YSoft SAFEQ Cloud mobile app

For YSoft SafeQ Job Service to support the YSoft SAFEQ Cloud mobile application we have to add a new OpenID Client so the mobile application can sign in the user.

  1. Open YSoft SafeQ Job Service's local.json located in the configuration folder

  2. Find IdentityServerOptions section

    IdentityServerOptions section
    {
    "IdentityServerOptions": {
    }
    }
  3. Add new OpenID Connect client that is being used by the mobile application by adding following configuration as AdditionalClients section:

    Adding new client
    {
    "IdentityServerOptions": {
    "AdditionalClients": [
    {
    "ClientId": "mobile-application",
    "ClientName": "Mobile App",
    "RequireClientSecret": false,
    "AllowAccessTokensViaBrowser": true,
    "AllowedGrantTypes": [
    "authorization_code"
    ],
    "RequireConsent": false,
    "AllowOfflineAccess": true,
    "RedirectUris": [
    "safeq-app://logincallback"
    ],
    "PostLogoutRedirectUris": [
    "safeq-app://logoutcallback"
    ],
    "AllowedScopes": [
    "openid",
    "id_token",
    "profile",
    "jobs:create",
    "jobs:read"
    ],
    "AlwaysIncludeUserClaimsInIdToken": true,
    "AccessTokenLifetime": 3600
    }
    ]
    }
    }

  4. Restart YSoft SafeQ Job Service