@hiregenius/utils
v4.1.0
Published
Utils service is for using firestore, google secret, salesforce, twilio modules.
Readme
Utils service
Utils service is for using firestore, google secret, salesforce, twilio modules.
Installation
yarn add @hiregenius/utilsUsage
Import the utils service inside the application module. Use it inside controllers & services & modules.
To use salesforce methods in services first you need to initialize SalesforceAuth: this.salesforceAuth = new SalesforceAuth( this.configService.get('DEFAULT_CONSUMER_KEY'), this.configService.get('NODE_ENV'), this.crypto, this.googleSecret, this.redisClass, this.configService.get('ADMIN_PRIVATE_KEY'), ); Then to create salesforce object like this: const sfClient = await SalesforceClient.createSalesforceClientObject( this.salesforceAuth, account, this.crypto, this.redisClass, ); Then use sfClient for all functions that needed.
