Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


The below configuration shows 2 objects inside the tenant configuration: URAC - Mail.

Code Block
languagejs
titleURAC Tenant Configuration Sample
linenumberstrue
{
   commonFields: {
     "mail"commonFields": {
        "from": 'me@localhost.com',
        "transport": {
           "type": "sendmail",
     	 "optionalAlgorithm": "aes256", //used by hasher
     "optionshashIterations": {}
        }
     }
   },
   "urac": {
12, //used by hasher
     "passportLoginmail": {

        "twitterfrom": {
            "clientID": "qywH8YMduIsKA2RRlUkS50kCZ",
   'me@localhost.com',
        "clientSecrettransport": "aodnXVCBijQcS8sJrcLM3ULgCl9VEoqqwu00XgamRUv5qm8bF1",
{
           "callbackURLtype": "http://local-widget.com/urac/login/successsendmail",
 
          userProfileURL: "https://api.twitter.com/1.1/account/verify_credentials.json?include_email=true"
         },
         "facebook "options": {}
            clientID: '331502413866510',}
     }
       clientSecret: '1a07a7eb9c9884dc5d148106ede830b2',
     },
      callbackURL: "http://local-widget.com/urac/login/success?mode=facebook"
         },
         "google": {

           clientID: '393278808961-7qahk8kadr2jhbo05o84pbp5tc774a1l.apps.googleusercontent.com',
            clientSecret: 'sdSpS8FLeUvc0UBs_z8m4f89',
            callbackURL: "http://local-widget.com/urac/login/success"
         }
      }"tokenExpiryTTL": 2 * 24 * 3600 * 1000,
      "hashIterationsvalidateJoin": 1024true, //usedtrue byif hasherregistration       "seedLength": 32, //used by hasher
needs validation
    
      "link": {
         "addUser": "http://dashboard.soajs.org/#/setNewPassword",
         "changeEmail": "http://dashboard.soajs.org/#/changeEmail/validate",
         "forgotPassword": "http://dashboard.soajs.org/#/resetPassword",
         "join": "http://dashboard.soajs.org/#/join/validate"
		....
      },
      "tokenExpiryTTL": 2 * 24 * 3600 * 1000,
      "validateJoin": true, //true if registration needs validation
      "mail": { //urac mail options
         "join": {
            "subject": 'Welcome to SOAJS',
            "path": "./mail/urac/join.tmpl"
         },
         "forgotPassword": {
            "subject": 'Reset Your Password at SOAJS',
            "path": "./mail/urac/forgotPassword.tmpl"
         },
         "addUser": {
            "subject": 'Account Created at SOAJS',
            "path": "./mail/urac/addUser.tmpl"
         },
         "changeUserStatus": {
            "subject": "Account Status changed at SOAJS",
            //use custom HTML
            "content": "<p>Dear <b>{{ username }}</b>, <br />Your account status has changed to <b>{{ status }}</b> by the administrator on {{ ts|date('F jS, Y') }}.<br /><br /> Regards,<br/> SOAJS Team. </p>"
         },
         "changeEmail": {
            "subject": "Change Account Email at SOAJS",
            "path": "./mail/urac/changeEmail.tmpl"
         },
		....
      }
   }
}